Introducing XDA:DevCon – A Conference For Developers By Developers
XDA Developers Android and Mobile Development Forum
Forgot your password?
 
Post Reply+
Tip us?
 
he_stheone64
Old
(Last edited by he_stheone64; 7th January 2011 at 10:52 AM.) Reason: Solved
#1  
he_stheone64's Avatar
Recognized Themer - OP
Thanks Meter 9112
Posts: 4,713
Join Date: Aug 2008
Location: Vienna & Düsseldorf
Default [Q] Need help with inverting colours on htcdialer buttons - Solved it myself...

Guys - this is driving me nuts. After exploring stock Android inside out with the Milestone, there is a new and great learning curve with Sense, which is fine. In any case after investigating it is pretty clear what to do, if I want to change htcdialer to a black background and in this case certainly white (or another bright) font colour for the dialer buttons. After decompiling and checking the layout folders everything directly aims to style.xml - so I edited the corresponding values:

<style name="text_style_dialer_button_number">
<item name="android:textSize">27.0sp</item>
<item name="android:textColor">#ffffffff</item>
<item name="android:layout_gravity">center_horizontal</item>
<item name="android:layout_width">wrap_content</item>
<item name="android:layout_height">wrap_content</item>
<item name="android:shadowColor">@color/color_255_255_255</item>
<item name="android:shadowDx">2.0</item>
<item name="android:shadowDy">2.0</item>
<item name="android:shadowRadius">1.0</item>
</style>
<style name="text_style_dialer_button_alphabet">
<item name="android:textSize">14.0sp</item>
<item name="android:textColor">#ff777777</item>
<item name="android:layout_gravity">center_horizontal</item>
<item name="android:layout_width">wrap_content</item>
<item name="android:layout_height">wrap_content</item>
<item name="android:layout_marginTop">42.0px</item>
</style>
<style name="text_style_dialer_button_zero_number">
<item name="android:textSize">27.0sp</item>
<item name="android:textColor">#ffffffff</item>
<item name="android:layout_gravity">center</item>
<item name="android:layout_width">wrap_content</item>
<item name="android:layout_height">wrap_content</item>
<item name="android:shadowColor">@color/color_255_255_255</item>
<item name="android:shadowDx">2.0</item>
<item name="android:shadowDy">2.0</item>
<item name="android:shadowRadius">1.0</item>

Unforunately no success - I also tried several layout xml despite knowing it will not work, just to double check. I also looked into EVO threads (since there was nothing here) and found out, that this style.xml and my values are right (certainly knowing that HTC changed something for DHD).

I also checked htcframework - besides a few pngs which I certainly found and edited no corresponding xml. So the answer seems to be in the smali code.

Anyone else tried this and succeeded? Any help would be greatly appreciated - Thx
 
he_stheone64
Old
#2  
he_stheone64's Avatar
Recognized Themer - OP
Thanks Meter 9112
Posts: 4,713
Join Date: Aug 2008
Location: Vienna & Düsseldorf
solved it myself - see Revolution theme thread
 
MrYuiM
Old
#3  
Senior Member
Thanks Meter 38
Posts: 511
Join Date: Jun 2010
Location: Stalkerland
Quote:
Originally Posted by he_stheone64 View Post
solved it myself - see Revolution theme thread
Would you mind sharing how you did it? I spent over an hour editing each PNG one by one to find out it doesnt work! Now that got me a bit pissed grrrrr
 
he_stheone64
Old
#4  
he_stheone64's Avatar
Recognized Themer - OP
Thanks Meter 9112
Posts: 4,713
Join Date: Aug 2008
Location: Vienna & Düsseldorf
That is certainly not png related, you need to decompile the apk first and then need to edity styles.xml in values-hdpi folder.I was so used to AOSP (had a Milestone before, never had values-hdpi), that I started editing everything in values folder and with all the language value folders was not looking at the obvious...
 
MrYuiM
Old
#5  
Senior Member
Thanks Meter 38
Posts: 511
Join Date: Jun 2010
Location: Stalkerland
Thanks. Last question, how would I go about making the buttons plain black, instead of having a sort of gradient around it/button around it? I'm trying to match my keyboard.
 
he_stheone64
Old
#6  
he_stheone64's Avatar
Recognized Themer - OP
Thanks Meter 9112
Posts: 4,713
Join Date: Aug 2008
Location: Vienna & Düsseldorf
1. Use my themed htcdialer from Revolution Theme (which is already compiled for inverted use - credit is always nice, if you release it)
2. Make htc_pin_asset_rest.png in htcdialer 100% transparent
3. You should at least have a little glow or whatever effect for htc_pin_asset_pressed.png in order to have feedback for input
4. Make phone_keypad_background.png in com.htcresources.apk as dark as you like it
 
kurniawan77
Old
#7  
kurniawan77's Avatar
Retired Forum Moderator
Thanks Meter 437
Posts: 1,285
Join Date: Nov 2008
Location: ☺☻♦®▼▼õ┘Œ

 
DONATE TO ME
whaaa!!! almost a week looking at those files.... and indeed never looked between those language folders....H
__________________________________________




http://forum.xda-developers.com/show...9&postcount=45 Maybe then.... some of you might understand why!
 
MrYuiM
Old
#8  
Senior Member
Thanks Meter 38
Posts: 511
Join Date: Jun 2010
Location: Stalkerland
Much appreciated and I will make sure to credit you if I release
 
Aamir.Badat
Old
#9  
Aamir.Badat's Avatar
Senior Member
Thanks Meter 24
Posts: 814
Join Date: Nov 2010
can you install the dialer as an apk file? if you could please pass it over it would would go well with my screen setup at the moment
 
he_stheone64
Old
#10  
he_stheone64's Avatar
Recognized Themer - OP
Thanks Meter 9112
Posts: 4,713
Join Date: Aug 2008
Location: Vienna & Düsseldorf
You only need to download the Revolution Theme and flash only the htcdialer (delete anything in the update.zip, which you don`t need -certainly not the Meta-INF...)

 
Post Reply+
Thread Tools Search this Thread
Search this Thread:

Advanced Search
Display Modes

report this ad
Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts
BB code is On
Smilies are On
[IMG] code is On
HTML code is Off

Go to top of page...

XDA PORTAL POSTS

Tasker Alternative: AutomateIt, Automates Your Device Tasks – XDA Developer TV

XDA Developer TV Producer Kevin wants to help make your … more

Preventing App Piracy: Join the Discussion

The topic of piracy is always a touchy subject, but I feel that the grass roots style of Android … more

Jolla Sailfish OS Flagship Device Makes First Appearance

Given the amount of coverage that Android receives around here, you could almost be … more

XDA University: Porting ClockworkMod Recovery to New Devices

Having a good recovery makes the process of modifying, tweaking, maintaining, … more