Menu

Option: Pretty print NOT collapse empty tags?

Help
pasbesoin
2007-10-23
2012-12-07
  • pasbesoin

    pasbesoin - 2007-10-23

    Would it be possible/desirable to add an option that would cause pretty print to NOT collapse empty tags (e.g. "<name></name>" becomes "<name/>")?  There are times when I wish to pretty print a document, but then add values to empty tags.  I also sometimes prefer the uncollapsed presentation.  I'm using the Windows version 1.1.0.3 .

     
    • gnschmidt

      gnschmidt - 2007-10-30

      Sorry about the delay.

      I'll have another look at the libxml options for this: AFAIK there isn't an option for this though. (Pretty-printing isn't entirely trivial so it's handled by the parser - libxml - at the moment.) What might be worth implementing is an algorithm that ignores the DTD and indents each and every tag, inline or not. Do you think this might be useful?
      -Gerald

       
      • Alex Woodhouse

        Alex Woodhouse - 2007-11-15

        I would rather that if you did this, you could leave the existing functionality in as an option. One of the reasons i selected this XML editor was because it would not place inline tags on a new line.

         
    • gnschmidt

      gnschmidt - 2007-11-16

      Thanks Alex, that goes without saying! I would treat this as an additional, separate function and perhaps present it as an option later.
      -G

       

Log in to post a comment.