Qt: TQtWidgetSet.CreateRectRgn() create region with X=0 and Y=0 and then translate by offset X1 and Y1

git-svn-id: trunk@30607 -
This commit is contained in:
zeljko 2011-05-07 19:27:55 +00:00
parent b531c7e6c8
commit 6a9535a69a

View File

@ -757,7 +757,7 @@ function TQtWidgetSet.CreateRectRgn(X1,Y1,X2,Y2 : Integer): HRGN;
var
QtRegion: TQtRegion;
begin
QtRegion := TQtRegion.Create(True, X1, Y1, X2, Y2);
QtRegion := TQtRegion.Create(True, 0, 0, X2, Y2);
if (X1 <> 0) or (Y1 <> 0) then
QtRegion.translate(X1, Y1);
Result := HRGN(QtRegion);