diff --git a/src/AddIns/DisplayBindings/XmlEditor/Project/Src/XmlFoldingStrategy.cs b/src/AddIns/DisplayBindings/XmlEditor/Project/Src/XmlFoldingStrategy.cs index d715f1e911..03eb1065b0 100644 --- a/src/AddIns/DisplayBindings/XmlEditor/Project/Src/XmlFoldingStrategy.cs +++ b/src/AddIns/DisplayBindings/XmlEditor/Project/Src/XmlFoldingStrategy.cs @@ -89,7 +89,7 @@ namespace ICSharpCode.XmlEditor /// elements. /// bool showAttributesWhenFolded = false; - + public XmlFoldingStrategy() { } @@ -136,7 +136,8 @@ namespace ICSharpCode.XmlEditor } } catch (Exception) { // If the xml is not well formed keep the foldings - // we found. + // that already exist in the document. + return document.FoldingManager.FoldMarker; } return foldMarkers;