return;
}
mathcursor->getPos(x, y);
+ x = mathcursor->targetX();
x -= xo_;
y -= yo_;
//lyxerr << "getCursorPos: " << x << " " << y << "\n";
return;
fitInsetCursor(bv);
int x, y, asc, des;
- getCursorPos(bv, x, y);
+ mathcursor->getPos(x, y);
math_font_max_dim(font_, asc, des);
- bv->showLockedInsetCursor(x + xo_, y, asc, des);
+ bv->showLockedInsetCursor(x, y - yo_, asc, des);
setCursorVisible(true);
//lyxerr << "showInsetCursor: " << x << " " << y << "\n";
}
return lfunMouseMotion(cmd);
case LFUN_MOUSE_RELEASE:
return lfunMouseRelease(cmd);
+ case LFUN_MOUSE_DOUBLE:
+ //lyxerr << "Mouse double\n";
+ return localDispatch(FuncRequest(LFUN_WORDSEL));
default:
break;
}
case LFUN_MATH_EXTERN:
case LFUN_TABULAR_FEATURE:
case LFUN_PASTESELECTION:
+ case LFUN_MATH_LIMITS:
bv->lockedInsetStoreUndo(Undo::EDIT);
mathcursor->dispatch(cmd);
updateLocal(bv, true);
break;
- case LFUN_WORDRIGHTSEL:
case LFUN_RIGHTSEL:
sel = true; // fall through...
case LFUN_RIGHT:
//bv->owner()->message(mathcursor->info());
break;
- case LFUN_WORDLEFTSEL:
case LFUN_LEFTSEL:
sel = true; // fall through
case LFUN_LEFT:
updateLocal(bv, false);
break;
+ case LFUN_WORDSEL:
+ mathcursor->home(false);
+ mathcursor->end(true);
+ updateLocal(bv, false);
+ break;
+
case LFUN_HOMESEL:
+ case LFUN_WORDLEFTSEL:
sel = true; // fall through
case LFUN_HOME:
+ case LFUN_WORDLEFT:
result = mathcursor->home(sel) ? DISPATCHED : FINISHED;
updateLocal(bv, false);
break;
case LFUN_ENDSEL:
+ case LFUN_WORDRIGHTSEL:
sel = true; // fall through
case LFUN_END:
+ case LFUN_WORDRIGHT:
result = mathcursor->end(sel) ? DISPATCHED : FINISHED_RIGHT;
updateLocal(bv, false);
break;
case LFUN_PRIORSEL:
case LFUN_PRIOR:
+ case LFUN_BEGINNINGBUFSEL:
+ case LFUN_BEGINNINGBUF:
result = FINISHED_UP;
updateLocal(bv, false);
break;
case LFUN_NEXTSEL:
case LFUN_NEXT:
+ case LFUN_ENDBUFSEL:
+ case LFUN_ENDBUF:
result = FINISHED_DOWN;
updateLocal(bv, false);
break;
case LFUN_FRAK: handleFont(bv, cmd.argument, "mathfrak"); break;
case LFUN_ITAL: handleFont(bv, cmd.argument, "mathit"); break;
case LFUN_NOUN: handleFont(bv, cmd.argument, "mathbb"); break;
- case LFUN_DEFAULT: handleFont(bv, cmd.argument, "textnormal"); break;
case LFUN_FREE: handleFont(bv, cmd.argument, "textrm"); break;
+ case LFUN_DEFAULT: handleFont(bv, cmd.argument, "textnormal"); break;
case LFUN_GREEK:
handleFont(bv, cmd.argument, "lyxgreek1");
//bv->owner()->message(_("math text mode toggled"));
break;
- case LFUN_MATH_LIMITS:
- bv->lockedInsetStoreUndo(Undo::EDIT);
- if (mathcursor->toggleLimits())
- updateLocal(bv, true);
- break;
-
case LFUN_MATH_SIZE:
#if 0
if (!arg.empty()) {