[fxruby-users] How can you bold the text in a label?

Paul Carvalho tester.paul at gmail.com
Thu Apr 15 12:30:43 EDT 2010

I'm not at my development computer right now so I can't tell you the exact
code I tried, but I can say that, yes, I did try to use a nil/empty string
font face and Ruby choked on it -- didn't like it.

I tried "system" as a font face and that *really* didn't do what I wanted
either! =)

I entered "arial" and then the one label font changed - I had forgotten that
the default system font is not Arial.  So the one label really stands out
now because it's a totally different font.. which is not what I want.

I don't want to hard-code a font that is different from the system font,
especially if the app will run on different platforms and I don't know what
the default fonts will be.

I can try some other variations tonight.  I've already spent over 4 hours on
this and haven't gotten it to work.  Maybe I just needed a break to see
something that I've missed.

I thought it would be something that would have come up by now.. I've seen
lots of apps where a label is bolded to indicate a required field.  I just
haven't found any FXRuby examples of this *without* also specifying the font
at the same time.

Cheers.  P.

2010/4/15 Bartosz Dziewoński :

> Have you tried to use nil/empty string font face and use font style
> hint "System"? Or try any font together with the hint?
> I haven't tried it myself, but according to docs it might work.
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://rubyforge.org/pipermail/fxruby-users/attachments/20100415/c35311fc/attachment.html>

More information about the fxruby-users mailing list