diff --git a/lcl/include/intfbasewinapi.inc b/lcl/include/intfbasewinapi.inc index 899a85daf8..6539c4347d 100644 --- a/lcl/include/intfbasewinapi.inc +++ b/lcl/include/intfbasewinapi.inc @@ -864,7 +864,7 @@ begin // ' Clip=',DbgS(Clip),8),' RGn=',DbgS(Cardinal(RGN),' Mode=',dbgs(Mode)); Result := CombineRGN(Clip, OldC, RGN, Mode); //DebugLn('TWidgetSet.ExtSelectClipRGN B Result=',Result); - If Result <> ERROR then + if Result <> ERROR then Result := SelectClipRGN(DC, Clip); DeleteObject(Clip); DeleteObject(OldC); @@ -1192,7 +1192,7 @@ begin RRGN := CreateRectRgn(Left, Top, Right, Bottom); //DebugLn('TWidgetSet.IntersectClipRect A RGN=',DbgS(RRGN), // ' ',dbgs(Left),',',dbgs(Top),',',dbgs(Right),',',dbgs(Bottom)); - If not DCClipRegionValid(DC) then + if not DCClipRegionValid(DC) then Result := SelectClipRGN(DC, RRGN) else Result := ExtSelectClipRGN(DC, RRGN, RGN_AND); diff --git a/lcl/interfaces/gtk2/gtk2winapi.inc b/lcl/interfaces/gtk2/gtk2winapi.inc index 7fa44906d2..dcd854ae5b 100644 --- a/lcl/interfaces/gtk2/gtk2winapi.inc +++ b/lcl/interfaces/gtk2/gtk2winapi.inc @@ -1774,7 +1774,7 @@ begin S2Obj := PGdiObject(Src2); Continue := IsValidGDIObject(Dest) and IsValidGDIObject(Src1) and IsValidGDIObject(Src2); - If Not Continue then begin + if not Continue then begin DebugLn('WARNING: [TGtk2WidgetSet.CombineRgn] Invalid HRGN'); Result := Error; end @@ -1782,7 +1782,7 @@ begin S1 := S1Obj^.GDIRegionObject; S2 := S2Obj^.GDIRegionObject; //DebugLn('TGtk2WidgetSet.CombineRgn A fnCombineMode=',Dbgs(fnCombineMode)); - Case fnCombineMode of + case fnCombineMode of RGN_AND : D := PGDKRegion(gdk_region_intersect(S1, S2)); RGN_COPY : @@ -3325,15 +3325,15 @@ var DCOrigin: TPoint; begin Result := SIMPLEREGION; - If not IsValidDC(DC) then + if not IsValidDC(DC) then Result := ERROR else with TGtkDeviceContext(DC) do begin //DebugLn('TGtk2WidgetSet.ExtSelectClipRGN A ClipRegValid=',dbgs(DCClipRegionValid(DC)), // ' Mode=',dbgs(Mode),' RGN=',GDKRegionAsString(PGdiObject(RGN)^.GDIRegionObject)); - If ClipRegion=nil then begin + if ClipRegion=nil then begin // there is no clipping region in the DC - Case Mode of + case Mode of RGN_COPY: begin Result := RegionType(PGdiObject(RGN)^.GDIRegionObject);