9
Mój kod to:Zmiana Pasek motyw programowo
<android.support.v7.widget.Toolbar
android:id="@+id/toolbar"
android:layout_width="match_parent"
android:layout_height="wrap_content"
android:background="?attr/colorPrimary"
android:minHeight="?attr/actionBarSize"
app:theme="@style/Toolbar_Theme"/>
Chcę zmienić app: motyw w kodzie Java. Czy mogę znaleźć dowolną metodę jako toolbar.setTheme
, która służy do zmiany stylu paska narzędzi?
można zmienić tylko kolor tła i kolor tytuł używając kodu: toolbar.setBackgroundColor (newColor); toolbar.setTitleTextColor (titleColor); – Lazai
@Lazai dziękuję –
Wypróbuj to: https://stackoverflow.com/questions/31225189/how-to-change-appcompat-v21-toolbar-theme-programically –