int selectionWidth = font.getWidth(selectionString);
Vector2i selectionTopLeft = new Vector2i(offsetX, (lineOffset) * font.getLineHeight());
Rect2i region = Rect2i.createFromMinAndSize(selectionTopLeft.x, selectionTopLeft.y, selectionWidth, font.getLineHeight());
canvas.drawTexture(cursorTexture, region, textColor);
canvas.drawTextRaw(FontColor.stripColor(selectionString), font, textColor.inverse(), region);
}
currentChar += innerLine.length();
lineOffset++;
}
currentChar++;