Make use of the DEFAULT_DEBUG_CHANNEL where appropriate.
Use the default version of FIXME, ERR, WARN, TRACE for the default
channel.
diff --git a/objects/font.c b/objects/font.c
index d1933db..c00f607 100644
--- a/objects/font.c
+++ b/objects/font.c
@@ -16,7 +16,7 @@
#include "winerror.h"
#include "dc.h"
-DECLARE_DEBUG_CHANNEL(font)
+DEFAULT_DEBUG_CHANNEL(font)
DECLARE_DEBUG_CHANNEL(gdi)
#define ENUM_UNICODE 0x00000001
@@ -319,25 +319,24 @@
fontPtr = (FONTOBJ *) GDI_HEAP_LOCK( hFont );
memcpy( &fontPtr->logfont, font, sizeof(LOGFONT16) );
- TRACE_(font)("(%i %i %i %i) '%s' %s %s => %04x\n",
- font->lfHeight, font->lfWidth,
- font->lfEscapement, font->lfOrientation,
- font->lfFaceName ? font->lfFaceName : "NULL",
- font->lfWeight > 400 ? "Bold" : "",
- font->lfItalic ? "Italic" : "",
- hFont);
+ TRACE("(%i %i %i %i) '%s' %s %s => %04x\n",
+ font->lfHeight, font->lfWidth,
+ font->lfEscapement, font->lfOrientation,
+ font->lfFaceName ? font->lfFaceName : "NULL",
+ font->lfWeight > 400 ? "Bold" : "",
+ font->lfItalic ? "Italic" : "", hFont);
if (font->lfEscapement != font->lfOrientation) {
/* this should really depend on whether GM_ADVANCED is set */
fontPtr->logfont.lfOrientation = fontPtr->logfont.lfEscapement;
- WARN_(font)(
- "orientation angle %f set to escapement angle %f for new font %04x\n",
- font->lfOrientation/10., font->lfEscapement/10., hFont);
+ WARN("orientation angle %f set to "
+ "escapement angle %f for new font %04x\n",
+ font->lfOrientation/10., font->lfEscapement/10., hFont);
}
GDI_HEAP_UNLOCK( hFont );
}
}
- else WARN_(font)("(NULL) => NULL\n");
+ else WARN("(NULL) => NULL\n");
return hFont;
}
@@ -375,8 +374,7 @@
{
LOGFONT16 logfont;
- TRACE_(font)("('%s',%d,%d)\n",
- (name ? name : "(null)") , height, width);
+ TRACE("('%s',%d,%d)\n", (name ? name : "(null)") , height, width);
logfont.lfHeight = height;
logfont.lfWidth = width;
@@ -877,9 +875,8 @@
!dc->funcs->pGetTextExtentPoint( dc, str, count, size ))
return FALSE;
- TRACE_(font)("(%08x %s %d %p): returning %d,%d\n",
- hdc, debugstr_an (str, count), count,
- size, size->cx, size->cy );
+ TRACE("(%08x %s %d %p): returning %d,%d\n",
+ hdc, debugstr_an (str, count), count, size, size->cx, size->cy );
return TRUE;
}
@@ -922,7 +919,7 @@
BOOL WINAPI GetTextExtentPointA( HDC hdc, LPCSTR str, INT count,
LPSIZE size )
{
- TRACE_(font)("not bug compatible.\n");
+ TRACE("not bug compatible.\n");
return GetTextExtentPoint32A( hdc, str, count, size );
}
@@ -932,7 +929,7 @@
BOOL WINAPI GetTextExtentPointW( HDC hdc, LPCWSTR str, INT count,
LPSIZE size )
{
- TRACE_(font)("not bug compatible.\n");
+ TRACE("not bug compatible.\n");
return GetTextExtentPoint32W( hdc, str, count, size );
}
@@ -972,8 +969,8 @@
size->cx = extent;
*lpnFit = nFit;
- TRACE_(font)("(%08x '%.*s' %d) returning %d %d %d\n",
- hdc,count,str,maxExt,nFit, size->cx,size->cy);
+ TRACE("(%08x '%.*s' %d) returning %d %d %d\n",
+ hdc,count,str,maxExt,nFit, size->cx,size->cy);
return TRUE;
}
@@ -1049,26 +1046,26 @@
metrics->tmMaxCharWidth = WDPTOLP(metrics->tmMaxCharWidth);
metrics->tmOverhang = WDPTOLP(metrics->tmOverhang);
- TRACE_(font)("text metrics:\n"
- " Weight = %03li\t FirstChar = %03i\t AveCharWidth = %li\n"
- " Italic = % 3i\t LastChar = %03i\t\t MaxCharWidth = %li\n"
- " UnderLined = %01i\t DefaultChar = %03i\t Overhang = %li\n"
- " StruckOut = %01i\t BreakChar = %03i\t CharSet = %i\n"
- " PitchAndFamily = %02x\n"
- " --------------------\n"
- " InternalLeading = %li\n"
- " Ascent = %li\n"
- " Descent = %li\n"
- " Height = %li\n",
- metrics->tmWeight, metrics->tmFirstChar, metrics->tmAveCharWidth,
- metrics->tmItalic, metrics->tmLastChar, metrics->tmMaxCharWidth,
- metrics->tmUnderlined, metrics->tmDefaultChar, metrics->tmOverhang,
- metrics->tmStruckOut, metrics->tmBreakChar, metrics->tmCharSet,
- metrics->tmPitchAndFamily,
- metrics->tmInternalLeading,
- metrics->tmAscent,
- metrics->tmDescent,
- metrics->tmHeight );
+ TRACE("text metrics:\n"
+ " Weight = %03li\t FirstChar = %03i\t AveCharWidth = %li\n"
+ " Italic = % 3i\t LastChar = %03i\t\t MaxCharWidth = %li\n"
+ " UnderLined = %01i\t DefaultChar = %03i\t Overhang = %li\n"
+ " StruckOut = %01i\t BreakChar = %03i\t CharSet = %i\n"
+ " PitchAndFamily = %02x\n"
+ " --------------------\n"
+ " InternalLeading = %li\n"
+ " Ascent = %li\n"
+ " Descent = %li\n"
+ " Height = %li\n",
+ metrics->tmWeight, metrics->tmFirstChar, metrics->tmAveCharWidth,
+ metrics->tmItalic, metrics->tmLastChar, metrics->tmMaxCharWidth,
+ metrics->tmUnderlined, metrics->tmDefaultChar, metrics->tmOverhang,
+ metrics->tmStruckOut, metrics->tmBreakChar, metrics->tmCharSet,
+ metrics->tmPitchAndFamily,
+ metrics->tmInternalLeading,
+ metrics->tmAscent,
+ metrics->tmDescent,
+ metrics->tmHeight );
return TRUE;
}
@@ -1100,7 +1097,7 @@
UINT16 cbData, /* [in] Size of metric data array */
LPOUTLINETEXTMETRIC16 lpOTM) /* [out] Address of metric data array */
{
- FIXME_(font)("(%04x,%04x,%p): stub\n", hdc,cbData,lpOTM);
+ FIXME("(%04x,%04x,%p): stub\n", hdc,cbData,lpOTM);
return 0;
}
@@ -1183,7 +1180,7 @@
UINT cbData, /* [in] Size of metric data array */
LPOUTLINETEXTMETRICW lpOTM) /* [out] Address of metric data array */
{
- FIXME_(font)("(%d,%d,%p): stub\n", hdc, cbData, lpOTM);
+ FIXME("(%d,%d,%p): stub\n", hdc, cbData, lpOTM);
return 0;
}
@@ -1284,7 +1281,7 @@
if(dc->funcs->pSetMapperFlags)
ret = dc->funcs->pSetMapperFlags( dc, dwFlag );
else
- FIXME_(font)("(0x%04x, 0x%08lx): stub - harmless\n", hDC, dwFlag);
+ FIXME("(0x%04x, 0x%08lx): stub - harmless\n", hDC, dwFlag);
GDI_HEAP_UNLOCK( hDC );
return ret;
}
@@ -1294,8 +1291,7 @@
*/
BOOL16 WINAPI GetAspectRatioFilterEx16( HDC16 hdc, LPSIZE16 pAspectRatio )
{
- FIXME_(font)("(%04x, %p): -- Empty Stub !\n",
- hdc, pAspectRatio);
+ FIXME("(%04x, %p): -- Empty Stub !\n", hdc, pAspectRatio);
return FALSE;
}
@@ -1304,8 +1300,7 @@
*/
BOOL WINAPI GetAspectRatioFilterEx( HDC hdc, LPSIZE pAspectRatio )
{
- FIXME_(font)("(%04x, %p): -- Empty Stub !\n",
- hdc, pAspectRatio);
+ FIXME("(%04x, %p): -- Empty Stub !\n", hdc, pAspectRatio);
return FALSE;
}
@@ -1354,7 +1349,7 @@
LPABC abc )
{
/* No TrueType fonts in Wine so far */
- FIXME_(font)("(%04x,%04x,%04x,%p): stub\n", hdc, firstChar, lastChar, abc);
+ FIXME("(%04x,%04x,%04x,%p): stub\n", hdc, firstChar, lastChar, abc);
return FALSE;
}
@@ -1366,7 +1361,7 @@
LPGLYPHMETRICS16 lpgm, DWORD cbBuffer,
LPVOID lpBuffer, const MAT2 *lpmat2 )
{
- FIXME_(font)("(%04x, '%c', %04x, %p, %ld, %p, %p): stub\n",
+ FIXME("(%04x, '%c', %04x, %p, %ld, %p, %p): stub\n",
hdc, uChar, fuFormat, lpgm, cbBuffer, lpBuffer, lpmat2 );
return (DWORD)-1; /* failure */
}
@@ -1379,7 +1374,7 @@
LPGLYPHMETRICS lpgm, DWORD cbBuffer,
LPVOID lpBuffer, const MAT2 *lpmat2 )
{
- FIXME_(font)("(%04x, '%c', %04x, %p, %ld, %p, %p): stub\n",
+ FIXME("(%04x, '%c', %04x, %p, %ld, %p, %p): stub\n",
hdc, uChar, fuFormat, lpgm, cbBuffer, lpBuffer, lpmat2 );
return (DWORD)-1; /* failure */
}
@@ -1391,7 +1386,7 @@
LPGLYPHMETRICS lpgm, DWORD cbBuffer,
LPVOID lpBuffer, const MAT2 *lpmat2 )
{
- FIXME_(font)("(%04x, '%c', %04x, %p, %ld, %p, %p): stub\n",
+ FIXME("(%04x, '%c', %04x, %p, %ld, %p, %p): stub\n",
hdc, uChar, fuFormat, lpgm, cbBuffer, lpBuffer, lpmat2 );
return (DWORD)-1; /* failure */
}
@@ -1419,7 +1414,7 @@
* enumbered with EnumFonts/EnumFontFamilies
* lpszCurrentPath can be NULL
*/
- FIXME_(font)("(%ld,%s,%s,%s): stub\n",
+ FIXME("(%ld,%s,%s,%s): stub\n",
fHidden, lpszResourceFile, lpszFontFile, lpszCurrentPath );
return FALSE; /* create failed */
}
@@ -1432,7 +1427,7 @@
LPCWSTR lpszFontFile,
LPCWSTR lpszCurrentPath )
{
- FIXME_(font)("(%ld,%p,%p,%p): stub\n",
+ FIXME("(%ld,%p,%p,%p): stub\n",
fHidden, lpszResourceFile, lpszFontFile, lpszCurrentPath );
return FALSE; /* create failed */
}
@@ -1467,8 +1462,7 @@
{
/* At this time kerning is ignored (set to 0) */
int i;
- FIXME_(font)("(%x,%d,%p): almost empty stub!\n",
- hDC, cPairs, lpKerningPairs);
+ FIXME("(%x,%d,%p): almost empty stub!\n", hDC, cPairs, lpKerningPairs);
for (i = 0; i < cPairs; i++)
lpKerningPairs[i].iKernAmount = 0;
return 0;
@@ -1483,8 +1477,7 @@
LPKERNINGPAIR lpKerningPairs )
{
int i;
- FIXME_(font)("(%x,%ld,%p): almost empty stub!\n",
- hDC, cPairs, lpKerningPairs);
+ FIXME("(%x,%ld,%p): almost empty stub!\n", hDC, cPairs, lpKerningPairs);
for (i = 0; i < cPairs; i++)
lpKerningPairs[i].iKernAmount = 0;
return 0;
@@ -1548,7 +1541,7 @@
*/
DWORD WINAPI GetFontLanguageInfo(HDC hdc) {
/* return value 0 is correct for most cases anyway */
- FIXME_(font)("(%x):stub!\n", hdc);
+ FIXME("(%x):stub!\n", hdc);
return 0;
}
@@ -1557,7 +1550,7 @@
*/
DWORD WINAPI GetFontLanguageInfo16(HDC16 hdc) {
/* return value 0 is correct for most cases anyway */
- FIXME_(font)("(%x):stub!\n",hdc);
+ FIXME("(%x):stub!\n",hdc);
return 0;
}
@@ -1580,8 +1573,7 @@
DWORD WINAPI GetFontData(HDC hdc, DWORD table, DWORD offset,
LPVOID buffer, DWORD length)
{
- FIXME_(font)("(%x,%ld,%ld,%p,%ld): stub\n",
- hdc, table, offset, buffer, length);
+ FIXME("(%x,%ld,%ld,%p,%ld): stub\n", hdc, table, offset, buffer, length);
SetLastError(ERROR_CALL_NOT_IMPLEMENTED);
return GDI_ERROR;
}
@@ -1610,18 +1602,19 @@
DWORD ret=0;
SIZE size;
- TRACE_(font)("%s 0x%08x 0x%08x 0x%08lx:stub!\n",
- debugstr_a(lpString), uCount, nMaxExtent, dwFlags);
+ TRACE("%s 0x%08x 0x%08x 0x%08lx:stub!\n",
+ debugstr_a(lpString), uCount, nMaxExtent, dwFlags);
- TRACE_(font)("lpOrder=%p lpDx=%p lpCaretPos=%p lpClass=%p lpOutString=%p lpGlyphs=%p\n",
- lpResults->lpOrder, lpResults->lpDx, lpResults->lpCaretPos, lpResults->lpClass,
- lpResults->lpOutString, lpResults->lpGlyphs);
+ TRACE("lpOrder=%p lpDx=%p lpCaretPos=%p lpClass=%p "
+ "lpOutString=%p lpGlyphs=%p\n",
+ lpResults->lpOrder, lpResults->lpDx, lpResults->lpCaretPos,
+ lpResults->lpClass, lpResults->lpOutString, lpResults->lpGlyphs);
- if(dwFlags) FIXME_(font)("flags 0x%08lx ignored\n", dwFlags);
- if(lpResults->lpOrder) FIXME_(font)("reordering not implemented\n");
- if(lpResults->lpCaretPos) FIXME_(font)("caret positions not implemented\n");
- if(lpResults->lpClass) FIXME_(font)("classes not implemented\n");
- if(lpResults->lpGlyphs) FIXME_(font)("glyphs not implemented\n");
+ if(dwFlags) FIXME("flags 0x%08lx ignored\n", dwFlags);
+ if(lpResults->lpOrder) FIXME("reordering not implemented\n");
+ if(lpResults->lpCaretPos) FIXME("caret positions not implemented\n");
+ if(lpResults->lpClass) FIXME("classes not implemented\n");
+ if(lpResults->lpGlyphs) FIXME("glyphs not implemented\n");
/* copy will do if the GCP_REORDER flag is not set */
if(lpResults->lpOutString)
@@ -1654,7 +1647,7 @@
DWORD dwFlags)
{
/* return value 0 is correct for most cases anyway */
- FIXME_(font)(":stub!\n");
+ FIXME(":stub!\n");
return 0;
}