Tidy options

Simon L. Nielsen simon at FreeBSD.org
Thu Sep 4 14:05:42 UTC 2003


On 2003.09.04 13:34:41 +0100, Ceri Davies wrote:
> On Thu, Sep 04, 2003 at 01:00:37AM +0200, Simon L. Nielsen wrote:
> > In the DocBook documentation with HTML output when using a package
> > reference preceded by a character (with no space in between) there are
> > often inserted spaces which looks odd.  E.g from
> > http://www.freebsd.org/doc/en_US.ISO8859-1/books/handbook/video-playback.html
> > 
> > 	... codec with MPEG3 audio encoding (  audio/lame is required):
> > 
> > The HTML that gives this problem is:
> > 
> >             the MPEG4 codec with MPEG3 audio encoding (<a
> >             href="http://www.FreeBSD.org/cgi/url.cgi?ports/audio/lame/pkg-descr">
> >             <tt class="FILENAME">audio/lame</tt></a> is
> > 
> > The problem is that Tidy is a bit too agressive when trying to make the
> > HTML look nice, so it inserts newline where it really shouldn't, since
> > it tries to keep the lines at max 68 characters (the Tidy default
> > default).
> > 
> > To fix this I propose to remove the -i flag (which indents the HTML)
> > from the default Tidy arguments and add '-wrap 90'.  This makes the HTML
> > more "ugly", but I don't really think this matters, since it's still
> > correct and of course the browsers doesn't care.  If anybody for some
> > reason still like to generate more readable HTML, they can just use the
> > TIDYFLAG make variable to override the defaults.
> 
> Doesn't this simply decrease the chance of this happening, as opposed to
> actually fixing the issue?  Surely the above situation can still occur on
> a 90 column boundary.

Yes, I should have mentioned that.  The chance that it actually happen
is reduced a lot.  It would have to be a very long package name for the
problem to occur with the proposed settings.

> > Any objection to changing this?
> 
> Not really, but it doesn't sound like a real fix, unless I'm misunderstanding
> something.

It is a workaround, and of course tidy should do it right in any case,
but this will got us a long way without having to modify tidy.  If
somebody has the time to fix Tidy it would be great, but I don't at the
moment.

-- 
Simon L. Nielsen
FreeBSD Documentation Team
-------------- next part --------------
A non-text attachment was scrubbed...
Name: not available
Type: application/pgp-signature
Size: 187 bytes
Desc: not available
URL: <http://lists.freebsd.org/pipermail/freebsd-doc/attachments/20030904/608fd194/attachment.sig>


More information about the freebsd-doc mailing list