1
0
Fork 0

Fix b7630b0: Incorrect padding for text purchase list.

Restore to original (and more normal) framerect padding.
pull/12160/head
Peter Nelson 2024-02-22 21:42:49 +00:00
parent 4c117dd2d8
commit 0634f092a7
No known key found for this signature in database
GPG Key ID: 8EF8F0A467DF75ED
1 changed files with 1 additions and 1 deletions

View File

@ -1821,7 +1821,7 @@ struct BuildVehicleWindow : Window {
int needed_height = this->details_height; int needed_height = this->details_height;
/* Draw details panels. */ /* Draw details panels. */
if (this->sel_engine != INVALID_ENGINE) { if (this->sel_engine != INVALID_ENGINE) {
const Rect r = this->GetWidget<NWidgetBase>(WID_BV_PANEL)->GetCurrentRect().Shrink(WidgetDimensions::scaled.frametext, WidgetDimensions::scaled.framerect); const Rect r = this->GetWidget<NWidgetBase>(WID_BV_PANEL)->GetCurrentRect().Shrink(WidgetDimensions::scaled.framerect);
int text_end = DrawVehiclePurchaseInfo(r.left, r.right, r.top, this->sel_engine, this->te); int text_end = DrawVehiclePurchaseInfo(r.left, r.right, r.top, this->sel_engine, this->te);
needed_height = std::max(needed_height, (text_end - r.top) / GetCharacterHeight(FS_NORMAL)); needed_height = std::max(needed_height, (text_end - r.top) / GetCharacterHeight(FS_NORMAL));
} }