implemented PS_DOT, PS_DASH and PS_INSIDEFRAME in IntGdiCreatePenIndirect

(speeds up Thunderbird a bit (much less debug output)

svn path=/trunk/; revision=20853
This commit is contained in:
Christoph von Wittich 2006-01-14 16:08:57 +00:00
parent e1fd1adbfa
commit 9a1758ce5a

View file

@ -33,6 +33,8 @@ IntGdiCreatePenIndirect(PLOGPEN LogPen)
HPEN hPen;
PGDIBRUSHOBJ PenObject;
static const WORD wPatternAlternate[] = {0x5555};
static const WORD wPatternDash[] = {0x0F0F};
static const WORD wPatternDot[] = {0x3333};
if (LogPen->lopnStyle > PS_INSIDEFRAME)
return 0;
@ -66,6 +68,21 @@ IntGdiCreatePenIndirect(PLOGPEN LogPen)
PenObject->hbmPattern = NtGdiCreateBitmap(8, 1, 1, 1, (LPBYTE)wPatternAlternate);
break;
case PS_DOT:
PenObject->flAttrs |= GDIBRUSH_IS_BITMAP;
PenObject->hbmPattern = NtGdiCreateBitmap(8, 1, 1, 1, (LPBYTE)wPatternDot);
break;
case PS_DASH:
PenObject->flAttrs |= GDIBRUSH_IS_BITMAP;
PenObject->hbmPattern = NtGdiCreateBitmap(8, 1, 1, 1, (LPBYTE)wPatternDash);
break;
case PS_INSIDEFRAME:
/* FIXME: does it need some additional work? */
PenObject->flAttrs |= GDIBRUSH_IS_SOLID;
break;
default:
DPRINT1("FIXME: IntGdiCreatePenIndirect is UNIMPLEMENTED\n");
}