[Date Prev][Date Next] [Thread Prev][Thread Next] [Date Index] [Thread Index]

Re: Linguistic work on rgbPaint.

Dear Justin, dear all,

here I go, exposing my shortcomings.

måndag den 29 november 2010 klockan 19:14 skrev Justin B Rye detta:
> Mats Erik Andersson wrote:
> > I am preparing the initial packaging of rgbPaint, a software for which
> > I recently got help to rework the package description.
> >
> > [...]
> >
> > uses some 550 lines of XML-code to produce the manual page. Would it
> > be possible to find an accomplice for this amount of peer reviewing?
> I'm expecting to have even more free time than usual this month, so I
> can certainly help if you post it to the list - I don't know
> anything much about DocBook, though.

The attachments are threefold:

    rgbpaint.xml   is the Docbook source, intended for peer reviewing,

    manpage.xsl,   are stylesheets and evaluation helpers.

A crash course in Docbook compilation now follows! Only two dependencies:

    # apt-get install xsltproc docbook-xsl

Once these are in place, and putting the above three files in a common
directory, the command

    $ xsltproc manpage.xsl rgbpaint.xml

will produce a subdirectory "$(PWD)/man/" where the manual page rgbpaint.1
is deposited. Correspondingly

    $ xsltproc xhtml.xsl rgbpaint.xml
    $ lynx html/index.html

will create "$(PWD)/html/" and deposit three XHTML files there for viewing.

Personally, I find Vim very useful in giving me syntax highlighting
of rgbpaint.xml. Beyond that help I believe there is only one issue
in reading the XML source. The tags <xref> will expand in the target
format to either a title content, augmented by a noun phrase, or the
verbatim content of a tag <xreflabel> of the identifier referenced to.
For this reason I recommend using the xsltproc calls above. It is only
a matter of following the attribute "id" to locate the correct section.

The two target formats display slightly different emphasises, but are
mostly identical. With a bit of luck, anyone trying these steps in
Docbook compilation for the first time, might enjoy it enough to expand
the private tool box with also this knowledge for future work! The trick
with the stylesheets is to make some costumisation and to hide two very
long file paths.

Best regards,

Mats E A

Attachment: rgbpaint.xml
Description: XML document

Attachment: manpage.xsl
Description: XML document

Attachment: xhtml.xsl
Description: XML document

Attachment: signature.asc
Description: Digital signature

Reply to: