Changeset 565 for trunk/Packages/CevoComponents/DrawDlg.pas
- Timestamp:
- May 1, 2024, 12:08:20 PM (7 months ago)
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/Packages/CevoComponents/DrawDlg.pas
r554 r565 21 21 procedure DoDeactivate(Sender: TObject); 22 22 protected 23 // Defines area to grip the window for moving (from top) 23 24 TitleHeight: Integer; 24 // defines area to grip the window for moving (from top)25 25 procedure InitButtons; 26 26 procedure OnEraseBkgnd(var Msg: TMessage); message WM_ERASEBKGND; … … 237 237 procedure TDrawDlg.SmartInvalidate; 238 238 var 239 i: Integer; 240 r0, r1: HRgn; 241 begin 242 r0 := CreateRectRgn(0, 0, Width, Height); 243 for i := 0 to ControlCount - 1 do 244 if not (Controls[i] is TArea) and Controls[i].Visible then 245 begin 246 with Controls[i].BoundsRect do 247 r1 := CreateRectRgn(Left, Top, Right, Bottom); 248 CombineRgn(r0, r0, r1, RGN_DIFF); 249 DeleteObject(r1); 250 end; 251 InvalidateRgn(Handle, r0, False); 252 DeleteObject(r0); 239 I: Integer; 240 R0, R1: HRgn; 241 begin 242 R0 := CreateRectRgn(0, 0, Width, Height); 243 for I := 0 to ControlCount - 1 do 244 if not (Controls[I] is TArea) and Controls[I].Visible then begin 245 with Controls[I].BoundsRect do 246 R1 := CreateRectRgn(Left, Top, Right, Bottom); 247 CombineRgn(R0, R0, R1, RGN_DIFF); 248 DeleteObject(R1); 249 end; 250 InvalidateRgn(Handle, R0, False); 251 DeleteObject(R0); 253 252 end; 254 253 … … 272 271 begin 273 272 if csDesigning in ComponentState then Exit; 274 PaintBackground( Self, 3 + Border, 3 + Border, Width - (6 + 2 * Border),275 Height - (6 + 2 * Border) );273 PaintBackground(Canvas, 3 + Border, 3 + Border, Width - (6 + 2 * Border), 274 Height - (6 + 2 * Border), Width, Height); 276 275 for I := 0 to Border do 277 Frame(Canvas, I, I, Width - 1 - I, Height - 1 - I, 278 $000000, $000000); 276 Frame(Canvas, I, I, Width - 1 - I, Height - 1 - I, $000000, $000000); 279 277 Frame(Canvas, Border + 1, Border + 1, Width - (2 + Border), 280 278 Height - (2 + Border), MainTexture.ColorBevelLight,
Note:
See TracChangeset
for help on using the changeset viewer.