flat assembler
Message board for the users of flat assembler.

Index > Macroinstructions > [BUG] GDI32.INC font handling equates are Unicode

Author
Thread Post new topic Reply to topic
revolution
When all else fails, read the source


Joined: 24 Aug 2004
Posts: 17665
Location: In your JS exploiting you and your system
revolution
See the code for the 10 places where db needs to be replaced with TCHAR
Code:
struct TEXTMETRIC
  tmHeight             dd ?
  tmAscent      dd ?
  tmDescent             dd ?
  tmInternalLeading  dd ?
  tmExternalLeading  dd ?
  tmAveCharWidth     dd ?
  tmMaxCharWidth     dd ?
  tmWeight          dd ?
  tmOverhang            dd ?
  tmDigitizedAspectX dd ?
  tmDigitizedAspectY dd ?
  tmFirstChar         TCHAR ?            ;<<<---- Variable character width
  tmLastChar           TCHAR ?            ;<<<---- Variable character width
  tmDefaultChar      TCHAR ?              ;<<<---- Variable character width
  tmBreakChar          TCHAR ?            ;<<<---- Variable character width
  tmItalic             db ?
  tmUnderlined          db ?
  tmStruckOut           db ?
  tmPitchAndFamily   db ?
  tmCharSet        db ?
ends

struct LOGFONT
  lfHeight      dd ?
  lfWidth       dd ?
  lfEscapement          dd ?
  lfOrientation    dd ?
  lfWeight           dd ?
  lfItalic      db ?
  lfUnderline           db ?
  lfStrikeOut           db ?
  lfCharSet     db ?
  lfOutPrecision   db ?
  lfClipPrecision  db ?
  lfQuality       db ?
  lfPitchAndFamily db ?
  lfFaceName         TCHAR 32 dup (?)     ;<<<---- Variable character width
ends

struct ENUMLOGFONT
  elfLogFont  LOGFONT
  elfFullName TCHAR 64 dup (?)         ;<<<---- Variable character width
  elfStyle    TCHAR 32 dup (?)            ;<<<---- Variable character width
ends

struct ENUMLOGFONTEX
  elfLogFont  LOGFONT
  elfFullName TCHAR 64 dup (?)               ;<<<---- Variable character width
  elfStyle    TCHAR 32 dup (?)            ;<<<---- Variable character width
  elfScript   TCHAR 32 dup (?)            ;<<<---- Variable character width
ends    
Post 02 Aug 2010, 13:50
View user's profile Send private message Visit poster's website Reply with quote
Display posts from previous:
Post new topic Reply to topic

Jump to:  


< Last Thread | Next Thread >
Forum Rules:
You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum
You cannot vote in polls in this forum
You cannot attach files in this forum
You can download files in this forum


Copyright © 1999-2020, Tomasz Grysztar. Also on GitHub, YouTube, Twitter.

Website powered by rwasa.