Skip to main content
QueSarahSera
Participant
July 23, 2014
Question

Word Wrap Lost When Switching Between XML and Author Views

  • July 23, 2014
  • 1 reply
  • 270 views

I compose DITA topics in the XML view with the word wrap option selected. If I switch to the Author view to check something and then return to the XML view, my nicely formatted XML view with all the happy element-nesting tabs goes away. I wind up with an ugly chunk of flush-left code and text that's difficult to read. Is there a reason why FM can't remember the tabs and word wrap when I return to the XML view?

I'm relatively new to using FM's structured side for DITA, so perhaps I'm missing the obvious solution to this problem. If you know the answer, I'd appreciate if you'd clue me in.

Thanks!

This topic has been closed for replies.

1 reply

Inspiring
July 23, 2014

Sarah,

When you switch from XML to Author (or WYSIWYG) view, FM does not "remember" the XML document at all. Instead, internally it creates a structured FM document with the same element structure (possibly modified by the underlying XML application). When you switch back to XML view, it creates a new XML document from the current element structure, thereby preserving any changes you made in Author View. FM is very conservative about writing white space to XML in order to avoid inserting unwanted significant space.

If you do all your editing in XML View and want to inspect the formatted version of the document without making changes to white space, always make a copy of the XML document (with File > Save As) and use the copy in Author View.

--Lynne

QueSarahSera
Participant
July 23, 2014

Thanks for the explanation, Lynne. I appreciate it very much.