@@ -550,7 +550,6 @@ void FullscreenUI::DrawIndicators(NotificationLayout& layout)
550550{
551551 static constexpr float INDICATOR_WIDTH_COEFF = 0 .3f ;
552552
553- static constexpr const float & font_size = UIStyle.MediumFontSize ;
554553 static constexpr const float & font_weight = UIStyle.BoldFontWeight ;
555554
556555 static constexpr float bg_opacity = 0 .8f ;
@@ -560,6 +559,7 @@ void FullscreenUI::DrawIndicators(NotificationLayout& layout)
560559 const float padding = ImCeil (10 .0f * scale);
561560 const float rounding = ImCeil (10 .0f * scale);
562561 const float image_size = ImCeil (50 .0f * scale);
562+ const float font_size = ImCeil (LAYOUT_MEDIUM_FONT_SIZE * scale);
563563 const ImGuiIO& io = ImGui::GetIO ();
564564 ImDrawList* dl = ImGui::GetBackgroundDrawList ();
565565
@@ -662,7 +662,7 @@ void FullscreenUI::DrawIndicators(NotificationLayout& layout)
662662 const ImVec4 right_background_color = DarkerColor (UIStyle.ToastBackgroundColor , 0 .8f );
663663 TinyString tstr;
664664
665- const auto measure_tracker = [&tstr](const Achievements::LeaderboardTrackerIndicator& indicator) {
665+ const auto measure_tracker = [&font_size, & tstr](const Achievements::LeaderboardTrackerIndicator& indicator) {
666666 tstr.assign (ICON_FA_STOPWATCH " " );
667667 for (u32 i = 0 ; i < indicator.text .length (); i++)
668668 {
@@ -676,9 +676,9 @@ void FullscreenUI::DrawIndicators(NotificationLayout& layout)
676676 return UIStyle.Font ->CalcTextSizeA (font_size, font_weight, FLT_MAX, 0 .0f , IMSTR_START_END (tstr));
677677 };
678678
679- const auto draw_tracker = [&padding, &rounding, &dl , &left_background_color , &right_background_color , &tstr ,
680- &measure_tracker](Achievements::LeaderboardTrackerIndicator& indicator,
681- const ImVec2& pos, float opacity) {
679+ const auto draw_tracker = [&padding, &rounding, &font_size , &dl , &left_background_color , &right_background_color ,
680+ &tstr, & measure_tracker](Achievements::LeaderboardTrackerIndicator& indicator,
681+ const ImVec2& pos, float opacity) {
682682 const ImVec2 size = measure_tracker (indicator);
683683 const float box_width = size.x + padding * 2 .0f ;
684684 const float box_height = size.y + padding * 2 .0f ;
0 commit comments