Commit 3b917fde authored by mae's avatar mae

mac fix for parenthesis matching

parent d213532a
......@@ -2135,7 +2135,7 @@ void BaseTextEditor::paintEvent(QPaintEvent *e)
}
}
if (d->m_animator) {
if (d->m_animator && d->m_animator->isRunning()) {
QTextCursor cursor = textCursor();
cursor.setPosition(d->m_animator->position());
d->m_animator->draw(&painter, cursorRect(cursor).topLeft());
......@@ -3420,6 +3420,11 @@ void BaseTextEditorAnimator::draw(QPainter *p, const QPointF &pos)
p->drawText(r, m_text);
}
bool BaseTextEditorAnimator::isRunning() const
{
return m_timeline->state() == QTimeLine::Running;
}
QRectF BaseTextEditorAnimator::rect() const
{
QFont f = m_font;
......
......@@ -239,6 +239,8 @@ public:
void finish();
bool isRunning() const;
signals:
void updateRequest(int position, QRectF rect);
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment