]> git.lyx.org Git - features.git/commitdiff
Partial fox for bug #6622: Display \utilde and \undertilde on screen correctly.
authorGeorg Baum <Georg.Baum@post.rwth-aachen.de>
Mon, 9 May 2011 19:21:46 +0000 (19:21 +0000)
committerGeorg Baum <Georg.Baum@post.rwth-aachen.de>
Mon, 9 May 2011 19:21:46 +0000 (19:21 +0000)
git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/branches/BRANCH_2_0_X@38675 a592a061-630c-0410-9148-cb99ea01b6c8

12 files changed:
development/scons/scons_manifest.py
lib/Makefile.am
lib/chkconfig.ltx
lib/doc/LaTeXConfig.lyx
lib/images/math/undertilde.png [new file with mode: 0644]
lib/images/math/utilde.png [new file with mode: 0644]
lib/symbols
lib/ui/stdtoolbars.inc
src/LaTeXFeatures.cpp
src/mathed/InsetMathDecoration.cpp
src/mathed/MathSupport.cpp
status.20x

index 4bf7c9acfe5216b9f8c455a1442081edeba13223..75d781019bb04471d512448bb6f61878ba3960a4 100644 (file)
@@ -2074,6 +2074,7 @@ lib_images_math_files = Split('''
     underrightarrow.png
     underscore.png
     underset.png
+    undertilde.png
     uparrow.png
     uparrow2.png
     updownarrow.png
@@ -2085,6 +2086,7 @@ lib_images_math_files = Split('''
     upsilon2.png
     upuparrows.png
     urcorner.png
+    utilde.png
     varepsilon.png
     varkappa.png
     varnothing.png
index 2c7aab0d711666a323375ab76b0f7b308d58e0bc..7c9894907602cf89962feeb2290cd09b2bb61d77 100644 (file)
@@ -936,6 +936,7 @@ dist_imagesmath_DATA = \
        images/math/underrightarrow.png \
        images/math/underscore.png \
        images/math/underset.png \
+       images/math/undertilde.png \
        images/math/uparrow.png \
        images/math/uparrow2.png \
        images/math/updownarrow.png \
@@ -947,6 +948,7 @@ dist_imagesmath_DATA = \
        images/math/upsilon2.png \
        images/math/upuparrows.png \
        images/math/urcorner.png \
+       images/math/utilde.png \
        images/math/varepsilon.png \
        images/math/varkappa.png \
        images/math/varnothing.png \
index 95ea1fe2b1423ba9f0b59225d7d4e8315ef04ae8..7f5fcef3942141b61464550a86978d8133caba62 100644 (file)
 \TestPackage{subscript}
 \TestPackage[turkmen.ldf]{turkmen}
 \TestPackage{ulem}
+\TestPackage{undertilde}
 \TestPackage{units}
 \TestPackage{url}
 \TestPackage{varioref}
index 3b5059a3e08abc0ee236bec7198bab61e6e00682..c6947ca8b60341a7ddcc49f94d5b33c8dffaad00 100644 (file)
@@ -5591,6 +5591,41 @@ ulem
  to PDF.
 \end_layout
 
+\begin_layout Subsection
+undertilde
+\end_layout
+
+\begin_layout Description
+Found: 
+\begin_inset Info
+type  "package"
+arg   "undertilde"
+\end_inset
+
+
+\end_layout
+
+\begin_layout Description
+CTAN: 
+\family typewriter
+macros/latex/contrib/undertilde/
+\end_layout
+
+\begin_layout Description
+Notes: The package 
+\family sans
+undertilde
+\family default
+ provides the
+\family sans
+\backslash
+utilde
+\family default
+ command.
+ It is needed by LyX to underline symbols with a tilde in formulas.
+\end_layout
+
 \begin_layout Subsection
 units
 \end_layout
diff --git a/lib/images/math/undertilde.png b/lib/images/math/undertilde.png
new file mode 100644 (file)
index 0000000..9854880
Binary files /dev/null and b/lib/images/math/undertilde.png differ
diff --git a/lib/images/math/utilde.png b/lib/images/math/utilde.png
new file mode 100644 (file)
index 0000000..9854880
Binary files /dev/null and b/lib/images/math/utilde.png differ
index 1dcf0a419195928a5368727608b23503349fadbd..89373cefd4a3a4ef9c2d1b19b4f9d82f3045460f 100644 (file)
@@ -26,6 +26,14 @@ underleftarrow      decoration none       amsmath
 underleftrightarrow decoration none       amsmath
 underline           decoration none
 underrightarrow     decoration none       amsmath
+#Do not load automatically, it redefines some other symbols, and we don't
+#have a possibility to turn automatic loading off like for ams
+#undertilde          decoration none       accents
+undertilde          decoration none
+#Do not load automatically, since it might conflict with user macros and we
+#don't have a possibility to turn automatic loading off like for ams
+#utilde              decoration none       undertilde
+utilde              decoration none
 vec                 decoration none
 widehat             decoration none
 widetilde           decoration none
index 30bc22c16d0c6ea7dc44827a59b3b8fd8740ea69..3db71ce031d6c3b8c36fb0f99c8000cc608e2e45 100644 (file)
@@ -398,6 +398,8 @@ ToolbarSet
                Item "check" "math-insert \check"
                Item "widehat" "math-insert \widehat"
                Item "widetilde" "math-insert \widetilde"
+# enable this once the undertilde package is loaded automatically
+#              Item "utilde" "math-insert \utilde"
                Item "vec" "math-insert \vec"
                Item "acute" "math-insert \acute"
                Item "ddot" "math-insert \ddot"
index 61bd0a7a03da8ae4b5e004bb1049b65065e32a63..2cfc1ce6e2275940c4cb69f7f97f0eb3b11634f9 100644 (file)
@@ -614,7 +614,8 @@ char const * simplefeatures[] = {
        "amscd",
        "slashed",
        "multirow",
-       "tfrupee"
+       "tfrupee",
+       "undertilde",
 };
 
 int const nb_simplefeatures = sizeof(simplefeatures) / sizeof(char const *);
index 37fae799112bffe82725038f3537b89e85dd4c60..b5c235f8e7dfb08e70156e76d4ebdc7333b1dc1f 100644 (file)
@@ -47,7 +47,7 @@ Inset * InsetMathDecoration::clone() const
 
 bool InsetMathDecoration::upper() const
 {
-       return key_->name.substr(0, 5) != "under";
+       return key_->name.substr(0, 5) != "under" && key_->name != "utilde";
 }
 
 
@@ -93,7 +93,9 @@ bool InsetMathDecoration::wide() const
                        key_->name == "widetilde" ||
                        key_->name == "underleftarrow" ||
                        key_->name == "underrightarrow" ||
-                       key_->name == "underleftrightarrow";
+                       key_->name == "underleftrightarrow" ||
+                       key_->name == "undertilde" ||
+                       key_->name == "utilde";
 }
 
 
