[Guide] Begginers guide to theming android (Windows7)


  1. LDrifta

    LDrifta No Stranger 2 Danger Guide

    Index:
    a. welcome/goal
    b. tools/requirements
    c. preping

    I. basics

    II. user apk's

    III. system apk's
    a. awareness

    IV. Framework/SystemUI

    V. testing your product

    VI. ADB push/pull

    VII. Building a flashable zip

    ---------------------------------------------------
    a. Welcome & Goal

    ok guys this is just the basics i know of and how I do my theming, it's not 100% official but i get the job done!! :D

    the goal of this guide is to help out the girls/guys who want to make some changes of their own, or maybe learn more and start giving us some good themes :D

    ---------------------------------------------------
    b. Tools & Requirements

    this is a guide for windows 7 64/32-bit so tools & requirements are as well.. sorry im not a mac guy

    first your system will need to have java jdk 32-BIT installed!!! you can have 64 bit too but you NEED 32 bit for something

    now these are the tools:
    1. APKTool
    2. Android sdk
    3. Dsixda kitchen (cygwin or VM with lynux)
    4. Auto-sign batch file
    5. Gimp/photoshop for advanced image editing
    6. Notepad++
    7. 7Zip
    8. A LOT of patience

    Thank You justainchoe for the links :D

    ---------------------------------------------------
    c. Preparing for the ride of your life!!

    I personally consider this a requirement, KEEP a backup of all stock apk's your theming, i mean stock stock!! lol dont use one of my themes as a base or you will be fighting png errors the whole time lol

    now with that being said make sure all the tools listed above are installed and properly working :D

    ---------------------------------------------------
    I. Basics

    ok in any normal situation the easiest way to make a quick change to a theme is to open the apk with 7zip/winzip program, pull out the drawable folder containing your desired png/image files.. make your changes push em back in and boom your good to go :D i will explain below how to do this in detail..

    first...

    1. if you have 7zip installed you can just right-click the apk, highlight 7zip option and select 'open archive' option in secondary menu

    2.once you have the apk's contents in view, double-click the 'res' folder and you should see the res archive open up

    3.now depending on what your theming you'll want to pull out the 'drawable' folder or 'drawable-hdpi' folder (DO NOT edit ANYTHING in 'drawable-mdpi' folder because you wont do anything for your device lol)

    4. After extracting the desired folder, open it up and do your changes.. ( be careful if you manually edit some images you may have an issue with FC's so try to keep track of your edits)

    5. Once finished, push the folder with edits back into apk with 7zip and you are good to go :D

    Now for the more advanced stuff..

    Advertisement
  2. LDrifta

    LDrifta No Stranger 2 Danger Guide

    II. User-Apk's

    ok user apk's are apk's you can safely remove without corrupting your system, so 90% of them are what you download from the market.. the other 10% is stuff that comes on stock phones but are removable :D

    the reason these get a special chunk in the guide is because these apk's dont require a signature :D meaning you can edit them easily with the required tools

    of coarse you can do the basic edits with 7zip and image pushing, but you can also decompile these apk's and make font changes and ui changes like a smart person :D i will explain (as best as i can) how to do this below:

    WARNING: Use the Stock apk from Stock rom, DO NOT use themed rom as a base for decompiling apk's

    1. you will need apktool setup and a xml editor such as notepad++

    2. place the desired apk in same directory as your apktool files

    3. now open up cmd prompt and get yourself to the apktool directory as well

    Decompiling

    now to decompile the apk you want to edit.. type this:

    apktool d music.apk music

    music.apk is the apk your decompiling
    music is the folder you're creating for the decompiled apk

    now make your edits :D DO NOT Change/Edit ANY PNG's

    ------------------------------------------------------------------------------------------------------------
    Recompiling/Finished Product

    now to recompile your new apk type this:

    apktool b music music-new.apk


    music is the folder with your edited files
    music-new.apk is your new apk file :D

    Now we are NOT done... we cannot use the new apk's... we have to take what we did and add it back to the original apk file to keep proper signature :D

    use something like 7zip, take the 'resources.arcs' file and any other xml files you edited out of the "-new" apk and copy them into Original apk

    now the apk is ready to flash with your new changes :D :D


    III. System Apk's

    ok now here's the hard part :D

    system apk's is a very sensitive part of the rom so to decompile it you must first install the framework into your computers system!! after that than its basically as easy as editing user-apk's mentioned above, i will explain how to do this below:

    WARNING: Use the Stock apk from Stock rom, DO NOT use themed rom as a base for decompiling apk's

    Getting to CMD directory



    Open up a Cmd Prompt (terminal) and get to the 'apktool' directory ie:



    ------------------------------------------------------------------------------------------------------------
    Installing Framework


    Now that you are in directory we need to install the device's framework to your system for it to compile correctly so type this:


    apktool if framework-res.apk


    this will install the devices framework to your system (need to do this)

    ------------------------------------------------------------------------------------------------------------
    Decompiling


    now to decompile the apk you want to edit.. type this:


    apktool d music.apk music


    music.apk is the apk your decompiling
    music is the folder you're creating for the decompiled apk


    now make your edits :D DO NOT Change/Edit ANY PNG's

    ------------------------------------------------------------------------------------------------------------
    Recompiling/Finished Product

    now to recompile your new apk type this:


    apktool b music music-new.apk


    music is the folder with your edited files
    music-new.apk is your new apk file :D


    Now we are NOT done... we cannot use the new apk's... we have to take what we did and add it back to the original apk file to keep proper signature :D


    use something like 7zip, take the 'resources.arcs' file and any other xml files you edited out of the "-new" apk and copy them into Original apk


    now the apk is ready to flash with your new changes :D :D
    ------------------------------------------------------------------------------------------------------------

    Hope this helped some of you new themers out there!!!
  3. LDrifta

    LDrifta No Stranger 2 Danger Guide

    IV. Framework/SystemUI

    OK lol guys i made a section in here for these 2 apk's just for the people who dont really understand how the android system works.. i dont even fully understand it lol but basically these 2 apk's are where most of your work will be done, the good news is they are classified under system apk's :D so just follow steps above for theming advice lol

    just wanted to give out some warnings first

    1. If this is your first time, keeps your theming/edits to a minimum the first few times..

    Nothing sucks more than doing a whoooole bunch of work, then flashing to find yourself stuck in a boot loop lol

    2. ALWAYS use stock image files for decompile/recompiling these two apk's

    you can use the apk's from MT, PG and my roms to decompile, just be sure to switch out the themed images with stock before you decompile or you may have errors..

    if you decompile framework with battery mod (1-100%) do not delete those battery images, only replace the images you have stock copies of, dont just swap 'drawable-hdpi' folders lol


    V. Testing your product

    This is very important!!!!

    testing your poduct is KEY!!! never push out something your unsure of.. it's not nice to push out a brickme.zip lol

    there are a few different ways to do this, will deiscuss in next section. for now i just want to give you all some warnings and things to be cautios about

    1. MAIN thing, lol like mentioned above you dont want to give someone a zip file that will ruin their device..

    2. you want to be sure it works before you release it lol

    3. you want to realize how awesome you are before anyone else does!? lol

    k, now below are the 2 KNOWN methods of testing your own work :D
    Kajangist and dubtee like this.
  4. LDrifta

    LDrifta No Stranger 2 Danger Guide

  5. gbiggie

    gbiggie La patience et le pardon Guide

    A very nice start brother!
    Sleep is for sissies:rolleyes:
  6. HereticSins

    HereticSins Well-Known Member

    This is what we needed. :p
  7. justainchoe

    justainchoe Well-Known Member

    If I'm making changes to only the images in framework-res.apk, can I just unzip it to a folder, make the edits, copy the edited png files back into the apk and then push it back into the \system\framework folder?

    Also, I know I'm skipping ahead to part VII, but if I wanted to make my theme flashable, briefly, what is that process like? Is it as simple as just putting the new files into specific directories of a zip file, or do I need to decompile and recompile the files with signatures? OR is there something else I have to do?
  8. justainchoe

    justainchoe Well-Known Member

    I'm a FAILURE!! :(

    As my FIRST newbie attempt at theming, I just wanted to change 1 little thing to test if it works. Using Android Commander, I pulled the framework-res.apk file, I unzipped the framework-res.apk into a directory, opened a png file in gimp, edited the png, saved the png, dragged the png into the framework-res.apk file using winzip, and then I used Android Commander to push the framework-res.apk file back into place. FAIL! My background changed, everything is unstable, the icon I changed actually did change! SUCCESS!! :) But ahhh!! everything is freezing up and lagging, and.. Restoring..

    Ok, so all I tried to do is get rid of that ******ed GPS Privacy Icon. That stupid icon is on the notification bar all the time and it doesn't ever change and is completely useless to me. So I decided to edit the png so that it's just a completely transparent png. It'll still be there but you just can't see it. Pretty clever eh? Anyways..

    What thing(s) did I do wrong? And don't just reply with "everything." lol

    Someone help me. The png file is in the framework-res.apk file, and the location of the file is: \res\drawable-hdpi\stat_sys_gps_privacy.png.

    So, can someone teach me how to change that to become completely transparent and then push the mofo back into the my Android \system\framework\framework-res.apk.
  9. ShinySide

    ShinySide Disabled

    Everything! :p

    Just take a copy of your systemui, framework, settings and Res-cap. Then using 7zip or winrar extract the apk. Then change the icon and then open the apk as an archive with 7zip or winrar and copy the whole Res folder over to the archive. Then take one of Ldriftas or my theme zip files replace all the apks with yours then flash it. I don't use Android commander at all really.

    Sent from my LG-MS910 using Tapatalk 2 Beta-5
    justainchoe likes this.
  10. toke_

    toke_ Well-Known Member

    i cant find a stable download link to any of the required programs, i'd greatly appreciate it if you can link me up :D
    jzebrahockey likes this.
  11. justainchoe

    justainchoe Well-Known Member

  12. Williamw545

    Williamw545 Well-Known Member

  13. LDrifta

    LDrifta No Stranger 2 Danger Guide

  14. hvrc

    hvrc Well-Known Member

    im using windows xp :/

    soon will have 7 on a new laptop, soon
  15. LDrifta

    LDrifta No Stranger 2 Danger Guide

    you should be fine with xp... thats really just a warning for mac users to go buy an iphone and die somewhere hahaha im just kidding :D but xp should be fine!!
  16. hvrc

    hvrc Well-Known Member

    the pc im on now, well it blows donkey junk. half of the stuff wont run properly on this pc that i try to install.
  17. gbiggie

    gbiggie La patience et le pardon Guide

  18. justainchoe

    justainchoe Well-Known Member

    Forgot to thank you. It worked :) so basically, I just need that META-INF folder in the zip?
  19. LDrifta

    LDrifta No Stranger 2 Danger Guide

    yup! :D just that and a proper layout of folders for the system
  20. max25002

    max25002 Well-Known Member

    hey not tryin to bother but when will u finish this
  21. LDrifta

    LDrifta No Stranger 2 Danger Guide

    lol dood im sorry, i promise i will finish this within the next few days.. just been reall busy and trying to keep up with the oms so people dont freak lol thanks for the reminder man!!
  22. Curster

    Curster Well-Known Member

    I must be Uber Noob I don't even know how to install the apktool. I read that you need to unpack the two files in the windows directory but I can't seem to figure that out. Jesus I hope I can get the rest of it ,:\{)3
  23. max25002

    max25002 Well-Known Member

    alirght ur welcome man hope u finish fast am halfway done with all this just need the other part
  24. LDrifta

    LDrifta No Stranger 2 Danger Guide

    lol will start on it tonight :D
  25. HereticSins

    HereticSins Well-Known Member

    Aye ld. You know how to change pngs in a user app?

Share This Page