: WorkArea(lyx_view)
{
cursor_ = new frontend::CursorWidget(this);
+ cursor_->hide();
setVerticalScrollBarPolicy(Qt::ScrollBarAlwaysOn);
setHorizontalScrollBarPolicy(Qt::ScrollBarAlwaysOff);
void GuiWorkArea::resizeEvent(QResizeEvent * ev)
{
+ cursor_->hide();
verticalScrollBar()->setPageStep(viewport()->height());
//paint_device_ = QPixmap(viewport()->width(), viewport()->height());
QAbstractScrollArea::resizeEvent(ev);
void GuiWorkArea::showCursor(int x, int y, int h, CursorShape shape)
{
- if (!qApp->focusWidget())
- return;
-
- cursor_->move(x, y);
+ cursor_->setGeometry(x, y, x + 2, y - h);
cursor_->shape_ = shape;
cursor_->on_ = true;
cursor_->show();
void GuiWorkArea::removeCursor()
{
+ if (!qApp->focusWidget())
+ return;
cursor_->hide();
}