Modify

Opened 8 years ago

Closed 8 years ago

#4588 closed defect (fixed)

Empty lines in pre-blocks are not preserved in FullBlogPlugin

Reported by: Artem Egorkine Owned by: Odd Simon Simonsen
Priority: normal Component: FullBlogPlugin
Severity: normal Keywords:
Cc: Trac Release: 0.11

Description

When creating posts that contain preformatted text blocks (such as code) that are encapsulated in '' and '' marks, empty lines are not preserved when the post is being displayed.

Here is a simple test post:

This is a test to check how Trac preserves line breaks.

This line should be on it's own.

This line and
this line are concatenated.

{{{
These lines should be separated by one empty line.

These lines should be separated by one empty line.

These lines should be separated by one empty line.
}}}

Attachments (7)

linebreak-test-wiki.png (64.7 KB) - added by Artem Egorkine 8 years ago.
A screen shot of how the sample post is rendered in a wiki page.
linebreak-test-blog.png (88.8 KB) - added by Artem Egorkine 8 years ago.
A screen shot of how the sample post is rendered in a blog page.
linebreak-test-wiki.html (5.6 KB) - added by Artem Egorkine 8 years ago.
The HTML output for a wiki page.
linebreak-test-blog.html (7.8 KB) - added by Artem Egorkine 8 years ago.
The HTML output for a blog page.
linebreak-test-ticket.png (67.2 KB) - added by Artem Egorkine 8 years ago.
A screen shot of how the sample post is rendered in a ticket page.
linebreak-test-ticket.html (15.7 KB) - added by Artem Egorkine 8 years ago.
The HTML output for a ticket page.
linebreak-test-ticket.2.html (15.7 KB) - added by Artem Egorkine 8 years ago.
The HTML output for a ticket page.

Download all attachments as: .zip

Change History (11)

Changed 8 years ago by Artem Egorkine

Attachment: linebreak-test-wiki.png added

A screen shot of how the sample post is rendered in a wiki page.

Changed 8 years ago by Artem Egorkine

Attachment: linebreak-test-blog.png added

A screen shot of how the sample post is rendered in a blog page.

Changed 8 years ago by Artem Egorkine

Attachment: linebreak-test-wiki.html added

The HTML output for a wiki page.

Changed 8 years ago by Artem Egorkine

Attachment: linebreak-test-blog.html added

The HTML output for a blog page.

comment:1 Changed 8 years ago by Artem Egorkine

This is observed using a fresh Trac setup with all the latest components:

comment:2 Changed 8 years ago by Odd Simon Simonsen

Owner: changed from osimmons to Odd Simon Simonsen

Hmm. Testing on a slightly older Trac 0.11 shows no such problems. I have a feeling this is related to recent introduction of preserve_newlines rendering hints.

For comparison, could you also provide the result of putting the wiki markup into a new ticket description?

Changed 8 years ago by Artem Egorkine

Attachment: linebreak-test-ticket.png added

A screen shot of how the sample post is rendered in a ticket page.

Changed 8 years ago by Artem Egorkine

Attachment: linebreak-test-ticket.html added

The HTML output for a ticket page.

Changed 8 years ago by Artem Egorkine

The HTML output for a ticket page.

comment:3 Changed 8 years ago by Artem Egorkine

The ticket page seems to render the text correctly.

comment:4 Changed 8 years ago by Odd Simon Simonsen

Resolution: fixed
Status: newclosed

(In [5204]) FullBlogPlugin: Fix for a change in pre-formatted newline handling that seems to have sneaked into a recent Trac 0.11.x. Closes #4588.

Modify Ticket

Change Properties
Set your email in Preferences
Action
as closed The owner will remain Odd Simon Simonsen.
The resolution will be deleted.

Add Comment


E-mail address and name can be saved in the Preferences.

 
Note: See TracTickets for help on using tickets.