This is the mail archive of the docbook@lists.oasis-open.org mailing list for the DocBook project.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]
Other format: [Raw text]

Re: [docbook] DocBook SGML encoding?


Matej Cepl wrote:

is there any standard way how to mark encoding of SGML Docbook file?

Unfortunately no. But some applications (notably these ones which are based on sp parser from James Clark) can understand XML declaration even in SGML file:


<?xml version="1.0" encoding="iso-8859-2"?>

> I have here documents produced by LyX in ISO-8859-2 (I
love LyX so I would rather stick with SGML and non-UTF-8 encoding). I have installed libxml2 and libxslt1 (with xsltproc), which claim to work with SGML DocBook (and XSL stylesheets).

If I remember it correctly, support for DocBook SGML will be dropped from libxml2 soon. So I would recommend you to use XML version of DocBook. If the LyX is unable to save files in XML, you can use sx (or osx) program from sp (or opensp) package to get XML from SGML. If you can't add encoding as XML declaration in LyX, you can set SP_ENCODING environment variable to the value "iso-8859-2" prior to running sx.


> Further I installed fop from xml.apache.org and I
would love to use it for production of PDF files. Unfortunately, I have not found a way how to persuade xsltproc that it should convert encoding while processing document. Is it possible?

With DocBook XML source DocBook stylesheets produce FO output in UTF-8. Maybe usage of SGML frontend in libxml2 brokes this behaviour.


Sorry, if this is too stupid question, but I am still total newbie in DocBook world, and still fighting my way through just small part of Docbook: The Definitive Guide.

Although TDG is briliant reference for DocBook its parts dealing with tools and processing of DocBook documents are little bit out-of-date. I can recommend you Bob's excellent guide to the processing DocBook with XSL stylesheets:


http://sagehill.net/docbookxsl/index.html

And if you are that Matěj who can read Czech :-D, you can find some information also in my own DocBook tutorial:

http://www.kosek.cz/xml/db/

Jirka

--
-----------------------------------------------------------------
  Jirka Kosek  	
  e-mail: jirka@kosek.cz
  http://www.kosek.cz

Attachment: smime.p7s
Description: S/MIME Cryptographic Signature


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]