SDAA259 January 2026 AM623 , AM625 , AM625-Q1 , AM625SIP , AM62P , AM62P-Q1
Figure 2-11 Repositioning Blink ButtonUse anchors. Anchors is a property within QML that allows UI elements to be positioned relative to other elements. A parent is something that can be used without manually calculating coordinates pixel by pixel. It helps define relationships between items such as the window and button. In this case, the Blink button is centered in the window.
Now when a user runs the application, the button is now centered on the screen.
Figure 2-12 Button Repositioned in WindowCan there be more than one button in the same row?
Figure 2-13 Adding a Row ComponentModify the program by adding a component called Row [1]. Row is a tool to help organize all the components in one row. In this case, components are organized along the center row utilizing the vertical [2] and horizontal [3] center of the window. Now any components that are added within this scope are on the same row and centered as shown Figure 2-14.
Figure 2-14 Multiple Components Centered Within Window