Top
PowerCOBOL V11.0 Reference
FUJITSU Software

4.6 Alignment Property

Description:

Gives the alignment of the character string(s), specified in the Caption property, within the control or object.

Used in:

Controls

CheckBox

Frame

Label

OptionButton

StaticText

TextBox

Objects

Column

TableColumn

Values (with constants):

CheckBox and OptionButton

0 - Left(POW-CAPTIONALIGNMENT-LEFT)
1 - Right(POW-CAPTIONALIGNMENT-RIGHT)

TextBox and Column

0 - Left(POW-TEXTALIGNMENT-LEFT)
1 - Center(POW-TEXTALIGNMENT-CENTER)
2 - Right(POW-TEXTALIGNMENT-RIGHT)

For the TextBox control, it is only effective when the EditableLabel property is True and the MultiLine property is False.

When the text is being edited the alignment is left justified regardless of the value of the Alignment property.

Frame

1 - Top/HCenter(POW-ALIGNMENT-TOPHCENTER)

2 - Top/Right(POW-ALIGNMENT-TOPRIGHT)

4 - VCenter/Left(POW-ALIGNMENT-VCENTERLEFT)

5 - VCenter/HCenter (POW-ALIGNMENT-VCENTERHCENTER)

6 - VCenter/Right (POW-ALIGNMENT-VCENTERRIGHT)

8 - Bottom/Left(POW-ALIGNMENT-BOTTOMLEFT)

9 - Bottom/HCenter (POW-ALIGNMENT-BOTTOMHCENTER)

10 - Bottom/Right (POW-ALIGNMENT-BOTTOMRIGHT)

99 - Auto(POW-ALIGNMENT-AUTO)

Note that:
If the FrameStyle property is "0 - GroupBox",
the values 0, 4 or 8 are Top/Left,
the values 1, 5 or 9 are Top/HCenter,
the values 2, 6 or 10 are Top/Right.

If the value is "99 - Auto" and the FrameStyle property is
"0 - GroupBox" the alignment becomes Top/Left.

If the value is "99 - Auto" and the FrameStyle property is
"1 - Panel", the alignment becomes VCenter/HCenter.

StaticText and TableColumn

0 - Top/Left(POW-ALIGNMENT-TOPLEFT)

1 - Top/HCenter (POW-ALIGNMENT-TOPHCENTER)

2 - Top/Right(POW-ALIGNMENT-TOPRIGHT)

4 - VCenter/Left(POW-ALIGNMENT-VCENTERLEFT)

5 - VCenter/HCenter (POW-ALIGNMENT-VCENTERHCENTER)

6 - VCenter/Right (POW-ALIGNMENT-VCENTERRIGHT)

8 - Bottom/Left(POW-ALIGNMENT-BOTTOMLEFT)

9 - Bottom/HCenter(POW-ALIGNMENT-BOTTOMHCENTER)

10 - Bottom/Right (POW-ALIGNMENT-BOTTOMRIGHT)
For the Table control, when a cell is being edited, the alignment is left justified regardless of the value of the Alignment property.

Default values:

CheckBox

1 - Right(POW-CAPTIONALIGNMENT-RIGHT)

Column

0 - Left(POW-TEXTALIGNMENT-LEFT)

Frame

99 - Auto(POW-ALIGNMENT-AUTO)

OptionButton

1 - Right(POW-CAPTIONALIGNMENT-RIGHT)

StaticText

0 - Top/Left(POW-ALIGNMENT-TOPLEFT)

TableColumn

6 - VCenter/Right(POW-ALIGNMENT-VCENTERBOTTOM)

TextBox

2 - Right(POW-TEXTALIGNMENT-RIGHT)

COBOL picture:

S9(4) COMP-5

OLE data type:

VT_I2

Design time access:

Set and reference.

Execution time access:

Set and reference.

Backward compatibility attribute:

For CheckBox, OptionButton, and StaticText

POW-TEXTPOSPIC S9(4) COMP-5