0 out of 1 rated this helpful - Rate this topic

-ms-text-align-last Attribute | textAlignLast Property

Gets or sets how to align the last line or only line of text in the object.

Syntax

CSS { -ms-text-align-last : sAlignLast }
Scripting [ sAlignLast = ] object.style.textAlignLast [ = sAlignLast ]

Possible Values

sAlignLast String that specifies or receives one of the following values.
auto
Default. Text is aligned like the other lines in the object, using the value of the textAlign property.
center
Text is centered.
inherit
Text is aligned like the text in the parent object.
justify
Text is justified.
left
Text is aligned to the left.
right
Text is aligned to the right.

The property is read/write for all objects except the following, for which it is read-only: currentStyle. The property has a default value of auto. The proposed Cascading Style Sheets (CSS) attribute is inherited.

DHTML expressions can be used in place of the preceding value(s). As of Internet Explorer 8, expressions are supported in IE7 Standards mode and IE5 (Quirks) mode only. For more information, see About Dynamic Properties and Defining Document Compatibility.

Remarks

Windows Internet Explorer 8. The -ms-text-align-last attribute is an extension to CSS, and can be used as a synonym for text-align-last in IE8 Standards mode.

The property is read-only for the currentStyle object .

The property applies to block elements.

Example

The following example shows an embedded style rule that justifies all the lines in the document's p elements. This is commonly found in East Asian typography.


<STYLE>
    P.DistributeAllLines { text-align: justify;
                           text-justify: distribute;                             
                           text-align-last: justify }
</STYLE>

Standards Information

This property is defined in Cascading Style Sheets (CSS), Level 3 (CSS3).

Applies To

ADDRESS, BLOCKQUOTE, BODY, CENTER, CSSStyleDeclaration, currentStyle, CUSTOM, DD, DIV, DL, DT, FIELDSET, FORM, hn, HR, ISINDEX, LI, LISTING, MENU, OL, P, PLAINTEXT, PRE, runtimeStyle, style, UL, XMP, CSSCurrentStyleDeclaration Constructor, CSSRuleStyleDeclaration Constructor, CSSStyleDeclaration Constructor
Did you find this helpful?
(1500 characters remaining)
Community Content Add
Annotations FAQ