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,
The trace() is worse. The first one should be a win_skip() the second one a skip(), so:
if (!pGdiGetCodePage) { win_skip("GdiGetCodePage not available on this platform\n"); return; }
if (!is_font_installed( "Arial" ) ) { skip("Arial is not installed\n"); return; }
The win_skip() means we skip the test on Windows if this function is not present but it will fail on Wine if this function is not there(exported). This will make sure that nobody messes up this function .
The skip() will make sure we skip the tests on all platforms if Arial is not available.
For that second item. Isn't it enough to put the GetDC() before the for-loop and the ReleaseDC after the for-loop?