Fredrik, It looks like you have not received a reply yet. Does this help?
font: ((TextStyle named: #Atlanta ) fontOfSize: 14) jrm On Fri, Sep 4, 2015 at 3:51 PM, Fredrik Alink <fal...@free.fr> wrote: > Hi, > > I got a nice way of creating button Morphs somewhere on the Web. However, > for showing the button label it uses the StringMorph. In StringMorph I find > the method “font: aFont”. Could I use that for setting the Font shown on > the > button? And what should I use as aFont? Doing “aFont := TextMorph new …..” > is wrong. Are there other ways to get to an alternative of the default font > through the StringMorph? > > What I did so far: > > *My Class instance:* > labelMorph := (ButtonElementMorph “new”) > createLabelMorph: aLabel > withEmphasis: anEmphasis > /withFont: aFont./ > > What I found on the web – *ButtonElementMorph Class instance:* > (StringMorph contents: aLabel) > emphasis: anEmphasis; > /font: aFont./ > > *StringMorph class instance:* > emphasis: anEmphasis. > /font: aFont/ “can I use this and what should I place here?” > > Thank you in advance for giving me th right direction to find a solution! > > Fredrik > > > > > -- > View this message in context: > http://forum.world.st/How-to-set-a-Font-in-a-StringMorph-tp4848183.html > Sent from the Squeak - Beginners mailing list archive at Nabble.com. > _______________________________________________ > Beginners mailing list > Beginners@lists.squeakfoundation.org > http://lists.squeakfoundation.org/mailman/listinfo/beginners >
_______________________________________________ Beginners mailing list Beginners@lists.squeakfoundation.org http://lists.squeakfoundation.org/mailman/listinfo/beginners