Theming question... - Droid X Themes and Apps

So I'm getting the hang on some basic theming and just had a question that I'm not completely sure about.
In most of the res folders, you have several different folders that contain images.
Can someone explain to me the difference between some of these folders? The ones I'm asking about are drawable and drawable-hdpi.
Any help will be greatly appreciated...

hacku said:
So I'm getting the hang on some basic theming and just had a question that I'm not completely sure about.
In most of the res folders, you have several different folders that contain images.
Can someone explain to me the difference between some of these folders? The ones I'm asking about are drawable and drawable-hdpi.
Any help will be greatly appreciated...
Click to expand...
Click to collapse
dont quote me, but from what i gather its for different phones that use different resolutions. Our phone used the hdpi folders but on occasion it may pull an image from the plain drawable folder. I read somewhere that the galaxy s currently uses the mdpi. I have yet needed to change one of those images.
Stick to hdpi, and if after you put the apk on your phone, an image is still stock then hunt in the drawable.
hope that helps.

bad4u6669 said:
dont quote me, but from what i gather its for different phones that use different resolutions. Our phone used the hdpi folders but on occasion it may pull an image from the plain drawable folder. I read somewhere that the galaxy s currently uses the mdpi. I have yet needed to change one of those images.
Stick to hdpi, and if after you put the apk on your phone, an image is still stock then hunt in the drawable.
hope that helps.
Click to expand...
Click to collapse
That's what I figured and just wanted to some clarification. Thanks...

Related

[Q] [IDEA] Porting HDPI themes to MDPI

