]> git.lyx.org Git - features.git/commit
Replacement for commits bc47054b and ad0d0f6d
authorEnrico Forestieri <forenr@lyx.org>
Sun, 14 Jun 2015 16:10:29 +0000 (18:10 +0200)
committerEnrico Forestieri <forenr@lyx.org>
Sun, 14 Jun 2015 16:10:29 +0000 (18:10 +0200)
commit11c2b7792caf22219b346f8bb69a01f6abbf362d
treeb6fe07d2e6c5af8efa2f87b1c96d770b38fe3452
parentbdec44d614e9a1bcc7e829653e2df7b27a8311cc
Replacement for commits bc47054b and ad0d0f6d

The strategy adopted in bc47054b had some drawbacks related to the way
instant preview snippets are generated. See the subthread starting at
http://www.mail-archive.com/lyx-devel@lists.lyx.org/msg187916.html
for details.

The strategy adopted in this commit is that of adding macro definitions
only for the macros actually used in a preview snippet, independently
of whether some macro was already used in a previous snippet. In this way
the snippets don't need to be changed according to whether they are
compiled as a whole or separately from each other. This fact was causing
the regeneration of a preview snippet whenever the cursor entered the
corresponding inset, even if the generated image would have not changed.
The problem of defining or redefining a macro is taken care by the
python scripts.
lib/scripts/lyxpreview2bitmap.py
src/insets/InsetPreview.cpp
src/mathed/InsetMath.h
src/mathed/InsetMathFrac.h
src/mathed/InsetMathHull.cpp
src/mathed/InsetMathHull.h