Specification
Contents
Previous
Next

9.1 White Space

The following two lines should render identically (because of whitespace collapsing) - there should not be any extra characters to indicate unknown or invalid characters, but underlining whiskers are a minor defect:

Normal Text Underlined Text Normal Text
Normal Text Underlined Text Normal Text

9.2 Structured Text

9.2.1 Phrase Elements: EM, STRONG, DFN, SAMP, KBD, VAR, ABBR, and ACRONYM

In the paragraph below, the elements are set with titles that explain the tag. The browser should provide access to these titles in some way. Also note that only the name of the tag should be any different from normal text, and if the tag is accepted, it will be yellow on navy.

Here is EM text.
Here is STRONG text.
Here is CITE text.
Here is DFN text.
Here is CODE text.
Here is SAMP text.
Here is KBD text.
Here is VAR text.
Here is ABBR text.
Here is ACRONYM text.

9.2.2 Quotations: The BLOCKQUOTE and Q Elements

Examples without attributes (the first Q and first BLOCKQUOTE should be white on black, if supported; the browser should NOT apply the style to Q without adding some type of quotes):

Urfob says Hello.

This is text within a BLOCKQUOTE. This is text within a BLOCKQUOTE. This is text within a BLOCKQUOTE. This is text within a BLOCKQUOTE. This is text within a BLOCKQUOTE. This is text within a BLOCKQUOTE. This is text within a BLOCKQUOTE. This is text within a BLOCKQUOTE. This is text within a BLOCKQUOTE. This is text within a BLOCKQUOTE. This is text within a BLOCKQUOTE. This is text within a BLOCKQUOTE. This is text within a BLOCKQUOTE. This is text within a BLOCKQUOTE. This is text within a BLOCKQUOTE. This is text within a BLOCKQUOTE. This is text within a BLOCKQUOTE. This is text within a BLOCKQUOTE. This is text within a BLOCKQUOTE. This is text within a BLOCKQUOTE.

The cite attribute:

Visual user agents must ensure that the content of the Q element is rendered with delimiting quotation marks. Authors should not put quotation marks at the beginning and end of the content of a Q element.

Visual user agents generally render BLOCKQUOTE as an indented block.

