A GraphicsFont
is an adapter to allow using wx.Font
with a
GraphicsContext
when drawing text.
__init__ |
Constructs a new GraphicsFont . |
Apply |
Apply this font’s properties to the given context. |
CreateFromFont |
Create a ``GraphicsFont from a wx.Font . |
IsNull |
Brush |
A GraphicsBrush to use for filling the text when using this |
Colour |
The color to be associated with this font. It will be used as the |
PointSize |
The size in points of the font. |
GraphicsFont
(GraphicsObject)¶A GraphicsFont
is an adapter to allow using wx.Font
with a
GraphicsContext
when drawing text.
__init__
(self)¶Constructs a new GraphicsFont
.
Note
Currently user code should be using
CreateFromFont
instead of creating new GraphicsFont
instances themselves.
Apply
(self, ctx, colour)¶Apply this font’s properties to the given context.
Called by GraphicsContext
as needed.
CreateFromFont
(font, colour=None)¶Create a GraphicsFont from a :class:`wx.Font`.
Currently this is the only way to construct a ``GraphicsFont
.
Parameters: |
---|
IsNull
(self)¶Brush
¶A GraphicsBrush
to use for filling the text when using this
font. An alternative to using a plain colour.
Type: | GraphicsBrush |
---|
Colour
¶The color to be associated with this font. It will be used as the fill when drawing text with this font.
Type: | wx.Colour |
---|
PointSize
¶The size in points of the font.
Type: | int or float |
---|