[GUIDE] Want to learn how to theme?

Did this guide help you out?


  • Total voters
    1,542
Search This thread

ciao99

Senior Member
Jan 8, 2010
416
52
hi guys, i'm looking for files that control lockscreen's appearance, for example where the position (x,y) of a icon is coded, beacause i want to enable 2 icons in my lockscreen...someone can tell me where find them? ;)
 
Last edited:

hulkhaugen

Senior Member
May 4, 2010
228
12
Arendal
bstart.net
I'm having problems with my themes. I did modify a couple of Tmobile Theme Changer themes, but they won't apply. So i tried to decompile and recompile one of the ones i found without touching them, that worked. So i tried, just for the fun of it, replacing a few .png's inside a theme using 7-Zip w/o compiling, didn't work. Now, i just made a simple theme from scratch, only including statusbar icons for framework-res and SystemUI, and a little mod to the battery for having a different icon for every 4% instead of default 5-10-20-40-60-80-100, nothing more than that. The apk installs, but doesn't appear in Tmobile Theme Chooser, and i can't figure out why.

Please anyone, take a look at my attached apk, or help me figure out why it wont show up. I've spent so much time already, but can't seem to bypass this predicament. My details are as follows: LG Optimus Black P-970 running CM7 Nightly 27, using apktool and Notepadd++, haven't used Eclipse for anything yet, don't really know the benefits of it...

EDIT: They are signed with PPCGeeks APK & Zip Signer...
 

Attachments

  • newtheme-signed.apk
    305.7 KB · Views: 24
Last edited:

AndroidNoober

Senior Member
Oct 7, 2010
456
44
Caguas
hi i dont know if this is the right place,but im trying to use uot kitchen, is my first time, i follow steps and when going to pick up always show SHTF and the order number is UOT-01-12-04-19-1

thanks for your help

(im running juggernault 4.1 from sgs2 phone)
 

s2d4

Senior Member
Mar 28, 2009
1,341
395
hi i dont know if this is the right place,but im trying to use uot kitchen, is my first time, i follow steps and when going to pick up always show SHTF and the order number is UOT-01-12-04-19-1

thanks for your help

(im running juggernault 4.1 from sgs2 phone)
what part of this is learning how to theme?
 

theimpaler747

Retired Forum Mod / Retired Recognized Developer
This is theme, well trying to do it, and when tried to pick up have a error and yes is part of learning.... Anything else?

This is actually for people wanting to try to learn how to theme, and not have an automated system do it for them. It sounds like UOT is having issues recompiling your framework though.
 

mindseed

Senior Member
May 2, 2011
52
5
Johannesburg
mindseed.co.za
Hassles with a missing String resource

Hi there, thanks for the help you've offered in your posts - they've gone a long way in helping me on my way. I have a small problem though and was hoping perhaps you could maybe help.

I've uploaded a GOContacts theme to the Market I decompiled, edited and recompiled using apktool. The problem is - it appears I'm getting a " string resource not found" on some devices, yet it installs fine on almost all others.

I've checked the error mesage and string identifier in the market error log and then searched in my .smali files the ID 0x7f040019 points to a string for "dialog_title" - which is definitely available in all my values/strings files. I know this is a real huge shot in the dark, but was hoping maybe you could maybe point me or assist me in the right direction. Any help would be greatly appreciated.

Thanks
 

Dreamboxuser

Senior Member
Jan 24, 2012
380
83
This is an amazing amount of information to take in . I was wondering if this guide would apply to tablets running honeycomb as well?
Thanks for sharing your knowledge and your hard work everyone.:)
 

master reiki

Senior Member
Nov 22, 2011
438
225
38
ängelholm
Definitely!!

This is an amazing amount of information to take in . I was wondering if this guide would apply to tablets running honeycomb as well?
Thanks for sharing your knowledge and your hard work everyone.:)


Especially honycomb! you can use ADW launcher whit a cool theme from market ;D
and some widgets like one more clock. Just search market for cool honecomb widgets :) good luck! :D
 
  • Like
Reactions: Dreamboxuser

Dreamboxuser

