Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

Change Google Place Picker Appbar Text Color

I would really like to know if I am able to change the text color of the Appbar text in the PlacePicker API for Android. It should inherit the styling from my application, but it does not do that.

my styles.xml is as follows:

<style name="MaterialParent" parent="Theme.AppCompat.Light.NoActionBar">
    <!-- ...and here we setting appcompat’s color theming attrs -->
    <item name="colorPrimary">@color/primary</item>
    <item name="colorPrimaryDark">@color/primary_dark</item>
    <item name="colorAccent">@color/accent</item>
    <item name="android:textColor">@android:color/white</item>
    <item name="android:textColorPrimary">@android:color/white</item>
    <item name="android:textColorSecondary">@color/secondary_text</item>
    <item name="icon">@color/icons</item>
    <item name="divider">@color/divider</item>
    <item name="colorControlHighlight">@color/accent_alpha26</item>

</style>

<style name="Material" parent="MaterialParent"/>

I've already tried changing android:textColorPrimary, android:textColorSecondary and textColor to white with no luck.

enter image description here

like image 461
orrett3 Avatar asked Jul 04 '15 11:07

orrett3


People also ask

How do I change text color in appbar?

Step 1: Locate the MaterialApp widget. Step 2: Inside the MaterialApp, add the theme parameter with ThemeData class assigned. Step 3: Inside the ThemeData add the appBarTheme parameter and then assign the AppBarTheme class. Step 4: Inside the AppBarTheme , specify the foregroundColor parameter and set the color.

How to change top bar Text color in Android?

Step 1: After opening the android studio and creating a new project with an empty activity. Step 2: Navigate to res/values/colors. xml, and add a color that you want to change for the status bar. Step 3: In your MainActivity, add this code in your onCreate method.

How do you change the title text color in flutter?

Steps. Step 1: Locate the file where you have placed the Text widget. Step 2: Inside the Text widget, add the Style parameter and assign the TextStyle widget. Step 3: Inside the TextStyle widget, add the color parameter and set the color of your choice.

How to change App Title color in Android?

In Android Studio, open colors. xml (app > res > values > colors. xml). After the existing colors, define a color resource named green using the value selected above, #1B5E20 .


1 Answers

Please use Theme.AppCompat.Light.NoActionBar instade of Theme.AppCompat.Light.DarkActionBar

like image 125
Özer Özcan Avatar answered Oct 03 '22 02:10

Özer Özcan