XML technologies / CSS / Advanced websites with CSS / CSS property reference / ruby-position

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

Ruby text is used in Japan and China to display pronunciation aids or other explanatory information in small type above the main text. It is part of XHTML 1.1 and is described in detail in the W3C’s “Ruby Annotation Recommendation”.

The property ruby-position determines ruby text’s position relative to the main text.

Inherited: no

See also: ruby-align, ruby-overhang

Values

Internet Explorer for Windows 5 and later supports these constants:

  • above

  • inline

The W3C’s current CSS3 draft, however, proposes these constants:

  • after

  • before

  • right

The exact meanings of these constants are explained in detail on the CSS3 Ruby module draft page.

Default value:

  • in Internet Explorer 5 and later: above

  • in the W3C CSS3 draft: before

Compatibility

CSS version: not yet supported by any CSS specification

Works only in Internet Explorer for Windows from version 5. Apply the property to the ruby element containing the relevant ruby text (rt).

Corresponding functionality is planned for CSS3.

Example

The following rule positions ruby text on the same line as the main text:

ruby {
 ruby-position: inline;
}

  

 

 

 

back to top