This repository has been archived on 2024-12-25. You can view files and clone it, but cannot push or open issues or pull requests.
OldPascalProjects/Graphics/Controls/cc8a_MoveObject.pas
2024-03-10 20:32:51 +03:00

27 lines
714 B
ObjectPascal

// Модуль Controls - IntegerBlock, IntegerBox и перемещение объекта
uses WPFObjects,Controls;
begin
Window.Title := 'Модуль Controls - IntegerBlock, IntegerBox и перемещение объекта';
LeftPanel;
var c := new CircleWPF(300,300,30,Colors.Blue);
var X := IntegerBox('X:',0,600);
X.Value := 300;
var Y := IntegerBox('Y:',0,600);
Y.Value := 300;
var XX := IntegerBlock('X:',300);
var YY := IntegerBlock('Y:',300);
X.ValueChanged := procedure begin
c.Center := Pnt(X.Value,Y.Value);
XX.Value := X.Value;
end;
Y.ValueChanged := procedure begin
c.Center := Pnt(X.Value,Y.Value);
YY.Value := Y.Value;
end;
end.