[Galaxy S II Themes and Apps] HighlanderZA:
Changing PNGs inside your APKs - Guide

Simple Mods for Toggles and other Icons for NeatROM.

This is aimed at beginners who, like me, have a Chernobyl moment when faced with coding and modding for Android.

It’s simple, like me, and it’s how I started.

Tools:

7Zip - http://www.7-zip.org/download.html

Gimp - http://www.gimp.org/ or

Paint.Net http://www.getpaint.net/ or

Photoshop.

Some form of android decompiler/compiler – search xda or Google.

Toggles:

The toggle icons or XXXXXX.png files are in two places depending on whether you are modding the stock icons or engloa’s 23 toggle icons.

Stock will be in SystemUI.apk - res\drawable-hdpi

These toggle icons are called:

‘tw_quick_panel_icon_rotation_on.png’ & ‘tw_quick_panel_icon_rotation_off.png’ and so on all starting with ‘tw_quick_panel_icon_xxx_off’ or ‘tw_quick_panel_icon_xxx_on’

Engloa’s, Wanam's and Sale's 23 Toggle mods are in lidroid-res.apk - res\drawable-hdpi

These toggle icons are called:

‘stat_airplane_off.png’ & ‘stat_airplane_on.png’ and so on all starting with ‘stat_xxx_off’ and ‘stat_xxx_on’

We will be talking about modifying the 23 Toggle Mods engloa has made for us.

With his kind permission and giving him all due credit of course.

What I do is use 7Zip to open the mod zip…..

There will be other files in the zip that we are not interested in for this exercise, HOWEVER, leave them alone, don’t remove what you are not sure of. Open ‘system’ to see below.

Open ‘framework’ to see below

Open ‘lidroid-res.apk’ to see below. This opens the apk (like a zip file) within the open mod zip(I hope that makes sense – it is important for later so get it right now)

Open ‘res’ to see below the contents of the ‘res’ folder. Remember the ‘drawable-hdpi’ folder…

Open it up to see its contents like below. If 7Zip is behaving correctly, you will still not have ‘EXTRACTED’ anything from the zip files.

Now for ease of use and to be able to view things a lot better, go back one step so you are at the screen below, use the up arrow just below the big Add button.

Now open up a new folder, labelled of course, and drag ‘drawable-hdpi’ into it.

Open that up to see all the png files inside. You will see in this pic that the ones I’ve modded are VERY different to the others and easy to find. View them as ICONS of course, not the file names.

You can now create new toggle icons to your hearts content and replace the ones here with your own.

No I don’t know where all of the other png’s are used.

As future ‘Recognised Themers’ and ‘Recognized Contributors’ and ‘ROM cookers’, that’s your adventure.

You can create all your icons and store them in a separate folder or in here, overwriting the existing ones.

Where you store them will change the path we follow when we update the mod zip for testing.

Use the same sizes as what you found the originals to be, would be my recommendation.

Example: 60X60 for the ‘six on a screen’ toggles in the ‘23 Toggle Mods’.

NOW to see whether your creation works.

I don’t have an emulator or know of one so I test on my phone.

You are going to replace all the modified PNG files inside the ‘res\drawable-hdpi’ folder in lidroid-res.apk.

Use 7Zip and open the mod zip following the same path all the way down until you get to here:

Now we simply drag the ‘drawable-hdpi’ folder containing all the new icons and all the unmodified icons across and drop it into the zip. It will ask you if you’re sure and of course you will be so ‘YES’.

You will see that the ‘drawable-hdpi’ folder now has a date when you modified it.

Use the ‘back’ button again and again until you get this message. Answer ‘OK’ and the lidroid-res.apk will be updated inside the main mod zip file.

Use the back button again and again until here and then exit out of the mod zip.

Your MOD is now ready to be copied to your phone and flashed via CWM for testing and more testing!

If it doesn’t work, well I’m sure you made a NANDROID backup BEFORE you started messing around, so restore to a working phone and try again.

That’s it – if it works and you think others might like it SHARE IT! Fame and fortune awaits.(Well maybe!)

Yes, there are ways to update these files on the phone using apktool and other ‘strange’ methods, but they involve changing file permissions and such and then you don’t have a readymade MOD file that you can share with everyone on the NeatROM thread.

Obviously this is just the basics. Once you start exploring the Villain Rom Theming methods I've used for most of the mods above, things change slightly and you will only have the pngs you have changed in your zip files.

That is altogether another guide and I would point you to the Villain ROM thread for more info.

NB!!

This will not work with the 9 patch or xxx.9.png files. (unless you are simply swapping out pngs and not editing them)

They are a special case and require special handling. There are guides here on xda for them.