Bambookit Home    Bambookit GUI Tutorial

Back    Next   

II. GUI Basics

Chapter 9. Widgets Styles

Font Style

Method signature

setFontStyle = "[style]"
[style] sets the font style of the widget. Valid values are: plain, bolditalic, italic, bold, underline, boldunderline, italicunderline, bolditalicunderline.

NOTE: If set this property is inherited by its children.
Fonts settings are inherited by widgets from their container parents. Therefore, if you set font for the widget-containers, that font applies to the font of all widgets and nested containers, unless you override the settings. This also means that if you override the font setting of a nested container, then each of its widgets inherits the new font of that container.


In this example we will be using a button widget

.. setFontStyle="plain"

.. setFontStyle="bolditalic"

.. setFontStyle="italic"

.. setFontStyle="bold"

.. setFontStyle="underline"

.. setFontStyle="boldunderline"

.. setFontStyle="italicunderline"

.. setFontStyle="bolditalicunderline"

See also 'Font Size'

Back    Next