• XML Editor

    Creating DocBook XML Documents with XMLMind’s XML Editor

    XML EditorCreating DocBook XML Documents with XMLMind’s XML Editor

    It is easier to create DocBook XML documents using an XML editor with a point-and-click graphical user interface (GUI) than a text editor like notepad. The steps are simple, too. To create a DocBook document using XMLMind’s XML Editor (XXE), follow the instructions below.

    Download XMLMind’s XML Editor

    Windows, Linux, Mac OS or any platform that supports Sun Java version 1.4 or better can run the XXE. It is Java-based, however, so if your computer does not have Java installed, you still won’t be able to run it. You need to visit http://java.sun.com and download the J2SE Java Runtime Environment (JRE) that is suitable for your operating system.

    Once you are sure that your computer can run Java, download XXE from XMLMind’s product page at http://www.xmlmind.com/products.html. The personal edition of XXE is free, and it comes with an end-user license. Additionally, if you want to convert your DocBook documents to HTML, PDF or Rich Text, you need to download XMLMind’s FO Converter.

    Installing XMLMind’s XML Editor

    Make sure that you are logged in as a user, so you have sufficient privileges to install the editor. If you are using Windows, installing the XXE would be easy — you’ll only have to accept the default directory locations. But if your computer runs other operating systems, you’ll need to install XXE using the tar+gzip archive.

    If you need to install XXE via the tar+gzip archive,

    1. Choose a suitable location to install. For instance, use /usr/local.
    2. Extract the archive to that location.
    3. Create an application launcher on the desktop that points to the XXE shell script.

    Fixing Installation Problems

    Sometimes, the XXE does not run after installation because it cannot find Java. To troubleshoot, make sure that the directory containing the Java binary is included in the system’s PATH variable. You could also run the editor from the command-line and check the error messages that might appear. If XXE still refuses to run, refer to the XXE FAQ.

    Creating a New DocBook XML Document

    Once the XXE is installed, you can create a new DocBook Document. To do this,

    1. Select File, New from the menu.
    2. Choose between DocBook Article and DocBook Book.
    3. Select Style, Both Tree And Styled Views from the menu, so you have a better feel of the document’s structure.
    4. Key in the title of your document in the empty title element. You could also fill in the section and chapter elements.
    5. Add new elements by choosing an existing element in the tree view. Then, select Edit, Insert After from the menu. For instance, if you want to add another section, select an existing section element and do an Insert After. Select ‘section’ from the edit tool on the far right of the XXE window.
    6. If you want to add inline markups for commands, user input, ulinks and others, highlight the chosen text. Select Edit, Convert from the menu. Then, select the element from the choices that will appear in the edit tool on the far right.
    7. To fill in values for elements, select the particular element and use the attribute tool. The attribute tool can be found on the tab that has a picture of two checkboxes.
    8. Save the document by using File, Save from the menu.

    Creating new DocBook documents will be easier once you get a good grasp of the step-by-step process. You could also refer to the XXE help file and product documentation to learn more about how to use the XML Editor.

    Publishing the DocBook XML Document

    All DocBook XML documents can be converted to HTML, PDF or Rich Text formats using the FO Converter. The converter’s licensing terms and installation process are like that of the XXE.

    To convert the document

    1. Choose the DocBook XML input document via the file browser.
    2. Select the format it will be converted into. For instance, DocBook to PDF.
    3. Choose an output directory for the finished file.
    4. Click the Convert button.

    Once converted, the document can be read using the right viewer. For instance, you can use a web browser for HTML files and an Acrobat Reader for PDF files.

    And there you have it. You’re now ready to create DocBook books and articles from XXE.