EN
Este conteúdo não está disponível em seu idioma, mas aqui está a versão em inglês.

dir property

Sets or retrieves a value that indicates the reading order of the object.

Syntax

JavaScript

p = object.dir

Property values

Type: String

ltr

Default. Content flows from left to right.

rtl

Content flows from right to left.

Remarks

Unless explicitly set, the dir property has no return value when accessed in script.

The dir property does not affect alphanumeric characters in Latin documents. These characters always render ltr. However, the property does affect punctuation characters in Latin documents. For example, punctuation marks such as periods and question marks will render to the left of a sentence when the dir property is set to rtl.

The value of dir property has no effect on the orientation of coordinates for an object's positioning properties. For example, the left property and the right property perform the same placement in both cases. However, when both the left and right properties are specified, the left property takes precedence when the dir property is set to ltr. Likewise, the right property takes precedence when the dir property is set to rtl.

See also

document
Reference
direction
Conceptual
HTML Character Sets

 

 

Mostrar:
© 2014 Microsoft