Re: [resend2] gdi32/tests: Add a test for GdiGetCodePage().
On Sonntag 14 Dezember 2008, ByeongSik Jeon wrote:
http://bugs.winehq.org/show_bug.cgi?id=16325
2008-12-14 (Sun), 13:34 +0100, Paul Vriens wrote:
Could you turn the skip in this piece of code:
+ if (!pGdiGetCodePage) + { + skip("GdiGetCodePage not available on this platform\n"); + return; + }
into a win_skip? That way we fail if the function is not available in Wine.
I changed it to the trace().
Another thing I'm not sure about though is that in the for() loop you don't do a DeleteObject( hfont ). Is that only needed at the end?
Thanks.
--- dlls/gdi32/tests/Makefile.in | 2 +- dlls/gdi32/tests/font.c | 153 ++++++++++++++++++++++++++++++++++++++++++ 2 files changed, 154 insertions(+), 1 deletions(-)
Hi, some small style notes.
+ CHARSETINFO csi; + + if ( ( ansi_assoc == -1 || oem_assoc == -1 ) && + RegOpenKeyA ( HKEY_LOCAL_MACHINE, associated_charset, &hkey) == ERROR_SUCCESS ) + { + RegQueryInfoKeyA ( hkey, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, &max_data_len, NULL, NULL ); + data = HeapAlloc ( GetProcessHeap(), 0, max_data_len ); + please try to use similar spacing like other parts of the file no space before and after '(' when calling a function.
+ case MAC_CHARSET: + acp = GetACP(); + cp = ( acp == 932 || acp == 936 || acp == 949 || acp == 950 )? 1252 : CP_ACP; + break;
Please try to avoid trailing whitespace
+ JOHAB_CHARSET, + VISCII_CHARSET, + TCVN_CHARSET, + KOI8_CHARSET, + ISO3_CHARSET, + ISO4_CHARSET, + ISO10_CHARSET, + CELTIC_CHARSET,
also some trailing whitespace here. Thanks for you patch. Greetings Peter
participants (1)
-
Peter Oberndorfer