]> git.saurik.com Git - wxWidgets.git/blob - wxPython/samples/wxPIA_book/Chapter-09/font_box.py
fixed wxVsnprintf() to write as much as it can if the output buffer is too short
[wxWidgets.git] / wxPython / samples / wxPIA_book / Chapter-09 / font_box.py
1 import wx
2
3 if __name__ == "__main__":
4 app = wx.PySimpleApp()
5 dialog = wx.FontDialog(None, wx.FontData())
6 if dialog.ShowModal() == wx.ID_OK:
7 data = dialog.GetFontData()
8 font = data.GetChosenFont()
9 colour = data.GetColour()
10 print 'You selected: "%s", %d points\n' % (
11 font.GetFaceName(), font.GetPointSize())
12 dialog.Destroy()
13
14
15
16