commit 1c8a6c77261f0c5fd99bc269cb4d72679845b731
Author: Jean-Marc Lasgouttes <[email protected]>
Date:   Mon Jan 19 18:28:37 2026 +0100

    Handle NoBreakAfter in shortenIfNeeded
---
 src/Row.cpp | 3 ++-
 1 file changed, 2 insertions(+), 1 deletion(-)

diff --git a/src/Row.cpp b/src/Row.cpp
index 83c2329294..264b2b3482 100644
--- a/src/Row.cpp
+++ b/src/Row.cpp
@@ -734,7 +734,8 @@ Row::Elements Row::shortenIfNeeded(int const max_width, int 
const next_width)
                LATTEST(tail.empty());
        }
 
-       if (cit != beg && cit->row_flags & NoBreakBefore) {
+       if (cit != beg && (cit->row_flags & NoBreakBefore
+                          || (cit -1)->row_flags & NoBreakAfter)) {
                // It is not possible to separate this element from the
                // previous one. (e.g. VIRTUAL)
                --cit;
-- 
lyx-cvs mailing list
[email protected]
https://lists.lyx.org/mailman/listinfo/lyx-cvs

Reply via email to