From 6a4c3457cf2edbc9f99d2839632a789cc450cffc Mon Sep 17 00:00:00 2001 From: Augustin Cavalier Date: Wed, 19 Oct 2022 14:23:32 -0400 Subject: [PATCH] HaikuDepot: Adjust some hard-coded font sizes. --- src/apps/haikudepot/ui/PackageListView.cpp | 4 ++-- src/apps/haikudepot/ui/UserUsageConditionsWindow.cpp | 2 +- 2 files changed, 3 insertions(+), 3 deletions(-) diff --git a/src/apps/haikudepot/ui/PackageListView.cpp b/src/apps/haikudepot/ui/PackageListView.cpp index 86e5da124a..709e2f38e2 100644 --- a/src/apps/haikudepot/ui/PackageListView.cpp +++ b/src/apps/haikudepot/ui/PackageListView.cpp @@ -741,7 +741,7 @@ public: fItemCount(0) { BFont font(be_plain_font); - font.SetSize(9.0f); + font.SetSize(font.Size() * 0.75f); SetFont(&font); SetViewUIColor(B_PANEL_BACKGROUND_COLOR); @@ -751,7 +751,7 @@ public: // constantly calculating the size is expensive so here a sensible // upper limit on the number of packages is arbitrarily chosen. fMinSize = BSize(StringWidth(_DeriveLabel(999999)) + 10, - B_H_SCROLL_BAR_HEIGHT); + be_control_look->GetScrollBarWidth()); } virtual BSize MinSize() diff --git a/src/apps/haikudepot/ui/UserUsageConditionsWindow.cpp b/src/apps/haikudepot/ui/UserUsageConditionsWindow.cpp index 60dcbc9b43..fd213e804e 100644 --- a/src/apps/haikudepot/ui/UserUsageConditionsWindow.cpp +++ b/src/apps/haikudepot/ui/UserUsageConditionsWindow.cpp @@ -168,7 +168,7 @@ UserUsageConditionsWindow::_InitUiControls() BSize(B_SIZE_UNLIMITED, B_SIZE_UNSET)); BFont versionFont(be_plain_font); - versionFont.SetSize(9.0); + versionFont.SetSize(versionFont.Size() * 0.75f); fVersionStringView = new BStringView("version string view", PLACEHOLDER_TEXT);