]> git.lyx.org Git - features.git/commitdiff
Mark inverted branch insets
authorYuriy Skalko <yuriy.skalko@gmail.com>
Thu, 21 Oct 2021 09:56:05 +0000 (12:56 +0300)
committerYuriy Skalko <yuriy.skalko@gmail.com>
Tue, 26 Oct 2021 21:56:06 +0000 (00:56 +0300)
lib/doc/UserGuide.lyx
src/insets/InsetBranch.cpp

index b3e93e8f62a81f5ba6d8f2c14f81fa104c89c433..123c09a52e3e0c876d5e1c852517cbda40418e79 100644 (file)
@@ -35523,8 +35523,18 @@ There are also inverted branch insets, whose content is output just in case
 \emph on
 not
 \emph default
- activated.
- This make it easy to add alternative text for different versions of a document.
+ activated
+\change_inserted 244031559 1635284375
+ (they are marked with ~ before the name)
+\change_unchanged
+.
+\change_deleted 244031559 1635284383
+This
+\change_inserted 244031559 1635284385
+Such insets
+\change_unchanged
+ make it easy to add alternative text for different versions of a document.
  To control whether a particular inset is inverted, right-click on the inset
  button and choose 
 \family sans
index 95f7ba9e9a61bb48217929daa3a1023b33d5fc5d..66cc6ef5529d232f16e08aed22bc9a0abad5f5d9 100644 (file)
@@ -112,8 +112,10 @@ docstring const InsetBranch::buttonLabel(BufferView const &) const
        if (inchild && master_selected != child_selected)
                symb += (child_selected ? tick : cross);
 
+    docstring inv_symb = from_ascii(params_.inverted ? "~" : "");
+
        if (decoration() == InsetDecoration::MINIMALISTIC)
-               return symb + params_.branch;
+               return symb + inv_symb + params_.branch;
 
        docstring s;
        if (inmaster && inchild)
@@ -124,7 +126,7 @@ docstring const InsetBranch::buttonLabel(BufferView const &) const
                s = _("Branch (master): ");
        else // !inmaster && !inchild
                s = _("Branch (undefined): ");
-       s += params_.branch;
+       s += inv_symb + params_.branch;
 
        return symb + s;
 }