commit 9ee952ce14c85a63860361a199949de26756e708
Author: Jean-Marc Lasgouttes <[email protected]>
Date:   Thu Jun 9 21:29:21 2022 +0200

    Allow to break rows before and after label and index insets
    
    Since they are elements that do not appear in output, there is no
    reason to make breaking around them difficult.
---
 src/insets/InsetIndex.h |    2 ++
 src/insets/InsetLabel.h |    2 ++
 2 files changed, 4 insertions(+), 0 deletions(-)

diff --git a/src/insets/InsetIndex.h b/src/insets/InsetIndex.h
index b064cc7..dacc477 100644
--- a/src/insets/InsetIndex.h
+++ b/src/insets/InsetIndex.h
@@ -43,6 +43,8 @@ public:
        static std::string params2string(InsetIndexParams const &);
        ///
        static void string2params(std::string const &, InsetIndexParams &);
+       ///
+       int rowFlags() const override { return CanBreakBefore | CanBreakAfter; }
 private:
        ///
        bool hasSettings() const override;
diff --git a/src/insets/InsetLabel.h b/src/insets/InsetLabel.h
index 54bfa07..dba25f0 100644
--- a/src/insets/InsetLabel.h
+++ b/src/insets/InsetLabel.h
@@ -29,6 +29,8 @@ public:
        docstring const & counterValue() const { return counter_value_; }
        ///
        docstring const & prettyCounter() const { return pretty_counter_; }
+       ///
+       int rowFlags() const override { return CanBreakBefore | CanBreakAfter; }
        /// Updates only the label string, doesn't handle undo nor references.
        void updateLabel(docstring const & new_label, bool const active = true);
        /// Updates the label and the references to it.
-- 
lyx-cvs mailing list
[email protected]
http://lists.lyx.org/mailman/listinfo/lyx-cvs

Reply via email to