Line breaks introduced into data when reformatting XML
已回答
When you reformat XML which contains long, or deeply nested fields, then line breaks are introduced as per the setting in "editor">>"Code Style">>"Hard wrap at". Whilst these line breaks may not be a problem for other languages, with XML this behaviour is corrupting the data itself.
I had a situation where text data within an XML element was being split with newline characters, therefore altering the meaning of that data.
Is it possible to stop hard linebreaks being inserted when reformatting code? If not, then it should be added as an option for XML or at the very least a warning should be shown as the data is being corrupted.
请先登录再写评论。
I've discovered how to do this. In "Editor" >> "Code style" >> "XML", unchecking "Wrap Text" prevents line breaks being inserted into the data when an elements text exceeds the hard wrap limit.
Perhaps this should be the default for XML, otherwise data can be corrupted.
Hello,
Please vote for https://youtrack.jetbrains.com/issue/IDEA-139128 with thumb up button.