mirror of
https://git.lyx.org/repos/lyx.git
synced 2024-11-22 01:59:02 +00:00
Regenerate a preview only when leaving a math inset with depth 1.
git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@4763 a592a061-630c-0410-9148-cb99ea01b6c8
This commit is contained in:
parent
c4c506908d
commit
00c0baf022
@ -3,6 +3,9 @@
|
|||||||
* formula.C (descent): add an arbitrary 12 pixels to the descent when
|
* formula.C (descent): add an arbitrary 12 pixels to the descent when
|
||||||
previewing a display mode equation, analogous to André's code elsewhere.
|
previewing a display mode equation, analogous to André's code elsewhere.
|
||||||
|
|
||||||
|
* math_nestinset.C (notifyCursorLeaves): generate the preview only
|
||||||
|
when leaving an inset with depth() == 1.
|
||||||
|
|
||||||
2002-07-22 Jean-Marc Lasgouttes <lasgouttes@freesurf.fr>
|
2002-07-22 Jean-Marc Lasgouttes <lasgouttes@freesurf.fr>
|
||||||
|
|
||||||
* math_support.C (mathed_draw_deco): fix rounding bug for rotated
|
* math_support.C (mathed_draw_deco): fix rounding bug for rotated
|
||||||
|
@ -277,12 +277,16 @@ MathArray MathNestInset::glue() const
|
|||||||
|
|
||||||
void MathNestInset::notifyCursorLeaves()
|
void MathNestInset::notifyCursorLeaves()
|
||||||
{
|
{
|
||||||
//lyxerr << "leaving " << *this << "\n";
|
// Generate a preview only if previews are active and we are leaving
|
||||||
if (!mathcursor || !grfx::Previews::activated())
|
// the InsetFormula itself
|
||||||
|
if (!grfx::Previews::activated() ||
|
||||||
|
!mathcursor || mathcursor->depth() != 1)
|
||||||
return;
|
return;
|
||||||
|
|
||||||
InsetFormulaBase * inset = mathcursor->formula();
|
InsetFormulaBase * inset = mathcursor->formula();
|
||||||
BufferView * bufferview = inset->view();
|
BufferView * bufferview = inset->view();
|
||||||
|
|
||||||
|
// Paranoia check
|
||||||
if (!bufferview || !bufferview->buffer())
|
if (!bufferview || !bufferview->buffer())
|
||||||
return;
|
return;
|
||||||
|
|
||||||
|
Loading…
Reference in New Issue
Block a user