Senior Member
Jan 24, 2012
380
83
I was trying to get apk manager but the link only gives me a corrupted zip. I think there might be a problem with the multiupload link posted. I tried several of the sites listed but most have 404 or the DOJ, FBI or some other 3 letter acronym notice saying that the site has been shut down. Oh and I don't have enough posts to say anything in the dev thread(fair enough) so if someone could pass that info along that would be greatly appreciated. Also what kind of resolution should the images be? Simply coz I want to do an old skool Transformers theme for my Transformer and i would prefer to use screen caps because i think it would be cool.
 

dEris

Senior Member
Nov 6, 2009
3,127
789
37
Dallas Texas
google.com
How does one make a apk (theme) file to change just the icons. I've torn apart an apk (theme) and cannot find the icons. For an mtz (MIUI) theme, the icons are literally in a file titled "icons." But for a tmobile theme engine theme, where are they at??
 

Top Liked Posts

  • There are no posts matching your filters.
  • 490
    I'm asked all the time how to theme; what's the best way, the best tools, etc. Well, I'm going to compile the best resources that I think will get you up and theming. It's a process, and you'll need to have time and devotion, but these tools and tips will help :D

    • A general guide (MOD Info: The document seems to have been removed and there is no possibility to recover it)

    This is the best guide that I know of out there for theming; it is comprehensive, and if you use it, you should give a big thanks to the makers of it.


    I find both of these to be great; I have apk manager (windows and linux) on my pc, and apktool (windows, mac, and linux) on my mac. APK manager will likely be best for beginners due to its simplistic and user friendly UI, and it offers some more features then apktool, like zipaligning, optimizing, etc. Both are fantastic, and absolutely a huge help for theming and decompiling apps.


    It's always helpful to know how to use the SDK for adb, zipaligning, and other tasks. Remember, even if you have other tools like apk manager to zipalign, it's always good to know how to do it by hand ;) And you'll need tools in it like draw9patch for those pesky .9pngs


    You will use this all the time. Editing files like decompiled XMLs on this is a breeze


    You'll use this every time you do XML edits; you'll need these color codes to tell the XMLs what color you want to show up


    Want to go all out? Go photoshop. Want a great, free tool to theme with? Gimp is the way to go. Either way, you'll want to use one of these tools for png edits when theming. Paint.net is also another good free tool for edits.


    For you mac users like me, Hex Fiend comes in handy if you ever need to edit binary (non readable or decompiled) XML.


    Fabulous tool on windows to create and modify elements of updates zips


    Want to make an ADW theme? This is a great tool to get you started on that :)

    • Knowledge ;)

    You'll want some general knowledge with terminal or windows cmd prompt. Because you will use it. Also, you'll need to know what to edit in a theme to change aspects of color and such correctly. Well, this is a great tool to find out what you need to edit :D


    I'll be adding to this guide as needed. Please, feel free to ask any questions, and I'll be here to answer them :) Hope this helps everyone!
    112
    In Depth Look: XMLs

    For the first in depth look, I'm going to focus on XML edits, as they are a major component to having a complete and thorough theme. Image edits are easy enough, but many don't know where to go when it comes to XMLs. Well, here's where I'll tell you ;)

    • What is an XML?

    Here's is a nice read on XMLs and what they are.

    • What do XMLs have to do with Android?

    XMLs can control many functions in android apps. For the scope of this thread, we'll be changing binary XML into a readable XML file to make our edits, which will usually result in color changes in apps.

    • How do I edit an XML?

    1. Make sure you have apktool or apk manager correctly set up. They'll make XML edits a breeze. If you need help setting them up, wither ask me or see their manuals.
    2. Take the apk you want to edit, and decompile it with one of those two tools. Make sure if it's dependent on Sense resources or TW ones that you have those set up. (Again, either ask me or see instructions for apktool and apk manager)
    3. Once decompiled, open the XML you'll need/want to edit. See the link I have above under knowledge for finding out what XML you may need to edit
    4. For Windows, use Notepad ++ to edit, and for Mac, use TextWrangler (just suggestions, others work as well)
    5. Use the Hex Color code link I have listed above in the OP to find the suitable code for the color you'll want if you;re making a color change. Remember, the color codes will be 6 digits, but there'll be 2 digits in the XML before the color code. 00 is transparent, and FF is the "regular" color for lack of a better term.
    6. When done with the XML changes, recompile the apk
    7. Sign if needed, and install to see if the changes you've made are worth it ;) :D
    105
    In Depth Look: Using Apktool or Apk Manager.

    • What are they?

    Apktool and Apk Manager allow you to decompile, reengineer, and compile apks after making changes to files in the decompiled apk.

    • Why would I need them?

    These tools allow you to edit XMLs, edit smali files, and change many other aspects of the apk that you wouldn't be able to do without decompiling the apk.

    • Setting up apktool on a mac

    If you have a mac like me, remember that apk manager doesn't work on macs. So, you must use apktool, which is absolutely fine, as in my opinion apktool is better than apk manager. To set up apktool, you must have root mode enabled on your mac. To do that, simply follow these steps:

    1. Open system preferences
    2. Open accounts
    3. Go to login options
    4. Hit join next to network account server
    5. Select open directory utility
    6. Click the lock at the bottom of the window that pops up and enter an admin password
    7. Then, go to the top bar on your mac, hit edit, and select enable root mode

    Once you have root mode enabled, you're ready to set up apktool:

    1. From the apktool website, download apktool1.3.2.tar.bz2 and apktool-install-macosx-2.2_r01-1.tar.bz2
    2. Next, open terminal
    3. su
    4. tar -C /usr/local/bin -xvf <zipped file name>
    5. tar -C /usr/local/bin -xvf <zipped file name> (for the second file)
    6. Now to confirm it worked, type "apktool" no quotes
    7. You should get a help menu for apktool
    8. If so, you're good to go! :D

    Now, once you have it set up, you're ready to go! After typing apktool, you'll see the help menu which'll give you the commands available for apktool, but I'll go over the basic ones here.

    • apktool d "apk path here" will decompile the apk
    • apktool b "decompiled apk path here" will build an apk from a previously decompiled one
    • apktool if "framework-res.apk path here" will install a framework res or any app really to allow you to work with dependent apps. For example, if you want to modify an HTC sense apk, you'll need to install the htc.resources.apk first through this method before decompiling the sense apk.

    • What if I have windows?

    The steps will be very similar. See the apktool website I have listed above for a bit more info, but as I said, it's not too far off minus the having to get root access part.

    • This seems to complex, and I hate using commands! I wish there were another way....

    Oh, but there is! *ends cheesy infomercial voice* Apk manager will give you a simplified setup, and all of the same features plus more; all you need is windows or linux.

    • Great! How do I get that?

    1. Download Apk Manager
    2. Extract the zip
    3. Open up the enclosed script
    4. The rest is pretty self explanatory ;)

    Now, even will apk manager, you'll need to make sure you know how to set frameworks up and such, but it makes it much easier with its convenient scripts. If you have any questions, ask them here and I'll certainly do my best to answer them :D

    Helpful Hint!

    • Remember, once you have an apk decompiled with apktool or apk manager, you have the best chance to correctly edit .9pngs!
    • If you open the .9png in the decompiled app and edit it with gimp or photoshop while leaving the pre-drawn boarder there, you'll be able to recompile the apk with a properly edited and themed .9png ;)


    Advanced Decompiling

    • Sometimes, you have that pesky app that just won't decompile correctly. Usually, it's an app related to others, like a proprietary system app based off framework-res.apks.
    • When this happens, you need to ensure that the frameworks are there to have the app's recourse tables properly compile.
    • For either apktool or apk manager, find a folder on your computer called "apktool."
    • The should be a folder in here called "framework," and inside that, a 1.apk.
    • For an app that is dependent on the framework-res.apk in a specific phone/rom, take the framework-res.apk for that rom and rename it 1.apk.
    • Replace the default one in the folder with yours.
    • If there's a second one, like the twframework-res.apk for Samsung phones, rename it 2.apk and place it in the "framework" folder.
    • Now, decompile like normal, and everything should be good :)
    54
    Editing Smali

    Right here, thanks to Yorzua :D
    10
    Cool, so what about theming market apps. I mean like changing the icon. I know how to change them individually but what about changing them in bulk. Where would one put them inside of an update.zip?

    Sent from sweet G2 :)

    Changing them in bulk would require you to theme each icon you'd like, and then you could do one of a couple things:

    1. Make them your custom icon with ADW or LP (easiest way)
    2. Install them over the apps you have on your phone to get your custom themed app
    3. Make a flashable zip to add the apps to system/app, resulting in a themed set of apps, now in system/app

    I should probably add a bit to the guide on making zips, yes? :eek: :D