Just recently been into themes and knew how they work.
If I use some kind of batch image resizer to resize hdpi png's to mdpi, and put those resized in drawable-mdpi it would work.
Am I correct? I see no reason why it can't be as easy as that.
I resize them with GIMP. Don't know what you use but in theory have to work
well, i don't know any coding language.
Maybe someone could make a script to resize images??
it would be a pain in the a** to resize them one by one
There are many batch resize windows apps that will let you convert a complete folder full more at once..
just google it
Sent on the run from my Magic 32A
It will not work on many .9.PNG files unless you resize them from source. Sorry but I've tried it with my theme. .9.png files are not just normal png files. They are made to stretch and readjust depending on the orientation of your device (landscape versus portrait) and may have what is called 'guides' coded within the images to tell the OS how to display that graphic. If you were to edit that file in any way those guides are over written and it messes up your whole theme. So if you were to use a batch resizer you would probably experience a disgusting looking interface coupled with acore crashes. Unless of course you used the files from source and just created the app from the source code. But who knows you might get lucky and whatever app that you are trying to theme may not use those pesky .9.png files.
Binary100100 said:
It will not work on many .9.PNG files unless you resize them from source. Sorry but I've tried it with my theme. .9.png files are not just normal png files. They are made to stretch and readjust depending on the orientation of your device (landscape versus portrait) and may have what is called 'guides' coded within the images to tell the OS how to display that graphic. If you were to edit that file in any way those guides are over written and it messes up your whole theme. So if you were to use a batch resizer you would probably experience a disgusting looking interface coupled with acore crashes. Unless of course you used the files from source and just created the app from the source code. But who knows you might get lucky and whatever app that you are trying to theme may not use those pesky .9.png files.
Click to expand...
Click to collapse
Thank you for this Binary100100..
In a regular theme, about how many pngs are .9?
and what do you mean "created from source"?
MicroMina said:
Thank you for this Binary100100..
In a regular theme, about how many pngs are .9?
and what do you mean "created from source"?
Click to expand...
Click to collapse
.9.png with guides? I have no clue. For an entire rom... I would say over a hundred easily. There are about a dozen of them just in the Dialer app itself. If you modify any one of them the whole thing get's messed up. It's very delicate. What do I mean create it from source? Download the source code from HTC website on a Linux machine and create the ENTIRE rom from scratch. It's not that hard actually once it's all set up. Before you do the "make" command you would do your xml edits, resizing, color edits, etc. You can tell what a .9.png file is because it has a line on the right of the image and a line on the bottom beneath it. It will have a black pixel at the top and one on the left. So you edit those files the way that you want it and then create the app or the entire rom. If you chose to create the entire rom then remove the parts from the rom that you don't want in your theme and then make an update-script file for your flashable theme. Nobody said that making a theme is fun or easy and in many cases the developers of the theme (like myself) do it just because they did it for their own device and chose to share their work. On average if you want to create an entire theme it will take you at least 30+ hours of work if you are already set up and knowledgable with Linux and image editing. That's how long it took me anyway.
Thank you for this very informative post.
I guess its not that easy after all. Maybe one day I could try it.
Thanks again.
MicroMina said:
Thank you for this very informative post.
I guess its not that easy after all. Maybe one day I could try it.
Thanks again.
Click to expand...
Click to collapse
Oh it's plenty easy, it's just very time consuming to make a theme from scratch and since you can't take a 3kb file measuring 20 x 20 and turn it into 36 x 36 and turn it into a 5.4 kb file without losing resolution (thus defeating the purpose of being on a AMOLED HD display) even if you were to suceed it probably still won't look very good. Think of it like this. Take a standard 800 x 600 video for your non-high definition television. Sure it looks alright but what about if you displayed it on a 1080p television. Is the picture going to look any better? Not really because it's the quality of the video and not the television itself. Now, if you could enhance the video... it would make a huge improvement. But by simply resizing the images wouldn't really do anything for a HD screen (my theory anyway).
But if you build everything from the source code (that is such as Cyanogen's github) and edit all the images from scratch then you shouldn't have a problem. But it is VERY time consuming like I mentioned before. I loathe the idea of upgrading my phone now because that means that my current theme along with all of the work that I've done with it... will be obsolete until I can do it all over again from source. Ugh.

Replacing Icons in framework-res.apk

I've been opening up framework-res.apk as a zip file and changing around icons for my status bar with other themes. I just replaced the signal bars icons and the 3G icons, repackaged the framework into a zip file, and applied it via rom manager. No Icon change. I've been able to replace several before, any ideas why it wouldn't work now? I reopened the file and verified the icons had been changed.
The icons you are looking for are in com.htc.resources.apk
If you have something specifically you want changed I can tell you where it is located and what the filename is. I am building some theme tutorial videos because I had a hard time finding all of this information. I want to make it easier for others. I remember all the way back in June when I got frustrated finding what files went where. I am making a list to help others out, let me know what you are looking for.
[email protected] said:
The icons you are looking for are in com.htc.resources.apk
If you have something specifically you want changed I can tell you where it is located and what the filename is. I am building some theme tutorial videos because I had a hard time finding all of this information. I want to make it easier for others. I remember all the way back in June when I got frustrated finding what files went where. I am making a list to help others out, let me know what you are looking for.
Click to expand...
Click to collapse
Subscribed!
Sent from my ADR6300 using XDA App
subscribed as well, a video with some info would be great. I am definitely no developer, but not afraid to mess around a bit. I was also interested in making similar changes as OP.
In fact I am using Jerick's smooth sense mod with white letter mod by squintz, and a couple of the icons were coming up out of order. I was not cool enough to be able to repair the info that points to an icon so I found the icons in framework-res.apk and changed the names of them so that I would get the correct icon in status bar. But obvously that is not the correct fix. However this is where the icons OP is talking about. So if I can make a name change to a png can't you also replace that png. I believe that the apk has to be signed correctly after manipulating?
Anyways any basic info about doing such would be greatly appreciated
spjoneser said:
subscribed as well, a video with some info would be great. I am definitely no developer, but not afraid to mess around a bit. I was also interested in making similar changes as OP.
In fact I am using Jerick's smooth sense mod with white letter mod by squintz, and a couple of the icons were coming up out of order. I was not cool enough to be able to repair the info that points to an icon so I found the icons in framework-res.apk and changed the names of them so that I would get the correct icon in status bar. But obvously that is not the correct fix. However this is where the icons OP is talking about. So if I can make a name change to a png can't you also replace that png. I believe that the apk has to be signed correctly after manipulating?
Anyways any basic info about doing such would be greatly appreciated
Click to expand...
Click to collapse
You don't need to resign the apk unless you completely extract it. Then good luck trying to get a system apk to work. Just open the archive and replace needed imgs then update the archive and you're done. All depends on what os your using. Linux makes it easy to edit apks without extracting. In win you have to rename to .zip then do line I said then rename back to .apk
Sent from my ADR6300 using XDA App
Which files specifically are the signal meter? I just want to change those ones back to the stock icons.
jskolm said:
Which files specifically are the signal meter? I just want to change those ones back to the stock icons.
Click to expand...
Click to collapse
I can tell you later (i dont have the dump on hand) but the signal meter pngs are located in com.htc.resources.apk under /res/drawlablehdpi/ thay have a name like sys_status_cdma1 or something like that. I think if you get that far the images might jump out at you. If you want the exact ones I can tell you when I get back from work.
[email protected] said:
I can tell you later (i dont have the dump on hand) but the signal meter pngs are located in com.htc.resources.apk under /res/drawlablehdpi/ thay have a name like sys_status_cdma1 or something like that. I think if you get that far the images might jump out at you. If you want the exact ones I can tell you when I get back from work.
Click to expand...
Click to collapse
Found them. Thanks for the direction. I was looking through the folders and I couldn't find them, because they are transparent backgrounds, so the white on white blended right in. I changed out the signals for the ones I wanted and everything looks like its working now.
Thanks for your help!

theming icons?

I'm wondering how one accesses the launcher icons. I'd like to be able to do my own tweaks if necessary. I've read up a bit on the android dev site, and saw the basics on creating them, but not on how to get to, and alter the stock icons. I'm guessing it may involved digging in with root explorer, but I have know idea where to look. Any direction on this?
I have never created my own due to the fact that there are so many already available from members of our great community, but have swapped out many png's in my system. Mostly status bar icons. But would be same process. What I usually do is copy apk from system to puter or extract from rom zip and open up with 7zip. Find said png, and copy new one to it's location. Close the zip at which time it may ask you if you would like to update, press yes. And then push the new apk to your system or create a flashable zip out of it.
How's that sound? Is that what you were looking for?
That sounds like what I would need to do, but it was a bit beyond my understanding at this point. I've never dug around in the system files, and barely understand all the terminology. I was kind a hoping for a go here, then there, then look for xxx.png, copy to pc, etc...
n8w said:
That sounds like what I would need to do, but it was a bit beyond my understanding at this point. I've never dug around in the system files, and barely understand all the terminology. I was kind a hoping for a go here, then there, then look for xxx.png, copy to pc, etc...
Click to expand...
Click to collapse
You need to start looking in
Rosie.apk (/system/app/)
com.htc.resources.apk (/system/framework/)
framework-res.apk (/system/framework/)
Copy them to your PC
Then extract the res folder with 7zip, replace the png files you want to change then drag and drop the res folder back into 7zip
Typically icons start with either ic_ or icon_ but that is not always the case so search visually in the res sub folders
adb push them back to their respective folders

[Q] How to dim soft keys Loli 5.1

Title say all , i have a Nexus 5 lolipop 5.1 and i want to full dim 0 my visor . Softkeys inclued.
Need help please.
If you want to dim the navigation bar (why would you need to?) you'll probably have to decompile SystemUI, modify the drawables then recompile, or use Xposed.
It's not necessary to decompile. As .apk is actually a .zip, you can simply change .png-s inside drawable folders.
But if you use 5.1 it will be much harder to change original SystemUI with yours, because of security changes in system partition.
zagorteney said:
It's not necessary to decompile. As .apk is actually a .zip, you can simply change .png-s inside drawable folders.
But if you use 5.1 it will be much harder to change original SystemUI with yours, because of security changes in system partition.
Click to expand...
Click to collapse
This one is tricky though since you have to make sure, not to damage the signature. Some PNG use a "special" format and need to be decompiled first --> modified --> recompiled --> injected again in the Framework.
Gorgtech said:
This one is tricky though since you have to make sure, not to damage the signature. Some PNG use a "special" format and need to be decompiled first --> modified --> recompiled --> injected again in the Framework.
Click to expand...
Click to collapse
I wrote this many times: you DON'T need to decompile apps which came from factory image. And even .9.png-s can be simplycomment on this are changed. For example: We wish to change background of power widget. 1. Pull the Settings.apk from /data/priv-app. Copy to PC. Rename it to .zip (you don't need any extra tool for this) or use TotalCommander - you even don't need to rename .apk to .zip with it. We must look for appropriate image (appwidget_bg_holo.9.png in /res/drawable-xxhdpi-v4) inside. Make some regullary png in Photoshop in size and resolution of original one - you can free your imaginations about colors as you like. Now copy the name of original image and with paste rename your own. Put your renamed image into .zip (overwrite original one) and thats all philosophy.
This is possible just with apps from factory image and you will not brake any signature. This works for me since Xperia X10 until Nexus 5 with 5.0.2. On 5.1 biggest problem is (at least for me) that I don't know how to integrate updates of system apps into rom. But if you are on 5.0.2 or above, you can simply try. Just remember to backup first.
Regards, Zagor
P.S. Any further informations are welcome, but at least people try this first. And it's a little annoying to write this down over and over again.
Extracting and inserting pictures is not the problem but like I mentioned before, the "9" PNG. If you simply copy them, edit them and reinsert them again, it might turn out to be a mess and these pictures are not displayed the right way. I gave up theming stuff a long time ago since it´s not really worth the trouble anymore. At least if you use a legal Gfx tool ( since I have my doubts that most people own a real licensed version of Photoshop anyway ) like eg. GIMP, you might expect some trouble if you don´t decompile "9" PNGs first. At least I can tell that I had to go through the trouble while I still had my old Galaxy S3 in order to make them usable, the way I wanted them to be
I know the procedure, don´t worry
Gorgtech said:
Extracting and inserting pictures is not the problem but like I mentioned before, the "9" PNG. If you simply copy them, edit them and reinsert them again, it might turn out to be a mess and these pictures are not displayed the right way. I gave up theming stuff a long time ago since it´s not really worth the trouble anymore. At least if you use a legal Gfx tool ( since I have my doubts that most people own a real licensed version of Photoshop anyway ) like eg. GIMP, you might expect some trouble if you don´t decompile "9" PNGs first. At least I can tell that I had to go through the trouble while I still had my old Galaxy S3 in order to make them usable, the way I wanted them to be
I know the procedure, don´t worry
Click to expand...
Click to collapse
As I said: you must not copy and edit existing .9.png. You have to create a new one and just name it with the procedure as I wrote above. So you have to copy the name of .9.png and paste that in the name of your own image. Am I clear enough now?
Forgive me to say, but you don't know this. Sorry.
Best regards, Zagor
I guess you don´t read what I write ? If you want to color a existing image ( "9" ), it will be displayed faulty if you don´t proceed like I did. End of the story. You can replace it with another image you can rename but it won´t be displayed the right way in some circumstances. I´m out.
zagorteney said:
As I said: you must not copy and edit existing .9.png. You have to create a new one and just name it with the procedure as I wrote above. So you have to copy the name of .9.png and paste that in the name of your own image. Am I clear enough now?
Forgive me to say, but you don't know this. Sorry.
Best regards, Zagor
Click to expand...
Click to collapse
Gorgtech said:
I guess you don´t read what I write ? If you want to color a existing image ( "9" ), it will be displayed faulty if you don´t proceed like I did. End of the story. You can replace it with another image you can rename but it won´t be displayed the right way in some circumstances. I´m out.
Click to expand...
Click to collapse
Out of what? Space?
I don't guess, I conclude: You don't read or understood what I wrote.
Back to topic: OP: If you want to change navbars buttons (those are ordinary .png-s) you can simply pull them off, modify them and put back into .apk as I already described. You don't need to decompile, compile, undercompile or hipercompile anything.
Regards from Jupiter (yes, I'm also out), Zagor
And the last and for all!
This has been done without superduperpuper compiling. Just pure windows and photoshop.
@Elluel, @Gorgtech and all of the other sceptics: Look at the navbars of attached screenshot and next time, please check the informations before you disagree with them.
Regards, Zagor
IMO @zagorteney is right as long as you do not unzip/extract the apk. If you check the .9.png with a zip viewer then you can see the black border of 1px. Modifying the icon/log/picture without touching the black borders should not create bugs.
Regarding the navbar buttons it's easier as explained above.
@Primokorn
I've changed almost all of Xperia S UI on that way, to looks more AOSP. But at the end I figured it out, that it's simplier if I get Nexus.
Just to notice you. The problem is because in photoshop you can't create .9.png-s. But if you create your own png and rename it with the mentioned method, there will be no problem with those images either. For example, you can try to change power widget background on this way.
zagorteney said:
@Primokorn
I've changed almost all of Xperia S UI on that way, to looks more AOSP. But at the end I figured it out, that it's simplier if I get Nexus.
Just to notice you. The problem is because in photoshop you can't create .9.png-s. But if you create your own png and rename it with the mentioned method, there will be no problem with those images either. For example, you can try to change power widget background on this way.
Click to expand...
Click to collapse
Actually you can create .9.png files with Photoshop. I did it a lot of times.
Anyways all my modded apks have been decompiled/modified/recompiled because you cannot use this method for .xml files, can you? Moreover, theming files with a phone is a mess compared to a comfortable destop version of PS lol
@Primokorn
Yes, its true if we are talking about some serious theming. But OP just want to get little different nav buttons. So, I just want to say, that you don't need to change any .xml for that purpose, you don't need to decompile and recompile and you don't need to worry that you'll break signatures. As simple as that.
That's all folks.
zagorteney said:
@Primokorn
Yes, its true if we are talking about some serious theming. But OP just want to get little different nav buttons. So, I just want to say, that you don't need to change any .xml for that purpose, you don't need to decompile and recompile and you don't need to worry that you'll break signatures. As simple as that.
That's all folks.
Click to expand...
Click to collapse
Yes, I know. Everything is clear on my side
Primokorn said:
Yes, I know. Everything is clear on my side
Click to expand...
Click to collapse
At least one who deserves all of those thanx.
zagorteney said:
At least one who deserves all of those thanx.
Click to expand...
Click to collapse
Do not be rude. Nobody can know everything and it is one of the goals of XDA to learn every day. All recognized members deserve their status.
A app that do that easy and without so much work is nice , my know how on this stuffs are limited :crying: , im kitkat i use a app that does that without so many work , now i use another but just dim the visor the softkeys still are very white full light... :crying:
Primokorn said:
Do not be rude. Nobody can know everything and it is one of the goals of XDA to learn every day. All recognized members deserve their status.
Click to expand...
Click to collapse
The problem is that n00bs are mislead by recognized members who think that they know everything. At least they could check before post.
And no, I'm not rude. Rude are exactly those contributors.

Good APK Modification Tutorial?

Hey Everyone,
I'm looking to get back into de-compiling, modifying, and recompiling APKs again (after many many years) and I'm finding it a bit difficult this time around. For starters, why are there so many "drawable-xxxx" folders now and how do I know which folder to modify the .png files that I want to customize? Also, how do I go about modifying the .xml file for an app to change the font color/style, theme, etc.?
Does anyone know of a good resource to refresh my memory on all of this?
Thanks for the help!
BMWPower06 said:
Hey Everyone,
I'm looking to get back into de-compiling, modifying, and recompiling APKs again (after many many years) and I'm finding it a bit difficult this time around. For starters, why are there so many "drawable-xxxx" folders now and how do I know which folder to modify the .png files that I want to customize? Also, how do I go about modifying the .xml file for an app to change the font color/style, theme, etc.?
Does anyone know of a good resource to refresh my memory on all of this?
Thanks for the help!
Click to expand...
Click to collapse
Hi,
I've made some, I don't claim they're the best or something, but I think it's a good place to start.
For everything I could think of: [GUIDE][INDEX]How to modify an apk
For colors and png:
[GUIDE][THEMING]How to find in the code what you want to theme
[THEME & GUIDE][XDA]XDA Reloaded
My last guide was the INDEX, in previous guides I use methods to sign or align apks that I don't really recommend anymore. Read the index first for signing and aligning, then other guides
I also have made themes, the link is in my signature, click it to see

Categories

Resources