24 of 313 menu

The text-orientation property

The text-orientation property specifies an orientation of characters in vertical text, i.e. text that is given the writing-mode property with the vertical-lr or vertical-rl values. The property takes two values: mixed (symbols are rotated 90° clockwise) or upright (symbols are placed one below the other).

Syntax

selector { text-orientation: mixed or upright; }

Example

Let's give all vertical text characters a rotation of 90°:

<p> Text </p> body { width: 200px; height: 100px; } p { text-orientation: mixed; background: #467CBC; color: white; padding: 10px; font-size: 2rem; writing-mode: vertical-lr; }

:

Example

Let's place all the vertical text characters below each other:

<p> Text </p> body { width: 200px; height: 100px; } p { text-orientation: upright; background: #467CBC; color: white; padding: 10px; font-size: 2rem; writing-mode: vertical-lr; }

:

See also

byenru