I am having problems with chars with accents making the rendering of text containing these chars compressed....
I have found the solution for this too...
In line 130 of file pdffontdatacore.cpp needs a (unsigned char) for correct mapping of table...
for (ch = t.begin(); ch != t.end(); ++ch)
{
- w += (*m_cw)[*ch];
+ w += (*m_cw)[(unsigned char)*ch];
}
Thanks
Maycon
Could you please tell which version and which build of wxWidgets you are using on which platform with which compiler?
I guess you are using an ANSI build since *ch returns a wxChar which is unsigned in Unicode build but potentially signed in ANSI build.
Since the key type of the underlying hash map m_cw is an unsigned integer type I would have expected that the conversion to unsigned would take place implicitly. I have to further investigate the issue. (Using unsigned char is not a general solution as in Unicode build wxChar is a wide character.)
For applications dealing with non-ASCII characters I would strongly recommend to use the Unicode build of wxWidgets.
In January I made a change to pdffontdatacore.cpp to fix a similar problem surfacing on OS X. Please get the latest version of the file from the wxCode SVN repository and check whether this solves your problem.