This is the mail archive of the
docbook-apps@lists.oasis-open.org
mailing list .
Re: Word order in Basque language
- From: Jirka Kosek <jirka at kosek dot cz>
- To: Camille Bégnis <camille at mandrakesoft dot com>
- Cc: apps docbook <docbook-apps at lists dot oasis-open dot org>
- Date: Fri, 12 Apr 2002 12:13:12 +0200
- Subject: Re: DOCBOOK-APPS: Word order in Basque language
- References: <3CB6A93F.891496ED@mandrakesoft.com>
Camille Bégnis wrote:
> in English when you number an item, you name it "Item X" for example:
> "Chapter 2". Though In Basque language (Euskara), it is named "X item",
> for example "2 Atala".
>
> It is possible to change the generated Xref strings through
> (eu-xref-strings) but I could not find the place to change it for the
> actual naming of elements (chapters, sections, figures, etc.).
If you want to get correct Basque text generated append lang attribute
with appropriate ISO language code to the root element of your document.
E.g.
<!DOCTYPE book ...>
<book lang="eu">
...
</book>
This should be sufficient. If you found some errors in translations,
please send corrected version of files
http://cvs.sourceforge.net/cgi-bin/viewcvs.cgi/*checkout*/docbook/gentext/locale/eu.xml?rev=HEAD&content-type=text/xml
http://cvs.sourceforge.net/cgi-bin/viewcvs.cgi/*checkout*/docbook/dsssl/common/dbl1eu.dsl?rev=HEAD&content-type=text/plain
as patches to SourceForge bug tracking system.
Huh, now I realised, that my answer is to different question than yours.
In XSL stylesheets it is easy to change this by template, but in DSSSL
it is not so easy AFAIK.
Probably changing rule in dbcompon.dsl will help:
(define ($component-title$ #!optional (titlegi "H1") (subtitlegi "H2"))
(let* ((info (cond
((equal? (gi) (normalize "appendix"))
(select-elements (children (current-node)) (normalize "docinfo")))
((equal? (gi) (normalize "article"))
(node-list-filter-by-gi (children (current-node))
(list (normalize "artheader")
(normalize "articleinfo"))))
((equal? (gi) (normalize "bibliography"))
(select-elements (children (current-node)) (normalize "docinfo")))
((equal? (gi) (normalize "chapter"))
(select-elements (children (current-node)) (normalize "docinfo")))
((equal? (gi) (normalize "dedication"))
(empty-node-list))
((equal? (gi) (normalize "glossary"))
(select-elements (children (current-node)) (normalize "docinfo")))
((equal? (gi) (normalize "index"))
(select-elements (children (current-node)) (normalize "docinfo")))
((equal? (gi) (normalize "preface"))
(select-elements (children (current-node)) (normalize "docinfo")))
((equal? (gi) (normalize "reference"))
(select-elements (children (current-node)) (normalize "docinfo")))
((equal? (gi) (normalize "setindex"))
(select-elements (children (current-node)) (normalize "docinfo")))
(else
(empty-node-list))))
(exp-children (if (node-list-empty? info)
(empty-node-list)
(expand-children (children info)
(list (normalize "bookbiblio")
(normalize "bibliomisc")
(normalize "biblioset")))))
(parent-titles (select-elements (children (current-node)) (normalize
"title")))
(info-titles (select-elements exp-children (normalize "title")))
(titles (if (node-list-empty? parent-titles)
info-titles
parent-titles))
(subtitles (select-elements exp-children (normalize "subtitle"))))
(make sequence
(make element gi: titlegi
(make sequence
(make empty-element gi: "A"
attributes: (list (list "NAME" (element-id))))
(if (and %chapter-autolabel%
(or (equal? (gi) (normalize "chapter"))
(equal? (gi) (normalize "appendix"))))
;; SWAPED (gentext-element... with (element-label HERE !!!!!
(literal
(element-label (current-node))
(gentext-element-name-space (gi))
(gentext-label-title-sep (gi)))
(empty-sosofo))
(if (node-list-empty? titles)
(element-title-sosofo) ;; get a default!
(with-mode title-mode
(process-node-list titles)))))
(if (node-list-empty? subtitles)
(empty-sosofo)
(with-mode subtitle-mode
(make element gi: subtitlegi
(process-node-list subtitles)))))))
Jirka
--
-----------------------------------------------------------------
Jirka Kosek
e-mail: jirka@kosek.cz
http://www.kosek.cz