Tutorial: RotationCenter for an APP with Delphi 11 Alexandria (FireMonkey) on Windows



Tutorial: RotationCenter for an APP with Delphi 11 Alexandria (FireMonkey) on Windows

Tutorial: RotationCenter for an APP with Delphi 11 Alexandria (FireMonkey) on Windows

DISCLAIMER: This video is boring to the average YouTube viewer.

We show an APP with which a floor plan can be viewed. In our example we are moving a rectangle. The center of rotation is represented by a circle. We work here with the mouse, right mouse button to rotate, left mouse button to move. Changing the center of rotation of the rectangle also changes its position in the view. We will balance it with K1 and K2 (TopLeft = X: 0; Y: 0).

Tutorial: RotationCenter für eine APP mit Delphi 11 Alexandria (FireMonkey) unter Windows

Wir zeigen eine APP, mit der ein Grundriss eingesehen werden kann. In unserem Beispiel bewegen wir ein Rechteck. Der Drehpunkt wird durch einen Kreis dargestellt. Wir arbeiten hier mit der Maus, rechte Maustaste zum Drehen, linke Maustaste zum Verschieben. Das Ändern des Rotationszentrums des Rechtecks ändert auch seine Position in der Ansicht. Wir werden es mit K1 und K2 ausgleichen (TopLeft = X: 0; Y: 0).

0:00 Overview
1:54 Start Delphi and go
2:23 We need a base – a layout
2:37 We need a Rectangle for the view
2:50 We need a circle for orientation
4:09 We want to move the view
5:12 Save the project
5:30 Test moving the view
5:46 AutoCapture must be set to True
6:29 We want to rotate the view
8:51 We want to change the orientation, move the circle
11:30 We want to use the center of rotation of the circle for the view
13:34 Why doesn’t the circle stop?
16:17 We need a rendering for a floor plan to test
18:32 We put the bitmap into the brush for the view
19:27 The orientation (the circle) is centered
19:38 We test the app

LocalToAbsoluteVector, PressedPosition, ParentControl, RotationCenter, ArcTan2, RotationAngle

2021 12 10 CheckRotcenter

#FireMonkey #Delphi

Comments are closed.