Skip to content

Commit

Permalink
fix: too much latency when drawing on 4k screens
Browse files Browse the repository at this point in the history
The entire area is refreshed when drawing

Log: The delay is too high when drawing on a 4k screen
Bug: https://pms.uniontech.com/bug-view-262599.html
  • Loading branch information
wyu71 authored and starhcq committed Jul 2, 2024
1 parent 4d9a32e commit 53d5718
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion src/drawshape/drawTools/cpentool.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -483,7 +483,7 @@ void CPenTool::paintPictureToView(const QPicture &picture, PageView *view)

painter.drawPicture(QPoint(0, 0), picture);

view->viewport()->update();
view->viewport()->update(trans.mapRect(picture.boundingRect()));
}

bool CPenTool::eventFilter(QObject *o, QEvent *e)
Expand Down

0 comments on commit 53d5718

Please sign in to comment.