mirror of https://github.com/aseprite/aseprite.git
Fix TextEdit selection bounds for multiple lines
If we select from the beginning of a line to the previous line the selection painting process was including the first character of the line where we started, but it shouldn't be included (as the cursor started in pos=0).
This commit is contained in:
parent
0faf9c0206
commit
fb4f4d9fa6
|
@ -860,7 +860,7 @@ gfx::Rect TextEdit::Line::getBounds(const int glyph) const
|
|||
gfx::Rect TextEdit::Line::getBounds(int startGlyph, int endGlyph) const
|
||||
{
|
||||
if (startGlyph == endGlyph)
|
||||
return getBounds(startGlyph);
|
||||
return {};
|
||||
|
||||
ASSERT(endGlyph > startGlyph);
|
||||
|
||||
|
|
Loading…
Reference in New Issue