PC SOFT

WINDEVWEBDEV AND WINDEV MOBILE
ONLINE HELP

Home | Sign in | English UK

  • Horizontal alignment and text not entirely displayed in the control
  • Vertical alignment
  • Limitation
WINDEV
WindowsLinuxUniversal Windows 10 AppJavaReports and QueriesUser code (UMC)
WEBDEV
WindowsLinuxPHPWEBDEV - Browser code
WINDEV Mobile
AndroidAndroid Widget iPhone/iPadApple WatchUniversal Windows 10 AppWindows Mobile
Others
Stored procedures
The horizontal alignment of a control consists in defining the position of the text in the control in relation to the borders of the control. This allows you to center the content of a Static control in relation to the control borders.
Several alignments are available:
  • alignment to left
    Text aligned to left
  • alignment to right
    Text aligned to right
  • centered
    Text centered
  • justified
..HorizontalAlignment is used to find out and modify the horizontal alignment of a control.
The initial alignment of control is defined in the editor during the control description.
Versions 15 and later
Android This property is now available for Android applications.
New in version 15
Android This property is now available for Android applications.
Android This property is now available for Android applications.
Versions 16 and later
Universal Windows 10 App This property is now available for Windows Phone applications.
New in version 16
Universal Windows 10 App This property is now available for Windows Phone applications.
Universal Windows 10 App This property is now available for Windows Phone applications.
Versions 17 and later
iPhone/iPad This property is now available for window controls in iPhone/iPad applications.
New in version 17
iPhone/iPad This property is now available for window controls in iPhone/iPad applications.
iPhone/iPad This property is now available for window controls in iPhone/iPad applications.
Versions 18 and later
Universal Windows 10 App This property is now available in Windows Store Apps mode.
iPhone/iPad This property is now available for report controls in iPhone/iPad applications.
New in version 18
Universal Windows 10 App This property is now available in Windows Store Apps mode.
iPhone/iPad This property is now available for report controls in iPhone/iPad applications.
Universal Windows 10 App This property is now available in Windows Store Apps mode.
iPhone/iPad This property is now available for report controls in iPhone/iPad applications.
Versions 20 and later
AndroidiPhone/iPad This property is now available for table columns in Android and iPhone/iPad applications.
New in version 20
AndroidiPhone/iPad This property is now available for table columns in Android and iPhone/iPad applications.
AndroidiPhone/iPad This property is now available for table columns in Android and iPhone/iPad applications.
Versions 21 and later
Universal Windows 10 App This property is now available in Universal Windows 10 App mode.
New in version 21
Universal Windows 10 App This property is now available in Universal Windows 10 App mode.
Universal Windows 10 App This property is now available in Universal Windows 10 App mode.
Example
// If the control is left-aligned, align it to right
IF STC_Static1..HorizontalAlignment = haLeft THEN
STC_Static1..HorizontalAlignment = haRight
END
Syntax

Finding out the horizontal alignment of a control Hide the details

<Current alignment>..HorizontalAlignment = <Control used>
<Current alignment>: Integer constant
Current horizontal alignment of control. The possible values are:
haCenterThe text is centered.
haRightThe text is aligned to right.
haLeftThe text is aligned to left.
haJustifiedThe text is justified.
haNotDefinedAlignment defined by the CSS inheritance.
This constant is available in WEBDEV only.
<Control used>: Control name
Name of control to use.

Modifying the horizontal alignment of a control Hide the details

<Control used>..HorizontalAlignment = <New alignment>
<Control used>: Control name
Name of control to use.
<New alignment>: Integer constant
New horizontal alignment of the control. The possible values are:
haCenterThe text is centered.
haRightThe text is aligned to right.
haLeftThe text is aligned to left.
haJustifiedThe text is justified.
haNotDefinedAlignment defined by the CSS inheritance.
This constant is available in WEBDEV only.
Remarks
AndroidiPhone/iPadUniversal Windows 10 AppWindows Mobile

Horizontal alignment and text not entirely displayed in the control

The following information is displayed if the text cannot be entirely displayed in the control:
  • In the report editor, the left part of the text is displayed.
  • In the window editor:
    • in a static control, the right part of text is displayed.
    • in an edit control, the left part of text is displayed.

Vertical alignment

To define the vertical alignment of the control, use ..VerticalAlignment.

Limitation

iPhone/iPadUniversal Windows 10 AppWindows Mobile In a report, ..HorizontalAlignment is used to find out and modify the horizontal alignment for the following types of controls:
  • Static control.
  • Calculated control.
  • Preset control.
  • Versions 17 and later
    Chart control.
    New in version 17
    Chart control.
    Chart control.
  • Groups of controls. This property will only be applied to the controls that support the horizontal alignment.
Versions 20 and later
AndroidiPhone/iPad ..HorizontalAlignment applies to the table columns.
New in version 20
AndroidiPhone/iPad ..HorizontalAlignment applies to the table columns.
AndroidiPhone/iPad ..HorizontalAlignment applies to the table columns.
Minimum version required
  • Version 9
This page is also available for…
Comments
Click [Add] to post a comment