Modify

Opened 6 years ago

Closed 6 years ago

#4588 closed defect (fixed)

Empty lines in pre-blocks are not preserved in FullBlogPlugin

Reported by: arteme Owned by: osimons
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 arteme 6 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 arteme 6 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 arteme 6 years ago.
The HTML output for a wiki page.
linebreak-test-blog.html (7.8 KB) - added by arteme 6 years ago.
The HTML output for a blog page.
linebreak-test-ticket.png (67.2 KB) - added by arteme 6 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 arteme 6 years ago.
The HTML output for a ticket page.
linebreak-test-ticket.2.html (15.7 KB) - added by arteme 6 years ago.
The HTML output for a ticket page.

Download all attachments as: .zip

Change History (11)

Changed 6 years ago by arteme

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

Changed 6 years ago by arteme

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

Changed 6 years ago by arteme

The HTML output for a wiki page.

Changed 6 years ago by arteme

The HTML output for a blog page.

comment:1 Changed 6 years ago by arteme

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

comment:2 Changed 6 years ago by osimons

  • Owner changed from osimmons to osimons

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 6 years ago by arteme

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

Changed 6 years ago by arteme

The HTML output for a ticket page.

Changed 6 years ago by arteme

The HTML output for a ticket page.

comment:3 Changed 6 years ago by arteme

The ticket page seems to render the text correctly.

comment:4 Changed 6 years ago by osimons

  • Resolution set to fixed
  • Status changed from new to closed

(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.

Add Comment

Modify Ticket

Action
as closed .
The resolution will be deleted. Next status will be 'reopened'.
Author


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

 
Note: See TracTickets for help on using tickets.