Page 1 of 1
Text Editor lumping all code together for one topic
Posted: Fri Jul 12, 2024 8:32 am
by perrinstewart
Everything was fine before the latest release of Flare. Now when I open a particular topic and click on the Text Editor, everything below the <body> tag is lumped together with no line breaks all the way down to the </body> tag. I tried a hard return on a few lines to see if they would stick, but nope, when I click on the XML Editor and then back to the Text Editor all the code is lumped together again.
Anyone ever run into this before? Other topics seem to be ok except for this one. Never run into this issue before on this one topic when using the text editor.
Re: Text Editor lumping all code together for one topic
Posted: Thu Jul 18, 2024 5:33 am
by scap
I haven't upgraded, but I do see this with certain type of XML code that Flare seemingly doesn't like.
The editor has lots of bad behavior, it desperately needs an update. Doesn't recognize Flex and CSS variables for example.
Re: Text Editor lumping all code together for one topic
Posted: Thu Jul 18, 2024 8:29 am
by perrinstewart
And it only seems to be happening in one topic, which is strange (and that topic's code has looked fine in the past)...
Re: Text Editor lumping all code together for one topic
Posted: Sun Jul 21, 2024 4:25 pm
by robdocsmith
I've seen it before when Flare doesn't like the way some things are nested. Sometimes removing or adding a single return can make the code spring between being in a clump or being in a nice ordered layout. Basically every time Flare opens the file in the text editor it is auto formatting the contents into what it considers a readable indented format, not just displaying the file as is. You'll notice that it identifies the file as needing saving when flicking between Text and XML views, even when you've not changed anything. I don't know you can turn that off.
Mostly I see it when there are nested lists and there are line breaks in what Flare considers the wrong position. Anything nested in a disagreeable (to Flare) position gets clumped which can mean a table within a list is just a block of clumped code. I think sometimes it feels like Flare says to itself "oh man I really don't know what to do with all the indents now, I'm just going to put all the code on the screen".
My solution is usually to open the file in an external text editor, use their prettify HTML option, and then save it. When you open back in Flare the code is formatted better.
Re: Text Editor lumping all code together for one topic
Posted: Tue Aug 06, 2024 11:14 am
by perrinstewart
Thank you for that tip...I downloaded the XML Tools plugin for Notepad++ and used its "Pretty print" option, and Madcap finally seems to like that formatting!