Susan F. wrote:
>
> my quest for more info led me to XXE documentation
> (http://www.xmlmind.com/xmleditor/documentation.shtml) long before i
> sent you an email. some of my questions are so elementary though that
> they are not covered in the documentation which assumes a basic level of
> understanding. but, i'm learning about XXE/DocBook faster than anyone
> else here at this company. i appreciate all your help and when i return
> to the States (or go to France?), i'd like to buy you a coffee/tea/jus
> de raisin ^^
Thanks. We appreciate your efforts and we'll try to help you as much as
we can.
>
> i have a few questions for which i cannot find answers on my own:
>
> * what is an imp file? is it an XXE-specific file? the *.imp, *.xxe
> files seem similar in their content/function, what is the
> difference between them?
* A .xxe file is a master XXE configuration file. A .incl ("incl" like
"include") file is an XXE configuration file which can not be used on
its own. It is intended to be included in another configuration (.xxe or
.incl) file.
* A .css file is a master CSS style sheet file. A .imp ("imp" like
"import") file is a CSS style sheet file which can not be used on its
own. It is intended to be included in another CSS style sheet (.css or
.imp) file.
> * if i make changes to docbook1.imp file (noted below) and then
> restart XXE and open my XML file, why can't i see "FooBar" as my
> Chapter heading in the XXE editing view:
>
> chapter > title:before {
> content: "Chapter " simple-counter(n-, decimal) ": "; */* change
> Chapter to FooBar, for example */*
> }
My answer assumes that you are creating DocBook 4 documents (my answer
would be similar if you happen to create DocBook 5 documents):
* XXE_install_dir/addon/config/docbook/docbook.xxe contains:
---
<css name="DocBook" location="css/docbook.css" />
<css name="Images displayed as thumbnails" alternate="true"
location="css/thumbnails.css" />
<css name="Document structure" alternate="true"
location="css/structure.css" />
<css name="Show info about included elements" alternate="true"
location="css/visible_inclusions.css" />
---
Therefore the main CSS style sheet is
XXE_install_dir/addon/config/docbook/css/docbook.css
* XXE_install_dir/addon/config/docbook/css/docbook.css contains:
---
@import "docbook1.imp";
@import "refentry.imp";
@import "docbook2.imp";
@import "html_cals_table.imp";
@import "image.imp";
@import "collapsible.imp";
@import "print.imp";
---
* XXE_install_dir/addon/config/docbook/css/docbook1.imp contains:
---
chapter > title:before {
content: "Chapter " simple-counter(n-, decimal) ": ";
}
---
* BUT XXE_install_dir/addon/config/docbook/css/collapsible.imp contains:
---
chapter > title:first-child:before {
content: collapser() " Chapter " simple-counter(n-, decimal) ": ";
}
---
That is, collapsible.imp *overrides* the styling of chapter/title found
in docbook1.imp in order to make chapters collapsible.
Therefore you need to modify collapsible.imp and not docbook1.imp.
> * we would like to change the number displayed in the XXE editing
> view so that when we open an XML file which is to be Chapter 8 in
> the final publication, XXE displays it as such, "Chapter 8", for
> example). How do we accomplish this? i found and read the info in
> this post
> (http://osdir.com/ml/editors.xxe.general/2006-09/msg00081.html)
> but still don't fully get the concept. where is the point of
> reference used by XXE to display the chapter numbering and how can
> we tell XXE to make the numbers different depending on XML file
> opened? (note: we use book.xml which consists of a list of
> includes of our chapter0n.xml files and we have one xml file for
> each chapter/appendix/etc.)
>
What's displayed by XXE is intended to help the author understand the
structure of the document. What's displayed by XXE is not intended to
reflect what you'll get when you'll convert the document to PDF.
Therefore (if I understand what you want to do), there is absolutely no
way to properly number chapter ``modules'' out of the scope of the
master book document which includes them.
Here's how it works in XXE:
[1] When you create or edit a chapter in its own file. The numbering of
this chapter is always 1.
Note: It is not a good idea to name your files chapter01.xml,
chpater02.xml, etc. You should rather give your files meaningful names:
introduction.xml, requirements.xml, getting_started.xml, etc.
[2] After creating a few chapters, you create a empty book using File|New.
[3] Then you use "Copy As Reference" (Ctrl+Shift-C) then "Paste After"
(Ctrl-W) to paste *references* to the aforementioned chapters into the book.
Now your book includes your chapters and the chapters are properly
numbered (chapter 1 is the first chapter included in the book, chapter 2
is the second chapter included in the book, etc).
Once again, this numbering just helps the author to understand the
structure of her document. You may convert your document to a PDF
showing a different numbering (e.g. the chapter number includes the
number of its parent part element) or no numbering at all.
--> The whole point of using an XML editor such as XXE versus using MS
Word is:
When you use an XML editor, you need to completely forget about how your
document will look when converted to HTML or PDF. You need to
concentrate on the prose, structure and semantics (i.e. markup) of your
document.
The job of getting it right (part/chapter/section numbering, font size,
vertical space between paragraphs, TOC, index, etc) when you convert
your document to HTML or PDF is *totally* *unrelated* to the job of
authoring the document.
> * do any of the *.imp, *.xxe, *.css or any other XXE/DocBook files
> influence the XML -> PDF generation process? (note: we use Apache
> Ant pdf command for rendering PDF output so that we can perform a
> visual inspection of the entire document before final submission.
> it seems as though only the XML files are input to that process
> but the *.imp files seems to include configurations that are for
> output rendering
No, not at all.
> .)
>
If you use an external tool to generate the PDF, then any of the *.imp,
*.xxe, *.css or any other XXE/DocBook configuration files do *not*
influence the behavior of this external tool. (This is consistent with
what I told you in the answer above.)
The look of the generated PDF is entirely controlled by the DocBook XSLT
style sheets[*] which are bundled with your external tool (which I don't
know).
---
[*] XXE has a "DocBook|Convert Document" menu which includes "Convert to
PDF" and as such, bundles its own copy of DocBook XSLT style sheets. But
from what you describe, you don't seem to use XXE's integrated document
conversion facilities.
Note that even if this was the the case, then the .css and .imp files
would have had no influence at all on the generated PDF.
---
PS: I've forwarded my answer to the xmleditor-support at xmlmind.com public
mailing list as your questions seem not to contain any confidential
information and seem to always be of general interest.