This documentation is preliminary and subject to change.
Sets the mode of text wrapping.
String that specifies one of the following values:
Default. Content exceeds the boundaries of its container.
Content wraps to next line, and a word-break occurs when necessary.
This property has a default value of normal. It is inherited.
This differs from the white-space property, which turns wrapping of the text on and off. The word-wrap property addresses only whether wrapping is permitted to occur at a place in the word that is not otherwise allowed by the language rules in effect.
This property applies to elements that have layout. An element has layout when it is absolutely positioned, is a block element, or is an inline element with a specified height or width.
The word "blonde" cannot be wrapped under typical English rules. But, when word-wrap is set to break-word, the word "blonde" can be split onto two lines in any way the browser chooses: such as "b" and "londe", or "blo" and "nde".
The following example shows how to use the break-word value of the word-wrap property to break one long word onto multiple lines. This value avoids horizontal scrolling and can be useful for printing. The p element in this example has layout, because its width is set.
<p style="word-wrap:break-word;width:100%;left:0"> LongWordLongWord...LongWordLongWord</p>
This property is defined in CSS Selectors Level 3 .
a, address, b, big, blockquote, body, button, caption, center, cite, code, col, colgroup, custom, dd, defaults, dfn, div, dl, dt, em, fieldset, form, hn, html, i, img, input type=button, input type=checkbox, input type=file, input type=image, input type=password, input type=radio, input type=reset, input type=submit, input type=text, li, ol, p, s, span, sub, table, tbody, td, tfoot, th, thead, tr, tt, u, ul, var, xmp