mirror of
https://git.lyx.org/repos/lyx.git
synced 2024-11-22 18:08:10 +00:00
fix math-delim
git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@4006 a592a061-630c-0410-9148-cb99ea01b6c8
This commit is contained in:
parent
07ba220763
commit
2611cce4f1
@ -1,3 +1,8 @@
|
||||
2002-04-16 Jean-Marc Lasgouttes <lasgouttes@freesurf.fr>
|
||||
|
||||
* formulabase.C (localDispatch): handle arguments of
|
||||
LFUN_MATH_DELIM better.
|
||||
|
||||
2002-04-04 Angus Leeming <a.leeming@ic.ac.uk>
|
||||
|
||||
* formulabase.C: remove unused variables hack_x, hack_y, hack_button.
|
||||
|
@ -622,15 +622,14 @@ InsetFormulaBase::localDispatch(BufferView * bv, kb_action action,
|
||||
case LFUN_MATH_DELIM:
|
||||
{
|
||||
//lyxerr << "formulabase::LFUN_MATH_DELIM, arg: '" << arg << "'\n";
|
||||
string ls = "(";
|
||||
string rs = ")";
|
||||
istringstream is(arg.c_str());
|
||||
is >> ls >> rs;
|
||||
if (!is) {
|
||||
lyxerr << "can't parse delimiters from '" << arg << "'\n";
|
||||
lyxerr << "left: '" << ls << "' rs: '" << rs << "'\n";
|
||||
break;
|
||||
}
|
||||
string ls;
|
||||
string rs = split(arg, ls, ' ');
|
||||
// Reasonable default values
|
||||
if (ls.empty())
|
||||
ls = '(';
|
||||
if (rs.empty())
|
||||
rs = ')';
|
||||
|
||||
bv->lockedInsetStoreUndo(Undo::EDIT);
|
||||
mathcursor->handleDelim(ls, rs);
|
||||
updateLocal(bv, true);
|
||||
|
Loading…
Reference in New Issue
Block a user