]> git.lyx.org Git - features.git/commit
Fix lyx2lyx math package defaults (bug #9069)
authorGeorg Baum <baum@lyx.org>
Sun, 27 Apr 2014 16:09:29 +0000 (18:09 +0200)
committerGeorg Baum <baum@lyx.org>
Sun, 27 Apr 2014 16:09:29 +0000 (18:09 +0200)
commitb73a59932ea32977797c558661a10fe722727dc6
tree1e102351efafb2c1b49258d725b7ae6eaac6e957
parentd47a556b46c2dde1a245e9ffa4918111e63fa70e
Fix lyx2lyx math package defaults (bug #9069)

lyx2lyx sets all new math packages to off when converting from old formats.
This is correct if any command which would cause an automatic package loading
exists in the document. However, it is wrong if no command exists: This leads
to problems if later a command is added (bug #9069), which is especially
annoying for templates.
The fix consists of two parts:
1) convert_use_package() considers now the used commands like
   revert_use_package(), and uses them to decide whether to set the package to
   auto or off.
2) convert_undertilde() and revert_undertilde() use a slightly adjusted copy of
   convert_use_package() and revert_use_package(), so that the bug is also
   fixed for undertilde. We cannot use the latter functions directly, because
   of "\usepackage undertilde" vs. "\use_undertilde".
lib/lyx2lyx/lyx_2_1.py
status.21x