| 1 | /* $Id: gdi32.cpp,v 1.45 2000-02-24 19:17:15 sandervl Exp $ */ | 
|---|
| 2 |  | 
|---|
| 3 | /* | 
|---|
| 4 | * GDI32 apis | 
|---|
| 5 | * | 
|---|
| 6 | * Copyright 1998 Sander van Leeuwen (sandervl@xs4all.nl) | 
|---|
| 7 | * Copyright 1998 Patrick Haller | 
|---|
| 8 | * | 
|---|
| 9 | * Project Odin Software License can be found in LICENSE.TXT | 
|---|
| 10 | * | 
|---|
| 11 | */ | 
|---|
| 12 | #include <os2win.h> | 
|---|
| 13 | #include <stdlib.h> | 
|---|
| 14 | #include <stdarg.h> | 
|---|
| 15 | #include <string.h> | 
|---|
| 16 | #include "misc.h" | 
|---|
| 17 | #include "callback.h" | 
|---|
| 18 | #include "unicode.h" | 
|---|
| 19 | #include "dibsect.h" | 
|---|
| 20 | #include <codepage.h> | 
|---|
| 21 | #include "oslibgpi.h" | 
|---|
| 22 | #include "oslibgdi.h" | 
|---|
| 23 |  | 
|---|
| 24 | #define DBG_LOCALLOG    DBG_gdi32 | 
|---|
| 25 | #include "dbglocal.h" | 
|---|
| 26 |  | 
|---|
| 27 | //****************************************************************************** | 
|---|
| 28 | //****************************************************************************** | 
|---|
| 29 | BOOL WIN32API GetTextExtentPointA(HDC hdc, LPCSTR lpsz, int cbString, LPSIZE lpSize) | 
|---|
| 30 | { | 
|---|
| 31 | BOOL rc; | 
|---|
| 32 |  | 
|---|
| 33 | lpSize->cx = lpSize->cy = 0; | 
|---|
| 34 | rc = O32_GetTextExtentPoint(hdc, lpsz, cbString, lpSize); | 
|---|
| 35 | dprintf(("GDI32: GetTextExtentPointA of %s returned %d\n", lpsz, rc)); | 
|---|
| 36 | return(rc); | 
|---|
| 37 | } | 
|---|
| 38 | //****************************************************************************** | 
|---|
| 39 | //****************************************************************************** | 
|---|
| 40 | COLORREF WIN32API SetBkColor(HDC hdc, COLORREF crColor) | 
|---|
| 41 | { | 
|---|
| 42 | dprintf(("GDI32: SetBkColor to %X\n", crColor)); | 
|---|
| 43 | return(O32_SetBkColor(hdc, crColor)); | 
|---|
| 44 | } | 
|---|
| 45 | //****************************************************************************** | 
|---|
| 46 | //****************************************************************************** | 
|---|
| 47 | COLORREF WIN32API SetTextColor(HDC hdc, COLORREF crColor) | 
|---|
| 48 | { | 
|---|
| 49 | COLORREF clr; | 
|---|
| 50 |  | 
|---|
| 51 | clr = O32_SetTextColor(hdc, crColor); | 
|---|
| 52 | dprintf(("GDI32: SetTextColor from %X to %X\n", clr, crColor)); | 
|---|
| 53 | return(clr); | 
|---|
| 54 | } | 
|---|
| 55 | //****************************************************************************** | 
|---|
| 56 | //****************************************************************************** | 
|---|
| 57 |  | 
|---|
| 58 | static hFntDefaultGui = NULL; | 
|---|
| 59 | HGDIOBJ WIN32API GetStockObject(int arg1) | 
|---|
| 60 | { | 
|---|
| 61 | HGDIOBJ obj; | 
|---|
| 62 |  | 
|---|
| 63 | switch(arg1) | 
|---|
| 64 | { | 
|---|
| 65 | case DEFAULT_GUI_FONT: | 
|---|
| 66 | if(NULL==hFntDefaultGui) | 
|---|
| 67 | hFntDefaultGui = CreateFontA( 9, 0, 0, 0, FW_MEDIUM, FALSE, | 
|---|
| 68 | FALSE, FALSE, ANSI_CHARSET, | 
|---|
| 69 | OUT_DEFAULT_PRECIS, | 
|---|
| 70 | CLIP_DEFAULT_PRECIS, | 
|---|
| 71 | DEFAULT_QUALITY, | 
|---|
| 72 | FIXED_PITCH|FF_MODERN, "WarpSans"); | 
|---|
| 73 | obj = hFntDefaultGui; | 
|---|
| 74 | break; | 
|---|
| 75 | default: | 
|---|
| 76 | obj = O32_GetStockObject(arg1); | 
|---|
| 77 | break; | 
|---|
| 78 | } | 
|---|
| 79 | dprintf(("GDI32: GetStockObject %d returned %X\n", arg1, obj)); | 
|---|
| 80 | return(obj); | 
|---|
| 81 | } | 
|---|
| 82 | //****************************************************************************** | 
|---|
| 83 | //****************************************************************************** | 
|---|
| 84 | int WIN32API GetObjectA( HGDIOBJ hObject, int size, void *lpBuffer) | 
|---|
| 85 | { | 
|---|
| 86 | int rc; | 
|---|
| 87 |  | 
|---|
| 88 | if(size == 0 || lpBuffer == NULL) { | 
|---|
| 89 | SetLastError(ERROR_INVALID_PARAMETER); | 
|---|
| 90 | return 0; | 
|---|
| 91 | } | 
|---|
| 92 |  | 
|---|
| 93 | if(DIBSection::getSection() != NULL) | 
|---|
| 94 | { | 
|---|
| 95 | DIBSection *dsect = DIBSection::find(hObject); | 
|---|
| 96 | if(dsect) | 
|---|
| 97 | { | 
|---|
| 98 | rc = dsect->GetDIBSection(size, lpBuffer); | 
|---|
| 99 | if(rc == 0) { | 
|---|
| 100 | SetLastError(ERROR_INVALID_PARAMETER); | 
|---|
| 101 | return 0; | 
|---|
| 102 | } | 
|---|
| 103 | SetLastError(ERROR_SUCCESS); | 
|---|
| 104 | return rc; | 
|---|
| 105 | } | 
|---|
| 106 | } | 
|---|
| 107 |  | 
|---|
| 108 | dprintf(("GDI32: GetObject %X %X %X\n", hObject, size, lpBuffer)); | 
|---|
| 109 | return O32_GetObject(hObject, size, lpBuffer); | 
|---|
| 110 | } | 
|---|
| 111 | //****************************************************************************** | 
|---|
| 112 | //****************************************************************************** | 
|---|
| 113 | int WIN32API GetObjectW( HGDIOBJ arg1, int arg2, void *  arg3) | 
|---|
| 114 | { | 
|---|
| 115 | dprintf(("GDI32: GetObjectW %X, %d %X not complete!", arg1, arg2, arg3)); | 
|---|
| 116 | return GetObjectA(arg1, arg2, arg3); | 
|---|
| 117 | } | 
|---|
| 118 | //****************************************************************************** | 
|---|
| 119 | //****************************************************************************** | 
|---|
| 120 | DWORD WIN32API GetObjectType( HGDIOBJ arg1) | 
|---|
| 121 | { | 
|---|
| 122 | dprintf2(("GDI32: GetObjectType\n")); | 
|---|
| 123 | return O32_GetObjectType(arg1); | 
|---|
| 124 | } | 
|---|
| 125 | //****************************************************************************** | 
|---|
| 126 | //****************************************************************************** | 
|---|
| 127 | BOOL WIN32API DeleteObject(HANDLE hObj) | 
|---|
| 128 | { | 
|---|
| 129 | dprintf(("GDI32: DeleteObject %x", hObj)); | 
|---|
| 130 | DIBSection::deleteSection((DWORD)hObj); | 
|---|
| 131 | return O32_DeleteObject(hObj); | 
|---|
| 132 | } | 
|---|
| 133 | //****************************************************************************** | 
|---|
| 134 | //****************************************************************************** | 
|---|
| 135 | BOOL WIN32API DeleteDC( HDC hdc) | 
|---|
| 136 | { | 
|---|
| 137 | dprintf(("GDI32: DeleteDC %x", hdc)); | 
|---|
| 138 | return O32_DeleteDC(hdc); | 
|---|
| 139 | } | 
|---|
| 140 | //****************************************************************************** | 
|---|
| 141 | //****************************************************************************** | 
|---|
| 142 | HBRUSH WIN32API CreatePatternBrush(HBITMAP arg1) | 
|---|
| 143 | { | 
|---|
| 144 | HBRUSH brush; | 
|---|
| 145 |  | 
|---|
| 146 | brush = O32_CreatePatternBrush(arg1); | 
|---|
| 147 | dprintf(("GDI32: CreatePatternBrush from bitmap %X returned %X\n", arg1, brush)); | 
|---|
| 148 | return(brush); | 
|---|
| 149 | } | 
|---|
| 150 | //****************************************************************************** | 
|---|
| 151 | //****************************************************************************** | 
|---|
| 152 | HPEN WIN32API CreatePen( int fnPenStyle, int nWidth, COLORREF crColor) | 
|---|
| 153 | { | 
|---|
| 154 | dprintf(("GDI32: CreatePen\n")); | 
|---|
| 155 |  | 
|---|
| 156 | //CB: todo: PS_DOT is different in Win32 (. . . . and not - - - -) | 
|---|
| 157 | //    Open32 looks like LINETYPE_SHORTDASH instead of LINETYPE_DOT!!! | 
|---|
| 158 | //    -> difficult to fix without performance decrease! | 
|---|
| 159 |  | 
|---|
| 160 | return O32_CreatePen(fnPenStyle,nWidth,crColor); | 
|---|
| 161 | } | 
|---|
| 162 | //****************************************************************************** | 
|---|
| 163 | //****************************************************************************** | 
|---|
| 164 | HPEN WIN32API CreatePenIndirect( const LOGPEN * lplgpn) | 
|---|
| 165 | { | 
|---|
| 166 | dprintf(("GDI32: CreatePenIndirect\n")); | 
|---|
| 167 | return O32_CreatePenIndirect(lplgpn); | 
|---|
| 168 | } | 
|---|
| 169 | //****************************************************************************** | 
|---|
| 170 | //****************************************************************************** | 
|---|
| 171 | HBRUSH WIN32API CreateDIBPatternBrushPt( const VOID * arg1, UINT  arg2) | 
|---|
| 172 | { | 
|---|
| 173 | dprintf(("GDI32: CreateDIBPatternBrushPt\n")); | 
|---|
| 174 | return O32_CreateDIBPatternBrushPt(arg1, arg2); | 
|---|
| 175 | } | 
|---|
| 176 | //****************************************************************************** | 
|---|
| 177 | //****************************************************************************** | 
|---|
| 178 | HDC WIN32API CreateCompatibleDC( HDC hdc) | 
|---|
| 179 | { | 
|---|
| 180 | HDC newHdc; | 
|---|
| 181 |  | 
|---|
| 182 | newHdc = O32_CreateCompatibleDC(hdc); | 
|---|
| 183 | ULONG oldcp = OSLibGpiQueryCp(hdc); | 
|---|
| 184 | if (!oldcp) /* If new DC is to be created */ | 
|---|
| 185 | oldcp = GetDisplayCodepage(); | 
|---|
| 186 |  | 
|---|
| 187 | OSLibGpiSetCp(newHdc, oldcp); | 
|---|
| 188 | dprintf(("CreateCompatibleDC %X returned %x", hdc, newHdc)); | 
|---|
| 189 | return newHdc; | 
|---|
| 190 | } | 
|---|
| 191 | //****************************************************************************** | 
|---|
| 192 | //****************************************************************************** | 
|---|
| 193 | INT WIN32API StretchDIBits(HDC hdc, INT xDst, INT yDst, INT widthDst, | 
|---|
| 194 | INT heightDst, INT xSrc, INT ySrc, INT widthSrc, | 
|---|
| 195 | INT heightSrc, const void *bits, | 
|---|
| 196 | const BITMAPINFO *info, UINT wUsage, DWORD dwRop ) | 
|---|
| 197 | { | 
|---|
| 198 | #if 1 | 
|---|
| 199 | dprintf(("GDI32: StretchDIBits %x to (%d,%d) (%d,%d) from (%d,%d) (%d,%d), %x %x %x %x", hdc, xDst, yDst, widthDst, heightDst, xSrc, ySrc, widthSrc, heightSrc, bits, info, wUsage, dwRop)); | 
|---|
| 200 |  | 
|---|
| 201 | if(wUsage == DIB_PAL_COLORS && info->bmiHeader.biSize == sizeof(BITMAPINFOHEADER)) | 
|---|
| 202 | { | 
|---|
| 203 | // workaround for open32 bug. | 
|---|
| 204 | // If syscolors > 256 and wUsage == DIB_PAL_COLORS. | 
|---|
| 205 |  | 
|---|
| 206 | int i; | 
|---|
| 207 | USHORT *pColorIndex = (USHORT *)info->bmiColors; | 
|---|
| 208 | RGBQUAD *pColors = (RGBQUAD *) alloca(info->bmiHeader.biClrUsed * | 
|---|
| 209 | sizeof(RGBQUAD)); | 
|---|
| 210 | BITMAPINFO *infoLoc = (BITMAPINFO *) alloca(sizeof(BITMAPINFO) + | 
|---|
| 211 | info->bmiHeader.biClrUsed * sizeof(RGBQUAD)); | 
|---|
| 212 |  | 
|---|
| 213 | memcpy(infoLoc, info, sizeof(BITMAPINFO)); | 
|---|
| 214 |  | 
|---|
| 215 | if(GetDIBColorTable(hdc, 0, info->bmiHeader.biClrUsed, pColors) == 0) | 
|---|
| 216 | return FALSE; | 
|---|
| 217 |  | 
|---|
| 218 | for(i=0;i<info->bmiHeader.biClrUsed;i++, pColorIndex++) | 
|---|
| 219 | { | 
|---|
| 220 | infoLoc->bmiColors[i] = pColors[*pColorIndex]; | 
|---|
| 221 | } | 
|---|
| 222 |  | 
|---|
| 223 | return O32_StretchDIBits(hdc, xDst, yDst, widthDst, heightDst, xSrc, ySrc, | 
|---|
| 224 | widthSrc, heightSrc, (void *)bits, | 
|---|
| 225 | (PBITMAPINFO)infoLoc, DIB_RGB_COLORS, dwRop); | 
|---|
| 226 | } | 
|---|
| 227 |  | 
|---|
| 228 | return O32_StretchDIBits(hdc, xDst, yDst, widthDst, heightDst, xSrc, ySrc, | 
|---|
| 229 | widthSrc, heightSrc, (void *)bits, | 
|---|
| 230 | (PBITMAPINFO)info, wUsage, dwRop); | 
|---|
| 231 | #else | 
|---|
| 232 | dprintf(("GDI32: StretchDIBits\n")); | 
|---|
| 233 | return O32_StretchDIBits(arg1, arg2, arg3, arg4, arg5, arg6, arg7, arg8, arg9, (void *)arg10, (PBITMAPINFO)arg11, arg12, arg13); | 
|---|
| 234 | #endif | 
|---|
| 235 | } | 
|---|
| 236 | //****************************************************************************** | 
|---|
| 237 | //****************************************************************************** | 
|---|
| 238 | BOOL WIN32API StrokeAndFillPath( HDC arg1) | 
|---|
| 239 | { | 
|---|
| 240 | dprintf(("GDI32: StrokeAndFillPath\n")); | 
|---|
| 241 | return O32_StrokeAndFillPath(arg1); | 
|---|
| 242 | } | 
|---|
| 243 | //****************************************************************************** | 
|---|
| 244 | //****************************************************************************** | 
|---|
| 245 | BOOL WIN32API StrokePath( HDC arg1) | 
|---|
| 246 | { | 
|---|
| 247 | dprintf(("GDI32: StrokePath\n")); | 
|---|
| 248 | return O32_StrokePath(arg1); | 
|---|
| 249 | } | 
|---|
| 250 | //****************************************************************************** | 
|---|
| 251 | //****************************************************************************** | 
|---|
| 252 | HGDIOBJ WIN32API SelectObject(HDC hdc, HGDIOBJ hObj) | 
|---|
| 253 | { | 
|---|
| 254 | HGDIOBJ rc; | 
|---|
| 255 |  | 
|---|
| 256 | dprintf2(("GDI32: SelectObject %x %x", hdc, hObj)); | 
|---|
| 257 |  | 
|---|
| 258 | if(DIBSection::getSection() != NULL) | 
|---|
| 259 | { | 
|---|
| 260 | DIBSection *dsect; | 
|---|
| 261 |  | 
|---|
| 262 | dsect = DIBSection::find(hdc); | 
|---|
| 263 | if(dsect) | 
|---|
| 264 | { | 
|---|
| 265 | //remove previously selected dibsection | 
|---|
| 266 | dsect->UnSelectDIBObject(); | 
|---|
| 267 | } | 
|---|
| 268 | dsect = DIBSection::find((DWORD)hObj); | 
|---|
| 269 | if(dsect) | 
|---|
| 270 | { | 
|---|
| 271 | dsect->SelectDIBObject(hdc); | 
|---|
| 272 | } | 
|---|
| 273 | } | 
|---|
| 274 | rc = O32_SelectObject(hdc, hObj); | 
|---|
| 275 | if(rc != 0 && DIBSection::getSection != NULL) | 
|---|
| 276 | { | 
|---|
| 277 | DIBSection *dsect = DIBSection::find((DWORD)rc); | 
|---|
| 278 | if(dsect) | 
|---|
| 279 | { | 
|---|
| 280 | dsect->UnSelectDIBObject(); | 
|---|
| 281 | } | 
|---|
| 282 | } | 
|---|
| 283 | return(rc); | 
|---|
| 284 | } | 
|---|
| 285 | //****************************************************************************** | 
|---|
| 286 | //****************************************************************************** | 
|---|
| 287 | int WIN32API SetBkMode( HDC arg1, int  arg2) | 
|---|
| 288 | { | 
|---|
| 289 | dprintf(("GDI32: SetBkMode\n")); | 
|---|
| 290 | return O32_SetBkMode(arg1, arg2); | 
|---|
| 291 | } | 
|---|
| 292 | //****************************************************************************** | 
|---|
| 293 | //****************************************************************************** | 
|---|
| 294 | COLORREF WIN32API GetPixel( HDC arg1, int arg2, int  arg3) | 
|---|
| 295 | { | 
|---|
| 296 | ////    dprintf(("GDI32: GetPixel\n")); | 
|---|
| 297 | return O32_GetPixel(arg1, arg2, arg3); | 
|---|
| 298 | } | 
|---|
| 299 | //****************************************************************************** | 
|---|
| 300 | //****************************************************************************** | 
|---|
| 301 | COLORREF WIN32API SetPixel( HDC arg1, int arg2, int arg3, COLORREF  arg4) | 
|---|
| 302 | { | 
|---|
| 303 | ////    dprintf(("GDI32: SetPixel\n")); | 
|---|
| 304 | return O32_SetPixel(arg1, arg2, arg3, arg4); | 
|---|
| 305 | } | 
|---|
| 306 | //****************************************************************************** | 
|---|
| 307 | //Faster version of SetPixel (since it doesn't need to return the original color) | 
|---|
| 308 | //Just use SetPixel for now | 
|---|
| 309 | //****************************************************************************** | 
|---|
| 310 | BOOL WIN32API SetPixelV(HDC arg1, int arg2, int arg3, COLORREF  arg4) | 
|---|
| 311 | { | 
|---|
| 312 | COLORREF rc; | 
|---|
| 313 |  | 
|---|
| 314 | ////    dprintf(("GDI32: SetPixelV\n")); | 
|---|
| 315 | rc = O32_SetPixel(arg1, arg2, arg3, arg4); | 
|---|
| 316 | if(rc == GDI_ERROR) // || rc == COLOR_INVALID) | 
|---|
| 317 | return(FALSE); | 
|---|
| 318 | return(TRUE); | 
|---|
| 319 | } | 
|---|
| 320 | //****************************************************************************** | 
|---|
| 321 | //****************************************************************************** | 
|---|
| 322 | BOOL WIN32API GetDCOrgEx(HDC arg1, PPOINT arg2) | 
|---|
| 323 | { | 
|---|
| 324 | dprintf(("GDI32: GetDCOrgEx\n")); | 
|---|
| 325 | return O32_GetDCOrgEx(arg1, arg2); | 
|---|
| 326 | } | 
|---|
| 327 | //****************************************************************************** | 
|---|
| 328 | //****************************************************************************** | 
|---|
| 329 | BOOL WIN32API GetWindowExtEx(HDC arg1, PSIZE arg2) | 
|---|
| 330 | { | 
|---|
| 331 | dprintf(("GDI32: GetWindowExtEx\n")); | 
|---|
| 332 | return O32_GetWindowExtEx(arg1, arg2); | 
|---|
| 333 | } | 
|---|
| 334 | //****************************************************************************** | 
|---|
| 335 | //****************************************************************************** | 
|---|
| 336 | int WIN32API AbortDoc( HDC arg1) | 
|---|
| 337 | { | 
|---|
| 338 | dprintf(("GDI32: AbortDoc")); | 
|---|
| 339 | return O32_AbortDoc(arg1); | 
|---|
| 340 | } | 
|---|
| 341 | //****************************************************************************** | 
|---|
| 342 | //****************************************************************************** | 
|---|
| 343 | BOOL WIN32API AbortPath( HDC arg1) | 
|---|
| 344 | { | 
|---|
| 345 | dprintf(("GDI32: AbortPath")); | 
|---|
| 346 | return O32_AbortPath(arg1); | 
|---|
| 347 | } | 
|---|
| 348 | //****************************************************************************** | 
|---|
| 349 | //****************************************************************************** | 
|---|
| 350 | BOOL WIN32API AngleArc( HDC arg1, int arg2, int arg3, DWORD arg4, float  arg5, float  arg6) | 
|---|
| 351 | { | 
|---|
| 352 | dprintf(("GDI32: AngleArc")); | 
|---|
| 353 | return O32_AngleArc(arg1, arg2, arg3, arg4, arg5, arg6); | 
|---|
| 354 | } | 
|---|
| 355 | //****************************************************************************** | 
|---|
| 356 | //****************************************************************************** | 
|---|
| 357 | BOOL WIN32API Arc( HDC arg1, int arg2, int arg3, int arg4, int arg5, int arg6, int arg7, int arg8, int  arg9) | 
|---|
| 358 | { | 
|---|
| 359 | dprintf(("GDI32: Arc")); | 
|---|
| 360 | return O32_Arc(arg1, arg2, arg3, arg4, arg5, arg6, arg7, arg8, arg9); | 
|---|
| 361 | } | 
|---|
| 362 | //****************************************************************************** | 
|---|
| 363 | //****************************************************************************** | 
|---|
| 364 | BOOL WIN32API ArcTo( HDC arg1, int arg2, int arg3, int arg4, int arg5, int  arg6, int  arg7, int  arg8, int  arg9) | 
|---|
| 365 | { | 
|---|
| 366 | dprintf(("GDI32: ArcTo")); | 
|---|
| 367 | return O32_ArcTo(arg1, arg2, arg3, arg4, arg5, arg6, arg7, arg8, arg9); | 
|---|
| 368 | } | 
|---|
| 369 | //****************************************************************************** | 
|---|
| 370 | //****************************************************************************** | 
|---|
| 371 | BOOL WIN32API BeginPath( HDC arg1) | 
|---|
| 372 | { | 
|---|
| 373 | dprintf(("GDI32: BeginPath")); | 
|---|
| 374 | return O32_BeginPath(arg1); | 
|---|
| 375 | } | 
|---|
| 376 | //****************************************************************************** | 
|---|
| 377 | //****************************************************************************** | 
|---|
| 378 | BOOL WIN32API Chord( HDC arg1, int arg2, int arg3, int arg4, int arg5, int  arg6, int  arg7, int  arg8, int  arg9) | 
|---|
| 379 | { | 
|---|
| 380 | dprintf(("GDI32: Chord")); | 
|---|
| 381 | return O32_Chord(arg1, arg2, arg3, arg4, arg5, arg6, arg7, arg8, arg9); | 
|---|
| 382 | } | 
|---|
| 383 | //****************************************************************************** | 
|---|
| 384 | //****************************************************************************** | 
|---|
| 385 | BOOL WIN32API CloseFigure( HDC arg1) | 
|---|
| 386 | { | 
|---|
| 387 | dprintf(("GDI32: CloseFigure")); | 
|---|
| 388 | return O32_CloseFigure(arg1); | 
|---|
| 389 | } | 
|---|
| 390 | //****************************************************************************** | 
|---|
| 391 | //****************************************************************************** | 
|---|
| 392 | HBRUSH WIN32API CreateBrushIndirect( const LOGBRUSH * arg1) | 
|---|
| 393 | { | 
|---|
| 394 | dprintf(("GDI32: CreateBrushIndirect")); | 
|---|
| 395 | return O32_CreateBrushIndirect((LPLOGBRUSH)arg1); | 
|---|
| 396 | } | 
|---|
| 397 | //****************************************************************************** | 
|---|
| 398 | //****************************************************************************** | 
|---|
| 399 | HDC WIN32API CreateDCA(LPCSTR lpszDriver, LPCSTR lpszDevice, LPCSTR lpszOutput, const DEVMODEA *lpInitData) | 
|---|
| 400 | { | 
|---|
| 401 | HDC hdc; | 
|---|
| 402 |  | 
|---|
| 403 | hdc = O32_CreateDC(lpszDriver, lpszDevice, lpszOutput, lpInitData); | 
|---|
| 404 | dprintf(("GDI32: CreateDCA %s %s %s %x returned %x", lpszDriver, lpszDevice, lpszOutput, lpInitData, hdc)); | 
|---|
| 405 | return hdc; | 
|---|
| 406 | } | 
|---|
| 407 | //****************************************************************************** | 
|---|
| 408 | //****************************************************************************** | 
|---|
| 409 | HDC WIN32API CreateDCW( LPCWSTR arg1, LPCWSTR arg2, LPCWSTR arg3, const DEVMODEW * arg4) | 
|---|
| 410 | { | 
|---|
| 411 | char *astring4, *astring5; | 
|---|
| 412 |  | 
|---|
| 413 | char *astring1 = UnicodeToAsciiString((LPWSTR)arg1); | 
|---|
| 414 | char *astring2 = UnicodeToAsciiString((LPWSTR)arg2); | 
|---|
| 415 | char *astring3 = UnicodeToAsciiString((LPWSTR)arg3); | 
|---|
| 416 |  | 
|---|
| 417 | if(arg4) | 
|---|
| 418 | { | 
|---|
| 419 | astring4 = UnicodeToAsciiString((LPWSTR)(arg4->dmDeviceName)); | 
|---|
| 420 | astring5 = UnicodeToAsciiString((LPWSTR)(arg4->dmFormName)); | 
|---|
| 421 | } | 
|---|
| 422 |  | 
|---|
| 423 | HDC   rc; | 
|---|
| 424 | DEVMODEA devmode; | 
|---|
| 425 |  | 
|---|
| 426 | dprintf(("GDI32: CreateDCW")); | 
|---|
| 427 |  | 
|---|
| 428 | if(arg4) | 
|---|
| 429 | { | 
|---|
| 430 | strcpy((char*)devmode.dmDeviceName, astring4); | 
|---|
| 431 | strcpy((char*)devmode.dmFormName, astring5); | 
|---|
| 432 |  | 
|---|
| 433 | devmode.dmSpecVersion      = arg4->dmSpecVersion; | 
|---|
| 434 | devmode.dmDriverVersion    = arg4->dmDriverVersion; | 
|---|
| 435 | devmode.dmSize             = arg4->dmSize; | 
|---|
| 436 | devmode.dmDriverExtra      = arg4->dmDriverExtra; | 
|---|
| 437 | devmode.dmFields           = arg4->dmFields; | 
|---|
| 438 | devmode.dmOrientation      = arg4->dmOrientation; | 
|---|
| 439 | devmode.dmPaperSize        = arg4->dmPaperSize; | 
|---|
| 440 | devmode.dmPaperLength      = arg4->dmPaperLength; | 
|---|
| 441 | devmode.dmPaperWidth       = arg4->dmPaperWidth; | 
|---|
| 442 | devmode.dmScale            = arg4->dmScale; | 
|---|
| 443 | devmode.dmCopies           = arg4->dmCopies; | 
|---|
| 444 | devmode.dmDefaultSource    = arg4->dmDefaultSource; | 
|---|
| 445 | devmode.dmPrintQuality     = arg4->dmPrintQuality; | 
|---|
| 446 | devmode.dmColor            = arg4->dmColor; | 
|---|
| 447 | devmode.dmDuplex           = arg4->dmDuplex; | 
|---|
| 448 | devmode.dmYResolution      = arg4->dmYResolution; | 
|---|
| 449 | devmode.dmTTOption         = arg4->dmTTOption; | 
|---|
| 450 | devmode.dmCollate          = arg4->dmCollate; | 
|---|
| 451 | devmode.dmLogPixels        = arg4->dmLogPixels; | 
|---|
| 452 | devmode.dmBitsPerPel       = arg4->dmBitsPerPel; | 
|---|
| 453 | devmode.dmPelsWidth        = arg4->dmPelsWidth; | 
|---|
| 454 | devmode.dmPelsHeight       = arg4->dmPelsHeight; | 
|---|
| 455 | devmode.dmDisplayFlags     = arg4->dmDisplayFlags; | 
|---|
| 456 | devmode.dmDisplayFrequency = arg4->dmDisplayFrequency; | 
|---|
| 457 | devmode.dmICMMethod        = arg4->dmICMMethod; | 
|---|
| 458 | devmode.dmICMIntent        = arg4->dmICMIntent; | 
|---|
| 459 | devmode.dmMediaType        = arg4->dmMediaType; | 
|---|
| 460 | devmode.dmDitherType       = arg4->dmDitherType; | 
|---|
| 461 | devmode.dmReserved1        = arg4->dmReserved1; | 
|---|
| 462 | devmode.dmReserved2        = arg4->dmReserved2; | 
|---|
| 463 | rc = O32_CreateDC(astring1,astring2,astring3,&devmode); | 
|---|
| 464 | } | 
|---|
| 465 | else | 
|---|
| 466 | rc = O32_CreateDC(astring1,astring2,astring3, NULL); | 
|---|
| 467 |  | 
|---|
| 468 | FreeAsciiString(astring1); | 
|---|
| 469 | FreeAsciiString(astring2); | 
|---|
| 470 | FreeAsciiString(astring3); | 
|---|
| 471 |  | 
|---|
| 472 | if(arg4) | 
|---|
| 473 | { | 
|---|
| 474 | FreeAsciiString(astring4); | 
|---|
| 475 | FreeAsciiString(astring5); | 
|---|
| 476 | } | 
|---|
| 477 |  | 
|---|
| 478 | return rc; | 
|---|
| 479 | } | 
|---|
| 480 | //****************************************************************************** | 
|---|
| 481 | //****************************************************************************** | 
|---|
| 482 | HBRUSH WIN32API CreateHatchBrush( int arg1, COLORREF  arg2) | 
|---|
| 483 | { | 
|---|
| 484 | dprintf(("GDI32: CreateHatchBrush")); | 
|---|
| 485 | return O32_CreateHatchBrush(arg1, arg2); | 
|---|
| 486 | } | 
|---|
| 487 | //****************************************************************************** | 
|---|
| 488 | //****************************************************************************** | 
|---|
| 489 | HDC WIN32API CreateICA(LPCSTR lpszDriver, LPCSTR lpszDevice, LPCSTR lpszOutput, | 
|---|
| 490 | const DEVMODEA *lpdvmInit) | 
|---|
| 491 | { | 
|---|
| 492 | static char *szDisplay = "DISPLAY"; | 
|---|
| 493 |  | 
|---|
| 494 | dprintf(("GDI32: CreateICA")); | 
|---|
| 495 | //SvL: Open32 tests for "DISPLAY" | 
|---|
| 496 | if(lpszDriver && !strcmp(lpszDriver, "display")) { | 
|---|
| 497 | lpszDriver = szDisplay; | 
|---|
| 498 | } | 
|---|
| 499 | //SvL: Open32 tests lpszDriver for NULL even though it's ignored | 
|---|
| 500 | if(lpszDriver == NULL) { | 
|---|
| 501 | lpszDriver = lpszDevice; | 
|---|
| 502 | } | 
|---|
| 503 | return O32_CreateIC(lpszDriver, lpszDevice, lpszOutput, lpdvmInit); | 
|---|
| 504 | } | 
|---|
| 505 | //****************************************************************************** | 
|---|
| 506 | //****************************************************************************** | 
|---|
| 507 | HDC WIN32API CreateICW( LPCWSTR arg1, LPCWSTR arg2, LPCWSTR arg3, const DEVMODEW * arg4) | 
|---|
| 508 | { | 
|---|
| 509 | char *astring4, *astring5; | 
|---|
| 510 |  | 
|---|
| 511 | char *astring1 = UnicodeToAsciiString((LPWSTR)arg1); | 
|---|
| 512 | char *astring2 = UnicodeToAsciiString((LPWSTR)arg2); | 
|---|
| 513 | char *astring3 = UnicodeToAsciiString((LPWSTR)arg3); | 
|---|
| 514 | if(arg4) | 
|---|
| 515 | { | 
|---|
| 516 | astring4 = UnicodeToAsciiString((LPWSTR)(arg4->dmDeviceName)); | 
|---|
| 517 | astring5 = UnicodeToAsciiString((LPWSTR)(arg4->dmFormName)); | 
|---|
| 518 | } | 
|---|
| 519 |  | 
|---|
| 520 | HDC   rc; | 
|---|
| 521 | DEVMODEA devmode; | 
|---|
| 522 |  | 
|---|
| 523 | dprintf(("GDI32: CreateICW")); | 
|---|
| 524 |  | 
|---|
| 525 | if(arg4) | 
|---|
| 526 | { | 
|---|
| 527 | strcpy((char*)devmode.dmDeviceName, astring4); | 
|---|
| 528 | strcpy((char*)devmode.dmFormName, astring5); | 
|---|
| 529 |  | 
|---|
| 530 | devmode.dmSpecVersion      = arg4->dmSpecVersion; | 
|---|
| 531 | devmode.dmDriverVersion    = arg4->dmDriverVersion; | 
|---|
| 532 | devmode.dmSize             = arg4->dmSize; | 
|---|
| 533 | devmode.dmDriverExtra      = arg4->dmDriverExtra; | 
|---|
| 534 | devmode.dmFields           = arg4->dmFields; | 
|---|
| 535 | devmode.dmOrientation      = arg4->dmOrientation; | 
|---|
| 536 | devmode.dmPaperSize        = arg4->dmPaperSize; | 
|---|
| 537 | devmode.dmPaperLength      = arg4->dmPaperLength; | 
|---|
| 538 | devmode.dmPaperWidth       = arg4->dmPaperWidth; | 
|---|
| 539 | devmode.dmScale            = arg4->dmScale; | 
|---|
| 540 | devmode.dmCopies           = arg4->dmCopies; | 
|---|
| 541 | devmode.dmDefaultSource    = arg4->dmDefaultSource; | 
|---|
| 542 | devmode.dmPrintQuality     = arg4->dmPrintQuality; | 
|---|
| 543 | devmode.dmColor            = arg4->dmColor; | 
|---|
| 544 | devmode.dmDuplex           = arg4->dmDuplex; | 
|---|
| 545 | devmode.dmYResolution      = arg4->dmYResolution; | 
|---|
| 546 | devmode.dmTTOption         = arg4->dmTTOption; | 
|---|
| 547 | devmode.dmCollate          = arg4->dmCollate; | 
|---|
| 548 | devmode.dmLogPixels        = arg4->dmLogPixels; | 
|---|
| 549 | devmode.dmBitsPerPel       = arg4->dmBitsPerPel; | 
|---|
| 550 | devmode.dmPelsWidth        = arg4->dmPelsWidth; | 
|---|
| 551 | devmode.dmPelsHeight       = arg4->dmPelsHeight; | 
|---|
| 552 | devmode.dmDisplayFlags     = arg4->dmDisplayFlags; | 
|---|
| 553 | devmode.dmDisplayFrequency = arg4->dmDisplayFrequency; | 
|---|
| 554 | devmode.dmICMMethod        = arg4->dmICMMethod; | 
|---|
| 555 | devmode.dmICMIntent        = arg4->dmICMIntent; | 
|---|
| 556 | devmode.dmMediaType        = arg4->dmMediaType; | 
|---|
| 557 | devmode.dmDitherType       = arg4->dmDitherType; | 
|---|
| 558 | devmode.dmReserved1        = arg4->dmReserved1; | 
|---|
| 559 | devmode.dmReserved2        = arg4->dmReserved2; | 
|---|
| 560 |  | 
|---|
| 561 | rc = CreateICA(astring1,astring2,astring3,&devmode); | 
|---|
| 562 | } | 
|---|
| 563 | else | 
|---|
| 564 | rc = CreateICA(astring1,astring2,astring3, NULL); | 
|---|
| 565 |  | 
|---|
| 566 | FreeAsciiString(astring1); | 
|---|
| 567 | FreeAsciiString(astring2); | 
|---|
| 568 | FreeAsciiString(astring3); | 
|---|
| 569 | if(arg4) | 
|---|
| 570 | { | 
|---|
| 571 | FreeAsciiString(astring4); | 
|---|
| 572 | FreeAsciiString(astring5); | 
|---|
| 573 | } | 
|---|
| 574 |  | 
|---|
| 575 | return rc; | 
|---|
| 576 | } | 
|---|
| 577 | //****************************************************************************** | 
|---|
| 578 | //****************************************************************************** | 
|---|
| 579 | HBRUSH WIN32API CreateSolidBrush( COLORREF arg1) | 
|---|
| 580 | { | 
|---|
| 581 | dprintf(("GDI32: CreateSolidBrush\n")); | 
|---|
| 582 | return O32_CreateSolidBrush(arg1); | 
|---|
| 583 | } | 
|---|
| 584 | //****************************************************************************** | 
|---|
| 585 | //****************************************************************************** | 
|---|
| 586 | BOOL WIN32API DPtoLP( HDC arg1, PPOINT arg2, int  arg3) | 
|---|
| 587 | { | 
|---|
| 588 | dprintf(("GDI32: DPtoLP\n")); | 
|---|
| 589 | return O32_DPtoLP(arg1, arg2, arg3); | 
|---|
| 590 | } | 
|---|
| 591 | //****************************************************************************** | 
|---|
| 592 | //****************************************************************************** | 
|---|
| 593 | BOOL WIN32API Ellipse( HDC arg1, int arg2, int arg3, int arg4, int  arg5) | 
|---|
| 594 | { | 
|---|
| 595 | dprintf(("GDI32: Ellipse")); | 
|---|
| 596 | return O32_Ellipse(arg1, arg2, arg3, arg4, arg5); | 
|---|
| 597 | } | 
|---|
| 598 | //****************************************************************************** | 
|---|
| 599 | //****************************************************************************** | 
|---|
| 600 | int WIN32API EndDoc( HDC arg1) | 
|---|
| 601 | { | 
|---|
| 602 | dprintf(("GDI32: EndDoc")); | 
|---|
| 603 | return O32_EndDoc(arg1); | 
|---|
| 604 | } | 
|---|
| 605 | //****************************************************************************** | 
|---|
| 606 | //****************************************************************************** | 
|---|
| 607 | int WIN32API EndPage( HDC arg1) | 
|---|
| 608 | { | 
|---|
| 609 | dprintf(("GDI32: EndPage")); | 
|---|
| 610 | return O32_EndPage(arg1); | 
|---|
| 611 | } | 
|---|
| 612 | //****************************************************************************** | 
|---|
| 613 | //****************************************************************************** | 
|---|
| 614 | BOOL WIN32API EndPath( HDC arg1) | 
|---|
| 615 | { | 
|---|
| 616 | dprintf(("GDI32: EndPath")); | 
|---|
| 617 | return O32_EndPath(arg1); | 
|---|
| 618 | } | 
|---|
| 619 | //****************************************************************************** | 
|---|
| 620 | //****************************************************************************** | 
|---|
| 621 | BOOL WIN32API Rectangle( HDC arg1, int arg2, int arg3, int arg4, int  arg5) | 
|---|
| 622 | { | 
|---|
| 623 | dprintf(("GDI32: Rectangle\n")); | 
|---|
| 624 | return O32_Rectangle(arg1, arg2, arg3, arg4, arg5); | 
|---|
| 625 | } | 
|---|
| 626 | //****************************************************************************** | 
|---|
| 627 | //****************************************************************************** | 
|---|
| 628 | int WIN32API SetROP2( HDC hdc, int rop2) | 
|---|
| 629 | { | 
|---|
| 630 | dprintf(("GDI32: SetROP2 %x %x", hdc, rop2)); | 
|---|
| 631 | return O32_SetROP2(hdc, rop2); | 
|---|
| 632 | } | 
|---|
| 633 | //****************************************************************************** | 
|---|
| 634 | //****************************************************************************** | 
|---|
| 635 | int WIN32API EnumObjects( HDC arg1, int arg2, GOBJENUMPROC arg3, LPARAM  arg4) | 
|---|
| 636 | { | 
|---|
| 637 | dprintf(("GDI32: EnumObjects STUB")); | 
|---|
| 638 | //calling convention differences | 
|---|
| 639 | //    return O32_EnumObjects(arg1, arg2, arg3, arg4); | 
|---|
| 640 | return 0; | 
|---|
| 641 | } | 
|---|
| 642 | //****************************************************************************** | 
|---|
| 643 | //****************************************************************************** | 
|---|
| 644 | int WIN32API Escape( HDC arg1, int arg2, int arg3, LPCSTR arg4, PVOID  arg5) | 
|---|
| 645 | { | 
|---|
| 646 | dprintf(("GDI32: Escape")); | 
|---|
| 647 | return O32_Escape(arg1, arg2, arg3, arg4, arg5); | 
|---|
| 648 | } | 
|---|
| 649 | //****************************************************************************** | 
|---|
| 650 | //****************************************************************************** | 
|---|
| 651 | int WIN32API ExcludeClipRect( HDC arg1, int arg2, int arg3, int arg4, int  arg5) | 
|---|
| 652 | { | 
|---|
| 653 | dprintf(("GDI32: ExcludeClipRect")); | 
|---|
| 654 | return O32_ExcludeClipRect(arg1, arg2, arg3, arg4, arg5); | 
|---|
| 655 | } | 
|---|
| 656 | //****************************************************************************** | 
|---|
| 657 | //****************************************************************************** | 
|---|
| 658 | HPEN WIN32API ExtCreatePen( DWORD arg1, DWORD arg2, const LOGBRUSH * arg3, DWORD arg4, const DWORD *  arg5) | 
|---|
| 659 | { | 
|---|
| 660 | dprintf(("GDI32: ExtCreatePen")); | 
|---|
| 661 | return O32_ExtCreatePen(arg1, arg2, arg3, arg4, arg5); | 
|---|
| 662 | } | 
|---|
| 663 | //****************************************************************************** | 
|---|
| 664 | //****************************************************************************** | 
|---|
| 665 | BOOL WIN32API ExtFloodFill( HDC arg1, int arg2, int arg3, COLORREF arg4, UINT  arg5) | 
|---|
| 666 | { | 
|---|
| 667 | dprintf(("GDI32: ExtFloodFill")); | 
|---|
| 668 | return O32_ExtFloodFill(arg1, arg2, arg3, arg4, arg5); | 
|---|
| 669 | } | 
|---|
| 670 | //****************************************************************************** | 
|---|
| 671 | //****************************************************************************** | 
|---|
| 672 | BOOL WIN32API FillPath( HDC arg1) | 
|---|
| 673 | { | 
|---|
| 674 | dprintf(("GDI32: FillPath")); | 
|---|
| 675 | return O32_FillPath(arg1); | 
|---|
| 676 | } | 
|---|
| 677 | //****************************************************************************** | 
|---|
| 678 | //****************************************************************************** | 
|---|
| 679 | BOOL WIN32API FlattenPath( HDC arg1) | 
|---|
| 680 | { | 
|---|
| 681 | dprintf(("GDI32: FlattenPath")); | 
|---|
| 682 | return O32_FlattenPath(arg1); | 
|---|
| 683 | } | 
|---|
| 684 | //****************************************************************************** | 
|---|
| 685 | //****************************************************************************** | 
|---|
| 686 | BOOL WIN32API FloodFill(HDC arg1, int arg2, int arg3, COLORREF  arg4) | 
|---|
| 687 | { | 
|---|
| 688 | dprintf(("GDI32: FloodFill")); | 
|---|
| 689 | return O32_FloodFill(arg1, arg2, arg3, arg4); | 
|---|
| 690 | } | 
|---|
| 691 | //****************************************************************************** | 
|---|
| 692 | //****************************************************************************** | 
|---|
| 693 | int WIN32API GetArcDirection( HDC arg1) | 
|---|
| 694 | { | 
|---|
| 695 | dprintf(("GDI32: GetArcDirection")); | 
|---|
| 696 | return O32_GetArcDirection(arg1); | 
|---|
| 697 | } | 
|---|
| 698 | //****************************************************************************** | 
|---|
| 699 | //****************************************************************************** | 
|---|
| 700 | BOOL WIN32API GetAspectRatioFilterEx( HDC arg1, PSIZE  arg2) | 
|---|
| 701 | { | 
|---|
| 702 | dprintf(("GDI32: GetAspectRatioFilterEx")); | 
|---|
| 703 | return O32_GetAspectRatioFilterEx(arg1, arg2); | 
|---|
| 704 | } | 
|---|
| 705 | //****************************************************************************** | 
|---|
| 706 | //****************************************************************************** | 
|---|
| 707 | COLORREF WIN32API GetBkColor( HDC arg1) | 
|---|
| 708 | { | 
|---|
| 709 | dprintf(("GDI32: GetBkColor")); | 
|---|
| 710 | return O32_GetBkColor(arg1); | 
|---|
| 711 | } | 
|---|
| 712 | //****************************************************************************** | 
|---|
| 713 | //****************************************************************************** | 
|---|
| 714 | int WIN32API GetBkMode( HDC arg1) | 
|---|
| 715 | { | 
|---|
| 716 | dprintf(("GDI32: GetBkMode")); | 
|---|
| 717 | return O32_GetBkMode(arg1); | 
|---|
| 718 | } | 
|---|
| 719 | //****************************************************************************** | 
|---|
| 720 | //****************************************************************************** | 
|---|
| 721 | UINT WIN32API GetBoundsRect( HDC arg1, PRECT arg2, UINT  arg3) | 
|---|
| 722 | { | 
|---|
| 723 | dprintf(("GDI32: GetBoundsRect")); | 
|---|
| 724 | return O32_GetBoundsRect(arg1, arg2, arg3); | 
|---|
| 725 | } | 
|---|
| 726 | //****************************************************************************** | 
|---|
| 727 | //****************************************************************************** | 
|---|
| 728 | BOOL WIN32API GetBrushOrgEx( HDC arg1, PPOINT  arg2) | 
|---|
| 729 | { | 
|---|
| 730 | dprintf(("GDI32: GetBrushOrgEx")); | 
|---|
| 731 | return O32_GetBrushOrgEx(arg1, arg2); | 
|---|
| 732 | } | 
|---|
| 733 | //****************************************************************************** | 
|---|
| 734 | //****************************************************************************** | 
|---|
| 735 | BOOL WIN32API GetCharABCWidthsA( HDC arg1, UINT arg2, UINT arg3, LPABC arg4) | 
|---|
| 736 | { | 
|---|
| 737 | dprintf(("GDI32: GetCharABCWidthsA")); | 
|---|
| 738 | return O32_GetCharABCWidths(arg1, arg2, arg3, arg4); | 
|---|
| 739 | } | 
|---|
| 740 | //****************************************************************************** | 
|---|
| 741 | //****************************************************************************** | 
|---|
| 742 | BOOL WIN32API GetCharABCWidthsW( HDC arg1, UINT arg2, UINT arg3, LPABC arg4) | 
|---|
| 743 | { | 
|---|
| 744 | dprintf(("GDI32: GetCharABCWidthsW not properly implemented.")); | 
|---|
| 745 | // NOTE: This will not work as is (needs UNICODE support) | 
|---|
| 746 | return O32_GetCharABCWidths(arg1, arg2, arg3, arg4); | 
|---|
| 747 | } | 
|---|
| 748 | //****************************************************************************** | 
|---|
| 749 | //****************************************************************************** | 
|---|
| 750 | BOOL WIN32API GetCharWidth32A( HDC arg1, UINT arg2, UINT arg3, PINT  arg4) | 
|---|
| 751 | { | 
|---|
| 752 | dprintf(("GDI32: GetCharWidth32A")); | 
|---|
| 753 | return O32_GetCharWidth(arg1, arg2, arg3, arg4); | 
|---|
| 754 | } | 
|---|
| 755 | //****************************************************************************** | 
|---|
| 756 | //TODO: Cut off Unicode chars? | 
|---|
| 757 | //****************************************************************************** | 
|---|
| 758 | BOOL WIN32API GetCharWidth32W(HDC arg1, UINT iFirstChar, UINT iLastChar, PINT  arg4) | 
|---|
| 759 | { | 
|---|
| 760 | dprintf(("GDI32: GetCharWidth32W, not properly implemented")); | 
|---|
| 761 | return O32_GetCharWidth(arg1, iFirstChar, iLastChar, arg4); | 
|---|
| 762 | } | 
|---|
| 763 | //****************************************************************************** | 
|---|
| 764 | //****************************************************************************** | 
|---|
| 765 | int WIN32API GetClipBox( HDC arg1, PRECT  arg2) | 
|---|
| 766 | { | 
|---|
| 767 | int rc; | 
|---|
| 768 |  | 
|---|
| 769 | rc = O32_GetClipBox(arg1, arg2); | 
|---|
| 770 | dprintf(("GDI32: GetClipBox of %X returned %d\n", arg1, rc)); | 
|---|
| 771 | return(rc); | 
|---|
| 772 | } | 
|---|
| 773 | //****************************************************************************** | 
|---|
| 774 | //****************************************************************************** | 
|---|
| 775 | HANDLE WIN32API GetCurrentObject( HDC hdc, UINT arg2) | 
|---|
| 776 | { | 
|---|
| 777 | dprintf(("GDI32: GetCurrentObject %x %x", hdc, arg2)); | 
|---|
| 778 | return (HANDLE)O32_GetCurrentObject(hdc, arg2); | 
|---|
| 779 | } | 
|---|
| 780 | //****************************************************************************** | 
|---|
| 781 | //****************************************************************************** | 
|---|
| 782 | BOOL WIN32API GetCurrentPositionEx( HDC arg1, PPOINT  arg2) | 
|---|
| 783 | { | 
|---|
| 784 | dprintf(("GDI32: GetCurrentPositionEx")); | 
|---|
| 785 | return O32_GetCurrentPositionEx(arg1, arg2); | 
|---|
| 786 | } | 
|---|
| 787 | //****************************************************************************** | 
|---|
| 788 | //****************************************************************************** | 
|---|
| 789 | int WIN32API GetDeviceCaps(HDC hdc, int nIndex) | 
|---|
| 790 | { | 
|---|
| 791 | int rc; | 
|---|
| 792 |  | 
|---|
| 793 | rc = O32_GetDeviceCaps(hdc, nIndex); | 
|---|
| 794 | dprintf(("GDI32: GetDeviceCaps %X, %d returned %d\n", hdc, nIndex, rc)); | 
|---|
| 795 | //SvL: 13-9-'98: NT returns -1 when using 16 bits colors, NOT 65536! | 
|---|
| 796 | if(nIndex == NUMCOLORS && rc > 256) | 
|---|
| 797 | return -1; | 
|---|
| 798 |  | 
|---|
| 799 | return(rc); | 
|---|
| 800 | } | 
|---|
| 801 | //****************************************************************************** | 
|---|
| 802 | //****************************************************************************** | 
|---|
| 803 | int WIN32API GetGraphicsMode(HDC arg1) | 
|---|
| 804 | { | 
|---|
| 805 | dprintf(("GDI32: GetGraphicsMode")); | 
|---|
| 806 | return O32_GetGraphicsMode(arg1); | 
|---|
| 807 | } | 
|---|
| 808 | //****************************************************************************** | 
|---|
| 809 | //****************************************************************************** | 
|---|
| 810 | DWORD WIN32API GetKerningPairsA( HDC arg1, DWORD arg2, LPKERNINGPAIR  arg3) | 
|---|
| 811 | { | 
|---|
| 812 | dprintf(("GDI32: GetKerningPairsA")); | 
|---|
| 813 | return O32_GetKerningPairs(arg1, arg2, arg3); | 
|---|
| 814 | } | 
|---|
| 815 | //****************************************************************************** | 
|---|
| 816 | //****************************************************************************** | 
|---|
| 817 | DWORD WIN32API GetKerningPairsW( HDC arg1, DWORD arg2, LPKERNINGPAIR  arg3) | 
|---|
| 818 | { | 
|---|
| 819 | dprintf(("GDI32: GetKerningPairsW")); | 
|---|
| 820 | // NOTE: This will not work as is (needs UNICODE support) | 
|---|
| 821 | return O32_GetKerningPairs(arg1, arg2, arg3); | 
|---|
| 822 | } | 
|---|
| 823 | //****************************************************************************** | 
|---|
| 824 | //****************************************************************************** | 
|---|
| 825 | int WIN32API GetMapMode( HDC arg1) | 
|---|
| 826 | { | 
|---|
| 827 | dprintf(("GDI32: GetMapMode")); | 
|---|
| 828 | return O32_GetMapMode(arg1); | 
|---|
| 829 | } | 
|---|
| 830 | //****************************************************************************** | 
|---|
| 831 | //****************************************************************************** | 
|---|
| 832 | BOOL WIN32API GetMiterLimit( HDC arg1, float * arg2) | 
|---|
| 833 | { | 
|---|
| 834 | dprintf(("GDI32: GetMiterLimit")); | 
|---|
| 835 | return O32_GetMiterLimit(arg1, arg2); | 
|---|
| 836 | } | 
|---|
| 837 | //****************************************************************************** | 
|---|
| 838 | //****************************************************************************** | 
|---|
| 839 | COLORREF WIN32API GetNearestColor( HDC arg1, COLORREF  arg2) | 
|---|
| 840 | { | 
|---|
| 841 | dprintf(("GDI32: GetNearestColor\n")); | 
|---|
| 842 | return O32_GetNearestColor(arg1, arg2); | 
|---|
| 843 | } | 
|---|
| 844 | //****************************************************************************** | 
|---|
| 845 | //****************************************************************************** | 
|---|
| 846 | UINT WIN32API GetOutlineTextMetricsA( HDC arg1, UINT arg2, LPOUTLINETEXTMETRICA  arg3) | 
|---|
| 847 | { | 
|---|
| 848 | dprintf(("GDI32: GetOutlineTextMetricsA")); | 
|---|
| 849 | return O32_GetOutlineTextMetrics(arg1, arg2, arg3); | 
|---|
| 850 | } | 
|---|
| 851 | //****************************************************************************** | 
|---|
| 852 | //****************************************************************************** | 
|---|
| 853 | UINT WIN32API GetOutlineTextMetricsW( HDC arg1, UINT arg2, LPOUTLINETEXTMETRICW  arg3) | 
|---|
| 854 | { | 
|---|
| 855 | dprintf(("GDI32: GetOutlineTextMetricsW STUB")); | 
|---|
| 856 | // NOTE: This will not work as is (needs UNICODE support) | 
|---|
| 857 | //    return O32_GetOutlineTextMetrics(arg1, arg2, arg3); | 
|---|
| 858 | return 0; | 
|---|
| 859 | } | 
|---|
| 860 | //****************************************************************************** | 
|---|
| 861 | //****************************************************************************** | 
|---|
| 862 | INT WIN32API GetPath( HDC arg1, PPOINT arg2, PBYTE arg3, int  arg4) | 
|---|
| 863 | { | 
|---|
| 864 | dprintf(("GDI32: GetPath")); | 
|---|
| 865 | return O32_GetPath(arg1, arg2, arg3, arg4); | 
|---|
| 866 | } | 
|---|
| 867 | //****************************************************************************** | 
|---|
| 868 | //****************************************************************************** | 
|---|
| 869 | int WIN32API GetPolyFillMode( HDC arg1) | 
|---|
| 870 | { | 
|---|
| 871 | dprintf(("GDI32: GetPolyFillMode")); | 
|---|
| 872 | return O32_GetPolyFillMode(arg1); | 
|---|
| 873 | } | 
|---|
| 874 | //****************************************************************************** | 
|---|
| 875 | //****************************************************************************** | 
|---|
| 876 | int WIN32API GetROP2( HDC arg1) | 
|---|
| 877 | { | 
|---|
| 878 | dprintf(("GDI32: GetROP2")); | 
|---|
| 879 | return O32_GetROP2(arg1); | 
|---|
| 880 | } | 
|---|
| 881 | //****************************************************************************** | 
|---|
| 882 | //****************************************************************************** | 
|---|
| 883 | BOOL WIN32API GetRasterizerCaps(LPRASTERIZER_STATUS arg1, UINT  arg2) | 
|---|
| 884 | { | 
|---|
| 885 | dprintf(("GDI32: GetRasterizerCaps")); | 
|---|
| 886 | return O32_GetRasterizerCaps(arg1, arg2); | 
|---|
| 887 | } | 
|---|
| 888 | //****************************************************************************** | 
|---|
| 889 | //****************************************************************************** | 
|---|
| 890 | UINT WIN32API GetTextAlign( HDC arg1) | 
|---|
| 891 | { | 
|---|
| 892 | dprintf(("GDI32: GetTextAlign")); | 
|---|
| 893 | return O32_GetTextAlign(arg1); | 
|---|
| 894 | } | 
|---|
| 895 | //****************************************************************************** | 
|---|
| 896 | //****************************************************************************** | 
|---|
| 897 | int WIN32API GetTextCharacterExtra( HDC arg1) | 
|---|
| 898 | { | 
|---|
| 899 | dprintf(("GDI32: GetTextCharacterExtra")); | 
|---|
| 900 | return O32_GetTextCharacterExtra(arg1); | 
|---|
| 901 | } | 
|---|
| 902 | //****************************************************************************** | 
|---|
| 903 | //****************************************************************************** | 
|---|
| 904 | COLORREF WIN32API GetTextColor( HDC arg1) | 
|---|
| 905 | { | 
|---|
| 906 | dprintf(("GDI32: GetTextColor")); | 
|---|
| 907 | return O32_GetTextColor(arg1); | 
|---|
| 908 | } | 
|---|
| 909 | //****************************************************************************** | 
|---|
| 910 | //****************************************************************************** | 
|---|
| 911 | BOOL WIN32API GetTextExtentPoint32A( HDC hdc, LPCSTR lpsz, int cbString, PSIZE  lpSize) | 
|---|
| 912 | { | 
|---|
| 913 | BOOL rc; | 
|---|
| 914 |  | 
|---|
| 915 | lpSize->cx = lpSize->cy = 0; | 
|---|
| 916 | rc = O32_GetTextExtentPoint32(hdc, lpsz, cbString, lpSize); | 
|---|
| 917 | dprintf(("GDI32: GetTextExtentPoint32A %x %s %d returned %d (%d,%d)", hdc, lpsz, cbString, rc, lpSize->cx, lpSize->cy)); | 
|---|
| 918 | return rc; | 
|---|
| 919 | } | 
|---|
| 920 | //****************************************************************************** | 
|---|
| 921 | //****************************************************************************** | 
|---|
| 922 | BOOL WIN32API GetTextExtentPoint32W(HDC arg1, LPCWSTR arg2, int arg3, PSIZE lpSize) | 
|---|
| 923 | { | 
|---|
| 924 | char *astring = UnicodeToAsciiString((LPWSTR)arg2); | 
|---|
| 925 | BOOL  rc; | 
|---|
| 926 |  | 
|---|
| 927 | dprintf(("GDI32: GetTextExtentPoint32W %s\n", astring)); | 
|---|
| 928 | lpSize->cx = lpSize->cy = 0; | 
|---|
| 929 | rc = O32_GetTextExtentPoint32(arg1, astring, arg3, lpSize); | 
|---|
| 930 | FreeAsciiString(astring); | 
|---|
| 931 | return(rc); | 
|---|
| 932 | } | 
|---|
| 933 | //****************************************************************************** | 
|---|
| 934 | //****************************************************************************** | 
|---|
| 935 | BOOL WIN32API GetTextExtentPointW(HDC    hdc, | 
|---|
| 936 | LPCWSTR lpString, | 
|---|
| 937 | int    cbString, | 
|---|
| 938 | PSIZE  lpSize) | 
|---|
| 939 | { | 
|---|
| 940 | char *astring = UnicodeToAsciiString((LPWSTR)lpString); | 
|---|
| 941 | BOOL  rc; | 
|---|
| 942 |  | 
|---|
| 943 | lpSize->cx = lpSize->cy = 0; | 
|---|
| 944 | rc = O32_GetTextExtentPoint(hdc, | 
|---|
| 945 | astring, | 
|---|
| 946 | cbString, | 
|---|
| 947 | lpSize); | 
|---|
| 948 | dprintf(("GDI32: GetTextExtentPointW %X %s (size %08xh) returned %d\n", hdc, astring, cbString, rc)); | 
|---|
| 949 | dprintf(("GDI32: GetTextExtentPointW (%d,%d)\n", lpSize->cx, lpSize->cy)); | 
|---|
| 950 |  | 
|---|
| 951 | FreeAsciiString(astring); | 
|---|
| 952 | return(rc); | 
|---|
| 953 | } | 
|---|
| 954 | //****************************************************************************** | 
|---|
| 955 | //****************************************************************************** | 
|---|
| 956 | int WIN32API GetTextFaceA( HDC arg1, int arg2, LPSTR  arg3) | 
|---|
| 957 | { | 
|---|
| 958 | dprintf(("GDI32: GetTextFaceA")); | 
|---|
| 959 | return O32_GetTextFace(arg1, arg2, arg3); | 
|---|
| 960 | } | 
|---|
| 961 | //****************************************************************************** | 
|---|
| 962 | //****************************************************************************** | 
|---|
| 963 | int WIN32API GetTextFaceW( HDC arg1, int arg2, LPWSTR  arg3) | 
|---|
| 964 | { | 
|---|
| 965 | char *astring = (char *)malloc(arg2+1); | 
|---|
| 966 | int   rc; | 
|---|
| 967 |  | 
|---|
| 968 | dprintf(("GDI32: GetTextFaceW")); | 
|---|
| 969 | rc = O32_GetTextFace(arg1, arg2, astring); | 
|---|
| 970 | AsciiToUnicode(astring, arg3); | 
|---|
| 971 | free(astring); | 
|---|
| 972 | return rc; | 
|---|
| 973 | } | 
|---|
| 974 | //****************************************************************************** | 
|---|
| 975 | //****************************************************************************** | 
|---|
| 976 | BOOL WIN32API GetTextMetricsA( HDC arg1, LPTEXTMETRICA  arg2) | 
|---|
| 977 | { | 
|---|
| 978 | BOOL rc; | 
|---|
| 979 |  | 
|---|
| 980 | rc = O32_GetTextMetrics(arg1, arg2); | 
|---|
| 981 | dprintf(("GDI32: GetTextMetricsA returned %d\n", rc)); | 
|---|
| 982 | return(rc); | 
|---|
| 983 | } | 
|---|
| 984 | //****************************************************************************** | 
|---|
| 985 | //****************************************************************************** | 
|---|
| 986 | BOOL WIN32API GetTextMetricsW( HDC arg1, LPTEXTMETRICW pwtm) | 
|---|
| 987 | { | 
|---|
| 988 | BOOL rc; | 
|---|
| 989 | TEXTMETRICA atm; | 
|---|
| 990 |  | 
|---|
| 991 | dprintf(("GDI32: GetTextMetricsW")); | 
|---|
| 992 |  | 
|---|
| 993 | rc = O32_GetTextMetrics(arg1, &atm); | 
|---|
| 994 | pwtm->tmHeight = atm.tmHeight; | 
|---|
| 995 | pwtm->tmAscent = atm.tmAscent; | 
|---|
| 996 | pwtm->tmDescent = atm.tmDescent; | 
|---|
| 997 | pwtm->tmInternalLeading = atm.tmInternalLeading; | 
|---|
| 998 | pwtm->tmExternalLeading = atm.tmExternalLeading; | 
|---|
| 999 | pwtm->tmAveCharWidth = atm.tmAveCharWidth; | 
|---|
| 1000 | pwtm->tmMaxCharWidth = atm.tmMaxCharWidth; | 
|---|
| 1001 | pwtm->tmWeight = atm.tmWeight; | 
|---|
| 1002 | pwtm->tmOverhang = atm.tmOverhang; | 
|---|
| 1003 | pwtm->tmDigitizedAspectX = atm.tmDigitizedAspectX; | 
|---|
| 1004 | pwtm->tmDigitizedAspectY = atm.tmDigitizedAspectY; | 
|---|
| 1005 | pwtm->tmFirstChar = atm.tmFirstChar; | 
|---|
| 1006 | pwtm->tmLastChar = atm.tmLastChar; | 
|---|
| 1007 | pwtm->tmDefaultChar = atm.tmDefaultChar; | 
|---|
| 1008 | pwtm->tmBreakChar = atm.tmBreakChar; | 
|---|
| 1009 | pwtm->tmItalic = atm.tmItalic; | 
|---|
| 1010 | pwtm->tmUnderlined = atm.tmUnderlined; | 
|---|
| 1011 | pwtm->tmStruckOut = atm.tmStruckOut; | 
|---|
| 1012 | pwtm->tmPitchAndFamily = atm.tmPitchAndFamily; | 
|---|
| 1013 | pwtm->tmCharSet = atm.tmCharSet; | 
|---|
| 1014 | return(rc); | 
|---|
| 1015 | } | 
|---|
| 1016 | //****************************************************************************** | 
|---|
| 1017 | //****************************************************************************** | 
|---|
| 1018 | BOOL WIN32API GetViewportExtEx( HDC arg1, PSIZE  arg2) | 
|---|
| 1019 | { | 
|---|
| 1020 | dprintf(("GDI32: GetViewportExtEx")); | 
|---|
| 1021 | return O32_GetViewportExtEx(arg1, arg2); | 
|---|
| 1022 | } | 
|---|
| 1023 | //****************************************************************************** | 
|---|
| 1024 | //****************************************************************************** | 
|---|
| 1025 | BOOL WIN32API GetViewportOrgEx( HDC arg1, PPOINT  arg2) | 
|---|
| 1026 | { | 
|---|
| 1027 | dprintf(("GDI32: GetViewportOrgEx")); | 
|---|
| 1028 | return O32_GetViewportOrgEx(arg1, arg2); | 
|---|
| 1029 | } | 
|---|
| 1030 | //****************************************************************************** | 
|---|
| 1031 | //****************************************************************************** | 
|---|
| 1032 | BOOL WIN32API GetWindowOrgEx( HDC arg1, PPOINT  arg2) | 
|---|
| 1033 | { | 
|---|
| 1034 | dprintf(("GDI32: GetWindowOrgEx")); | 
|---|
| 1035 | return O32_GetWindowOrgEx(arg1, arg2); | 
|---|
| 1036 | } | 
|---|
| 1037 | //****************************************************************************** | 
|---|
| 1038 | //****************************************************************************** | 
|---|
| 1039 | BOOL WIN32API GetWorldTransform( HDC arg1, LPXFORM  arg2) | 
|---|
| 1040 | { | 
|---|
| 1041 | dprintf(("GDI32: GetWorldTransform")); | 
|---|
| 1042 | return O32_GetWorldTransform(arg1, arg2); | 
|---|
| 1043 | } | 
|---|
| 1044 | //****************************************************************************** | 
|---|
| 1045 | //****************************************************************************** | 
|---|
| 1046 | int WIN32API IntersectClipRect(HDC arg1, int arg2, int arg3, int arg4, int  arg5) | 
|---|
| 1047 | { | 
|---|
| 1048 | int rc; | 
|---|
| 1049 |  | 
|---|
| 1050 | rc = O32_IntersectClipRect(arg1, arg2, arg3, arg4, arg5); | 
|---|
| 1051 | dprintf(("GDI32: IntersectClipRect returned %d\n", rc)); | 
|---|
| 1052 | return(rc); | 
|---|
| 1053 | } | 
|---|
| 1054 | //****************************************************************************** | 
|---|
| 1055 | //****************************************************************************** | 
|---|
| 1056 | BOOL WIN32API LPtoDP( HDC arg1, PPOINT arg2, int  arg3) | 
|---|
| 1057 | { | 
|---|
| 1058 | dprintf(("GDI32: LPtoDP")); | 
|---|
| 1059 | return O32_LPtoDP(arg1, arg2, arg3); | 
|---|
| 1060 | } | 
|---|
| 1061 | //****************************************************************************** | 
|---|
| 1062 | //****************************************************************************** | 
|---|
| 1063 | BOOL WIN32API ModifyWorldTransform( HDC arg1, const XFORM *arg2, DWORD  arg3) | 
|---|
| 1064 | { | 
|---|
| 1065 | dprintf(("GDI32: ModifyWorldTransform")); | 
|---|
| 1066 | return O32_ModifyWorldTransform(arg1, (LPXFORM)arg2, arg3); | 
|---|
| 1067 | } | 
|---|
| 1068 | //****************************************************************************** | 
|---|
| 1069 | //****************************************************************************** | 
|---|
| 1070 | BOOL WIN32API OffsetViewportOrgEx( HDC arg1, int arg2, int arg3, PPOINT  arg4) | 
|---|
| 1071 | { | 
|---|
| 1072 | dprintf(("GDI32: OffsetViewportOrgEx")); | 
|---|
| 1073 | return O32_OffsetViewportOrgEx(arg1, arg2, arg3, arg4); | 
|---|
| 1074 | } | 
|---|
| 1075 | //****************************************************************************** | 
|---|
| 1076 | //****************************************************************************** | 
|---|
| 1077 | BOOL WIN32API OffsetWindowOrgEx( HDC arg1, int arg2, int arg3, PPOINT  arg4) | 
|---|
| 1078 | { | 
|---|
| 1079 | dprintf(("GDI32: OffsetWindowOrgEx")); | 
|---|
| 1080 | return O32_OffsetWindowOrgEx(arg1, arg2, arg3, arg4); | 
|---|
| 1081 | } | 
|---|
| 1082 | //****************************************************************************** | 
|---|
| 1083 | //****************************************************************************** | 
|---|
| 1084 | BOOL WIN32API Pie(HDC hdc, int nLeftRect, int nTopRect, int nRightRect, | 
|---|
| 1085 | int nBottomRect, int nXRadial1, int nYRadial1, int nXRadial2, | 
|---|
| 1086 | int nYRadial2) | 
|---|
| 1087 | { | 
|---|
| 1088 | dprintf(("GDI32: Pie")); | 
|---|
| 1089 | //CB: bug in O32_Pie | 
|---|
| 1090 | if (nXRadial1 == nXRadial2 && nYRadial1 == nYRadial2) | 
|---|
| 1091 | return O32_Ellipse(hdc,nLeftRect,nTopRect,nRightRect,nBottomRect); | 
|---|
| 1092 | else | 
|---|
| 1093 | return O32_Pie(hdc,nLeftRect,nTopRect,nRightRect,nBottomRect,nXRadial1,nYRadial1,nXRadial2,nYRadial2); | 
|---|
| 1094 | } | 
|---|
| 1095 | //****************************************************************************** | 
|---|
| 1096 | //****************************************************************************** | 
|---|
| 1097 | BOOL WIN32API PolyBezier( HDC arg1, const POINT * arg2, DWORD  arg3) | 
|---|
| 1098 | { | 
|---|
| 1099 | dprintf(("GDI32: PolyBezier")); | 
|---|
| 1100 | return O32_PolyBezier(arg1, arg2, (int)arg3); | 
|---|
| 1101 | } | 
|---|
| 1102 | //****************************************************************************** | 
|---|
| 1103 | //****************************************************************************** | 
|---|
| 1104 | BOOL WIN32API PolyBezierTo( HDC arg1, const POINT * arg2, DWORD  arg3) | 
|---|
| 1105 | { | 
|---|
| 1106 | dprintf(("GDI32: PolyBezierTo")); | 
|---|
| 1107 | return O32_PolyBezierTo(arg1, arg2, arg3); | 
|---|
| 1108 | } | 
|---|
| 1109 | //****************************************************************************** | 
|---|
| 1110 | //****************************************************************************** | 
|---|
| 1111 | BOOL WIN32API PolyDraw( HDC arg1, const POINT * arg2, const BYTE * arg3, DWORD  arg4) | 
|---|
| 1112 | { | 
|---|
| 1113 | dprintf(("GDI32: PolyDraw")); | 
|---|
| 1114 | return O32_PolyDraw(arg1, arg2, arg3, arg4); | 
|---|
| 1115 | } | 
|---|
| 1116 | //****************************************************************************** | 
|---|
| 1117 | //****************************************************************************** | 
|---|
| 1118 | BOOL WIN32API PolyPolygon( HDC arg1, const POINT * arg2, const INT * arg3, UINT  arg4) | 
|---|
| 1119 | { | 
|---|
| 1120 | dprintf(("GDI32: PolyPolygon")); | 
|---|
| 1121 | return O32_PolyPolygon(arg1, arg2, arg3, arg4); | 
|---|
| 1122 | } | 
|---|
| 1123 | //****************************************************************************** | 
|---|
| 1124 | //****************************************************************************** | 
|---|
| 1125 | BOOL WIN32API PolyPolyline( HDC hdc, const POINT * lppt, const DWORD * lpdwPolyPoints, DWORD cCount) | 
|---|
| 1126 | { | 
|---|
| 1127 | dprintf(("GDI32: PolyPolyline")); | 
|---|
| 1128 |  | 
|---|
| 1129 | return O32_PolyPolyline(hdc,lppt,lpdwPolyPoints,cCount); | 
|---|
| 1130 | } | 
|---|
| 1131 | //****************************************************************************** | 
|---|
| 1132 | //****************************************************************************** | 
|---|
| 1133 | BOOL WIN32API Polygon( HDC arg1, const POINT * arg2, int  arg3) | 
|---|
| 1134 | { | 
|---|
| 1135 | dprintf(("GDI32: Polygon")); | 
|---|
| 1136 | return O32_Polygon(arg1, arg2, arg3); | 
|---|
| 1137 | } | 
|---|
| 1138 | //****************************************************************************** | 
|---|
| 1139 | //****************************************************************************** | 
|---|
| 1140 | BOOL WIN32API PtVisible( HDC arg1, int arg2, int  arg3) | 
|---|
| 1141 | { | 
|---|
| 1142 | dprintf(("GDI32: PtVisible")); | 
|---|
| 1143 | return O32_PtVisible(arg1, arg2, arg3); | 
|---|
| 1144 | } | 
|---|
| 1145 | //****************************************************************************** | 
|---|
| 1146 | //****************************************************************************** | 
|---|
| 1147 | BOOL WIN32API RectVisible( HDC arg1, const RECT * arg2) | 
|---|
| 1148 | { | 
|---|
| 1149 | dprintf(("GDI32: RectVisible\n")); | 
|---|
| 1150 | return O32_RectVisible(arg1, arg2); | 
|---|
| 1151 | } | 
|---|
| 1152 | //****************************************************************************** | 
|---|
| 1153 | //****************************************************************************** | 
|---|
| 1154 | HDC WIN32API ResetDCA( HDC arg1, const DEVMODEA *  arg2) | 
|---|
| 1155 | { | 
|---|
| 1156 | dprintf(("GDI32: ResetDCA\n")); | 
|---|
| 1157 | return (HDC)O32_ResetDC(arg1, arg2); | 
|---|
| 1158 | } | 
|---|
| 1159 | //****************************************************************************** | 
|---|
| 1160 | //****************************************************************************** | 
|---|
| 1161 | HDC WIN32API ResetDCW( HDC arg1, const DEVMODEW *  arg2) | 
|---|
| 1162 | { | 
|---|
| 1163 | dprintf(("GDI32: ResetDCW\n")); | 
|---|
| 1164 | // NOTE: This will not work as is (needs UNICODE support) | 
|---|
| 1165 | return (HDC)O32_ResetDC(arg1, (const DEVMODEA *)arg2); | 
|---|
| 1166 | } | 
|---|
| 1167 | //****************************************************************************** | 
|---|
| 1168 | //****************************************************************************** | 
|---|
| 1169 | BOOL WIN32API RestoreDC( HDC arg1, int  arg2) | 
|---|
| 1170 | { | 
|---|
| 1171 | dprintf(("GDI32: RestoreDC\n")); | 
|---|
| 1172 | return O32_RestoreDC(arg1, arg2); | 
|---|
| 1173 | } | 
|---|
| 1174 | //****************************************************************************** | 
|---|
| 1175 | //****************************************************************************** | 
|---|
| 1176 | BOOL WIN32API RoundRect( HDC arg1, int arg2, int arg3, int arg4, int arg5, int arg6, int  arg7) | 
|---|
| 1177 | { | 
|---|
| 1178 | dprintf(("GDI32: RoundRect")); | 
|---|
| 1179 | return O32_RoundRect(arg1, arg2, arg3, arg4, arg5, arg6, arg7); | 
|---|
| 1180 | } | 
|---|
| 1181 | //****************************************************************************** | 
|---|
| 1182 | //****************************************************************************** | 
|---|
| 1183 | int WIN32API SaveDC( HDC arg1) | 
|---|
| 1184 | { | 
|---|
| 1185 | dprintf(("GDI32: SaveDC")); | 
|---|
| 1186 | return O32_SaveDC(arg1); | 
|---|
| 1187 | } | 
|---|
| 1188 | //****************************************************************************** | 
|---|
| 1189 | //****************************************************************************** | 
|---|
| 1190 | BOOL WIN32API ScaleViewportExtEx( HDC arg1, int arg2, int arg3, int arg4, int arg5, PSIZE  arg6) | 
|---|
| 1191 | { | 
|---|
| 1192 | dprintf(("GDI32: ScaleViewportExtEx")); | 
|---|
| 1193 | return O32_ScaleViewportExtEx(arg1, arg2, arg3, arg4, arg5, arg6); | 
|---|
| 1194 | } | 
|---|
| 1195 | //****************************************************************************** | 
|---|
| 1196 | //****************************************************************************** | 
|---|
| 1197 | BOOL WIN32API ScaleWindowExtEx( HDC arg1, int arg2, int arg3, int arg4, int arg5, PSIZE  arg6) | 
|---|
| 1198 | { | 
|---|
| 1199 | dprintf(("GDI32: ScaleWindowExtEx")); | 
|---|
| 1200 | return O32_ScaleWindowExtEx(arg1, arg2, arg3, arg4, arg5, arg6); | 
|---|
| 1201 | } | 
|---|
| 1202 | //****************************************************************************** | 
|---|
| 1203 | //****************************************************************************** | 
|---|
| 1204 | int WIN32API SetArcDirection( HDC arg1, int  arg2) | 
|---|
| 1205 | { | 
|---|
| 1206 | dprintf(("GDI32: SetArcDirection")); | 
|---|
| 1207 | return O32_SetArcDirection(arg1, arg2); | 
|---|
| 1208 | } | 
|---|
| 1209 | //****************************************************************************** | 
|---|
| 1210 | //****************************************************************************** | 
|---|
| 1211 | UINT WIN32API SetBoundsRect( HDC arg1, const RECT * arg2, UINT arg3) | 
|---|
| 1212 | { | 
|---|
| 1213 | dprintf(("GDI32: SetBoundsRect")); | 
|---|
| 1214 | return O32_SetBoundsRect(arg1, arg2, arg3); | 
|---|
| 1215 | } | 
|---|
| 1216 | //****************************************************************************** | 
|---|
| 1217 | //****************************************************************************** | 
|---|
| 1218 | BOOL WIN32API SetBrushOrgEx( HDC arg1, int arg2, int arg3, PPOINT  arg4) | 
|---|
| 1219 | { | 
|---|
| 1220 | BOOL rc; | 
|---|
| 1221 |  | 
|---|
| 1222 | rc = O32_SetBrushOrgEx(arg1, arg2, arg3, arg4); | 
|---|
| 1223 | dprintf(("GDI32: SetBrushOrgEx returned %d\n", rc)); | 
|---|
| 1224 | return(rc); | 
|---|
| 1225 | } | 
|---|
| 1226 | //****************************************************************************** | 
|---|
| 1227 | //****************************************************************************** | 
|---|
| 1228 | int WIN32API SetGraphicsMode(HDC arg1, int  arg2) | 
|---|
| 1229 | { | 
|---|
| 1230 | dprintf(("GDI32: SetGraphicsMode")); | 
|---|
| 1231 | return O32_SetGraphicsMode(arg1, arg2); | 
|---|
| 1232 | } | 
|---|
| 1233 | //****************************************************************************** | 
|---|
| 1234 | //****************************************************************************** | 
|---|
| 1235 | int WIN32API SetMapMode( HDC arg1, int  arg2) | 
|---|
| 1236 | { | 
|---|
| 1237 | dprintf(("GDI32: SetMapMode")); | 
|---|
| 1238 | return O32_SetMapMode(arg1, arg2); | 
|---|
| 1239 | } | 
|---|
| 1240 | //****************************************************************************** | 
|---|
| 1241 | //****************************************************************************** | 
|---|
| 1242 | DWORD WIN32API SetMapperFlags( HDC arg1, DWORD  arg2) | 
|---|
| 1243 | { | 
|---|
| 1244 | dprintf(("GDI32: SetMapperFlags")); | 
|---|
| 1245 | return O32_SetMapperFlags(arg1, arg2); | 
|---|
| 1246 | } | 
|---|
| 1247 | //****************************************************************************** | 
|---|
| 1248 | //****************************************************************************** | 
|---|
| 1249 | BOOL WIN32API SetMiterLimit( HDC arg1, float  arg2, float *  arg3) | 
|---|
| 1250 | { | 
|---|
| 1251 | dprintf(("GDI32: SetMiterLimit")); | 
|---|
| 1252 | return O32_SetMiterLimit(arg1, arg2, arg3); | 
|---|
| 1253 | } | 
|---|
| 1254 | //****************************************************************************** | 
|---|
| 1255 | //****************************************************************************** | 
|---|
| 1256 | int WIN32API SetPolyFillMode( HDC arg1, int  arg2) | 
|---|
| 1257 | { | 
|---|
| 1258 | dprintf(("GDI32: SetPolyFillMode")); | 
|---|
| 1259 | return O32_SetPolyFillMode(arg1, arg2); | 
|---|
| 1260 | } | 
|---|
| 1261 | //****************************************************************************** | 
|---|
| 1262 | //****************************************************************************** | 
|---|
| 1263 | UINT WIN32API SetTextAlign( HDC arg1, UINT  arg2) | 
|---|
| 1264 | { | 
|---|
| 1265 | dprintf(("GDI32: SetTextAlign")); | 
|---|
| 1266 | return O32_SetTextAlign(arg1, arg2); | 
|---|
| 1267 | } | 
|---|
| 1268 | //****************************************************************************** | 
|---|
| 1269 | //****************************************************************************** | 
|---|
| 1270 | int WIN32API SetTextCharacterExtra( HDC arg1, int  arg2) | 
|---|
| 1271 | { | 
|---|
| 1272 | dprintf(("GDI32: SetTextCharacterExtra")); | 
|---|
| 1273 | return O32_SetTextCharacterExtra(arg1, arg2); | 
|---|
| 1274 | } | 
|---|
| 1275 | //****************************************************************************** | 
|---|
| 1276 | //****************************************************************************** | 
|---|
| 1277 | BOOL WIN32API SetTextJustification( HDC arg1, int arg2, int  arg3) | 
|---|
| 1278 | { | 
|---|
| 1279 | dprintf(("GDI32: SetTextJustification")); | 
|---|
| 1280 | return O32_SetTextJustification(arg1, arg2, arg3); | 
|---|
| 1281 | } | 
|---|
| 1282 | //****************************************************************************** | 
|---|
| 1283 | //****************************************************************************** | 
|---|
| 1284 | BOOL WIN32API SetViewportExtEx( HDC arg1, int arg2, int arg3, PSIZE  arg4) | 
|---|
| 1285 | { | 
|---|
| 1286 | dprintf(("GDI32: SetViewportExtEx")); | 
|---|
| 1287 | return O32_SetViewportExtEx(arg1, arg2, arg3, arg4); | 
|---|
| 1288 | } | 
|---|
| 1289 | //****************************************************************************** | 
|---|
| 1290 | //****************************************************************************** | 
|---|
| 1291 | BOOL WIN32API SetViewportOrgEx( HDC arg1, int arg2, int arg3, PPOINT  arg4) | 
|---|
| 1292 | { | 
|---|
| 1293 | dprintf(("GDI32: SetViewportOrgEx")); | 
|---|
| 1294 | return O32_SetViewportOrgEx(arg1, arg2, arg3, arg4); | 
|---|
| 1295 | } | 
|---|
| 1296 | //****************************************************************************** | 
|---|
| 1297 | //****************************************************************************** | 
|---|
| 1298 | BOOL WIN32API SetWindowExtEx( HDC arg1, int arg2, int arg3, PSIZE  arg4) | 
|---|
| 1299 | { | 
|---|
| 1300 | dprintf(("GDI32: SetWindowExtEx")); | 
|---|
| 1301 | return O32_SetWindowExtEx(arg1, arg2, arg3, arg4); | 
|---|
| 1302 | } | 
|---|
| 1303 | //****************************************************************************** | 
|---|
| 1304 | //****************************************************************************** | 
|---|
| 1305 | BOOL WIN32API SetWindowOrgEx( HDC arg1, int arg2, int arg3, PPOINT  arg4) | 
|---|
| 1306 | { | 
|---|
| 1307 | dprintf(("GDI32: SetWindowOrgEx")); | 
|---|
| 1308 | return O32_SetWindowOrgEx(arg1, arg2, arg3, arg4); | 
|---|
| 1309 | } | 
|---|
| 1310 | //****************************************************************************** | 
|---|
| 1311 | //****************************************************************************** | 
|---|
| 1312 | BOOL WIN32API SetWorldTransform( HDC arg1, const XFORM *arg2) | 
|---|
| 1313 | { | 
|---|
| 1314 | dprintf(("GDI32: SetWorldTransform")); | 
|---|
| 1315 | return O32_SetWorldTransform(arg1, (LPXFORM)arg2); | 
|---|
| 1316 | } | 
|---|
| 1317 | //****************************************************************************** | 
|---|
| 1318 | //****************************************************************************** | 
|---|
| 1319 | INT WIN32API StartDocA( HDC arg1, const DOCINFOA *arg2) | 
|---|
| 1320 | { | 
|---|
| 1321 | dprintf(("GDI32: StartDocA")); | 
|---|
| 1322 | return O32_StartDoc(arg1, (LPDOCINFOA)arg2); | 
|---|
| 1323 | } | 
|---|
| 1324 | //****************************************************************************** | 
|---|
| 1325 | //****************************************************************************** | 
|---|
| 1326 | INT WIN32API StartDocW( HDC arg1, const DOCINFOW *arg2) | 
|---|
| 1327 | { | 
|---|
| 1328 | dprintf(("GDI32: StartDocW STUB")); | 
|---|
| 1329 | // NOTE: This will not work as is (needs UNICODE support) | 
|---|
| 1330 | //    return O32_StartDoc(arg1, arg2); | 
|---|
| 1331 | return 0; | 
|---|
| 1332 | } | 
|---|
| 1333 | //****************************************************************************** | 
|---|
| 1334 | //****************************************************************************** | 
|---|
| 1335 | int WIN32API StartPage( HDC arg1) | 
|---|
| 1336 | { | 
|---|
| 1337 | dprintf(("GDI32: StartPage")); | 
|---|
| 1338 | return O32_StartPage(arg1); | 
|---|
| 1339 | } | 
|---|
| 1340 | //****************************************************************************** | 
|---|
| 1341 | //****************************************************************************** | 
|---|
| 1342 | BOOL WIN32API UnrealizeObject( HGDIOBJ arg1) | 
|---|
| 1343 | { | 
|---|
| 1344 | dprintf(("GDI32: UnrealizeObject")); | 
|---|
| 1345 | return O32_UnrealizeObject(arg1); | 
|---|
| 1346 | } | 
|---|
| 1347 | //****************************************************************************** | 
|---|
| 1348 | //****************************************************************************** | 
|---|
| 1349 | BOOL WIN32API WidenPath( HDC arg1) | 
|---|
| 1350 | { | 
|---|
| 1351 | dprintf(("GDI32: WidenPath")); | 
|---|
| 1352 | return O32_WidenPath(arg1); | 
|---|
| 1353 | } | 
|---|
| 1354 | //****************************************************************************** | 
|---|
| 1355 | //TODO: Not implemented | 
|---|
| 1356 | //****************************************************************************** | 
|---|
| 1357 | int WIN32API SetAbortProc(HDC hdc, ABORTPROC lpAbortProc) | 
|---|
| 1358 | { | 
|---|
| 1359 | dprintf(("GDI32: SetAbortProc - stub (1)w\n")); | 
|---|
| 1360 | return(1); | 
|---|
| 1361 | } | 
|---|
| 1362 | //****************************************************************************** | 
|---|
| 1363 | //Selects the current path as a clipping region for a device context, combining | 
|---|
| 1364 | //any existing clipping region by using the specified mode | 
|---|
| 1365 | //TODO: Can be emulated with SelectClipRegion?? | 
|---|
| 1366 | //****************************************************************************** | 
|---|
| 1367 | BOOL WIN32API SelectClipPath(HDC hdc, int iMode) | 
|---|
| 1368 | { | 
|---|
| 1369 | dprintf(("GDI32: SelectClipPath, not implemented!(TRUE)\n")); | 
|---|
| 1370 | return(TRUE); | 
|---|
| 1371 | } | 
|---|
| 1372 | //****************************************************************************** | 
|---|
| 1373 | //TODO: Sets the color adjustment values for a device context. (used to adjust | 
|---|
| 1374 | //      the input color of the src bitmap for calls of StretchBlt & StretchDIBits | 
|---|
| 1375 | //      functions when HALFTONE mode is set | 
|---|
| 1376 | //****************************************************************************** | 
|---|
| 1377 | BOOL WIN32API SetColorAdjustment(HDC hdc, CONST COLORADJUSTMENT *lpca) | 
|---|
| 1378 | { | 
|---|
| 1379 | dprintf(("GDI32: SetColorAdjustment, not implemented!(TRUE)\n")); | 
|---|
| 1380 | return(TRUE); | 
|---|
| 1381 | } | 
|---|
| 1382 | //****************************************************************************** | 
|---|
| 1383 | //Maps colors to system palette; faster way to update window (instead of redrawing) | 
|---|
| 1384 | //We just redraw | 
|---|
| 1385 | //****************************************************************************** | 
|---|
| 1386 | BOOL WIN32API UpdateColors(HDC hdc) | 
|---|
| 1387 | { | 
|---|
| 1388 | dprintf(("GDI32: UpdateColors\n")); | 
|---|
| 1389 | return O32_InvalidateRect(O32_WindowFromDC(hdc), NULL, FALSE); | 
|---|
| 1390 | } | 
|---|
| 1391 | //****************************************************************************** | 
|---|
| 1392 | //****************************************************************************** | 
|---|
| 1393 | BOOL WIN32API GdiFlush() | 
|---|
| 1394 | { | 
|---|
| 1395 | dprintf(("GDI32: GdiFlush, not implemented (TRUE)\n")); | 
|---|
| 1396 | return(TRUE); | 
|---|
| 1397 | } | 
|---|
| 1398 | //****************************************************************************** | 
|---|
| 1399 | //****************************************************************************** | 
|---|
| 1400 | BOOL WIN32API GdiComment(HDC hdc, UINT cbSize, CONST BYTE *lpData) | 
|---|
| 1401 | { | 
|---|
| 1402 | dprintf(("GDI32: GdiComment, not implemented (TRUE)\n")); | 
|---|
| 1403 | return(TRUE); | 
|---|
| 1404 | } | 
|---|
| 1405 | //****************************************************************************** | 
|---|
| 1406 | //****************************************************************************** | 
|---|
| 1407 | BOOL WIN32API GetCharWidthFloatA(HDC hdc, UINT iFirstChar, UINT iLastChar, PFLOAT pxBUffer) | 
|---|
| 1408 | { | 
|---|
| 1409 | dprintf(("GDI32: GetCharWidthFloatA, not implemented\n")); | 
|---|
| 1410 | return(FALSE); | 
|---|
| 1411 | } | 
|---|
| 1412 | //****************************************************************************** | 
|---|
| 1413 | //****************************************************************************** | 
|---|
| 1414 | BOOL WIN32API GetCharWidthFloatW(HDC hdc, UINT iFirstChar, UINT iLastChar, PFLOAT pxBUffer) | 
|---|
| 1415 | { | 
|---|
| 1416 | dprintf(("GDI32: GetCharWidthFloatW, not implemented\n")); | 
|---|
| 1417 | return(FALSE); | 
|---|
| 1418 | } | 
|---|
| 1419 | //****************************************************************************** | 
|---|
| 1420 | //****************************************************************************** | 
|---|
| 1421 | BOOL WIN32API GetCharABCWidthsFloatA(HDC hdc, UINT iFirstChar, UINT iLastChar, LPABCFLOAT pxBUffer) | 
|---|
| 1422 | { | 
|---|
| 1423 | dprintf(("GDI32: GetCharABCWidthsFloatA, not implemented\n")); | 
|---|
| 1424 | return(FALSE); | 
|---|
| 1425 | } | 
|---|
| 1426 | //****************************************************************************** | 
|---|
| 1427 | //****************************************************************************** | 
|---|
| 1428 | BOOL WIN32API GetCharABCWidthsFloatW(HDC hdc, | 
|---|
| 1429 | UINT iFirstChar, | 
|---|
| 1430 | UINT iLastChar, | 
|---|
| 1431 | LPABCFLOAT pxBUffer) | 
|---|
| 1432 | { | 
|---|
| 1433 | dprintf(("GDI32: GetCharABCWidthsFloatA, not implemented\n")); | 
|---|
| 1434 | return(FALSE); | 
|---|
| 1435 | } | 
|---|
| 1436 | //****************************************************************************** | 
|---|
| 1437 | //****************************************************************************** | 
|---|
| 1438 | INT WIN32API ExtEscape(HDC hdc, INT nEscape, INT cbInput, LPCSTR lpszInData, | 
|---|
| 1439 | INT cbOutput, LPSTR lpszOutData) | 
|---|
| 1440 | { | 
|---|
| 1441 | dprintf(("GDI32: ExtEscape, %x %x %d %x %d %x not implemented", hdc, nEscape, cbInput, lpszInData, cbOutput, lpszOutData)); | 
|---|
| 1442 | #ifdef DEBUG | 
|---|
| 1443 | if(cbInput && lpszInData) { | 
|---|
| 1444 | ULONG *tmp = (ULONG *)lpszInData; | 
|---|
| 1445 | for(int i=0;i<cbInput/4;i++) { | 
|---|
| 1446 | dprintf(("GDI32: ExtEscape par %d: %x", i, *tmp++)); | 
|---|
| 1447 | } | 
|---|
| 1448 | } | 
|---|
| 1449 | #endif | 
|---|
| 1450 | return(0); | 
|---|
| 1451 | } | 
|---|
| 1452 | //****************************************************************************** | 
|---|
| 1453 | //****************************************************************************** | 
|---|
| 1454 | int WIN32API DrawEscape(HDC hdc, int nEscape, int cbInput, LPCSTR lpszInData) | 
|---|
| 1455 | { | 
|---|
| 1456 | dprintf(("GDI32: DrawEscape, not implemented\n")); | 
|---|
| 1457 | return(0); | 
|---|
| 1458 | } | 
|---|
| 1459 | //****************************************************************************** | 
|---|
| 1460 | //****************************************************************************** | 
|---|
| 1461 | BOOL WIN32API GetColorAdjustment(HDC hdc, COLORADJUSTMENT *lpca) | 
|---|
| 1462 | { | 
|---|
| 1463 | dprintf(("GDI32: GetColorAdjustment, not implemented\n")); | 
|---|
| 1464 | return(FALSE); | 
|---|
| 1465 | } | 
|---|
| 1466 | //****************************************************************************** | 
|---|
| 1467 | //****************************************************************************** | 
|---|
| 1468 | DWORD WIN32API GetGlyphOutlineA(HDC hdc, UINT uChar, UINT uFormat, LPGLYPHMETRICS lpgm, | 
|---|
| 1469 | DWORD cbBuffer, LPVOID lpvBuffer, CONST MAT2 *lpmat2) | 
|---|
| 1470 | { | 
|---|
| 1471 | dprintf(("GDI32: GetGlyphOutLineA, not implemented (GDI_ERROR)\n")); | 
|---|
| 1472 | return(GDI_ERROR); | 
|---|
| 1473 | } | 
|---|
| 1474 | //****************************************************************************** | 
|---|
| 1475 |  | 
|---|
| 1476 | //****************************************************************************** | 
|---|
| 1477 | /*KSO Thu 21.05.1998*/ | 
|---|
| 1478 | DWORD WIN32API GetGlyphOutlineW(HDC hdc, UINT uChar, UINT uFormat, LPGLYPHMETRICS lpgm, | 
|---|
| 1479 | DWORD cbBuffer, LPVOID lpvBuffer, CONST MAT2 *lpmat2) | 
|---|
| 1480 | { | 
|---|
| 1481 | dprintf(("GDI32: GetGlyphOutLineW, not implemented\n")); | 
|---|
| 1482 | return(GDI_ERROR); | 
|---|
| 1483 | } | 
|---|
| 1484 | //****************************************************************************** | 
|---|
| 1485 |  | 
|---|
| 1486 | //****************************************************************************** | 
|---|
| 1487 | BOOL WIN32API SetObjectOwner( HGDIOBJ arg1, int arg2 ) | 
|---|
| 1488 | { | 
|---|
| 1489 | // Here is a guess for a undocumented entry | 
|---|
| 1490 | dprintf(("GDI32: SetObjectOwner - stub (TRUE)\n")); | 
|---|
| 1491 | return TRUE; | 
|---|
| 1492 | } | 
|---|
| 1493 | //****************************************************************************** | 
|---|
| 1494 |  | 
|---|
| 1495 |  | 
|---|
| 1496 | /* Office 97 stubs - KSO Thu 21.05.1998*/ | 
|---|
| 1497 | //****************************************************************************** | 
|---|
| 1498 | BOOL WIN32API GetTextExtentExPointA(/*KSO Thu 21.05.1998*/ | 
|---|
| 1499 | HDC     hdc, | 
|---|
| 1500 | LPCSTR  str, | 
|---|
| 1501 | int     count, | 
|---|
| 1502 | int     maxExt, | 
|---|
| 1503 | LPINT   lpnFit, | 
|---|
| 1504 | LPINT   alpDx, | 
|---|
| 1505 | LPSIZE  size) | 
|---|
| 1506 | { | 
|---|
| 1507 | int index, nFit, extent; | 
|---|
| 1508 | SIZE tSize; | 
|---|
| 1509 |  | 
|---|
| 1510 | dprintf(("GDI32: GetTextExtendExPointA\n")); | 
|---|
| 1511 |  | 
|---|
| 1512 | size->cx = size->cy = nFit = extent = 0; | 
|---|
| 1513 | for(index = 0; index < count; index++) | 
|---|
| 1514 | { | 
|---|
| 1515 | if(!O32_GetTextExtentPoint( hdc, str, 1, &tSize )) return FALSE; | 
|---|
| 1516 | if( extent+tSize.cx < maxExt ) | 
|---|
| 1517 | { | 
|---|
| 1518 | extent+=tSize.cx; | 
|---|
| 1519 | nFit++; | 
|---|
| 1520 | str++; | 
|---|
| 1521 | if( alpDx ) | 
|---|
| 1522 | alpDx[index] = extent; | 
|---|
| 1523 | if( tSize.cy > size->cy ) size->cy = tSize.cy; | 
|---|
| 1524 | } | 
|---|
| 1525 | else break; | 
|---|
| 1526 | } | 
|---|
| 1527 | size->cx = extent; | 
|---|
| 1528 |  | 
|---|
| 1529 | if (lpnFit != NULL)  // check if result is desired | 
|---|
| 1530 | *lpnFit = nFit; | 
|---|
| 1531 |  | 
|---|
| 1532 | dprintf(("GDI32: GetTextExtendExPointA(%08x '%.*s' %d) returning %d %d %d\n", | 
|---|
| 1533 | hdc,count,str,maxExt,nFit, size->cx,size->cy)); | 
|---|
| 1534 | return TRUE; | 
|---|
| 1535 | } | 
|---|
| 1536 | //****************************************************************************** | 
|---|
| 1537 | //****************************************************************************** | 
|---|
| 1538 | BOOL WIN32API GetTextExtentExPointW(                                 /*KSO Thu 21.05.1998*/ | 
|---|
| 1539 | HDC     arg1, | 
|---|
| 1540 | LPCWSTR arg2, | 
|---|
| 1541 | int     arg3, | 
|---|
| 1542 | int             arg4, | 
|---|
| 1543 | LPINT   arg5, | 
|---|
| 1544 | LPINT   arg6, | 
|---|
| 1545 | LPSIZE  arg7 | 
|---|
| 1546 | ) | 
|---|
| 1547 | { | 
|---|
| 1548 | char *astring = UnicodeToAsciiString((LPWSTR)arg2); | 
|---|
| 1549 | BOOL  rc; | 
|---|
| 1550 |  | 
|---|
| 1551 | dprintf(("GDI32: GetTextExtendExPointW\n")); | 
|---|
| 1552 | rc = GetTextExtentExPointA(arg1, astring, arg3, arg4, arg5, arg6, arg7); | 
|---|
| 1553 | FreeAsciiString(astring); | 
|---|
| 1554 | return rc; | 
|---|
| 1555 | } | 
|---|
| 1556 | //****************************************************************************** | 
|---|
| 1557 | //****************************************************************************** | 
|---|
| 1558 | UINT WIN32API DeleteColorSpace(                                              /*KSO Thu 21.05.1998*/ | 
|---|
| 1559 | HCOLORSPACE hColorSpace | 
|---|
| 1560 | ) | 
|---|
| 1561 | { | 
|---|
| 1562 | dprintf(("GDI32: DeleteColorSpace - stub\n")); | 
|---|
| 1563 | return FALSE; | 
|---|
| 1564 | } | 
|---|
| 1565 | //****************************************************************************** | 
|---|
| 1566 | //****************************************************************************** | 
|---|
| 1567 | BOOL WIN32API SetColorSpace(                                                 /*KSO Thu 21.05.1998*/ | 
|---|
| 1568 | HDC     hdc, | 
|---|
| 1569 | HCOLORSPACE hColorSpace | 
|---|
| 1570 | ) | 
|---|
| 1571 | { | 
|---|
| 1572 | dprintf(("GDI32: SetColorSpace - stub\n")); | 
|---|
| 1573 | return FALSE; | 
|---|
| 1574 | } | 
|---|
| 1575 | //****************************************************************************** | 
|---|
| 1576 | //****************************************************************************** | 
|---|
| 1577 | HCOLORSPACE WIN32API CreateColorSpaceA(                             /*KSO Thu 21.05.1998*/ | 
|---|
| 1578 | LPLOGCOLORSPACEA lpLogColorSpace | 
|---|
| 1579 | ) | 
|---|
| 1580 | { | 
|---|
| 1581 | dprintf(("GDI32: CreateColorSpaceA - stub\n")); | 
|---|
| 1582 | return 0; | 
|---|
| 1583 | } | 
|---|
| 1584 | //****************************************************************************** | 
|---|
| 1585 | //****************************************************************************** | 
|---|
| 1586 | HCOLORSPACE WIN32API CreateColorSpaceW(                              /*KSO Thu 21.05.1998*/ | 
|---|
| 1587 | LPLOGCOLORSPACEW lpwLogColorSpace | 
|---|
| 1588 | ) | 
|---|
| 1589 | { | 
|---|
| 1590 | dprintf(("GDI32: CreateColorSpaceW - stub\n")); | 
|---|
| 1591 | return 0; | 
|---|
| 1592 | } | 
|---|
| 1593 | //****************************************************************************** | 
|---|
| 1594 | //****************************************************************************** | 
|---|
| 1595 | HANDLE WIN32API GetColorSpace(                                               /*KSO Thu 21.05.1998*/ | 
|---|
| 1596 | HDC hdc | 
|---|
| 1597 | ) | 
|---|
| 1598 | { | 
|---|
| 1599 | dprintf(("GDI32: GetColorSpace - stub\n")); | 
|---|
| 1600 | return 0; | 
|---|
| 1601 | } | 
|---|
| 1602 | //****************************************************************************** | 
|---|
| 1603 | //****************************************************************************** | 
|---|
| 1604 | int WIN32API SetICMMode(                                                             /*KSO Thu 21.05.1998*/ | 
|---|
| 1605 | HDC hdc, | 
|---|
| 1606 | int mode | 
|---|
| 1607 | ) | 
|---|
| 1608 | { | 
|---|
| 1609 | dprintf(("GDI32: SetICMMode - stub\n")); | 
|---|
| 1610 | return 0; | 
|---|
| 1611 | } | 
|---|
| 1612 | //****************************************************************************** | 
|---|
| 1613 |  | 
|---|
| 1614 |  | 
|---|
| 1615 |  | 
|---|
| 1616 |  | 
|---|
| 1617 | /***************************************************************************** | 
|---|
| 1618 | * Name      : BOOL CancelDC | 
|---|
| 1619 | * Purpose   : The CancelDC function cancels any pending operation on the | 
|---|
| 1620 | *             specified device context (DC). | 
|---|
| 1621 | * Parameters: HDC hdc   handle of device context | 
|---|
| 1622 | * Variables : | 
|---|
| 1623 | * Result    : TRUE / FALSE | 
|---|
| 1624 | * Remark    : | 
|---|
| 1625 | * Status    : UNTESTED STUB | 
|---|
| 1626 | * | 
|---|
| 1627 | * Author    : Patrick Haller [Mon, 1998/06/15 08:00] | 
|---|
| 1628 | *****************************************************************************/ | 
|---|
| 1629 |  | 
|---|
| 1630 | BOOL WIN32API CancelDC(HDC hdc) | 
|---|
| 1631 | { | 
|---|
| 1632 | dprintf(("GDI32: CancelDC(%08xh) not implemented.\n", | 
|---|
| 1633 | hdc)); | 
|---|
| 1634 |  | 
|---|
| 1635 | return (FALSE); | 
|---|
| 1636 | } | 
|---|
| 1637 |  | 
|---|
| 1638 |  | 
|---|
| 1639 | /***************************************************************************** | 
|---|
| 1640 | * Name      : BOOL CheckColorsInGamut | 
|---|
| 1641 | * Purpose   : The CheckColorsInGamut function indicates whether the specified | 
|---|
| 1642 | *             color values are within the gamut of the specified device. | 
|---|
| 1643 | * Parameters: HDC    hdc        handle of device context | 
|---|
| 1644 | *             LPVOID lpaRGBQuad | 
|---|
| 1645 | *             LPVOID lpResult | 
|---|
| 1646 | *             DWORD  dwResult | 
|---|
| 1647 | * Variables : | 
|---|
| 1648 | * Result    : TRUE / FALSE | 
|---|
| 1649 | * Remark    : | 
|---|
| 1650 | * Status    : UNTESTED STUB | 
|---|
| 1651 | * | 
|---|
| 1652 | * Author    : Patrick Haller [Mon, 1998/06/15 08:00] | 
|---|
| 1653 | *****************************************************************************/ | 
|---|
| 1654 |  | 
|---|
| 1655 | BOOL WIN32API CheckColorsInGamut(HDC    hdc, | 
|---|
| 1656 | LPVOID lpaRGBQuad, | 
|---|
| 1657 | LPVOID lpResult, | 
|---|
| 1658 | DWORD  dwResult) | 
|---|
| 1659 | { | 
|---|
| 1660 | dprintf(("GDI32: CheckColorsInGamut(%08xh,%08xh,%08xh,%08xh) not implemented.\n", | 
|---|
| 1661 | hdc, | 
|---|
| 1662 | lpaRGBQuad, | 
|---|
| 1663 | lpResult, | 
|---|
| 1664 | dwResult)); | 
|---|
| 1665 |  | 
|---|
| 1666 | return (FALSE); | 
|---|
| 1667 | } | 
|---|
| 1668 |  | 
|---|
| 1669 |  | 
|---|
| 1670 | /***************************************************************************** | 
|---|
| 1671 | * Name      : BOOL ColorMatchToTarget | 
|---|
| 1672 | * Purpose   : The ColorMatchToTarget function enables or disables preview for | 
|---|
| 1673 | *             the specified device context. When preview is enabled, colors | 
|---|
| 1674 | *             in subsequent output to the specified device context are | 
|---|
| 1675 | *             displayed as they would appear on the target device. This is | 
|---|
| 1676 | *             useful for checking how well the target maps the specified | 
|---|
| 1677 | *             colors in an image. To enable preview, image color matching | 
|---|
| 1678 | *             must be enabled for both the target and the preview device context. | 
|---|
| 1679 | * Parameters: HDC    hdc        handle of device context | 
|---|
| 1680 | *             HDC    hdcTarget  handle of target device context | 
|---|
| 1681 | *             DWORD  uiAction | 
|---|
| 1682 | * Variables : | 
|---|
| 1683 | * Result    : TRUE / FALSE | 
|---|
| 1684 | * Remark    : | 
|---|
| 1685 | * Status    : UNTESTED STUB | 
|---|
| 1686 | * | 
|---|
| 1687 | * Author    : Patrick Haller [Mon, 1998/06/15 08:00] | 
|---|
| 1688 | *****************************************************************************/ | 
|---|
| 1689 |  | 
|---|
| 1690 | BOOL WIN32API ColorMatchToTarget(HDC   hdc, | 
|---|
| 1691 | HDC   hdcTarget, | 
|---|
| 1692 | DWORD uiAction) | 
|---|
| 1693 | { | 
|---|
| 1694 | dprintf(("GDI32: ColorMatchToTarget(%08xh,%08xh,%08xh) not implemented.\n", | 
|---|
| 1695 | hdc, | 
|---|
| 1696 | hdcTarget, | 
|---|
| 1697 | uiAction)); | 
|---|
| 1698 |  | 
|---|
| 1699 | return (FALSE); | 
|---|
| 1700 | } | 
|---|
| 1701 |  | 
|---|
| 1702 |  | 
|---|
| 1703 | /***************************************************************************** | 
|---|
| 1704 | * Name      : BOOL CombineTransform | 
|---|
| 1705 | * Purpose   : The CombineTransform function concatenates two world-space to | 
|---|
| 1706 | *             page-space transformations. | 
|---|
| 1707 | * Parameters: LLPXFORM lLPXFORMResult address of combined transformation | 
|---|
| 1708 | *             XFORM  *lLPXFORM1      address of 1st transformation | 
|---|
| 1709 | *             XFORM  *lLPXFORM2      address of 2nd transformation | 
|---|
| 1710 | * Variables : | 
|---|
| 1711 | * Result    : TRUE / FALSE | 
|---|
| 1712 | * Remark    : | 
|---|
| 1713 | * Status    : UNTESTED | 
|---|
| 1714 | * | 
|---|
| 1715 | * Author    : Patrick Haller [Mon, 1998/06/15 08:00] | 
|---|
| 1716 | *             Markus Montkowski [Wen, 1999/01/12 20:18] | 
|---|
| 1717 | *****************************************************************************/ | 
|---|
| 1718 |  | 
|---|
| 1719 | BOOL WIN32API CombineTransform(LPXFORM lLPXFORMResult, | 
|---|
| 1720 | CONST   XFORM *lLPXFORM1, | 
|---|
| 1721 | CONST   XFORM *lLPXFORM2) | 
|---|
| 1722 | { | 
|---|
| 1723 | dprintf(("GDI32: CombineTransform(%08xh,%08xh,%08xh).\n", | 
|---|
| 1724 | lLPXFORMResult, | 
|---|
| 1725 | lLPXFORM1, | 
|---|
| 1726 | lLPXFORM2)); | 
|---|
| 1727 |  | 
|---|
| 1728 | XFORM xfrm; | 
|---|
| 1729 | if( O32_IsBadWritePtr( (void*)lLPXFORMResult, sizeof(XFORM)) || | 
|---|
| 1730 | O32_IsBadReadPtr(  (void*)lLPXFORM1, sizeof(XFORM)) || | 
|---|
| 1731 | O32_IsBadWritePtr( (void*)lLPXFORM2, sizeof(XFORM)) ) | 
|---|
| 1732 | return (FALSE); | 
|---|
| 1733 |  | 
|---|
| 1734 | // Add the translations | 
|---|
| 1735 | lLPXFORMResult->eDx = lLPXFORM1->eDx + lLPXFORM2->eDx; | 
|---|
| 1736 | lLPXFORMResult->eDy = lLPXFORM1->eDy + lLPXFORM2->eDy; | 
|---|
| 1737 |  | 
|---|
| 1738 | // Multiply the matrixes | 
|---|
| 1739 | xfrm.eM11 = lLPXFORM1->eM11 * lLPXFORM2->eM11 + lLPXFORM1->eM21 * lLPXFORM1->eM12; | 
|---|
| 1740 | xfrm.eM12 = lLPXFORM1->eM11 * lLPXFORM2->eM12 + lLPXFORM1->eM12 * lLPXFORM1->eM22; | 
|---|
| 1741 | xfrm.eM21 = lLPXFORM1->eM21 * lLPXFORM2->eM11 + lLPXFORM1->eM22 * lLPXFORM1->eM21; | 
|---|
| 1742 | xfrm.eM22 = lLPXFORM1->eM21 * lLPXFORM2->eM12 + lLPXFORM1->eM22 * lLPXFORM1->eM22; | 
|---|
| 1743 |  | 
|---|
| 1744 | // Now copy to resulting XFROM as the pt must not be distinct | 
|---|
| 1745 | lLPXFORMResult->eM11 = xfrm.eM11; | 
|---|
| 1746 | lLPXFORMResult->eM12 = xfrm.eM12; | 
|---|
| 1747 | lLPXFORMResult->eM21 = xfrm.eM21; | 
|---|
| 1748 | lLPXFORMResult->eM22 = xfrm.eM22; | 
|---|
| 1749 |  | 
|---|
| 1750 | return (TRUE); | 
|---|
| 1751 | } | 
|---|
| 1752 |  | 
|---|
| 1753 |  | 
|---|
| 1754 |  | 
|---|
| 1755 | /***************************************************************************** | 
|---|
| 1756 | * Name      : HBRUSH CreateDIBPatternBrush | 
|---|
| 1757 | * Purpose   : The CreateDIBPatternBrush function creates a logical brush that | 
|---|
| 1758 | *             has the pattern specified by the specified device-independent | 
|---|
| 1759 | *             bitmap (DIB). The brush can subsequently be selected into any | 
|---|
| 1760 | *             device context that is associated with a device that supports | 
|---|
| 1761 | *             raster operations. | 
|---|
| 1762 | *             This function is provided only for compatibility with applications | 
|---|
| 1763 | *             written for versions of Windows earlier than 3.0. For Win32-based | 
|---|
| 1764 | *             applications, use the CreateDIBPatternBrushPt function. | 
|---|
| 1765 | * Parameters: HGLOBAL hglbDIBPacked Identifies a global memory object containing | 
|---|
| 1766 | *             a packed DIB, which consists of a BITMAPINFO structure immediately | 
|---|
| 1767 | *             followed by an array of bytes defining the pixels of the bitmap. | 
|---|
| 1768 | *             UINT    fuColorSpec   color table data | 
|---|
| 1769 | * Variables : | 
|---|
| 1770 | * Result    : TRUE / FALSE | 
|---|
| 1771 | * Remark    : | 
|---|
| 1772 | * Status    : UNTESTED | 
|---|
| 1773 | * | 
|---|
| 1774 | * Author    : Patrick Haller [Mon, 1998/06/15 08:00] | 
|---|
| 1775 | *             Markus Montkowski [Wen, 1999/01/12 20:00] | 
|---|
| 1776 | *****************************************************************************/ | 
|---|
| 1777 |  | 
|---|
| 1778 | HBRUSH WIN32API CreateDIBPatternBrush( HGLOBAL hglbDIBPacked, | 
|---|
| 1779 | UINT    fuColorSpec) | 
|---|
| 1780 | { | 
|---|
| 1781 | LPVOID lpMem; | 
|---|
| 1782 | HBRUSH ret = 0; | 
|---|
| 1783 | dprintf(("GDI32: CreateDIBPatternBrush(%08xh, %08xh) \n", | 
|---|
| 1784 | hglbDIBPacked, | 
|---|
| 1785 | fuColorSpec)); | 
|---|
| 1786 |  | 
|---|
| 1787 | lpMem = GlobalLock(hglbDIBPacked); | 
|---|
| 1788 | if(NULL!=lpMem) | 
|---|
| 1789 | { | 
|---|
| 1790 |  | 
|---|
| 1791 | ret = CreateDIBPatternBrushPt( lpMem, | 
|---|
| 1792 | fuColorSpec); | 
|---|
| 1793 | GlobalUnlock(hglbDIBPacked); | 
|---|
| 1794 | } | 
|---|
| 1795 |  | 
|---|
| 1796 | return (ret); | 
|---|
| 1797 | } | 
|---|
| 1798 |  | 
|---|
| 1799 |  | 
|---|
| 1800 |  | 
|---|
| 1801 |  | 
|---|
| 1802 | /***************************************************************************** | 
|---|
| 1803 | * Name      : int EnumICMProfilesA | 
|---|
| 1804 | * Purpose   : The EnumICMProfilesA function enumerates the different color | 
|---|
| 1805 | *             profiles that the system supports for the specified device context. | 
|---|
| 1806 | * Parameters: HDC         hdc | 
|---|
| 1807 | *             ICMENUMPROC lpICMEnumFunc | 
|---|
| 1808 | *             LPARAM      lParam | 
|---|
| 1809 | * Variables : | 
|---|
| 1810 | * Result    : TRUE / FALSE | 
|---|
| 1811 | * Remark    : | 
|---|
| 1812 | * Status    : UNTESTED STUB | 
|---|
| 1813 | * | 
|---|
| 1814 | * Author    : Patrick Haller [Mon, 1998/06/15 08:00] | 
|---|
| 1815 | *****************************************************************************/ | 
|---|
| 1816 |  | 
|---|
| 1817 | int WIN32API EnumICMProfilesA(HDC         hdc, | 
|---|
| 1818 | ICMENUMPROCA lpICMEnumProc, | 
|---|
| 1819 | LPARAM      lParam) | 
|---|
| 1820 | { | 
|---|
| 1821 | dprintf(("GDI32: EnumICMProfilesA(%08xh, %08xh, %08xh) not implemented(-1).\n", | 
|---|
| 1822 | hdc, | 
|---|
| 1823 | lpICMEnumProc, | 
|---|
| 1824 | lParam)); | 
|---|
| 1825 |  | 
|---|
| 1826 | return (-1); | 
|---|
| 1827 | } | 
|---|
| 1828 |  | 
|---|
| 1829 |  | 
|---|
| 1830 | /***************************************************************************** | 
|---|
| 1831 | * Name      : int EnumICMProfilesW | 
|---|
| 1832 | * Purpose   : The EnumICMProfilesW function enumerates the different color | 
|---|
| 1833 | *             profiles that the system supports for the specified device context. | 
|---|
| 1834 | * Parameters: HDC         hdc | 
|---|
| 1835 | *             ICMENUMPROC lpICMEnumFunc | 
|---|
| 1836 | *             LPARAM      lParam | 
|---|
| 1837 | * Variables : | 
|---|
| 1838 | * Result    : TRUE / FALSE | 
|---|
| 1839 | * Remark    : | 
|---|
| 1840 | * Status    : UNTESTED STUB | 
|---|
| 1841 | * | 
|---|
| 1842 | * Author    : Patrick Haller [Mon, 1998/06/15 08:00] | 
|---|
| 1843 | *****************************************************************************/ | 
|---|
| 1844 |  | 
|---|
| 1845 | int WIN32API EnumICMProfilesW(HDC          hdc, | 
|---|
| 1846 | ICMENUMPROCW lpICMEnumProc, | 
|---|
| 1847 | LPARAM       lParam) | 
|---|
| 1848 | { | 
|---|
| 1849 | dprintf(("GDI32: EnumICMProfilesW(%08xh, %08xh, %08xh) not implemented (-1).\n", | 
|---|
| 1850 | hdc, | 
|---|
| 1851 | lpICMEnumProc, | 
|---|
| 1852 | lParam)); | 
|---|
| 1853 |  | 
|---|
| 1854 | return (-1); | 
|---|
| 1855 | } | 
|---|
| 1856 |  | 
|---|
| 1857 |  | 
|---|
| 1858 | /***************************************************************************** | 
|---|
| 1859 | * Name      : BOOL FixBrushOrgEx | 
|---|
| 1860 | * Purpose   : The FixBrushOrgEx function is not implemented in the Win32 API. | 
|---|
| 1861 | *             It is provided for compatibility with Win32s. If called, the | 
|---|
| 1862 | *             function does nothing, and returns FALSE. | 
|---|
| 1863 | * Parameters: HDC, int, int, LPPOINT | 
|---|
| 1864 | * Variables : | 
|---|
| 1865 | * Result    : TRUE / FALSE | 
|---|
| 1866 | * Remark    : not implemented in Win32 | 
|---|
| 1867 | * Status    : UNTESTED STUB | 
|---|
| 1868 | * | 
|---|
| 1869 | * Author    : Patrick Haller [Mon, 1998/06/15 08:00] | 
|---|
| 1870 | *****************************************************************************/ | 
|---|
| 1871 |  | 
|---|
| 1872 | BOOL WIN32API FixBrushOrgEx(HDC     hdc, | 
|---|
| 1873 | int     iDummy1, | 
|---|
| 1874 | int     iDummy2, | 
|---|
| 1875 | LPPOINT lpPoint) | 
|---|
| 1876 | { | 
|---|
| 1877 | dprintf(("GDI32: FixBrushOrgEx(%08xh,%08xh,%08xh,%08xh) not implemented.\n", | 
|---|
| 1878 | hdc, | 
|---|
| 1879 | iDummy1, | 
|---|
| 1880 | iDummy2, | 
|---|
| 1881 | lpPoint)); | 
|---|
| 1882 |  | 
|---|
| 1883 | return (FALSE); | 
|---|
| 1884 | } | 
|---|
| 1885 |  | 
|---|
| 1886 |  | 
|---|
| 1887 | /***************************************************************************** | 
|---|
| 1888 | * Name      : DWORD GdiGetBatchLimit | 
|---|
| 1889 | * Purpose   : The GdiGetBatchLimit function returns the maximum number of | 
|---|
| 1890 | *             function calls that can be accumulated in the calling thread's | 
|---|
| 1891 | *             current batch. The system flushes the current batch whenever | 
|---|
| 1892 | *             this limit is exceeded. | 
|---|
| 1893 | * Parameters: | 
|---|
| 1894 | * Variables : | 
|---|
| 1895 | * Result    : 1 | 
|---|
| 1896 | * Remark    : | 
|---|
| 1897 | * Status    : UNTESTED STUB | 
|---|
| 1898 | * | 
|---|
| 1899 | * Author    : Patrick Haller [Mon, 1998/06/15 08:00] | 
|---|
| 1900 | *****************************************************************************/ | 
|---|
| 1901 |  | 
|---|
| 1902 | DWORD WIN32API GdiGetBatchLimit(VOID) | 
|---|
| 1903 | { | 
|---|
| 1904 | dprintf(("GDI32: GdiGetBatchLimit() not implemented (1).\n")); | 
|---|
| 1905 |  | 
|---|
| 1906 | return (1); | 
|---|
| 1907 | } | 
|---|
| 1908 |  | 
|---|
| 1909 |  | 
|---|
| 1910 | /***************************************************************************** | 
|---|
| 1911 | * Name      : DWORD GdiSetBatchLimit | 
|---|
| 1912 | * Purpose   : The GdiSetBatchLimit function sets the maximum number of | 
|---|
| 1913 | *             functions that can be accumulated in the calling thread's current | 
|---|
| 1914 | *             batch. The system flushes the current batch whenever this limit | 
|---|
| 1915 | *             is exceeded. | 
|---|
| 1916 | * Parameters: DWORD dwLimit | 
|---|
| 1917 | * Variables : | 
|---|
| 1918 | * Result    : | 
|---|
| 1919 | * Remark    : | 
|---|
| 1920 | * Status    : UNTESTED STUB | 
|---|
| 1921 | * | 
|---|
| 1922 | * Author    : Patrick Haller [Mon, 1998/06/15 08:00] | 
|---|
| 1923 | *****************************************************************************/ | 
|---|
| 1924 |  | 
|---|
| 1925 | DWORD WIN32API GdiSetBatchLimit(DWORD dwLimit) | 
|---|
| 1926 | { | 
|---|
| 1927 | dprintf(("GDI32: GdiSetBatchLimit(%08xh) not implemented (1).\n", | 
|---|
| 1928 | dwLimit)); | 
|---|
| 1929 |  | 
|---|
| 1930 | return (1); | 
|---|
| 1931 | } | 
|---|
| 1932 |  | 
|---|
| 1933 |  | 
|---|
| 1934 | /***************************************************************************** | 
|---|
| 1935 | * Name      : DWORD GetCharacterPlacementA | 
|---|
| 1936 | * Purpose   : The GetCharacterPlacementA function retrieves information about | 
|---|
| 1937 | *             a character string, such as character widths, caret positioning, | 
|---|
| 1938 | *             ordering within the string, and glyph rendering. The type of | 
|---|
| 1939 | *             information returned depends on the dwFlags parameter and is | 
|---|
| 1940 | *             based on the currently selected font in the given display context. | 
|---|
| 1941 | *             The function copies the information to the specified GCP_RESULTSA | 
|---|
| 1942 | *             structure or to one or more arrays specified by the structure. | 
|---|
| 1943 | * Parameters: HDC     hdc        handle to device context | 
|---|
| 1944 | *             LPCSTR lpString   pointer to string | 
|---|
| 1945 | *             int     nCount     number of characters in string | 
|---|
| 1946 | *             int     nMaxExtent maximum extent for displayed string | 
|---|
| 1947 | *             LPGCP_RESULTSA *lpResults  pointer to buffer for placement result | 
|---|
| 1948 | *             DWORD   dwFlags    placement flags | 
|---|
| 1949 | * Variables : | 
|---|
| 1950 | * Result    : | 
|---|
| 1951 | * Remark    : | 
|---|
| 1952 | * Status    : UNTESTED STUB | 
|---|
| 1953 | * | 
|---|
| 1954 | * Author    : Patrick Haller [Mon, 1998/06/15 08:00] | 
|---|
| 1955 | *****************************************************************************/ | 
|---|
| 1956 |  | 
|---|
| 1957 | DWORD WIN32API GetCharacterPlacementA(HDC           hdc, | 
|---|
| 1958 | LPCSTR       lpString, | 
|---|
| 1959 | int           nCount, | 
|---|
| 1960 | int           nMaxExtent, | 
|---|
| 1961 | GCP_RESULTSA * lpResults, | 
|---|
| 1962 | DWORD         dwFlags) | 
|---|
| 1963 | { | 
|---|
| 1964 | dprintf(("GDI32: GetCharacterPlacementA(%08xh,%s,%08xh,%08xh,%08xh,%08xh) not implemented.\n", | 
|---|
| 1965 | hdc, | 
|---|
| 1966 | lpString, | 
|---|
| 1967 | nCount, | 
|---|
| 1968 | nMaxExtent, | 
|---|
| 1969 | lpResults, | 
|---|
| 1970 | dwFlags)); | 
|---|
| 1971 |  | 
|---|
| 1972 | return (0); | 
|---|
| 1973 | } | 
|---|
| 1974 |  | 
|---|
| 1975 |  | 
|---|
| 1976 | /***************************************************************************** | 
|---|
| 1977 | * Name      : DWORD GetCharacterPlacementW | 
|---|
| 1978 | * Purpose   : The GetCharacterPlacementW function retrieves information about | 
|---|
| 1979 | *             a character string, such as character widths, caret positioning, | 
|---|
| 1980 | *             ordering within the string, and glyph rendering. The type of | 
|---|
| 1981 | *             information returned depends on the dwFlags parameter and is | 
|---|
| 1982 | *             based on the currently selected font in the given display context. | 
|---|
| 1983 | *             The function copies the information to the specified GCP_RESULTSW | 
|---|
| 1984 | *             structure or to one or more arrays specified by the structure. | 
|---|
| 1985 | * Parameters: HDC     hdc        handle to device context | 
|---|
| 1986 | *             LPCSTR lpString   pointer to string | 
|---|
| 1987 | *             int     nCount     number of characters in string | 
|---|
| 1988 | *             int     nMaxExtent maximum extent for displayed string | 
|---|
| 1989 | *             GCP_RESULTSW *lpResults  pointer to buffer for placement result | 
|---|
| 1990 | *             DWORD   dwFlags    placement flags | 
|---|
| 1991 | * Variables : | 
|---|
| 1992 | * Result    : | 
|---|
| 1993 | * Remark    : | 
|---|
| 1994 | * Status    : UNTESTED STUB | 
|---|
| 1995 | * | 
|---|
| 1996 | * Author    : Patrick Haller [Mon, 1998/06/15 08:00] | 
|---|
| 1997 | *****************************************************************************/ | 
|---|
| 1998 |  | 
|---|
| 1999 | DWORD WIN32API GetCharacterPlacementW(HDC           hdc, | 
|---|
| 2000 | LPCWSTR       lpString, | 
|---|
| 2001 | int           nCount, | 
|---|
| 2002 | int           nMaxExtent, | 
|---|
| 2003 | GCP_RESULTSW *lpResults, | 
|---|
| 2004 | DWORD         dwFlags) | 
|---|
| 2005 | { | 
|---|
| 2006 | dprintf(("GDI32: GetCharacterPlacementW(%08xh,%s,%08xh,%08xh,%08xh,%08xh) not implemented.\n", | 
|---|
| 2007 | hdc, | 
|---|
| 2008 | lpString, | 
|---|
| 2009 | nCount, | 
|---|
| 2010 | nMaxExtent, | 
|---|
| 2011 | lpResults, | 
|---|
| 2012 | dwFlags)); | 
|---|
| 2013 |  | 
|---|
| 2014 | return (0); | 
|---|
| 2015 | } | 
|---|
| 2016 |  | 
|---|
| 2017 |  | 
|---|
| 2018 | /***************************************************************************** | 
|---|
| 2019 | * Name      : DWORD GetDeviceGammaRamp | 
|---|
| 2020 | * Purpose   : The GetDeviceGammaRamp function retrieves the gamma ramp on | 
|---|
| 2021 | *             direct color display boards. | 
|---|
| 2022 | * Parameters: HDC     hdc        handle to device context | 
|---|
| 2023 | *             LPVOID  lpRamp     Gamma ramp array | 
|---|
| 2024 | * Variables : | 
|---|
| 2025 | * Result    : | 
|---|
| 2026 | * Remark    : | 
|---|
| 2027 | * Status    : UNTESTED STUB | 
|---|
| 2028 | * | 
|---|
| 2029 | * Author    : Patrick Haller [Mon, 1998/06/15 08:00] | 
|---|
| 2030 | *****************************************************************************/ | 
|---|
| 2031 |  | 
|---|
| 2032 | DWORD WIN32API GetDeviceGammaRamp(HDC    hdc, | 
|---|
| 2033 | LPVOID lpRamp) | 
|---|
| 2034 | { | 
|---|
| 2035 | dprintf(("GDI32: GetDeviceGammaRamp(%08xh, %08xh) not implemented.\n", | 
|---|
| 2036 | hdc, | 
|---|
| 2037 | lpRamp)); | 
|---|
| 2038 |  | 
|---|
| 2039 | return (FALSE); | 
|---|
| 2040 | } | 
|---|
| 2041 |  | 
|---|
| 2042 |  | 
|---|
| 2043 |  | 
|---|
| 2044 |  | 
|---|
| 2045 | /***************************************************************************** | 
|---|
| 2046 | * Name      : BOOL GetICMProfileA | 
|---|
| 2047 | * Purpose   : The GetICMProfileA function retrieves the name of the color | 
|---|
| 2048 | *             profile file for the device associated with the specified device | 
|---|
| 2049 | *             context. | 
|---|
| 2050 | * Parameters: HDC     hdc        handle to device context | 
|---|
| 2051 | *             DWORD   cbName | 
|---|
| 2052 | *             LPTSTR  lpszFilename | 
|---|
| 2053 | * Variables : | 
|---|
| 2054 | * Result    : TRUE / FALSE | 
|---|
| 2055 | * Remark    : | 
|---|
| 2056 | * Status    : UNTESTED STUB | 
|---|
| 2057 | * | 
|---|
| 2058 | * Author    : Patrick Haller [Mon, 1998/06/15 08:00] | 
|---|
| 2059 | *****************************************************************************/ | 
|---|
| 2060 |  | 
|---|
| 2061 | BOOL WIN32API GetICMProfileA(HDC    hdc, | 
|---|
| 2062 | DWORD  cbName, | 
|---|
| 2063 | LPTSTR lpszFilename) | 
|---|
| 2064 | { | 
|---|
| 2065 | dprintf(("GDI32: GetICMProfileA(%08xh, %08xh, %08xh) not implemented.\n", | 
|---|
| 2066 | hdc, | 
|---|
| 2067 | cbName, | 
|---|
| 2068 | lpszFilename)); | 
|---|
| 2069 |  | 
|---|
| 2070 | return (FALSE); | 
|---|
| 2071 | } | 
|---|
| 2072 |  | 
|---|
| 2073 |  | 
|---|
| 2074 | /***************************************************************************** | 
|---|
| 2075 | * Name      : BOOL GetICMProfileW | 
|---|
| 2076 | * Purpose   : The GetICMProfileW function retrieves the name of the color | 
|---|
| 2077 | *             profile file for the device associated with the specified device | 
|---|
| 2078 | *             context. | 
|---|
| 2079 | * Parameters: HDC     hdc        handle to device context | 
|---|
| 2080 | *             DWORD   cbName | 
|---|
| 2081 | *             LPWSTR  lpszFilename | 
|---|
| 2082 | * Variables : | 
|---|
| 2083 | * Result    : TRUE / FALSE | 
|---|
| 2084 | * Remark    : | 
|---|
| 2085 | * Status    : UNTESTED STUB | 
|---|
| 2086 | * | 
|---|
| 2087 | * Author    : Patrick Haller [Mon, 1998/06/15 08:00] | 
|---|
| 2088 | *****************************************************************************/ | 
|---|
| 2089 |  | 
|---|
| 2090 | BOOL WIN32API GetICMProfileW(HDC    hdc, | 
|---|
| 2091 | DWORD  cbName, | 
|---|
| 2092 | LPTSTR lpszFilename) | 
|---|
| 2093 | { | 
|---|
| 2094 | dprintf(("GDI32: GetICMProfileW(%08xh, %08xh, %08xh) not implemented.\n", | 
|---|
| 2095 | hdc, | 
|---|
| 2096 | cbName, | 
|---|
| 2097 | lpszFilename)); | 
|---|
| 2098 |  | 
|---|
| 2099 | return (FALSE); | 
|---|
| 2100 | } | 
|---|
| 2101 |  | 
|---|
| 2102 |  | 
|---|
| 2103 | /***************************************************************************** | 
|---|
| 2104 | * Name      : BOOL GetLogColorSpaceA | 
|---|
| 2105 | * Purpose   : The GetLogColorSpace function retrieves information about the | 
|---|
| 2106 | *             logical color space identified by the specified handle. | 
|---|
| 2107 | * Parameters: HCOLORSPACE     hColorSpace | 
|---|
| 2108 | *             LPLOGCOLORSPACE lpbuffer | 
|---|
| 2109 | *             DWORD           nSize | 
|---|
| 2110 | * Variables : | 
|---|
| 2111 | * Result    : TRUE / FALSE | 
|---|
| 2112 | * Remark    : | 
|---|
| 2113 | * Status    : UNTESTED STUB | 
|---|
| 2114 | * | 
|---|
| 2115 | * Author    : Patrick Haller [Mon, 1998/06/15 08:00] | 
|---|
| 2116 | *****************************************************************************/ | 
|---|
| 2117 |  | 
|---|
| 2118 | #define LPLOGCOLORSPACE LPVOID | 
|---|
| 2119 | BOOL WIN32API GetLogColorSpaceA(HCOLORSPACE     hColorSpace, | 
|---|
| 2120 | LPLOGCOLORSPACE lpBuffer, | 
|---|
| 2121 | DWORD           nSize) | 
|---|
| 2122 | { | 
|---|
| 2123 | dprintf(("GDI32: GetLogColorSpaceA(%08xh, %08xh, %08xh) not implemented.\n", | 
|---|
| 2124 | hColorSpace, | 
|---|
| 2125 | lpBuffer, | 
|---|
| 2126 | nSize)); | 
|---|
| 2127 |  | 
|---|
| 2128 | return (FALSE); | 
|---|
| 2129 | } | 
|---|
| 2130 |  | 
|---|
| 2131 |  | 
|---|
| 2132 | /***************************************************************************** | 
|---|
| 2133 | * Name      : BOOL GetLogColorSpaceW | 
|---|
| 2134 | * Purpose   : The GetLogColorSpace function retrieves information about the | 
|---|
| 2135 | *             logical color space identified by the specified handle. | 
|---|
| 2136 | * Parameters: HCOLORSPACE     hColorSpace | 
|---|
| 2137 | *             LPLOGCOLORSPACE lpbuffer | 
|---|
| 2138 | *             DWORD           nSize | 
|---|
| 2139 | * Variables : | 
|---|
| 2140 | * Result    : TRUE / FALSE | 
|---|
| 2141 | * Remark    : | 
|---|
| 2142 | * Status    : UNTESTED STUB | 
|---|
| 2143 | * | 
|---|
| 2144 | * Author    : Patrick Haller [Mon, 1998/06/15 08:00] | 
|---|
| 2145 | *****************************************************************************/ | 
|---|
| 2146 |  | 
|---|
| 2147 | BOOL WIN32API GetLogColorSpaceW(HCOLORSPACE     hColorSpace, | 
|---|
| 2148 | LPLOGCOLORSPACE lpBuffer, | 
|---|
| 2149 | DWORD           nSize) | 
|---|
| 2150 | { | 
|---|
| 2151 | dprintf(("GDI32: GetLogColorSpaceW(%08xh, %08xh, %08xh) not implemented.\n", | 
|---|
| 2152 | hColorSpace, | 
|---|
| 2153 | lpBuffer, | 
|---|
| 2154 | nSize)); | 
|---|
| 2155 |  | 
|---|
| 2156 | return (FALSE); | 
|---|
| 2157 | } | 
|---|
| 2158 |  | 
|---|
| 2159 |  | 
|---|
| 2160 | /***************************************************************************** | 
|---|
| 2161 | * Name      : BOOL SetDeviceGammaRamp | 
|---|
| 2162 | * Purpose   : The SetDeviceGammaRamp function sets the gamma ramp on direct | 
|---|
| 2163 | *             color display boards. | 
|---|
| 2164 | * Parameters: HDC    hdc   handle of device context | 
|---|
| 2165 | *             LPVOID lpRamp | 
|---|
| 2166 | * Variables : | 
|---|
| 2167 | * Result    : TRUE / FALSE | 
|---|
| 2168 | * Remark    : | 
|---|
| 2169 | * Status    : UNTESTED STUB | 
|---|
| 2170 | * | 
|---|
| 2171 | * Author    : Patrick Haller [Mon, 1998/06/15 08:00] | 
|---|
| 2172 | *****************************************************************************/ | 
|---|
| 2173 |  | 
|---|
| 2174 | BOOL WIN32API SetDeviceGammaRamp(HDC    hdc, | 
|---|
| 2175 | LPVOID lpRamp) | 
|---|
| 2176 | { | 
|---|
| 2177 | dprintf(("GDI32: SetDeviceGammaRamp(%08xh, %08xh) not implemented.\n", | 
|---|
| 2178 | hdc, | 
|---|
| 2179 | lpRamp)); | 
|---|
| 2180 |  | 
|---|
| 2181 | return (FALSE); | 
|---|
| 2182 | } | 
|---|
| 2183 |  | 
|---|
| 2184 |  | 
|---|
| 2185 | /***************************************************************************** | 
|---|
| 2186 | * Name      : BOOL SetICMProfileA | 
|---|
| 2187 | * Purpose   : The SetICMProfileA function sets the color profile for the | 
|---|
| 2188 | *             specified device context. | 
|---|
| 2189 | * Parameters: HDC    hdc   handle of device context | 
|---|
| 2190 | *             LPTSTR lpFileName | 
|---|
| 2191 | * Variables : | 
|---|
| 2192 | * Result    : TRUE / FALSE | 
|---|
| 2193 | * Remark    : | 
|---|
| 2194 | * Status    : UNTESTED STUB | 
|---|
| 2195 | * | 
|---|
| 2196 | * Author    : Patrick Haller [Mon, 1998/06/15 08:00] | 
|---|
| 2197 | *****************************************************************************/ | 
|---|
| 2198 |  | 
|---|
| 2199 | BOOL WIN32API SetICMProfileA(HDC    hdc, | 
|---|
| 2200 | LPTSTR lpFileName) | 
|---|
| 2201 | { | 
|---|
| 2202 | dprintf(("GDI32: SetICMProfileA(%08xh, %s) not implemented.\n", | 
|---|
| 2203 | hdc, | 
|---|
| 2204 | lpFileName)); | 
|---|
| 2205 |  | 
|---|
| 2206 | return (FALSE); | 
|---|
| 2207 | } | 
|---|
| 2208 |  | 
|---|
| 2209 |  | 
|---|
| 2210 | /***************************************************************************** | 
|---|
| 2211 | * Name      : BOOL SetICMProfileW | 
|---|
| 2212 | * Purpose   : The SetICMProfileW function sets the color profile for the | 
|---|
| 2213 | *             specified device context. | 
|---|
| 2214 | * Parameters: HDC    hdc   handle of device context | 
|---|
| 2215 | *             LPTSTR lpFileName | 
|---|
| 2216 | * Variables : | 
|---|
| 2217 | * Result    : TRUE / FALSE | 
|---|
| 2218 | * Remark    : | 
|---|
| 2219 | * Status    : UNTESTED STUB | 
|---|
| 2220 | * | 
|---|
| 2221 | * Author    : Patrick Haller [Mon, 1998/06/15 08:00] | 
|---|
| 2222 | *****************************************************************************/ | 
|---|
| 2223 |  | 
|---|
| 2224 | BOOL WIN32API SetICMProfileW(HDC    hdc, | 
|---|
| 2225 | LPWSTR lpFileName) | 
|---|
| 2226 | { | 
|---|
| 2227 | dprintf(("GDI32: SetICMProfileW(%08xh, %s) not implemented.\n", | 
|---|
| 2228 | hdc, | 
|---|
| 2229 | lpFileName)); | 
|---|
| 2230 |  | 
|---|
| 2231 | return (FALSE); | 
|---|
| 2232 | } | 
|---|
| 2233 |  | 
|---|
| 2234 |  | 
|---|
| 2235 |  | 
|---|
| 2236 | /***************************************************************************** | 
|---|
| 2237 | * Name      : BOOL UpdateICMRegKeyA | 
|---|
| 2238 | * Purpose   : The UpdateICMRegKeyA function installs, removes, or queries | 
|---|
| 2239 | *             registry entries that identify ICC color profiles or color-matching | 
|---|
| 2240 | *             DLLs. The function carries out the action specified by the nCommand | 
|---|
| 2241 | *             parameter. | 
|---|
| 2242 | * Parameters: DWORD   dwReserved | 
|---|
| 2243 | *             DWORD   CMID | 
|---|
| 2244 | *             LPTSTR  lpszFileName | 
|---|
| 2245 | *             UINT    nCommand | 
|---|
| 2246 | * Variables : | 
|---|
| 2247 | * Result    : TRUE / FALSE | 
|---|
| 2248 | * Remark    : | 
|---|
| 2249 | * Status    : UNTESTED STUB | 
|---|
| 2250 | * | 
|---|
| 2251 | * Author    : Patrick Haller [Mon, 1998/06/15 08:00] | 
|---|
| 2252 | *****************************************************************************/ | 
|---|
| 2253 |  | 
|---|
| 2254 | BOOL WIN32API UpdateICMRegKeyA(DWORD  dwReserved, | 
|---|
| 2255 | DWORD  CMID, | 
|---|
| 2256 | LPTSTR lpszFileName, | 
|---|
| 2257 | UINT   nCommand) | 
|---|
| 2258 | { | 
|---|
| 2259 | dprintf(("GDI32: UpdateICMRegKeyA(%08xh, %08xh, %08xh, %08xh) not implemented.\n", | 
|---|
| 2260 | dwReserved, | 
|---|
| 2261 | CMID, | 
|---|
| 2262 | lpszFileName, | 
|---|
| 2263 | nCommand)); | 
|---|
| 2264 |  | 
|---|
| 2265 | return (FALSE); | 
|---|
| 2266 | } | 
|---|
| 2267 |  | 
|---|
| 2268 |  | 
|---|
| 2269 | /***************************************************************************** | 
|---|
| 2270 | * Name      : BOOL UpdateICMRegKeyW | 
|---|
| 2271 | * Purpose   : The UpdateICMRegKeyW function installs, removes, or queries | 
|---|
| 2272 | *             registry entries that identify ICC color profiles or color-matching | 
|---|
| 2273 | *             DLLs. The function carries out the action specified by the nCommand | 
|---|
| 2274 | *             parameter. | 
|---|
| 2275 | * Parameters: DWORD   dwReserved | 
|---|
| 2276 | *             DWORD   CMID | 
|---|
| 2277 | *             LPWSTR  lpszFileName | 
|---|
| 2278 | *             UINT    nCommand | 
|---|
| 2279 | * Variables : | 
|---|
| 2280 | * Result    : TRUE / FALSE | 
|---|
| 2281 | * Remark    : | 
|---|
| 2282 | * Status    : UNTESTED STUB | 
|---|
| 2283 | * | 
|---|
| 2284 | * Author    : Patrick Haller [Mon, 1998/06/15 08:00] | 
|---|
| 2285 | *****************************************************************************/ | 
|---|
| 2286 |  | 
|---|
| 2287 | BOOL WIN32API UpdateICMRegKeyW(DWORD  dwReserved, | 
|---|
| 2288 | DWORD  CMID, | 
|---|
| 2289 | LPWSTR lpszFileName, | 
|---|
| 2290 | UINT   nCommand) | 
|---|
| 2291 | { | 
|---|
| 2292 | dprintf(("GDI32: UpdateICMRegKeyW(%08xh, %08xh, %08xh, %08xh) not implemented.\n", | 
|---|
| 2293 | dwReserved, | 
|---|
| 2294 | CMID, | 
|---|
| 2295 | lpszFileName, | 
|---|
| 2296 | nCommand)); | 
|---|
| 2297 |  | 
|---|
| 2298 | return (FALSE); | 
|---|
| 2299 | } | 
|---|
| 2300 |  | 
|---|
| 2301 |  | 
|---|
| 2302 |  | 
|---|