Problem with diacritical characters in wPDF.

  • Hello,

    I have a text file I am parsing and am having
    an issue in wPDF with diacritical accent characters.

    Examples:

    Stähli in my text file looks like the following in wPDF,
    The ä becomes ä (ASCII char 195 / HEX C3) followed by
    (ASCII char 164 / HEX A4).

    Flösser in my text file looks like the following in wPDF,
    The ö becomes ö (ASCII char 195 / HEX C3) followed by
    (ASCII char 182 / HEX B6).

    This happens when I do a textout to my wPDF Canvas.

    I am using Delphi 5 with wPDF. I am new to this
    and using wPDF for the most part and would appreciate
    any and all help with this situation gettng resolved.

    Thank you for your attention to this critical issue
    for me.

    =====
    Sincerely,

    Kim Hovorka
    801-785-3669
    kimhovorka@yahoo.com

    • Offizieller Beitrag

    I mean the text out procedure.

    Here you have to set Canvas.Charset or use the Charset in the CreateFont procedure if you use that API. It is absolutely required to use a charset when creating text which is not ANSI - using 'Default Charset' is not enough since the PDF engine has otherwise no way to know which encoding should be used.

    Julian Ziersch