From 4bb31d492a2650c4348142a2a7819e1c11d79af6 Mon Sep 17 00:00:00 2001 From: gdlbo <41114720+gdlbo@users.noreply.github.com> Date: Sun, 24 Jul 2022 20:11:11 +0300 Subject: [PATCH] bold text labels --- .../lite/ui/bottomnavigation/BottomNavigationItemView.java | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/app/src/main/java/com/vtosters/lite/ui/bottomnavigation/BottomNavigationItemView.java b/app/src/main/java/com/vtosters/lite/ui/bottomnavigation/BottomNavigationItemView.java index 613bb7505..e5227b6d9 100644 --- a/app/src/main/java/com/vtosters/lite/ui/bottomnavigation/BottomNavigationItemView.java +++ b/app/src/main/java/com/vtosters/lite/ui/bottomnavigation/BottomNavigationItemView.java @@ -7,6 +7,7 @@ import android.content.Context; import android.content.res.ColorStateList; import android.graphics.Color; import android.graphics.PorterDuff; +import android.graphics.Typeface; import android.graphics.drawable.Drawable; import android.text.TextUtils; import android.util.AttributeSet; @@ -222,6 +223,9 @@ public class BottomNavigationItemView extends FrameLayout implements MenuView.It // ViewCompat.setScaleY(mLargeLabel, !mStaticModeEnabled && !checked ? mLargeScale : 1.0f); ViewCompat.setScaleX(mSmallLabel, !mStaticModeEnabled && checked ? mSmallScale : 1.0f); ViewCompat.setScaleY(mSmallLabel, !mStaticModeEnabled && checked ? mSmallScale : 1.0f); + // make mLargeLabel and mSmallLabel are bold + mLargeLabel.setTypeface(null, Typeface.BOLD); + mSmallLabel.setTypeface(null, Typeface.BOLD); mLargeLabel.setVisibility(/*checked ? VISIBLE :*/ INVISIBLE); mSmallLabel.setVisibility(VISIBLE);//checked ? INVISIBLE : VISIBLE);