diff options
author | Pawel Z Wronek <unknown> | 2024-11-25 08:28:55 +1100 |
---|---|---|
committer | Pawel Z Wronek <unknown> | 2024-11-25 08:28:55 +1100 |
commit | b1280b8651fce6be3e020ced53ecb5a17b59a7ab (patch) | |
tree | 0d5286ca5961bc0ddd50b4ae1a43c11fea50aed4 /src | |
parent | 28ee322763282711d4394e092aeefd29e9f972bb (diff) | |
download | scintilla-mirror-b1280b8651fce6be3e020ced53ecb5a17b59a7ab.tar.gz |
Bug [#2456]. Fix wrapping removed lines.
Diffstat (limited to 'src')
-rw-r--r-- | src/Editor.cxx | 6 |
1 files changed, 6 insertions, 0 deletions
diff --git a/src/Editor.cxx b/src/Editor.cxx index d1bcfa02a..1c3437b7e 100644 --- a/src/Editor.cxx +++ b/src/Editor.cxx @@ -2634,6 +2634,12 @@ void Editor::CheckModificationForWrap(DocModification mh) { const Sci::Line lineDoc = pdoc->SciLineFromPosition(mh.position); const Sci::Line lines = std::max(static_cast<Sci::Line>(0), mh.linesAdded); if (Wrapping()) { + // Check if this modification crosses any of the wrap points + if (wrapPending.NeedsWrap()) { + if (lineDoc < wrapPending.end) { // Inserted/deleted before or inside wrap range + wrapPending.end += mh.linesAdded; + } + } NeedWrapping(lineDoc, lineDoc + lines + 1); } RefreshStyleData(); |