Skip site navigation (1)Skip section navigation (2)
Date:      Sun, 28 Jul 2013 20:44:24 +0200
From:      Gabor Kovesdan <gabor@FreeBSD.org>
To:        Warren Block <wblock@wonkity.com>, doc@FreeBSD.org
Subject:   Re: Another CSS suggestion: pre-wrap
Message-ID:  <51F56688.5040900@FreeBSD.org>
In-Reply-To: <51F558D2.1010808@FreeBSD.org>
References:  <alpine.BSF.2.00.1307281057160.9642@wonkity.com> <51F558D2.1010808@FreeBSD.org>

next in thread | previous in thread | raw e-mail | index | archive | help
On 2013.07.28. 19:45, Gabor Kovesdan wrote:
> On 2013.07.28. 19:00, Warren Block wrote:
>> Long lines in screen and programlisting elements run off the right 
>> side of the screen with the current CSS.
>>
>> It would be great to have them wrap and include a visible a line wrap 
>> indicator, but that may not be possible, or may require Javascript.
>>
>> Better than nothing is to have them at least have forced wrapping 
>> based on screen width.  That can be done with changes in div.screen 
>> and div.programlisting:
>>
>> -    white-space: pre;
>> +    white-space: pre-wrap;
>>
>> This seems to work well, other than there being no visible marker 
>> where a line is wrapped due to screen width.
>>
>> Is there a better way to accomplish this? 
> This seems to work:
> http://iany.me/2012/02/css-line-wrap-indicator/
>
> The wrapping of programlisting content into span elements can be done 
> in XSLT. 
This seems to does the XSLT-part, although it may be done in a better 
way since it breaks some DocBook features that we don't use:
http://kovesdan.org/patches/xhtml-wrap.diff

Gabor



Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?51F56688.5040900>