mirror of
https://gitlab.com/freepascal.org/lazarus/lazarus.git
synced 2025-08-14 05:00:25 +02:00
CairoCanvas: debugclip
git-svn-id: trunk@40981 -
This commit is contained in:
parent
24fb6810b9
commit
edbbec026e
@ -8,6 +8,7 @@ unit CairoCanvas;
|
|||||||
|
|
||||||
{$define pangocairo}
|
{$define pangocairo}
|
||||||
{-$define breaklines} // disabled as it's not UTF-8 safe
|
{-$define breaklines} // disabled as it's not UTF-8 safe
|
||||||
|
{-$define DebugClip}
|
||||||
|
|
||||||
interface
|
interface
|
||||||
|
|
||||||
@ -355,6 +356,14 @@ begin
|
|||||||
|
|
||||||
cairo_reset_clip(cr);
|
cairo_reset_clip(cr);
|
||||||
|
|
||||||
|
{$ifdef DebugClip}
|
||||||
|
with fUserClipRect^ do begin
|
||||||
|
DrawPoint(x, y, clRed);
|
||||||
|
DrawPoint(x+Width, y+Height, clBlue);
|
||||||
|
DrawRefRect(x, y, width, height, clAqua);
|
||||||
|
end;
|
||||||
|
{$endif}
|
||||||
|
|
||||||
with fUserClipRect^ do
|
with fUserClipRect^ do
|
||||||
cairo_rectangle(cr, x, y, width, Height);
|
cairo_rectangle(cr, x, y, width, Height);
|
||||||
|
|
||||||
@ -968,9 +977,11 @@ begin
|
|||||||
r := BoxWidth+Pen.Width;
|
r := BoxWidth+Pen.Width;
|
||||||
b := BoxHeight+Pen.Width;
|
b := BoxHeight+Pen.Width;
|
||||||
|
|
||||||
//DrawPoint(boxLeft, boxTop, clRed);
|
{$ifdef DebugClip}
|
||||||
//DrawPoint(boxLeft+r, boxTop+b, clBlue);
|
DrawPoint(boxLeft, boxTop, clRed);
|
||||||
//DrawRefRect(boxLeft, boxTop, r, b, clGreen);
|
DrawPoint(boxLeft+r, boxTop+b, clBlue);
|
||||||
|
DrawRefRect(boxLeft, boxTop, r, b, clGreen);
|
||||||
|
{$endif}
|
||||||
|
|
||||||
cairo_rectangle(cr, BoxLeft, BoxTop, r, b);
|
cairo_rectangle(cr, BoxLeft, BoxTop, r, b);
|
||||||
cairo_clip(cr);
|
cairo_clip(cr);
|
||||||
|
Loading…
Reference in New Issue
Block a user