StringShape.HorizontalAlignment

From Xojo Documentation

Property (As Alignment )
aStringShape.HorizontalAlignment = newAlignmentValue
or
AlignmentValue = aStringShape.HorizontalAlignment

New in 2009r3

Supported for all project types and targets.

Sets the horizontal alignment of the StringShape.

Notes

The choices are: Left, Center, or Right. The default is Center. The alignment is relative to the Object2D.X property.

Example

This example aligns the StringShape to the left.

Dim ss As New StringShape
ss.X = 20
ss.Text = "Hello World"
ss.HorizontalAlignment = StringShape.Alignment.Left