This is Interesting: Free Magazines for Graphics designers and webmasters  


Home > Archive > Site Ratings & Reviews > September 2004 > CSS stylesheet for DocBook XML





You are viewing an archived Text-only version of the thread. To view this thread in it's original format and/or if you want to reply to this thread please [click here]

Author CSS stylesheet for DocBook XML
rumionfire@gmail.com

2004-09-12, 7:16 pm

Jean-Philippe Guérard of Traduc.org, has prepared a CSS stylesheet for
HTML, that enhances documents created using DocBook XML (via the TLDP
XSL stylesheet).

The CSS is available @
http://www.traduc.org/docs/HOWTO/lecture/style.css

You can find a few sample Documents that use this CSS at :
http://www.xml-dev.com/blog/#88

(All of the HOWTOs list at http://www.xml-dev.com/blog/#88 use the
above mentioned CSS)


Please provide a critique of the CSS.

Thanks.
Saqib Ali
http://validate.sf.net
rf

2004-09-12, 11:15 pm

rumionfire@XXXXXXXXXX wrote:

> The CSS is available @
> http://www.traduc.org/docs/HOWTO/lecture/style.css


I hope you did not actually *pay* for this.

--
Cheers
Richard.


Chris Beall

2004-09-12, 11:15 pm

rumionfire@XXXXXXXXXX wrote:
> Jean-Philippe Guérard of Traduc.org, has prepared a CSS stylesheet for
> HTML, that enhances documents created using DocBook XML (via the TLDP
> XSL stylesheet).
>
> The CSS is available @
> http://www.traduc.org/docs/HOWTO/lecture/style.css
>
> You can find a few sample Documents that use this CSS at :
> http://www.xml-dev.com/blog/#88
>
> (All of the HOWTOs list at http://www.xml-dev.com/blog/#88 use the
> above mentioned CSS)
>
>
> Please provide a critique of the CSS.
>
> Thanks.
> Saqib Ali
> http://validate.sf.net


I looked at the CSS (which validates clean) and then looked at the
'Autodir HOWTO' document. My browsers were full-screen at 600 X 800 pixels.

In IE 5.5, none of the colored backgrounds appear and the borders are
gray rather than the specified color.

In NN 7.1, all <tt> text, in addition to being significantly smaller
than the body text, is on a lower baseline than the text within which it
occurs. (This is most evident if you swipe-select the text with the
mouse). Most of the <tt> text was assigned a class="filename", but there
is nothing in the CSS which selects on that class, nor any override of
the browser's definition for <tt>. I suspect a Netscape bug for the
baseline thing.

There is a block diagram tagged with <pre class="screen">. The class
specifies:
background: #f0f0ff;
padding: 5px;
margin: 5px;
In NN 7.1, the background color appears, but at 600 X 800 it does not
extend completely under the text on the right side. Instead, it is
centered on the window, with equal white space on each side. If the
window is made smaller, the background shrinks to correspond, while the
<pre> text, as expected, extends beyond the window on the right.
[I think there's either something I don't understand here (likely) or a
bug in NN 7.1. <pre> is normally display:block and I see nothing in the
CSS that changes this. If the TEXT inside the <pre> is allowed to cross
the inherited right boundary, why is the background not also allowed to
do so?]

The following CSS seems to be redundant:
/* Alignement des colonnes */
/* Colunms alignment */

td[align=center] , th[align=center] { text-align: center; }
td[align=right] , th[align=right] { text-align: right; }
td[align=left] , th[align=left] { text-align: left; }
td[align=justify] , th[align=justify] { text-align: justify; }

unless browsers don't action <td align="center"> etc. for Transitional
XHTML.

Anyway, other than that it all looked pretty clean. I liked the fact
that there were comments in the CSS, including both languages.

Since you asked for a review of the CSS, I deduce that you have no
control over the XML, so I won't comment on it.

For those who, like me, never heard of DocBook, you can find some
information at http://docbook.sourceforge.net/#d4e77. It kept referring
to 'DocBook' this and 'DocBook' that, but I never found much on what the
objectives of DocBook were, just that "DocBook is a document type
definition (DTD) in SGML and XML. It is particularly well suited to
books and papers about computer hardware and software (though it is by
no means limited to these applications)."

Regards,
Chris Beall


Neal

2004-09-13, 4:16 am

On 12 Sep 2004 09:49:45 -0700, <rumionfire@XXXXXXXXXX> wrote:

> Jean-Philippe Guérard of Traduc.org, has prepared a CSS stylesheet for
> HTML, that enhances documents created using DocBook XML (via the TLDP
> XSL stylesheet).
>
> The CSS is available @
> http://www.traduc.org/docs/HOWTO/lecture/style.css
>
> You can find a few sample Documents that use this CSS at :
> http://www.xml-dev.com/blog/#88
>
> (All of the HOWTOs list at http://www.xml-dev.com/blog/#88 use the
> above mentioned CSS)
>
>
> Please provide a critique of the CSS.


font-family: Apolline, "URW Palladio L", Garamond, jGaramond, "Bitstream
Cyberbit", "Palatino Linotype", serif;

I have none of these fonts, so TNR. Big deal.

h1 { font-size: 200%; font-weight: 900; }
h2 { font-size: 160%; font-weight: 900; }
h3 { font-size: 130%; font-weight: bold; }
h4 { font-size: 115%; font-weight: bold; }
h5 { font-size: 108%; font-weight: bold; }
h6 { font-weight: bold; }

I like this, in practice the lower headings have too small default
renderings. font-weight: 900 is not really needed, though, bold will be
fine.

div[class~="blockquote"]

What's wrong with div.blockquote ? Means the same thing in a hell of a lot
less bits. To my knowledge, it's better supported too, though I haven't
tested it.

img { border: 0; }

This makes it impossible to discern some images as anchor links.

:link , :visited , :active { text-decoration: none; }

Boo. How do I know it's a link in the first place, how do I know to hover?
I don't hover on every goddamn word, and neither do you.

In summary - a mix of good and poor practice. I'd leave it alone, or take
the best parts and modify for usability.
rumionfire@gmail.com

2004-09-13, 12:17 pm

"rf" <rf@.invalid> wrote in message news:<Q241d.28671$D7.1971@news-server.bigpond.net.au>...
> rumionfire@XXXXXXXXXX wrote:
>
>
> I hope you did not actually *pay* for this.


it's that bad?

In Peace,
Saqib Ali
http://validate.sf.net
rumionfire@gmail.com

2004-09-13, 12:17 pm

Thanks for the reponse :)

> Since you asked for a review of the CSS, I deduce that you have no
> control over the XML, so I won't comment on it.


We have limited control over XSLT that is used for converting XML to
HTML. If you would like to make suggestions that will improve the HTML
output, please feel free to do so.

Thanks.
Saqib Ali
http://validate.sf.net
rumionfire@gmail.com

2004-09-13, 7:18 pm

> font-family: Apolline, "URW Palladio L", Garamond, jGaramond, "Bitstream
> Cyberbit", "Palatino Linotype", serif;
> I have none of these fonts, so TNR. Big deal.

Thanks for the suggestion. I changed it to:

font-family: Verdana, Helvetica, sans-serif;

Thanks,
Saqib Ali
http://validate.sf.net
Sponsored Links


Copyright 2003 - 2008 forum4designers.com  Software forum  Computer Hardware reviews