Never mind, apparently I have to draw the underline manually. On Sat, Sep 19, 2015 at 3:38 AM, Peter Uhnák <i.uhnak@gmail.com> wrote:
Hi,
is it currently possible to draw underlined text onto AthensCanvas?
~~~~~~~~~~~~~~~~~~~~~~~~~~~~ |font view| font := TextStyle defaultFont. font := font emphasized: TextEmphasis underlined emphasisCode. "<- underline does NOT work" "font := font emphasized: TextEmphasis bold emphasisCode." "<- bold works"
view := AthensSceneView new.
view scene: [:canvas | canvas surface clear: Color black. canvas setFont: font. canvas setPaint: Color red. canvas drawString: font asString. ]. view openInWindow. ~~~~~~~~~~~~~~~~~~~~~~~~~~~~
I managed to find this previous discussion, however that is related more to Morphic http://forum.world.st/FreeType-fonts-and-underline-strikethrough-emphasis-td... https://pharo.fogbugz.com/f/cases/15362/
or maybe it's the same?
This also doesn't work for StringMorph (as mentioned in the linked discussion), however TextMorph seems to work just fine..
Thanks, Peter