Quote styles and nesting based on language (there should be some indication of the nesting level by which quote marks are used, and these should not all be the same, but if levels 3 and 4 are the same as level 2, that's acceptable):

English: Quote Level 1 Quote Level 2 Quote Level 3 Quote Level 4 3 2 1
French: Quote Level 1 Quote Level 2 Quote Level 3 Quote Level 4 3 2 1
German: Quote Level 1 Quote Level 2 Quote Level 3 Quote Level 4 3 2 1
Italian: Quote Level 1 Quote Level 2 Quote Level 3 Quote Level 4 3 2 1
Dutch: Quote Level 1 Quote Level 2 Quote Level 3 Quote Level 4 3 2 1
Greek: Quote Level 1 Quote Level 2 Quote Level 3 Quote Level 4 3 2 1
Spanish: Quote Level 1 Quote Level 2 Quote Level 3 Quote Level 4 3 2 1
Portugese: Quote Level 1 Quote Level 2 Quote Level 3 Quote Level 4 3 2 1
Arabic: Quote Level 1 Quote Level 2 Quote Level 3 Quote Level 4 3 2 1
Hebrew: Quote Level 1 Quote Level 2 Quote Level 3 Quote Level 4 3 2 1
Russian: Quote Level 1 Quote Level 2 Quote Level 3 Quote Level 4 3 2 1
Chinse: Quote Level 1 Quote Level 2 Quote Level 3 Quote Level 4 3 2 1
Japanese: Quote Level 1 Quote Level 2 Quote Level 3 Quote Level 4 3 2 1
Hindi: Quote Level 1 Quote Level 2 Quote Level 3 Quote Level 4 3 2 1
Urdu: Quote Level 1 Quote Level 2 Quote Level 3 Quote Level 4 3 2 1
Sanskrit: Quote Level 1 Quote Level 2 Quote Level 3 Quote Level 4 3 2 1

9.2.3 Subscripts and Superscripts: the SUB and SUP Elements

Simple Test:

Normal Text Subscript Text
Normal Text Superscript Text

9.3 Lines and Paragraphs

9.3.1 Paragraphs: The P Element

This paragraph has lang and title attributes set. Can you access them?

According to the specification, User agents should ignore empty P elements. Therefore, there should be same amount of space between this paragraph and the second one as between the second and "third" paragraphs.

This is the second paragraph.

This is the third paragraph.

9.3.2 Controlling Line Breaks

This
sentence
should
have
only
one
word
on
each
line.

This header should not wrap; it should, however, be scrollable to the right.  If this header scrolls onto multiple lines or there is no way to scroll right to read all of this, the   entity is not properly supported.

9.3.3 Hyphenation

Now contained in tables of explicit pixel width 500, to avoid the ambiguity of the right edge of the viewport vs. the right edge of the document as forced by some of the non-wrapping lines.

Plain (Hard) Hyphen (not required to break line at these):

test-test-test-test-test-test-test-test-test-test-test-test-test-test-test-test-test-test-test-test-test-test-test-test-test-test-test-test-test-test-test-test-test-test-test-test-test-test-test-test-test-test-test-test-test-test-test-test-test-test-test-test-test-test-test-test-test-test-test-test-test-test-test-test

Soft Hyphen (may break line after one of these, but only show the one the line was broken after, replacing hard hyphens above with soft hyphens):

Named Character Reference:

test­test­test­test­test­test­test­test­test­test­test­test­test­test­test­test­test­test­test­test­test­test­test­test­test­test­test­test­test­test­test­test­test­test­test­test­test­test­test­test­test­test­test­test­test­test­test­test­test­test­test­test­test­test­test­test­test­test­test­test­test­test­test­test­

Numeric Character Reference:

test­test­test­test­test­test­test­test­test­test­test­test­test­test­test­test­test­test­test­test­test­test­test­test­test­test­test­test­test­test­test­test­test­test­test­test­test­test­test­test­test­test­test­test­test­test­test­test­test­test­test­test­test­test­test­test­test­test­test­test­test­test­test­test­

Hexadecimal Character Reference:

test­test­test­test­test­test­test­test­test­test­test­test­test­test­test­test­test­test­test­test­test­test­test­test­test­test­test­test­test­test­test­test­test­test­test­test­test­test­test­test­test­test­test­test­test­test­test­test­test­test­test­test­test­test­test­test­test­test­test­test­test­test­test­test­

9.3.4 Preformatted Text: The PRE Element

The PRE element tells visual user agents that the enclosed text is "preformatted". When handling preformatted text, visual user agents:

Whitespace Preserving

     This sentence is preceded by 5 spaces, so it should not line up with the paragraph above.
	This sentence is preceded by the SGML character reference for a horizontal tab.

There should be a blank line between the horizontal tab line and this one, due to line breaks.
 This sentence is preceded by an SGML character reference for a simple space.

Fixed-Pitch Font: All the lines in the following PRE should line up:

0        1         2         3          4
12345678901234567890123456789012345678890
Simple Text in the PRE, to line up here->
MMMMMMMMMMMMMMMMMMMMMMMMMMMMMMMMMMMMMMMMM
mmmmmmmmmmmmmmmmmmmmmmmmmmmmmmmmmmmmmmmmm
lllllllllllllllllllllllllllllllllllllllll
|||||||||||||||||||||||||||||||||||||||||

Disable automatic word wrap

This preformatted text should not wrap, even if it is much wider than the viewport. This is filler text to exceed the width of the viewport. This is filler text to exceed the width of the viewport. This is filler text to exceed the width of the viewport. This is filler text to exceed the width of the viewport. This is filler text to exceed the width of the viewport. This is filler text to exceed the width of the viewport. This is filler text to exceed the width of the viewport. This is filler text to exceed the width of the viewport. This is filler text to exceed the width of the viewport. This is filler text to exceed the width of the viewport. This is filler text to exceed the width of the viewport. This is filler text to exceed the width of the viewport.

Inline elements within a PRE (the inline elements below should not prevent all the lines from lining up at the right)

0        1         2         3          4
12345678901234567890123456789012345678890
This is a PRE text contaning three inline
elements, one of which is emphasized text
and another is strong text, there are not
CR/LF combos around any of the above tags

9.4 Making Document Changes: The INS and DEL Elements

Block-Level Usage (there should be a gap or at least a line-break between the end of the block-level inserted text and the start of the block-level deleted text, but if those two are on the same line, the INS and DEL elements are incorrectly being treated as inline-level elements)

Block-Level Inserted Text
DIV within Inserted Text acting as block-level element
Back to Block-Level Inserted Text
Block-Level Deleted Text
DIV within Deleted Text acting as block-level element
Back to Block-Level Deleted Text

Inline-Level Usage

Inline-Level Inserted Text Inline-Level Deleted Text Inline-Level Deleted Text within Inline-Level Inserted Text Inline-Level Inserted Text within Inline-Level Deleted Text

Nesting with datetime attribute:

This is Deleted Text within Inserted Text, but since the datetime attributes indicate that the insertion was more recent than the deletion, the best way to render this is to only display this as inserted, not as deleted.

This is Deleted Text within Inserted Text, but since the datetime attributes indicate that the deletion was more recent than the insertion, the best way to render this is to only display this as deleted, not as inserted.

This is Inserted Text within Deleted Text, but since the datetime attributes indicate that the deletion was more recent than the insertion, the best way to render this is to only display this as deleted, not as inserted.

This is Inserted Text within Deleted Text, but since the datetime attributes indicate that the insertion was more recent than the deletion, the best way to render this is to only display this as inserted, not as deleted.

The cite attribute (goes to http://www.kmax.com/): Dummy Inserted Text

Valid HTML 4.01!