diff options
Diffstat (limited to 'engines/glk/window_text_grid.cpp')
-rw-r--r-- | engines/glk/window_text_grid.cpp | 7 |
1 files changed, 7 insertions, 0 deletions
diff --git a/engines/glk/window_text_grid.cpp b/engines/glk/window_text_grid.cpp index be097251fc..e0459e0b2e 100644 --- a/engines/glk/window_text_grid.cpp +++ b/engines/glk/window_text_grid.cpp @@ -624,6 +624,13 @@ void TextGridWindow::redraw() { w += _bbox.right - (x + w); screen.fillRect(Rect::fromXYWH(x, y, w, _font._leading), bgcolor); + // Draw the caret if necessary + if (_windows->getFocusWindow() == this && i == _curY && + (_lineRequest || _lineRequestUni || _charRequest || _charRequestUni)) { + _font.drawCaret(Point((x0 + _curX * _font._cellW) * GLI_SUBPIX, y + _font._baseLine)); + } + + // Write out the text for (k = a, o = x; k < b; k++, o += _font._cellW) { screen.drawStringUni(Point(o * GLI_SUBPIX, y + _font._baseLine), font, fgcolor, Common::U32String(&ln->_chars[k], 1)); |