+ added the win16api pen support functions

git-svn-id: trunk@31616 -
This commit is contained in:
nickysn 2015-09-12 12:27:54 +00:00
parent 1181eb0ddb
commit c0a63ea0ab
2 changed files with 37 additions and 0 deletions

View File

@ -370,3 +370,11 @@ function UnrealizeObject(hgdiobj: HGDIOBJ): BOOL; external 'GDI';
function EnumObjects(hdc: HDC; fnObjectType: SmallInt; goenmprc: GOBJENUMPROC; lParam: LPARAM): SmallInt; external 'GDI';
function EnumObjects(hdc: HDC; fnObjectType: SmallInt; goenmprc: FARPROC; lParam: LPARAM): SmallInt; external 'GDI';
{ Pen support }
function CreatePen(fnPenStyle, nWidth: SmallInt; clrref: COLORREF): HPEN; external 'GDI';
function CreatePenIndirect(lplgpn: LPLOGPEN): HPEN; external 'GDI';
{$ifdef VAR_PARAMS_ARE_FAR}
function CreatePenIndirect(var lgpn: LOGPEN): HPEN; external 'GDI';
{$endif}

View File

@ -540,3 +540,32 @@ const
{ Object types for EnumObjects() }
OBJ_PEN = 1;
OBJ_BRUSH = 2;
{ Pen support }
{ Logical Pen }
type
PLOGPEN = ^LOGPEN;
NPLOGPEN = ^LOGPEN; near;
LPLOGPEN = ^LOGPEN; far;
LOGPEN = record
lopnStyle: UINT;
lopnWidth: POINT;
lopnColor: COLORREF;
end;
TLogPen = LOGPEN;
{ Pen Styles }
const
PS_SOLID = 0;
PS_DASH = 1;
PS_DOT = 2;
PS_DASHDOT = 3;
PS_DASHDOTDOT = 4;
PS_NULL = 5;
PS_INSIDEFRAME = 6;
{ Stock pens for use with GetStockObject(); }
WHITE_PEN = 6;
BLACK_PEN = 7;
NULL_PEN = 8;