This is a static dump of issues in the old "Flyspray" bugtracker for DokuWiki. Bugs and feature requests
are now tracked at the issue tracker at Github.

Closed
Fixed

FS#1652 Blank lines are only blank lines when they don't have spaces

Syntax

2009-03-16levitte

Blank lines are supposed to separate paragraphs. However, that seems to be restricted to "\n\n", no spaces allowed. For users editing a page, spaces in a blank line aren't very visible, so they might type in a few, resulting in a blank line like "\n \n", and it seems like that doesn't count as a blank line, although it is one visually.

Looking at the HTML result, it seems like "\n \n" (one space) is simply left there, just isn't transformed to "<p>\n\n</p>" like I would have expected, while "\n \n" is removed entirely. I'm guessing that the latter involves the code for preformatted source text and that this becomes kind of a special case...

Either way, this is pretty non-intuitive for people who aren't terribly computer-literate, and I'd love to see this resolved.

Cheers,
Richard Levitte

2009-10-04ChrisS

Ooops, closed prematurely.

Two cases:
- in a region of non-parsed text (each line started with spaces) a blank line, is only a blank line if it contains no white space.
- in a region with no, non-parsed text, a blank line is a blank line even if it contains some whitespace.

2009-10-04ChrisS

Speculative deduction :) ... the 'preformatted' mode will take care of blank lines with spaces within blocks of 'preformatted' text. It sufficient to update the eol pattern to swallow all non-eol whitespace preceding the eol character (when there is only non-eol whitespace preceding the pattern). This change will remove non-eol white space at the end of lines when another syntax mode terminates at the last non-whitespace character, which could affect other plugins.

I'll leave this task open to give time for reports on its success/effects.