Modify

Opened 15 years ago

Last modified 4 years ago

#4283 new enhancement

If code block is larger than page left alignment is more readable than a centered one.

Reported by: Sébastien GISSINGER Owned by:
Priority: normal Component: TracWikiToPdfPlugin
Severity: normal Keywords:
Cc: Trac Release: 0.11

Description

Everything is in the summary.

Attachments (1)

large-code-block.jpg (59.3 KB) - added by Sébastien GISSINGER 15 years ago.
Without the beginning of the sentences it's very difficult to understand.

Download all attachments as: .zip

Change History (8)

Changed 15 years ago by Sébastien GISSINGER

Attachment: large-code-block.jpg added

Without the beginning of the sentences it's very difficult to understand.

comment:1 Changed 15 years ago by anonymous

Summary: If code block is larger than page left alignement is more readable than a centered one.If code block is larger than page left alignment is more readable than a centered one.

comment:2 Changed 15 years ago by Ryan J Ollos

Cc: Ryan J Ollos added; anonymous removed

comment:3 Changed 15 years ago by Ryan J Ollos

Just wanted to mention that the Email Processor macro works well in this situation if you want to force the code block to wrap to fit the page.

comment:4 Changed 13 years ago by gregmac

Seems a bit obscure to have to add #!email to code blocks while editing code on wiki pages that you (or someone else, unbeknownst to you) intends to create PDFs from.

I think the only way around this might be to have wikitopdf do a couple things:

  • replace the <pre> tag with something else, <div class="pre"> and then define some css for .pre that makes it act a lot like regular pre, but with word wrapping
  • replace all newlines inside the <pre> with <br/>'s

Not sure if there is entirely a way to allow wraps without also ignoring extra whitespace though, so it may also be necessary to replace all spaces with &nbsp; or even to wrap each line in its own <pre> tag, and then adjust the css rules so it doesn't look like several individual boxes.

comment:5 in reply to:  4 Changed 13 years ago by Ryan J Ollos

Replying to gregmac:

Seems a bit obscure to have to add #!email to code blocks while editing code on wiki pages that you (or someone else, unbeknownst to you) intends to create PDFs from.

It was just meant as a workaround since no one has produced a patch yet and the plugin is unmaintained. If someone produces a working patch I will make sure it gets applied to the codebase in the repository.

comment:6 Changed 6 years ago by Ryan J Ollos

Owner: Diorgenes Felipe Grzesiuk deleted

comment:7 Changed 4 years ago by Ryan J Ollos

Cc: Ryan J Ollos removed

Modify Ticket

Change Properties
Set your email in Preferences
Action
as new The ticket will remain with no owner.

Add Comment


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

 
Note: See TracTickets for help on using tickets.