diff options
author | Johannes Schickel | 2013-11-23 23:50:21 +0100 |
---|---|---|
committer | Johannes Schickel | 2013-11-24 00:15:48 +0100 |
commit | aaad08c9fe25f00813ddd19458a9c98d06e723cf (patch) | |
tree | 30c7219507f4453bebde22b28a03ee05b4faf6eb | |
parent | e036aa76da22bbc9cc48d012469d2bad46018ff8 (diff) | |
download | scummvm-rg350-aaad08c9fe25f00813ddd19458a9c98d06e723cf.tar.gz scummvm-rg350-aaad08c9fe25f00813ddd19458a9c98d06e723cf.tar.bz2 scummvm-rg350-aaad08c9fe25f00813ddd19458a9c98d06e723cf.zip |
GUI: Fix character redrawing behind caret in EditTextWidgets.
This fixes an ugly y position change when the caret is moved to a character in
an edit text widget.
-rw-r--r-- | gui/widgets/editable.cpp | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/gui/widgets/editable.cpp b/gui/widgets/editable.cpp index 667850d6cc..c3354e53ea 100644 --- a/gui/widgets/editable.cpp +++ b/gui/widgets/editable.cpp @@ -277,7 +277,7 @@ void EditableWidget::drawCaret(bool erase) { int chrWidth = g_gui.getCharWidth(_editString[_caretPos], _font); const uint last = (_caretPos > 0) ? _editString[_caretPos - 1] : 0; x += g_gui.getKerningOffset(last, _editString[_caretPos], _font); - g_gui.theme()->drawText(Common::Rect(x, y, x + chrWidth, y + editRect.height() - 2), chr, _state, Graphics::kTextAlignLeft, _inversion, 0, false, _font, ThemeEngine::kFontColorNormal, true, _textDrawableArea); + g_gui.theme()->drawText(Common::Rect(x, y, x + chrWidth, y + editRect.height()), chr, _state, Graphics::kTextAlignLeft, _inversion, 0, false, _font, ThemeEngine::kFontColorNormal, true, _textDrawableArea); } } |