From 0cccd1e6285dce657e7106cc3ea0cd090a772860 Mon Sep 17 00:00:00 2001 From: Neil Date: Thu, 19 Jan 2017 21:25:16 +1100 Subject: Bug [#1896]. Ensure folding consistent when fold header added above folded part. --- doc/ScintillaHistory.html | 4 ++++ src/Editor.cxx | 2 +- 2 files changed, 5 insertions(+), 1 deletion(-) diff --git a/doc/ScintillaHistory.html b/doc/ScintillaHistory.html index e3d0dce25..1236efd7d 100644 --- a/doc/ScintillaHistory.html +++ b/doc/ScintillaHistory.html @@ -538,6 +538,10 @@ Bug #1848.
  • + Fix folding inconsistency when fold header added above a folded part. + Bug #1896. +
  • +
  • SciTE on GTK+ can have a wide divider between the panes with the split.wide property.
  • diff --git a/src/Editor.cxx b/src/Editor.cxx index 8e4ebf18a..29f0681fd 100644 --- a/src/Editor.cxx +++ b/src/Editor.cxx @@ -5500,7 +5500,7 @@ void Editor::FoldChanged(int line, int levelNow, int levelPrev) { if (!(levelNow & SC_FOLDLEVELWHITEFLAG) && (LevelNumber(levelPrev) < LevelNumber(levelNow))) { if (cs.HiddenLines()) { const int parentLine = pdoc->GetFoldParent(line); - if (!cs.GetExpanded(parentLine) && cs.GetExpanded(line)) + if (!cs.GetExpanded(parentLine) && cs.GetVisible(line)) FoldLine(parentLine, SC_FOLDACTION_EXPAND); } } -- cgit v1.2.3