- But is also unveils a rendering glitch. Now that invisible characters
are being printed as boxes, the Workspace now prints one of those empty boxes underneath your embedded morph. This is probably because an embedded morph is represented in a Text object by the Character value 2.
here is a handy method wrapping all is needed for anchoring a morph, returning a Text ready for display; the empty boxes are rendered invisible by setting their color to transparent.
Morph>>asAnchoredText
^ (Character value: 1) asText addAttribute: (TextAnchor new anchoredMorph: self) from: 1 to: 1; addAttribute: (TextColor color: Color transparent) from: 1 to: 1.
Stef