mirror of
https://gitlab.com/freepascal.org/lazarus/lazarus.git
synced 2025-06-10 05:58:16 +02:00
gtk intf: TGtkWidgetSet.CreateBrushIndirect: gdk_pixbuf_render_pixmap_and_mask creates the pixmap and mask itself
git-svn-id: trunk@21790 -
This commit is contained in:
parent
f75643d1fa
commit
90d57b132f
@ -969,7 +969,6 @@ const
|
|||||||
var
|
var
|
||||||
GObject: PGdiObject;
|
GObject: PGdiObject;
|
||||||
TmpMask: PGdkBitmap;
|
TmpMask: PGdkBitmap;
|
||||||
W, H: Integer;
|
|
||||||
begin
|
begin
|
||||||
Assert(False, Format('Trace:> [TGtkWidgetSet.CreateBrushIndirect] Style: %d, Color: %8x', [LogBrush.lbStyle, LogBrush.lbColor]));
|
Assert(False, Format('Trace:> [TGtkWidgetSet.CreateBrushIndirect] Style: %d, Color: %8x', [LogBrush.lbStyle, LogBrush.lbColor]));
|
||||||
|
|
||||||
@ -1046,11 +1045,10 @@ begin
|
|||||||
end;
|
end;
|
||||||
gbPixbuf:
|
gbPixbuf:
|
||||||
begin
|
begin
|
||||||
W := gdk_pixbuf_get_width(PGdiObject(lbHatch)^.GDIPixbufObject);
|
GObject^.GDIBrushPixmap := nil;
|
||||||
H := gdk_pixbuf_get_height(PGdiObject(lbHatch)^.GDIPixbufObject);
|
TmpMask := nil;
|
||||||
GObject^.GDIBrushPixmap := gdk_pixmap_new(nil, W, H, 24);
|
gdk_pixbuf_render_pixmap_and_mask(PGdiObject(lbHatch)^.GDIPixbufObject,
|
||||||
TmpMask := gdk_pixmap_new(nil, W, H, 1);
|
GObject^.GDIBrushPixmap, TmpMask, $80);
|
||||||
gdk_pixbuf_render_pixmap_and_mask(PGdiObject(lbHatch)^.GDIPixbufObject, GObject^.GDIBrushPixmap, TmpMask, $80);
|
|
||||||
gdk_pixmap_unref(TmpMask);
|
gdk_pixmap_unref(TmpMask);
|
||||||
end;
|
end;
|
||||||
else
|
else
|
||||||
|
Loading…
Reference in New Issue
Block a user