blob: aefd2280e55c0630f631befc295db153886b26ea (
plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
|
# font.py
import wx
class Font(wx.Font):
def __init__(self, name, size, italic=0, bold=0, underline=0):
wx.Font.__init__(self, size, wx.DEFAULT, italic and wx.ITALIC or wx.NORMAL,
bold and wx.BOLD or wx.NORMAL, underline, name)
def IsItalic(self):
return bool(self.GetStyle() & wx.ITALIC)
def IsBold(self):
return bool(self.GetWeight() & wx.BOLD)
def IsUnderlined(self):
return self.GetUnderlined()
|