mirror of
https://github.com/aseprite/aseprite.git
synced 2025-03-29 19:20:09 +00:00
Fix Theme::drawTextBox() to calculate the correct textbox size
If we are only calculating the textbox size (Graphics* g=nullptr) we don't need to use the View scroll information anyway.
This commit is contained in:
parent
161264a78d
commit
9dbbcbd7ef
@ -747,7 +747,7 @@ void Theme::drawSlices(Graphics* g, os::Surface* sheet,
|
||||
void Theme::drawTextBox(Graphics* g, Widget* widget,
|
||||
int* w, int* h, gfx::Color bg, gfx::Color fg)
|
||||
{
|
||||
View* view = View::getView(widget);
|
||||
View* view = (g ? View::getView(widget): nullptr);
|
||||
char* text = const_cast<char*>(widget->text().c_str());
|
||||
char* beg, *end;
|
||||
int x1, y1;
|
||||
|
Loading…
x
Reference in New Issue
Block a user