- Timestamp:
- May 24, 2001, 9:27:00 PM (24 years ago)
- Location:
- trunk/src/user32
- Files:
-
- 2 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/src/user32/text.cpp
r4825 r5796 1 /* $Id: text.cpp,v 1.1 0 2000-12-17 15:04:11sandervl Exp $ */1 /* $Id: text.cpp,v 1.11 2001-05-24 19:26:59 sandervl Exp $ */ 2 2 3 3 /* … … 30 30 INT WIN32API DrawTextW(HDC hDC,LPCWSTR lpString,INT nCount,PRECT lpRect,UINT nFormat) 31 31 { 32 dprintf(("USER32: DrawText W %x",hDC));32 dprintf(("USER32: DrawTextA %x %ls %d (%d,%d)(%d,%d) %x",hDC, lpString, nCount, lpRect->left, lpRect->top, lpRect->right, lpRect->bottom, nFormat)); 33 33 34 34 return InternalDrawTextExW(hDC,lpString,nCount,lpRect,nFormat,NULL,FALSE); … … 46 46 int WIN32API DrawTextExW(HDC hdc,LPWSTR lpchText,INT cchText,LPRECT lprc,UINT dwDTFormat,LPDRAWTEXTPARAMS lpDTParams) 47 47 { 48 dprintf(("USER32: DrawTextEx W %x",hdc));48 dprintf(("USER32: DrawTextExA %x %ls %d (%d,%d)(%d,%d) %x",hdc, lpchText, cchText, lprc->left, lprc->top, lprc->right, lprc->bottom, dwDTFormat)); 49 49 50 50 return InternalDrawTextExW(hdc,lpchText,cchText,lprc,dwDTFormat,lpDTParams,TRUE); -
trunk/src/user32/win32dlg.cpp
r5725 r5796 1 /* $Id: win32dlg.cpp,v 1.6 3 2001-05-17 09:50:30 sandervl Exp $ */1 /* $Id: win32dlg.cpp,v 1.64 2001-05-24 19:27:00 sandervl Exp $ */ 2 2 /* 3 3 * Win32 Dialog Code for OS/2 … … 83 83 /* and must be converted to pixels first */ 84 84 /* (see CreateFont() documentation in the Windows SDK). */ 85 HDC dc = GetDC(0); 86 int pixels = dlgInfo.pointSize * GetDeviceCaps(dc , LOGPIXELSY)/72; 87 ReleaseDC(0, dc); 85 int pixels; 86 if (((short)dlgInfo.pointSize) < 0) 87 pixels = -((short)dlgInfo.pointSize); 88 else 89 { 90 HDC hdc = GetDC(0); 91 pixels = dlgInfo.pointSize * GetDeviceCaps(hdc, LOGPIXELSY)/72; 92 ReleaseDC(0, hdc); 93 } 88 94 89 95 hUserFont = CreateFontW(-pixels, 0, 0, 0, … … 496 502 BOOL Win32Dialog::getCharSize( HFONT hUserFont, SIZE * pSize ) 497 503 { 498 HDC hDC = GetDC(0);504 HDC hDC = CreateCompatibleDC(0); 499 505 BOOL Success = getCharSizeFromDC( hDC, hUserFont, pSize ); 500 ReleaseDC(0,hDC);506 DeleteDC(hDC); 501 507 return Success; 502 508 }
Note:
See TracChangeset
for help on using the changeset viewer.