Tests about vertical space (vspace)
HeadingThis is a test. This is a test. |
HeadingThis is a test. This is a test. |
HeadingThis is a test. This is a test. |
HeadingThis is a test. |
HeadingThis is a test. This is a test. |
Information from earlier discussions:
http://thread.gmane.org/gmane.comp.web.wiki.pmwiki.user/22917/focus=23047
">Why was <p class="vspace"> introduced in PmWiki?
Because HTML is broken. If you put the margins onto the <p> elements themselves, then it becomes very difficult to get lists and other block elements to appear adjacent to paragraphs."
From PITS:00783 "...headings would ignore a blank line that follows, such that a paragraph following a heading doesn't get 'vspace' unless there are at least two blank lines ahead of it. The purpose of this is to allow the vertical space between a heading and its subsequent paragraph to be smaller than the vertical space between paragraphs..."
Test cases
Paragraph 1
Paragraph 2
List "heading"
- The first list item should have the
- same vertical distance to the "heading"
- as following list items to each other
List end
List "heading"
- The first list item should have the
- same vertical distance to the "heading"
- as following list items to each other
List end
Heading
Text directly following a heading
Another heading
one blank line between heading and text
One more heading
two blank lines between heading and text. This produces slightly more vertical space, where is this documented? Is there any real world use of this feature? I consider this somewhat surprising.
Heading following a paragraph directly without a blank line
Heading
- List directly
- following a heading
Tests with tables
|
This paragraph should contain a word wrap so we need some nonsense test here. This paragraph should contain a word wrap so we need some nonsense test here. This paragraph should contain a word wrap so we need some nonsense test here. | |
|
forced | |
|
Paragraph 1 Paragraph 2 |