Allison Bloodworth wrote:
> I want to specify my own stylesheet to transform a DocBook document and
> find the instructions very confusing. I want to *add* this stylesheet in
> addition to others that are already there.
>
> I was trying to follow your directions in the DocBook Support document,
> section "1.1. Convert Document sub-menu," but it told me to create a
> customize.xxe file here:
> C:\Documents and Settings\xxe\config\customize.xxe. This is obviously
> incorrect (I realize from wasting time reading further documentation)
> and should be C:\Documents and Settings\{user}\xxe\config\customize.xxe.
We'll fix this typo.
> Continuing to follow the instructions on this page
> (http://www.xmlmind.com/xmleditor/_distrib/docs/docbook/ar01s01.html#d0e255),
> I tried to create a new customize.xxe file using the XMLMind editor. I
> got the cfg:configuration menu, but didn't see an option to choose
> cfg:parameterGroup from the menu. Based on the listing of parameters in
> Chapter 6. Configuration elements
> (http://www.xmlmind.com/xmleditor/_distrib/docs/configure/ch06.html) it
> should be there. Does that mean I should take this document out of XML
> Mind and (god forbid!) edit it with a text editor to add the element I
> need since the GUI apparently isn't working properly?
>
> Also, do I need to write a new java class to add a new stylesheet? #4 in
> the directions on page
> http://www.xmlmind.com/xmleditor/_distrib/docs/docbook/ar01s01.html#d0e255
> isn't
> very specific at all about what the parameter name and the "value of the
> parameter in the text placeholder" field means.
I hope you are not an author, but someone paid to customize XXE for a
group of authors (i.e. an external consultant or the local guru). End
users are not supposed to do what you are trying to do. Unlike most
other products, XXE is not designed to let end users do that.
Please find attached to this email, a docbook customization file
(created using a text editor) which adds conversion to single-page XHTML
to the DocBook menu.
------------------------------------------------------
<configuration name="DocBook"
xmlns="http://www.xmlmind.com/xmleditor/schema/configuration"
xmlns:cfg="http://www.xmlmind.com/xmleditor/schema/configuration"
xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance">
<include location="xxe-config:docbook/docbook.xxe"/>
<command name="docb.toXHTML">
<process>
<mkdir dir="resources" />
<mkdir dir="raw" />
<copyDocument to="__doc.xml">
<resources match="(https|http|ftp)://.*" />
<resources match=".+\.(png|jpg|jpeg|gif)"
copyTo="resources" />
<resources match="(?:.+/)?(.+)\.(\w+)"
copyTo="raw" referenceAs="resources/$1.png" />
<resources match=".+"
copyTo="resources" />
</copyDocument>
<convertImage from="raw" to="resources" format="png" />
<!-- The stylesheet is specified here ================ -->
<transform stylesheet="xxe-config:docbook/xsl/xhtml/docbook.xsl"
file="__doc.xml" to="__doc.html">
<parameter name="generate.toc">%0</parameter>
<parameter name="toc.section.depth">3</parameter>
<parameter name="section.autolabel">%1</parameter>
<parameter name="callout.graphics">0</parameter>
<parameter name="shade.verbatim">1</parameter>
<parameter name="ulink.show">0</parameter>
</transform>
<upload base="%2">
<copyFile file="__doc.html" to="%2" />
<copyFiles files="resources/*" toDir="resources" />
</upload>
</process>
</command>
<command name="docb.convertToXHTML">
<macro>
<sequence>
<command name="selectFile" parameter="saveFileURL" />
<command name="docb.toXHTML" parameter='"%0" "%1" "%_"' />
</sequence>
</macro>
</command>
<menu label="DocBook" mnemonic="D">
<insert />
<separator />
<item label="Convert to XHTML (one page)..."
command="docb.convertToXHTML"
parameter='"/book toc /article toc" 1' />
<item label="Convert to XHTML (one page, no TOC)..."
command="docb.convertToXHTML" parameter='" " 0' />
</menu>
</configuration>
------------------------------------------------------
Please save attached file as C:\Documents and
Settings\{user}\xxe\config\mydocbook.xxe and then restart XXE. If you
want to test them, you'll have to open a DocBook document (i.e. not a
Simplified DocBook one). You'll notice two new menu entries at the end
of the DocBook menu.
Note that the above customization requires you to use a recent XXE
(because of the "xxe-config:" style URLs).
If you really want to understand how all this works in order to adapt it
to your needs, I'm sorry but you'll have to spent *several hours*
reading badly written documentation, at least:
http://www.xmlmind.com/xmleditor/_distrib/docs/commands/ch05.html
and
http://www.xmlmind.com/xmleditor/_distrib/docs/configure/ch04.html
---
PS: This kind of question must be sent to xmleditor-support at xmlmind.com.
-------------- next part --------------
A non-text attachment was scrubbed...
Name: mydocbook.xxe
Type: text/xml
Size: 2162 bytes
Desc: not available
Url :
http://www.xmlmind.com/pipermail/xmleditor-support/attachments/20041006/ed4d332b/attachment.xml