Item12168: Word Warp in verbatim formatted text in print preview

pencil
Priority: Normal
Current State: Confirmed
Released In: n/a
Target Release: n/a
Applies To: Extension
Component: PatternSkin
Branches:
Reported By: KlausReithmaier
Waiting For:
Last Change By: ArthurClemens
Our Company want to use Foswiki as a documentation plattform. Therefore we have often to use the verbatim-formatting for documenting scripts. Of course we make a daily backup form our foswiki-Files. But for worst case scenario (e.g. the datacenter burns down and we have to set up a basic configuration very quickly) we have to print out our implementation documentation.

At this point we have a problem with the verbatim formatting: If a line is wider than the width of the topic a scrollbar appears on the bottom of the verbatim-box (of course this is a good feature). But in print preview and on the printout all lines are cut off at the page with.

The best solution would be, that word wrapping is activated for verbatim formatted text in the printout.

Is there a solution for this problem? Maybe something like changing CSS files? I have not really much experience with web designing, but a colleague in another office is responsible for maintaining our homepage, maybe he could to that.

We use the default PatternSkin

-- KlausReithmaier - 19 Oct 2012

I think this should be added to print.css:
pre {
white-space: pre-wrap; /* css-3 */
white-space: -moz-pre-wrap !important; /* Mozilla, since 1999 */
white-space: -pre-wrap; /* Opera 4-6 */
white-space: -o-pre-wrap; /* Opera 7 */
word-wrap: break-word; /* Internet Explorer 5.5+ */
}

-- ArthurClemens - 19 Oct 2012

Thanks, it's working perfectly. Should this be reported as bug? I think, this lines should be written by default, because it is not prefered to cut off the lines at the and of the page if printed out.

Which CurrentState do I have to set?

-- KlausReithmaier - 29 Oct 2012

Leave this item open, I will get back to it. Set to Confirmed.

-- ArthurClemens - 29 Oct 2012

ItemTemplate edit

Summary Word Warp in verbatim formatted text in print preview
ReportedBy KlausReithmaier
Codebase 1.1.5
SVN Range
AppliesTo Extension
Component PatternSkin
Priority Normal
CurrentState Confirmed
WaitingFor
Checkins
TargetRelease n/a
ReleasedIn n/a
CheckinsOnBranches
trunkCheckins
Release01x01Checkins
Topic revision: r4 - 29 Oct 2012, ArthurClemens
The copyright of the content on this website is held by the contributing authors, except where stated elsewhere. See Copyright Statement. Creative Commons License    Legal Imprint    Privacy Policy