[Sony Xperia S, Acro S, Ion] funky0308:
Hi guys....

In this thread I'll try to learn you HOW TO MOD framework, settings (backgrounds, icons, colors) and how to use APKtool.

update 05/10/2013 !!!

O.K guys I found for you few excellent guides and tutorials.

Like always, post your questions here and we'll try to solve it together.

Update Zip creator/modifier

Great tool on windows to create and edit elements of updates zips

ADW Themes

If you want to create AWD themes - great tutorial...

I've got many PM from guys who want to theme their apps but dont't know where to look and what to modified so....read this.

this is a excellent way to find out where to look and what to edit.

Wanna learn more about XML files?

Well , here we go...

What is an XML?

Wikipedia link to learn and understand general things and facts about XML files.

you will need:

1) A computer

2) The app you want to edit

3) Latest Java Development Kit (JDK) (Download and Install with default settings Java

4) Notepad++ Notepad++

5) The Framework-res.apk and SemcGenericResUxp.apk from /system/framework

6) ZipSigner (for signe your apps) ZipSigner

So let's start...

Download APKtool from here Click me

Copy/extract APKtool to C:\Android\APK

Copy framework-res.apk and SemcGenericResUxp.apk from your system/framework folder to C:\Android\APK

and follow this tutorial to set your environment so we could proceed "Click me"

So, you set environment and we could proced ; (you'll have to do that from above only one time ;))

*** FIRST ONE ***

1. How to change settings background to white (or to use light theme - to be precise):

We'll start with this:

And end with this:

First copy settings.apk to C:\Android\APK

open cmd prompt ("SHIFT"+right click on empty space and select open command window here

...and write this to decompile settings.apk

apktool d settings.apk

Close cmd window and open newly created folder "settings" (it's in the C:\Android\APK)

Open \settings\res\values\styles.xml (open it with Notepad++)

You'll see this :

So..we have to add ".Light" to our style.xml file(to activate/select white theme) and we MUST change color to our fonts/text

to white (I guess it would be hard to read white text on white backgroung).

We will add ".Light" in every theme style and add ff000000 to set our text to black.

For example - on the left side is black settings and on the right is what we need - compare those two styles.xml.

You'll notice that I add word ".Light" to change this part/style to use light/white theme - we'll do that for every style in this file.

And the most important is third line on selected text - #ff000000.

With "#ff000000" we are telling our device to use black colour for text.

It's not hard at all....just continue to read.

You'll get all when you compare your style.xml to this one:

Here is complete style.xml , download it and compare this one with yours.

Just open both files and add ".Light" and "#ff000000" to every stile you see I've change.

https://app.box.com/s/ezd4k68li6g6f1mqp8u2

After you change all style in style.xml it's time for recompiling.

Again, open cmd prompt ("SHIFT"+right click) and write :

apktool b settings (without ".apk")

If you did all like you should you won't get any error.

Now open c:\Android\APK\dist

and you'll see settings.apk.

Copy it to your device

Wait......

It's not finished :)

As settings.apk is system app we have to sign it.

Open ZipSigner on your device and :

1.click "Choose In/Out...." - find and select your settings.apk (the one you just copied)

2.click "Key/mode": select "platform"

3.click "Sign The File"

........wait......

...and that's it, now just find your newly MODed and signed file and simple install it like any other app. :)

Next tutorial : how to change solid background colour to show your picture (any picture) in "calls" "email" "settings" clock" - MOD framework-res.apk....

Something like this:

Or even this...hahaha

update 05/10/2013 !!!

edit .9.png file correctly!

Remember, decompile apk and then edit .9.png files!

If you open the .9.png 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 ;)

How to edit smali files!

This is for advanced users or developers.

I'm still learning and trying to understand smali files so I won't trying to get smart ...

I'll share one great thread (TUTORIAL) and we could learn together.

tnx to [MENTION=2863152]Yorzua[/MENTION] for this awesome tutorial.

...and do awesome things like this :

SMALI editing TUTORIAL

Another nice tutorial for smali editing (beginners friendly)

SMALI editing TUTORIAL for beginners

I put this to the end of this thread purposely - editing or even understanding smali files isn't simple.

So go one step by step, don't try to edit smali files immediately after you learned how to decompile apk file - you'll failed and probably quit from any other MODing, theming or editing.

All great developers spent hours and hours to learn all this so you can't expect you'll know everything after 15min.

You'll get errors while compiling and decompiling and that"s perfectly normal, don't get angry...

Read what apktool "said" , fix your mistakes and move on.

It's very important to go step by step , especially when you trying to find bug.

Fix or edit line by line and compile after each part, compile and test app.

That's all for now guys...

see ya later

..............................................................

Tnx to: [MENTION=599722]niaboc79[/MENTION] (for tips and learning me some tricks) [MENTION=5097981]abo hani[/MENTION] (I used his settings.apk for screenshots) [MENTION=3964321]Xda F[/MENTION]or many stuff

If I helped you - say tnx ...:thumbup:

if you need help...well just ask here ;)