@@ -204,6 +206,8 @@ namespace {
                // this is the macron, again, but it works
                t["underline"] = Attributes(false, "&macr;");
                t["underrightarrow"] = Attributes(false, "&xrarr;");
+               t["undertilde"] = Attributes(false, "&Tilde;");
+               t["utilde"] = Attributes(false, "&Tilde;");
                t["vec"] = Attributes(true, "&rarr;");
                t["widehat"] = Attributes(true, "&Hat;");
                t["widetilde"] = Attributes(true, "&Tilde;");
index 16cfc46b8cafba18930423d778ca8a3b6b79ed47..1d7358abb086563096c30d33bf61e942a1898cae 100644 (file)
@@ -287,6 +287,8 @@ named_deco_struct deco_table[] = {
        {"underleftarrow",      arrow,    1 },
        {"underrightarrow",     arrow,    3 },
        {"underleftrightarrow", udarrow,  1 },
+       {"undertilde",          tilde,    0 },
+       {"utilde",              tilde,    0 },
 
        // Delimiters
        {"(",              parenth,    0 },
index bc0f624c2976a7cb18e82e654433fe491b8e0020..8d782d150a3b751c7c27fe98688cd64c46917ab5 100644 (file)
@@ -76,6 +76,8 @@ What's new
 - Show the correct label after adding a line to an AMS Multline formula (bug
   #7511).
 
+- Display \utilde and \undertilde in formulas correctly (part of bug #6622).
+
 
 * DOCUMENTATION AND LOCALIZATION