XML technologies / CSS / Advanced websites with CSS / CSS property reference / text-underline-position

(Excerpt from “CSS − Advanced websites with Cascading Stylesheets” by Rachel Andrew & Dan Shafer)

The property text-underline-position is not included in the CSS specification and describes underline placement in Asian or other vertically written text elements.

Because this property applies only to underlined elements, text-decoration must be declared with underline.

Inherited: yes

See also: text-decoration

Values

The property text-underline-position accepts the following constants:

  • auto or auto-pos: The underline appears above the text if the language is set to ja (Japanese) and the writing mode writing-mode to tb-rl.

  • above: The underline appears above the text.

  • below: The underline appears below the text.

Default values:

  • Internet Explorer 6 and later: auto

  • Internet Explorer 5.5: below

Compatibility

CSS version: not part of the CSS specification

Works only in Internet Explorer for Windows from version 5.5. The values auto and auto-pos are supported only from version 6.

Corresponding functionality is planned for CSS3, although the final property and value names will probably differ. Current information is available on the CSS Working Group website.

Example

The following rule always places underlines below the text in vertically written languages:

body {
 text-underline-position: below;
}

  

 

 

 

back to top