- fix: the size of horizontal caret is wrong

This commit is contained in:
Roy Qu 2022-09-07 15:08:31 +08:00
parent 6d40857fb9
commit 8474ae6b8f
2 changed files with 2 additions and 1 deletions

View File

@ -5,6 +5,7 @@ Red Panda C++ Version 1.3
- change: reduce time intervals for selection by mouse
- enhancement: change orders of the problems in the problem set panel by drag&drop
- enhancement: change orders of the problem cases in the problem panel by drag&drop
- fix: the size of horizontal caret is wrong
Red Panda C++ Version 1.2

View File

@ -3971,7 +3971,7 @@ void SynEdit::paintCaret(QPainter &painter, const QRect rcClip)
QRect caretRC;
int size = std::max(1,mTextHeight/15);
caretRC.setLeft(rcClip.left());
caretRC.setTop(rcClip.bottom()-1+size);
caretRC.setTop(rcClip.bottom()-1-size);
caretRC.setBottom(rcClip.bottom()-1);
caretRC.setRight(rcClip.right());
painter.fillRect(caretRC,caretColor);