Skip to main content
1-Visitor
May 8, 2013
Question

How to style a new XML element for edit view if don't have Styler?

  • May 8, 2013
  • 5 replies
  • 1343 views

Hi, all...



We use Arbortext but don't have a license for Styler, and we want to properly style an element we're introducing to the DTD. Actually, it's the inline element from DocBook 4.5, not supported by the current version of Arbortext. How to do this?



I added the following code to our *.style file underneath our custom/doctypes directory, and the code element is now being styled properly, but now all generated text (chapter and section numbers, section titles from xrefs) is getting many leading and trailing spaces or underscores.



 <element name="code" style="inline">


  

  </context>

    5 replies

    18-Opal
    May 8, 2013
    Hi Steve--



    Chances are if you are not using Styler to edit the stylesheet, but are
    editing it in a text editor (or in Arbortext as an XML file), the editor
    added linebreaks and maybe indenting whitespace to "pretty print" the
    XML. But in generated text, whitespace is treated as significant.



    Try saving the file with nonsignificant whitespace removed, and that
    should fix your problem. If you have trouble getting that to work, then
    try reverting back to your original stylesheet, and open it in a plain
    text editor, and make your change without doing any kind of element
    indenting or adding new line breaks.



    --Clay



    Clay Helberg

    Senior Consultant



    TerraXML

    1380 Forest Park Circle, Suite 100

    Lafayette, CO 80027
    sfogel1-VisitorAuthor
    1-Visitor
    May 10, 2013

    Right you are. I reverted the file and added my code without adding any white space, and the problem went away. Thanks so much!



    Steve

    16-Pearl
    May 10, 2013
    You'll be pleased to know you are not the first person to ever have problems with XML and whitespace 🙂 I'd say it's got to be one of XML's biggest design flaws.

    -Gareth
    sfogel1-VisitorAuthor
    1-Visitor
    May 10, 2013
    J







    HYPERLINK " \nOracle
    Steve Fogel | Information Architect, Oracle Database | 650.506.4914
    Oracle Server Technologies Information Development
    500 Oracle Parkway | M/S 4op1126 | Redwood Shores, CA 94065


    18-Opal
    May 10, 2013
    Right, that's how I recognized the problem right away. BTDT... 🙂



    Clay Helberg

    Senior Consultant



    TerraXML

    1380 Forest Park Circle, Suite 100

    Lafayette, CO 80027