Craig Turner wrote:
> I'm investigating use of xmleditor as a word processor. One of our
> clients are converting to a XML-based authoring system. If I'm at the
> end of the last paragraph of a chapter, how do I create a chapter after
> the current point? (I'm using the docbook DTD)
>
Method [1] select the chapter containing the paragraph, use command
"Insert After", choose element "chapter" from the list.
Method [2] use the "?" button found in the DocBook toolbar and choose
"chapter" from the menu.
Oops! this button/menu only contains "section", "sect1", "sect2", etc.
Fortunately, you can add to it "chapter", "appendix", etc, very easily
(may be we'll fix this omission in next version).
Here's how to do that:
[1] Edit XXE_install_dir/addon/config/docbook/toolBar.incl
[2] Change:
---
<button toolTip="Add section"
icon="../common/icons2/section_menu.gif">
<menu>
<item label="section" command="add"
parameter="after[implicitElement] section" />
<item label="sect1" command="add"
parameter="after[implicitElement] sect1" />
<item label="sect2" command="add"
parameter="after[implicitElement] sect2" />
<item label="sect3" command="add"
parameter="after[implicitElement] sect3" />
<item label="sect4" command="add"
parameter="after[implicitElement] sect4" />
<item label="sect5" command="add"
parameter="after[implicitElement] sect5" />
</menu>
</button>
---
to:
---
<button toolTip="Add chapter or section"
icon="../common/icons2/section_menu.gif">
<menu>
<item label="chapter" command="add"
parameter="after[implicitElement] chapter" />
<separator />
<item label="appendix" command="add"
parameter="after[implicitElement] appendix" />
<separator />
<item label="section" command="add"
parameter="after[implicitElement] section" />
<item label="sect1" command="add"
parameter="after[implicitElement] sect1" />
<item label="sect2" command="add"
parameter="after[implicitElement] sect2" />
<item label="sect3" command="add"
parameter="after[implicitElement] sect3" />
<item label="sect4" command="add"
parameter="after[implicitElement] sect4" />
<item label="sect5" command="add"
parameter="after[implicitElement] sect5" />
</menu>
</button>
---
[3] Restart XMLmind XML Editor.
Unlike command "insert"
(http://www.xmlmind.com/xmleditor/_distrib/doc/commands/insert.html),
command "add"
(http://www.xmlmind.com/xmleditor/_distrib/doc/commands/add.html)
must be passed the name of the element to be added. After that, this
command will automatically find where to add it.
---
PS: When we teach the use of XMLmind XML Editor to new users, our first
two sentences are always: "XMLmind XML Editor looks like a word
processor, but is *absolutely* *not* a word processor. You'll very often
need to think in terms of trees and nodes in order to use it, like it or
not.".