lora:
LIST
OF
REF
ANY => {
nodeName: ROPE = NARROW[lora.first];
attributes: LIST OF REF ANY = NARROW[lora.rest.first];
width: REAL = ImagerFont.RopeEscapement[font: nameFont, rope: nodeName].x;
x: REAL ¬ -bounds.subWidth/2;
Imager.TranslateT[context, [0, -nameSkip]];
Imager.SetXY[context, [-width/2, 0]];
Imager.SetFont[context, nameFont];
Imager.ShowRope[context: context, rope: nodeName];
FOR a:
LIST
OF
REF
ANY ¬ attributes, a.rest.rest
UNTIL a =
NIL
DO
attributeName: ROPE = NARROW[a.first];
attributeValue: ROPE = RopeFromAttributeValue[a.rest.first];
rope: ROPE = Rope.Cat[attributeName, " ", attributeValue];
width: REAL = ImagerFont.RopeEscapement[font: attrFont, rope: rope].x;
Imager.TranslateT[context, [0, -attrSkip]];
Imager.SetXY[context, [-width/2, 0]];
Imager.SetFont[context, attrFont];
Imager.ShowRope[context: context, rope: attributeName];
Imager.ShowRope[context: context, rope: " "];
Imager.ShowRope[context: context, rope: attributeValue];
ENDLOOP;
FOR each:
LIST
OF
REF
ANY ¬ lora.rest.rest, each.rest
UNTIL each =
NIL
DO
subBounds: Bounds = GetBounds[each.first, boundsTable];
Inner:
PROC = {
Imager.TranslateT[context, [x, -bounds.vPad]];
PaintTree[context, each.first, boundsTable];
};
x ¬ x - subBounds.treeBounds.xmin;
Imager.MaskVector[context: context, p1: [0, -bearOff-maxDescent], p2: [x, bearOff-bounds.vPad]];
Imager.DoSave[context, Inner];
x ¬ x + subBounds.treeBounds.xmax + hPad;
ENDLOOP;
};
rope:
ROPE => {
Imager.SetXY[context, [bounds.nodeBounds.xmin, bounds.nodeBounds.ymin]];
Imager.SetFont[context, literalFont];
Imager.ShowRope[context: context, rope: rope];
};