[LyX/2.4.x] Avoid missing updates after some operations on selection

Jean-Marc Lasgouttes lasgouttes at lyx.org
Sat Aug 31 14:28:18 UTC 2024


commit 4d46f766ea3f24608b8b7b418893054bfa7495dd
Author: Jean-Marc Lasgouttes <lasgouttes at lyx.org>
Date:   Fri Aug 30 17:26:48 2024 +0200

    Avoid missing updates after some operations on selection
    
    The logic at the end of Text::dispatch failed when needsUpdate and
    singleParUpdate were true at the same time.
---
 src/Text.cpp | 2 +-
 status.24x   | 1 +
 2 files changed, 2 insertions(+), 1 deletion(-)

diff --git a/src/Text.cpp b/src/Text.cpp
index e96c9a1e81..f63a6ede4b 100644
--- a/src/Text.cpp
+++ b/src/Text.cpp
@@ -6386,7 +6386,7 @@ void Text::dispatch(Cursor & cur, FuncRequest & cmd)
 
 	// FIXME: the following code should go in favor of fine grained
 	// update flag treatment.
-	if (singleParUpdate) {
+	if (singleParUpdate && !needsUpdate) {
 		// Inserting characters does not change par height in general. So, try
 		// to update _only_ this paragraph. BufferView will detect if a full
 		// metrics update is needed anyway.
diff --git a/status.24x b/status.24x
index 4ad8487467..2e789c7a5c 100644
--- a/status.24x
+++ b/status.24x
@@ -126,6 +126,7 @@ What's new
 - Fix crash when deleting tabs in a selection (with S-BackTab) in a
   text-only inset (ERT, Listings...).
 
+- Fix display glitches when applying some operations to a selection.
 
 * INTERNALS
 


More information about the lyx-cvs mailing list