[NEWBIE] Can't change font encoding

Hi all,

I'm writing an ebook reader, and I have a custom class handling text drawing. The problem is that when I call wxDC::SetFont, the encoding stays the same. Here's the code snippet:

···

###############################################
font = wxFont(14, wxROMAN , wxNORMAL, wxNORMAL, false, 'Times New Roman', wxFONTENCODING_CP1251)

dc.SetFont(font)
###############################################

Other font attributes, i.e. size, family, and actual font do change. But font encoding has no effect. Is this a bug, or am I doing something wrong here?

Denis Treskunov wrote:

Hi all,

I'm writing an ebook reader, and I have a custom class handling text drawing. The problem is that when I call wxDC::SetFont, the encoding stays the same. Here's the code snippet:

###############################################
font = wxFont(14, wxROMAN , wxNORMAL, wxNORMAL, false, 'Times New Roman', wxFONTENCODING_CP1251)

dc.SetFont(font)
###############################################

Other font attributes, i.e. size, family, and actual font do change. But font encoding has no effect. Is this a bug, or am I doing something wrong here?

Platform and version?

···

--
Robin Dunn
Software Craftsman
http://wxPython.org Java give you jitters? Relax with wxPython!

I'm using Python 2.2.1, with wxPython version 2.3.3.1, on a WinXP Pro machine.

I'll try writing my code in c++ with wxWindows to see if it's related to wxPython.

Robin Dunn wrote:

···

Denis Treskunov wrote:

Hi all,

I'm writing an ebook reader, and I have a custom class handling text drawing. The problem is that when I call wxDC::SetFont, the encoding stays the same. Here's the code snippet:

###############################################
font = wxFont(14, wxROMAN , wxNORMAL, wxNORMAL, false, 'Times New Roman', wxFONTENCODING_CP1251)

dc.SetFont(font)
###############################################

Other font attributes, i.e. size, family, and actual font do change. But font encoding has no effect. Is this a bug, or am I doing something wrong here?

Platform and version?