mirror of
https://git.lyx.org/repos/lyx.git
synced 2024-12-22 13:18:28 +00:00
Improve math-mode lfun for switching to text
math-mode inserts \text instead of \mbox when already in math mode, since this supports accented characters.
This commit is contained in:
parent
fde3963d99
commit
27f067dd9d
@ -65,11 +65,6 @@ The current macro system is clever, but could be neater. One improvement
|
|||||||
I'd like is to let LyX know about TeX's scoping rules...
|
I'd like is to let LyX know about TeX's scoping rules...
|
||||||
|
|
||||||
|
|
||||||
Yves Bastide:
|
|
||||||
|
|
||||||
- use AMS's \text instead of \mbox. It supports accented characters,
|
|
||||||
among others... (selected via validate()?)
|
|
||||||
|
|
||||||
|
|
||||||
Angus:
|
Angus:
|
||||||
|
|
||||||
|
@ -1010,7 +1010,7 @@ void InsetMathNest::doDispatch(Cursor & cur, FuncRequest & cmd)
|
|||||||
if (currentMode() <= Inset::TEXT_MODE)
|
if (currentMode() <= Inset::TEXT_MODE)
|
||||||
cur.plainInsert(MathAtom(new InsetMathEnsureMath(buffer_)));
|
cur.plainInsert(MathAtom(new InsetMathEnsureMath(buffer_)));
|
||||||
else
|
else
|
||||||
cur.plainInsert(MathAtom(new InsetMathBox(buffer_, from_ascii("mbox"))));
|
cur.plainInsert(createInsetMath("text", buffer_));
|
||||||
cur.posBackward();
|
cur.posBackward();
|
||||||
cur.pushBackward(*cur.nextInset());
|
cur.pushBackward(*cur.nextInset());
|
||||||
cur.niceInsert(save_selection);
|
cur.niceInsert(save_selection);
|
||||||
|
Loading…
Reference in New Issue
Block a user