mirror of
https://gitlab.com/freepascal.org/lazarus/lazarus.git
synced 2025-07-28 19:56:24 +02:00
MG: added TDeviceContext.SelectedColors
git-svn-id: trunk@2375 -
This commit is contained in:
parent
ed7dea699c
commit
69bef405be
@ -133,14 +133,26 @@ type
|
|||||||
dccGDIPenColor
|
dccGDIPenColor
|
||||||
);
|
);
|
||||||
|
|
||||||
|
TDevContextSelectedColorsType = (
|
||||||
|
dcscCustom,
|
||||||
|
dcscPen,
|
||||||
|
dcscBrush,
|
||||||
|
dcscFont
|
||||||
|
);
|
||||||
|
|
||||||
TDeviceContext = class
|
TDeviceContext = class
|
||||||
public
|
public
|
||||||
|
// device handles
|
||||||
hWnd: HWND;
|
hWnd: HWND;
|
||||||
GC: pgdkGC;
|
GC: pgdkGC;
|
||||||
Drawable: PGDKDrawable;
|
Drawable: PGDKDrawable;
|
||||||
|
|
||||||
|
// origins
|
||||||
Origin: TPoint;
|
Origin: TPoint;
|
||||||
SpecialOrigin: boolean;
|
SpecialOrigin: boolean;
|
||||||
PenPos: TPoint;
|
PenPos: TPoint;
|
||||||
|
|
||||||
|
// drawing settings
|
||||||
CurrentBitmap: PGdiObject;
|
CurrentBitmap: PGdiObject;
|
||||||
CurrentFont: PGdiObject;
|
CurrentFont: PGdiObject;
|
||||||
CurrentPen: PGdiObject;
|
CurrentPen: PGdiObject;
|
||||||
@ -149,6 +161,9 @@ type
|
|||||||
CurrentTextColor: TGDIColor;
|
CurrentTextColor: TGDIColor;
|
||||||
CurrentBackColor: TGDIColor;
|
CurrentBackColor: TGDIColor;
|
||||||
ClipRegion : hRGN;
|
ClipRegion : hRGN;
|
||||||
|
|
||||||
|
// control
|
||||||
|
SelectedColors: TDevContextSelectedColorsType;
|
||||||
SavedContext: TDeviceContext; // linked list of saved DCs
|
SavedContext: TDeviceContext; // linked list of saved DCs
|
||||||
DCFlags: TDeviceContextsFlags;
|
DCFlags: TDeviceContextsFlags;
|
||||||
procedure Clear;
|
procedure Clear;
|
||||||
@ -372,11 +387,13 @@ begin
|
|||||||
hWnd:=0;
|
hWnd:=0;
|
||||||
GC:=nil;
|
GC:=nil;
|
||||||
Drawable:=nil;
|
Drawable:=nil;
|
||||||
|
|
||||||
Origin.X:=0;
|
Origin.X:=0;
|
||||||
Origin.Y:=0;
|
Origin.Y:=0;
|
||||||
SpecialOrigin:=false;
|
SpecialOrigin:=false;
|
||||||
PenPos.X:=0;
|
PenPos.X:=0;
|
||||||
PenPos.Y:=0;
|
PenPos.Y:=0;
|
||||||
|
|
||||||
CurrentBitmap:=nil;
|
CurrentBitmap:=nil;
|
||||||
CurrentFont:=nil;
|
CurrentFont:=nil;
|
||||||
CurrentPen:=nil;
|
CurrentPen:=nil;
|
||||||
@ -385,6 +402,8 @@ begin
|
|||||||
FillChar(CurrentTextColor,SizeOf(CurrentTextColor),0);
|
FillChar(CurrentTextColor,SizeOf(CurrentTextColor),0);
|
||||||
FillChar(CurrentBackColor,SizeOf(CurrentBackColor),0);
|
FillChar(CurrentBackColor,SizeOf(CurrentBackColor),0);
|
||||||
ClipRegion:=0;
|
ClipRegion:=0;
|
||||||
|
|
||||||
|
SelectedColors:=dcscCustom;
|
||||||
SavedContext:=nil;
|
SavedContext:=nil;
|
||||||
DCFlags:=[];
|
DCFlags:=[];
|
||||||
end;
|
end;
|
||||||
@ -400,6 +419,9 @@ end.
|
|||||||
{ =============================================================================
|
{ =============================================================================
|
||||||
|
|
||||||
$Log$
|
$Log$
|
||||||
|
Revision 1.24 2002/10/08 14:10:02 lazarus
|
||||||
|
MG: added TDeviceContext.SelectedColors
|
||||||
|
|
||||||
Revision 1.23 2002/10/08 13:42:23 lazarus
|
Revision 1.23 2002/10/08 13:42:23 lazarus
|
||||||
MG: added TDevContextColorType
|
MG: added TDevContextColorType
|
||||||
|
|
||||||
|
Loading…
Reference in New Issue
Block a user