commit b02d9f107552c2cc42d8ff253783911e2bc6078e
Author: Jean-Marc Lasgouttes <lasgout...@lyx.org>
Date:   Mon Oct 22 15:29:08 2018 +0200

    Amend 4ecbff00: it is too early for skipping the updateMacros call
    
    (cherry picked from commit 9e7832915f9763510e5820167930a38e16a8321f)
---
 src/BufferView.cpp |    8 ++++++++
 1 files changed, 8 insertions(+), 0 deletions(-)

diff --git a/src/BufferView.cpp b/src/BufferView.cpp
index d2f324d..173c7b0 100644
--- a/src/BufferView.cpp
+++ b/src/BufferView.cpp
@@ -476,6 +476,14 @@ void BufferView::processUpdateFlags(Update::flags flags)
        if (flags == Update::None)
                return;
 
+       /* FIXME We would like to avoid doing this here, since it is very
+        * expensive and is called in updateBuffer already. However, even
+        * inserting a plain character can invalidate the overly fragile
+        * tables of child documents built by updateMacros. Some work is
+        * needed to avoid doing that when not necessary.
+        */
+       buffer_.updateMacros();
+
        // SinglePar is ignored for now (this should probably change). We
        // set it ourselves below, at the price of always rebreaking the
        // paragraph at cursor. This can be expensive for large tables.

Reply via email to