2 * ReactOS W32 Subsystem
3 * Copyright (C) 1998, 1999, 2000, 2001, 2002, 2003 ReactOS Team
5 * This program is free software; you can redistribute it and/or modify
6 * it under the terms of the GNU General Public License as published by
7 * the Free Software Foundation; either version 2 of the License, or
8 * (at your option) any later version.
10 * This program is distributed in the hope that it will be useful,
11 * but WITHOUT ANY WARRANTY; without even the implied warranty of
12 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
13 * GNU General Public License for more details.
15 * You should have received a copy of the GNU General Public License
16 * along with this program; if not, write to the Free Software
17 * Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA.
20 #undef WIN32_LEAN_AND_MEAN
22 #include <ddk/ntddk.h>
23 #include <win32k/pen.h>
26 #include <win32k/debug1.h>
30 NtGdiCreatePen(INT PenStyle, INT Width, COLORREF Color)
34 logpen.lopnStyle = PenStyle;
35 logpen.lopnWidth.x = Width;
36 logpen.lopnWidth.y = 0;
37 logpen.lopnColor = Color;
39 return NtGdiCreatePenIndirect(&logpen);
44 NtGdiCreatePenIndirect(CONST PLOGPEN lgpn)
49 if (lgpn->lopnStyle > PS_INSIDEFRAME) return 0;
51 hpen = PENOBJ_AllocPen();
54 penPtr = PENOBJ_LockPen( hpen );
57 penPtr->logpen.lopnStyle = lgpn->lopnStyle;
58 penPtr->logpen.lopnWidth = lgpn->lopnWidth;
59 penPtr->logpen.lopnColor = lgpn->lopnColor;
60 PENOBJ_UnlockPen( hpen );
66 NtGdiExtCreatePen(DWORD PenStyle,