I am new in titanium development. How i can create a custom alloy theme or change the holo theme action bar background. please help me with a example if you have solution.
1
votes
3 Answers
1
votes
The best way to do this is with this "actionbar generator". its works amazing to me. ActionBar Generator
0
votes
You should take a look at this thread in the Appcelerator forum. In short: You create a style where you define your color and apply it to your actionbar.
0
votes
Example:
platform/android/res/values/builtin_themes.xml
<!-- Works for Titanium SDK 3.2.x and earlier when built against Android 4.0x/API Level 14 -->
<?xml version="1.0" encoding="utf-8"?>
<resources>
<!-- Available for Android 4.0.x/API Level 14 and later -->
<style name="LightDarkBar" parent="@android:style/Theme.Holo.Light.DarkActionBar"/>
<!-- Available for Android 3.0.x/API Level 11 and later -->
<style name="Light" parent="@android:style/Theme.Holo.Light"/>
<style name="Dark" parent="@android:style/Theme.Holo"/>
<!-- Available for all Android versions -->
<style name="OldLight" parent="@android:style/Theme.Light"/>
<style name="OldDark" parent="@android:style/Theme.Black"/>
</resources>
modify the Android section of your tiapp.xml
<android xmlns:android="http://schemas.android.com/apk/res/android">
<manifest>
<application android:theme="@style/LightDarkBar"/>
<uses-sdk android:minSdkVersion="14" android:targetSdkVersion="19"/>
</manifest>
</android>