ONLINE HELP
 WINDEVWEBDEV AND WINDEV MOBILE

Help / WLanguage / WLanguage properties / Properties associated with windows, pages and controls
  • Horizontal alignment
  • Limitations
WINDEV
WindowsLinuxUniversal Windows 10 AppJavaReports and QueriesUser code (UMC)
WEBDEV
WindowsLinuxPHPWEBDEV - Browser code
WINDEV Mobile
AndroidAndroid Widget iPhone/iPadIOS WidgetApple WatchMac CatalystUniversal Windows 10 App
Others
Stored procedures
Vertical alignment determines how the text is positioned relative to the borders of the control. This allows you to center the content of an Edit control in relation to the borders of the input area.
There are three types of alignment:
  • Align top
    Top-aligned text
  • Align middle
    Middle-aligned text
  • Align bottom
    Bottom-aligned text
The VerticalAlignment property gets and changes the vertical alignment of a control.
The initial alignment is defined in the control description.
Example
// If the control is aligned to top, align it at bottom
IF STC_Static.VerticalAlignment = vaTop THEN
STC_Static.VerticalAlignment = vaBottom
END
Syntax

Getting the vertical alignment of a control Hide the details

<Current alignment> = <Control used>.VerticalAlignment
<Current alignment>: Integer constant
Current vertical alignment of the control. The possible values are as follows:
vaBottomthe text is located at the bottom of the control
vaMiddlethe text is located in the middle of the control
vaTopthe text is located at the top of the control

WEBDEV - Server codePHP Additional alignment options are available:
vaAboveVertical alignment above the baseline, as superscript (corresponds to the CSS "super" value)
vaAutoAutomatic vertical alignment (corresponds to the CSS "auto" value)
vaBaselineVertical alignment according to the baseline (corresponds to the CSS "baseline" value)
vaBelowVertical alignment below the baseline, as subscript (corresponds to the CSS "sub" value)
vaNotDefinedVertical alignment inherited from the parent
vaTextBottomVertical alignment with the bottom of the parent's font (corresponds to the CSS "text-bottom" value)
vaTextTopVertical alignment with the top of the parent's font (corresponds to the CSS "text-top" value)
<Control used>: Control name
Name of the control to be used.

Changing the vertical alignment of a control Hide the details

<Control used>.VerticalAlignment = <New alignment>
<Control used>: Control name
Name of the control to be used.
<New alignment>: Integer constant
New alignment of the control. The possible values are:
vaBottomthe text is located at the bottom of the control
vaMiddlethe text is located in the middle of the control
vaTopthe text is located at the top of the control

WEBDEV - Server codePHP Additional options for the vertical alignment can be specified via the following constants:
vaAboveVertical alignment above the baseline, as superscript (corresponds to the CSS "super" value)
vaAutoAutomatic vertical alignment (corresponds to the CSS "auto" value)
vaBaselineVertical alignment according to the baseline (corresponds to the CSS "baseline" value)
vaBelowVertical alignment below the baseline, as subscript (corresponds to the CSS "sub" value)
vaNotDefinedVertical alignment inherited from the parent
vaTextBottomVertical alignment with the bottom of the parent's font (corresponds to the CSS "text-bottom" value)
vaTextTopVertical alignment with the top of the parent's font (corresponds to the CSS "text-top" value)
Remarks

Horizontal alignment

To define the horizontal alignment of the control, use the HorizontalAlignment property.

Limitations

WEBDEV - Server code In a page, the VerticalAlignment property gets and changes the vertical alignment for the following types of controls:
  • Edit control
  • Static control
  • Button control
  • Check Box and Radio Button controls
  • List Box and Combo Box controls
  • Table control
  • Table control cells (read-only)
  • TreeView Table control and its cells (read-only)
  • Formatted display control
  • HTML control
  • Link control
  • HTML Static control
  • Pager control
  • Breadcrumb control
  • TreeView control
  • Progress Bar control
  • Scheduler control
  • Rating control
PHP In a page, the VerticalAlignment property gets and changes the vertical alignment for the following types of controls:
  • Edit control
  • Static control
  • Button control
  • Check Box and Radio Button controls
  • List Box or Combo Box control
  • Table control
  • TreeView Table control and its cells
  • Formatted display control
  • HTML control
  • Link control
  • HTML Static control
  • Pager control
  • TreeView control
WEBDEV - Server code In a report, the VerticalAlignment property gets and changes the vertical alignment for the following types of controls:
  • Static control.
  • Calculated control.
  • Preset control.
  • Chart control.
  • Group of controls: This property will only apply to controls that support vertical alignment.

Minimum version required
  • Version 9
This page is also available for…
Comments
Click [Add] to post a comment

Last update: 05/17/2024

Send a report | Local help