ShapeTextAlignment

ShapeTextAlignment class

Represents the setting of shape’s text alignment;

class ShapeTextAlignment;

Properties

PropertyTypeDescription
isTextWrappedbooleanGets or sets the text wrapped type of the shape which contains text.
rotateTextWithShapebooleanIndicates whether rotating text with shape.
textVerticalOverflowTextOverflowTypeGets and sets the text vertical overflow type of the text box.
textHorizontalOverflowTextOverflowTypeGets and sets the text horizontal overflow type of the text box.
rotationAnglenumberGets and sets the rotation of the shape.
textVerticalTypeTextVerticalTypeGets and sets the text direction.
isLockedTextbooleanIndicates whether the shape is locked when worksheet is protected.
autoSizebooleanIndicates if size of shape is adjusted automatically according to its content.
textShapeTypeAutoShapeTypeGets and set the transform type of text.
topMarginPtnumberReturns the top margin in unit of Points
bottomMarginPtnumberReturns the bottom margin in unit of Points
leftMarginPtnumberReturns the left margin in unit of Points
rightMarginPtnumberReturns the right margin in unit of Points
isAutoMarginbooleanIndicates whether the margin of the text frame is automatic.
numberOfColumnsnumberGets and sets the number of columns of text in the bounding rectangle.

Methods

MethodDescription
equals(VObject)Determines whether this instance has the same value as another specified ShapeTextAlignment object.
getHashCode()

isTextWrapped

Gets or sets the text wrapped type of the shape which contains text.

isTextWrapped : boolean;

rotateTextWithShape

Indicates whether rotating text with shape.

rotateTextWithShape : boolean;

textVerticalOverflow

Gets and sets the text vertical overflow type of the text box.

textVerticalOverflow : TextOverflowType;

textHorizontalOverflow

Gets and sets the text horizontal overflow type of the text box.

textHorizontalOverflow : TextOverflowType;

rotationAngle

Gets and sets the rotation of the shape.

rotationAngle : number;

textVerticalType

Gets and sets the text direction.

textVerticalType : TextVerticalType;

isLockedText

Indicates whether the shape is locked when worksheet is protected.

isLockedText : boolean;

Remarks

Only works when worksheet is protected.

autoSize

Indicates if size of shape is adjusted automatically according to its content.

autoSize : boolean;

textShapeType

Gets and set the transform type of text.

textShapeType : AutoShapeType;

topMarginPt

Returns the top margin in unit of Points

topMarginPt : number;

bottomMarginPt

Returns the bottom margin in unit of Points

bottomMarginPt : number;

leftMarginPt

Returns the left margin in unit of Points

leftMarginPt : number;

rightMarginPt

Returns the right margin in unit of Points

rightMarginPt : number;

isAutoMargin

Indicates whether the margin of the text frame is automatic.

isAutoMargin : boolean;

numberOfColumns

Gets and sets the number of columns of text in the bounding rectangle.

numberOfColumns : number;

equals(VObject)

Determines whether this instance has the same value as another specified ShapeTextAlignment object.

equals(obj: VObject) : boolean;

Parameters:

ParameterTypeDescription
objVObjectThe ShapeTextAlignment object to compare with this instance.

Returns

true if the value of the obj parameter is the same as the value of this instance; otherwise, false. If obj is null, this method returns false.

getHashCode()

getHashCode() : number;