[Solved] Align labels on the form lazarus / 21-General ---------------------------------------------------------------------- artem101 · 2024-12-28 11:20 I need to place several labels in a arrow with vertical align to middle and horizontal align to right of the parent. What I did (1st screenshot) is not exactrly what I expected. Code: Pascal  [Select][+][-]window.onload = function(){var x1 = document.getElementById("main_content_section"); if (x1) { var x = document.getElementsByClassName("geshi");for (var i = 0; i object Form1: TForm1  Left = 272  Height = 129  Top = 250  Width = 364  Caption = 'Form1'  ChildSizing.LeftRightSpacing = 15  ChildSizing.TopBottomSpacing = 15  ChildSizing.HorizontalSpacing = 15  ChildSizing.VerticalSpacing = 15  ChildSizing.Layout = cclLeftToRightThenTopToBottom  ChildSizing.ControlsPerLine = 999  ClientHeight = 129  ClientWidth = 364  LCLVersion = '2.2.4.0'  object Label1: TLabel    Left = 15    Height = 25    Top = 15    Width = 35  Alignment = taRightJustify    Caption = 'One'    Color = clFuchsia  Font.CharSet = RUSSIAN_CHARSET    Font.Height = -19    Font.Pitch = fpVariable    Font.Quality = fqDraft    Layout = tlCenter    ParentColor = False    ParentFont = False    Transparent = False  end  object Label2: TLabel    Left = 65    Height = 25    Top = 15    Width = 35    Alignment = taRightJustify    Caption = 'Two'    Color = clRed    Font.CharSet = RUSSIAN_CHARSET    Font.Height = -19    Font.Pitch = fpVariable    Font.Quality = fqDraft    Layout = tlCenter    ParentColor = False    ParentFont = False    Transparent = False  end  object Label3: TLabel    Left = 115    Height = 25    Top = 15    Width = 48    Alignment = taRightJustify    Caption = 'Three'    Color = clLime    Font.CharSet = RUSSIAN_CHARSET    Font.Height = -19    Font.Pitch = fpVariable    Font.Quality = fqDraft    Layout = tlCenter    ParentColor = False    ParentFont = False    Transparent = False  end  object Label4: TLabel    Left = 178    Height = 25    Top = 15    Width = 38    Alignment = taRightJustify    Caption = 'Four'  Color = clAqua    Font.CharSet = RUSSIAN_CHARSET    Font.Height = -19    Font.Pitch = fpVariable    Font.Quality = fqDraft    Layout = tlCenter    ParentColor = False    ParentFont = False    Transparent = False  endend  How to place labels as on the 2nd screenshot? ---------------------------------------------------------------------- CM630 · 2024-12-28 19:27 I did not understand your idea exactly, but just to make sure, are you aware of the Anchor editor? https://wiki.freepascal.org/IDE_Window:_Anchor_Editor ---------------------------------------------------------------------- wp · 2024-12-28 20:05 Two possibilities: Using the Anchor Editor (don't use ChildSizing): Drop the labels on the formOpen the Anchor EditorSelect all labelsAnchor them vertically to the center of the form (middle button in the "Top anchoring" box)Select the right-most label only. Remove its left anchor (Uncheck "Enabled" in the "Left anchoring" box). Anchor its right side to the right side of the form (Check "Enabled" in the "Right anchoring box", and press the "right-alignment" button)Select the label which is supposed to be next to the right-most label. Again, remove the left anchor as before with the other label. Anchor its right side to the left side of the right-most label (Check "Enabled" in the "right anchoring" box, and click the left alignment button).Repeat this step with the other labelsUsing an auxiliary panel with Childsizing and Anchor Editor Drop a panel on the formSet its ChildSizing like you did with the formDrop the labels on the panel --> The labels will be aligned inside the panelOpen the AnchorEditor and align the panel vertically to center of the formSet the panel's AutoSize to true --> The panel will shrink to just enclose the labels ---------------------------------------------------------------------- artem101 · 2024-12-29 10:06 Thanks, wp! I done this using your 1st solution.