[Guide] [Theme] Port Any rom's framework style theme to stock or any ROM - Miscellaneous Android Development

Hello guys.
The guide is to port framework styles from a rom to a rom's framework.
Read the »»»»whole thread«««« carefully.
Things required....
#Hardly 10 minutes (If you not mess up)
#Cool and fresh mind + Environment (For this spread some water over your hair,It will make you cool)
#Knows Apk compiling and decompiling.
Lets come to the main topic without wasting any time.
This is the guide is to port any ROM's framework theme to stock or any ROM but if your ROM is cm based then port cm based ROM's framework or it can give fc's
STEPS.....
1) Decompile the two framework
One which you using now and one which you want to port.
2) Give your framework folder name as BASE. And your port framework as PORT.
3) Enter to res/values/
4) Copy styles.xml to your BASE framework in res/ values folder.
5) Do the same thing with other files in values folder except public.xml
6) You need to even copy the drawables from
drawable folders from PORT to BASE.
7) Compile your framework.
8) Check for the errors in apktool or any alternative and fix them one by one.
9) And hence your framework is complete.
«»«««»««»«««»Note.««««»»««««»»»
The frameworks should (Both PORT and BASE
should be of same android version.
You may need to copy layouts as they are needed
for some styles(if available).
Credits XDA member @san122 For the guide

Related

[MOD] Theme updater for Windows/Linux

Hi everyone,
Imagine that you are updating two or more themes for roms like OpenDesire/Defrost/CyanogenMod (I'm pretty sure that this updater works for every AOSP rom but I didn't try), that in one week can be updated at least 4 times. Don't get me wrong, the updates are appreciated, but updating all the themes for all the new versions gets old in no time.
So, I made myself two scripts, one that runs on Windows (this is the first one so is no so updated, but if I see that people use this I'll be willing to create a C# version) and another for linux (bash script), that do this work for me.
This scripts, decompile, copy the modded file (for the status battery), compile the framework again and then add the new images to the framework. After all that it generates the update.zip file for each mod so they can be flash using the recovery (Clockworkmod/Amon Ra/even the default recovery).
Windows Version 1.0
Linux Version 1.0
In the second post, I'll put instructions explaining how to configure the scripts.
Credits :
Brut.all for APKTool.
Daneshm90 for the APKManager (It give me the basic knowledge to create the first versions of the scripts).
Instructions :
Windows.-
If you want to update more than one mod at the same time, you need to edit the script.bat file and modify the "start:" seccion like this :
Code:
:Start
if "%jumpmod%"=="0" set mod=MOD1
if "%jumpmod%"=="1" set mod=MOD2
if "%jumpmod%"=="2" set mod=MOD3
if "%jumpmod%"=="3" set mod=MOD4
if "%jumpmod%"=="4" goto end
set jump=0
goto Create
In order for this to work you need to put the original framework-res.apk in the folder "original"
The mod files have to be in MOD/Images (images you add) and MOD/Xml (xml to recompile). Right now the script is only prepare to recompile the xml for the status battery.
If you add more than one mod, the folders name must be the same as in the start seccion (MOD1, MOD2, MOD3...)
You must have installed Java JRE
Once you configure the script, run it, wait for it to be done. Then go to the result folder and you will find the update.zip file/s.
Linux.-
If you want to update more than one mod at the same time, you need to add as much folders as mods you want in the mods folder. The new folders must have the same structure as the default one.
The mod folders contains one folder to put the images to add after the framework have been recompile (MODNAME/add/drawable-hdpi) and one folder for the file that are used to make the mod (MODNAME/mod/drawable for the XML and MODNAME/mod/drawable-hdpi for the necessary images).
In order for this to work you need to put the original framework-res.apk in the folder "original" or you can download the original Rom by using the script (it extracts the framework-res.apk from /system/framework/).
YOU MUST configure the variables within the script.sh to set the initial path of the script and the path to copy the resulting update.zip files.
In order for this to work you must be ROOT (This is because the apktool, if anyone have a workaround please let me know)
You must copy the following files to /usr/local/sbin/ for this to work :
Code:
/theme_updater/other/7za
/theme_updater/other/aapt
You must have installed openjdk
Windows.-
Version 1.0 - Initial release
Linux.-
Version 1.0 - Initial release
thanks Zeussn, it worked like a charm when i was using it yesterday

[GUIDE] Newbie's How To: Port Theme's

How To Port Theme's
(Using Apktool, and Theme Porter)
Since there are some people out there willing to learn but not exactly able to with all of the convoluted information on the forums, I decided I'd start putting together a guide similar to other's to aid those trying to learn. Stay tuned as this is under construction!
All credit is due to original creators of the product's used in this process, without them there wouldn't be a reason for this guide . Please be respectful of other's work, sometimes it's best to ask before attempting (if it is an original product) but at very least give credit and a link back.
What is porting?
Porting very basically is taking .png files and XML changes from one theme (typically created for a different model, but using the same resolution) and copying them into deodexed stock rom's such as EC10/EE19 Pick and Pack so that they can be flashed onto our phones and used with our framework and/or updated framework.
Sounds really easy, doesn't it? At first it will be cumbersome and frustrating, but after you've used the processes enough you will be able to snap these out in 30 minutes or less! The problem lies in the way these files are packaged, they are mainly just a .zip file that isn't compressed, however there is another layer to an .apk that you can only see once you've learned how to use tools such as apktool/apkmanager. The other tool we will use to aid us in this painstaking process is an application called Theme Porter, which essentially is a script that has been written that will do all of the legwork for us. Let's get started!
What will I need?
Apktool I currently use an older version of the program, you can download here, this one I know works for sure - last I heard the other has issues.
ThemePorter
7zip (Win rar could be used instead)
Notepad++ (Or equivalent code editing software) which will be used to make the xml changes. If you're not familiar with using something such as this, you may want to take time to research before attempting to port.
How to set up;
Begin by getting ThemePorter setup, you just need to unzip the download and that will be "theme porter" It is basically just made up of a few folders, and has a batch script that you will use to initiate the process. I just place mine on the desktop for easy access.
Secondly, get apktool downloaded and unzipped. place the apt folder somewhere where you can easily navigate to it through a command prompt. C: might be a good place if you want to save yourself some keystrokes.
Next just make sure you have notepad++ or another editor installed for use later.
Lastly, get 7zip installed so that you're able to open .apk and .zip files without actually extracting the files.
Where do I get my source files?
You can use any framework from any rom that can be decompiled correctly with apktool. This means when you decompile it, there are no errors and it generates a folder with the same name. Download the rom of your choice and save it (still zipped) somewhere on your desktop, and make an extra copy in case you mess up and overwrite the wrong files. You will ALWAYS use these in the NEW folder within theme porter, but we will get to that.
As for the theme you're trying to port, I usually use fascinate theme's, because it is basically a direct copy of our phone (Note: As of 2.2 they now have a Data on/off icon in their status pull down, where we have Silence, so this will often need to be taken care of separate from this process.) I've also recently started using Vibrant theme's, as these are also very similar - but there are tweaks with these too and I will try to cover them in the guide at some point. You may find others that will work too, at this point this is all I've had time to mess with. Either way, download the .ZIP file and also place it somewhere easy to access.
This is where it get's sort of difficult.
Stock ROM's have some differences to theme's that theme porter cannot handle for you. These are basically MOD's that may exist in the theme ROM and/or XML changes that have been made to alter text color's to accommodate the theme (black to white, white to black, etc.) These changes WILL NOT be ported over using theme porter and unfortunately also cannot be made AFTER using theme porter, so there is a certain process to go about this.
Now enter's apktool. Apktool is a script brut.all very kindly wrote to assist android developers in decompiling/recompiling .apk files without losing structure that normal compression software breaks. Basically there are two reasons you will need to take this step.
When;
Editing Text Color- When choosing a theme to port you will need to pay attention to the screenshots the original poster has posted, as these will clue you in whether or not this needs to happen.
The Pick and Pack rom is essentially still stock, as far as XML goes - so the text on menu's for example, will be Black text on a white background. If the theme you chose has something different, you will need to take this step so that the text is legible in the final theme.
Adding accurate battery MOD- Also when choosing a theme you will need to take a look at the framework-res.apk file to determine if the themer has added the accurate battery mod. Essentially all this means is the XML and image's have been edited to show you each percentage of battery life vs. the stock one that only shows odd increments of 10/15/20.
Open framework-res.apk with 7zip
Navigate to res/drawable-hdpi (this also may be drawable-hdpi-v4 depending on your theme, I haven't quite figured out why this is)
Scroll down until you see the status_battery icons near the bottom - if there are not images for every percentage - then no mod exist's and you can skip using apktool for this step.
How;
For either change you will follow this process to decompile To gain access to the XML/PNG files that contain these text values, we will need to decompile the framework-res.apk file from the rom.
Copy framework-res.apk from the rom and place in the APT folder created earlier.
Rename this to something shorter such as "FW.apk" for easier command lines
Start a command prompt (in windows 7 type "cmd" in the search bar within start menu)
Navigate to the APT folder, For example;
Code:
CD c:\Users\brandon\Desktop\apt
Type
Code:
apktool d FW.apk
This will decompile the .apk into a folder called FW within the APT folder, allowing you access to the files. I will cover the actual changes in a later post.
At this point you have the files in a folder and they can be edited how you see fit (should you choose to just edit the stock ones vs. actually porting already changed ones).
You'll notice when examining the folder that there are quite a bit more files. Also, you will be introduced to the .9.png file type, which essentially is just a .png file that has some black lines embedded in the file to instruct android how to resize and reuse the image within the framework.
Any edits made to these files must be made carefully, as to not alter the integrity of these black lines. When the file is recompiled, the lines will disappear but will be included (if you tried doing this without decompiling - your photo editor would nix these lines and android wouldn't know how to size them)
If all your edits were complete, you would then recompile the file through apktool. (I will continue with the theme porting guide in the next step, this is just a good reference point for these steps.)
Type this into the command prompt
Code:
apktool b FW framework-res.apk
This would then create the framework-res.apk file in the APT folder, however there is an important step here. During this process the META folder is lost, and the AndroidManifest file is corrupted.
Delete the AndroidManifest.xml file from the new framework-res.apk
Copy the META-INF folder and the AndroidManfiest.xml file from the ORIGINAL framework-res.apk (now named FW.apk in this example) and place it in the new framework-res.apk using 7zip (do not extract the file, open the archive with 7zip.)
At this point, your framework could be ready for replacing in your theme.zip (will be covered later) with the edit's you've made Or if you're learning how to port theme's, continue reading.
Guide Part 2....
Preparing for Theme Porter
Okay now that we have some of the side process out of the way, let's get back to the guide.
Determine if you need to make any XML edit's for battery or text color changes and perform them per the processes detailed below. If you do not need to make them, you may skip this step completely and move on to using theme porter.
Correcting Accurate Battery Mod Animations-
Follow this guide to make the changes to the framework to use the new charging animation images and will allow you to then use theme porter to swap the .png files
Decompile the framework-res.apk from the ROM download (I usually just rename this to EE19.apk or whatever the rom is i'm working with)
Decompile the framework-res.apk (I first rename the framework-res.apk file to NEW.apk (or whatever you wish) Note: It will typcially give you errors (unless it's theme'd correctly) but you're just after some code from a few .xml files so don't worry.
In the NEW folder Navigate to
Code:
\res\drawable-hdpi\
or
\res\drawable-hdpi-v4\
Copy all of the battery charging .png's and drag them to a folder on your desktop. Then open the EE19 folder within APT (the one you decompiled from the rom you're working from) Drag those images into the /res/drawable-hdpi-v4 directory replacing any existing ones.
open the following file in notepad++
Code:
\apt\NEW\res\drawable\stat_sys_battery_charge.xml
Also open the same file within the EE19 decompiled folder
In the THEME xml file select all and copy
In the EE19 xml file, paste this replacing the text. Then save it overwriting the original.
At this point, the battery mod is done and the new .png files exist so that theme porter can do it's work (And the xml is there to make it works when it get's to your phone). If you don't have any text edits to make, you can recompile the apk (as stated in steps in first post) and move on to steps below (skipping the section on changing text).
Changing text colors-
If you have determined that the text in the theme is different from the rom framework (I.E. Text on notifications, menu's, etc.) then you will follow these steps to locate where these changes need to be made.
If you haven't already, decompile the framework-res.apk from the Rom.
Next, determine what text color edit's you need to make and then use this wonderful reference to determine which actual files those edit's correspond to.
Locate the file you need to edit in the decompiled folder, and open it with 7zip.
Typically removing the "inverse" reference on the color line will change it from black to white, or white to black and is the easiest/best way to alter colors in a ROM. (For a quick note, searching for "menu" in the styles.xml files located in /values/ will give you the items you need to change, watch for _bright references for the dividers, change those to _dark instead.
Once you are done making these edits, recompile the folder as stated in first post. And move on to using theme porter.
Using Theme Porter-PAY CLOSE ATTENTION HERE.
Now that you have the appropriate prep-work done, the easy part finally comes. (Hopefully)
Copy and paste the applications & framework-res.apk twframework-res.apk files from the THEME.zip into the appropriate folders within the OLD folder in theme porter.
Now copy and paste the same files that you copied from the theme.zip, now from the rom (EE19 for example) to the NEW folder in theme porter.
Once all files are in appropriate folders, run the Script.bat file in theme porter. Use a selection of "1" and press enter.
Theme porter will now copy all of the .png files from one .apk to the other (where the folder names are an exact match)
NOTE:At this step, you may have issues where the images aren't brought over (This typically only effects the framework files and just depends on how the file was generated/edited). This can be detrmined by opening the .apk in 7zip and pulling out the res folder, where you can view the files (you will see if it's been changed or not) If it hasn't, you will need to make sure the folder within the Themed .apk's are the exact same as the ROM you're themeing and re-run the theme porter script. (meaning you need to add or remove the -v4 ending depending on where the previous themer placed the themed files)
If you're lucky, everything is done at this point and you can move on to packaging a flashable update.zip.
Packaging A Flashable Update.Zip
A flashable package is simply a .zip file (stored as "store" in 7zip, no compression) that is made up of META-INF and System folders. The META-INF folder is very important as there is a big difference between using one from a ROM (pick and pick) and a theme (NeonGT) You will need to download a theme and pull the META-INF folder out so that you can use it in your theme ports. This is to ensure you have the correct script (edify or ammend) typically now we're using edify so use one from one of the H57 theme's via baked_tator The system folder should contain two folders "framework" and "app" each of which will hold the respective .apk files you have been working with. (but could also contain a "Media" folder for changing bootanimation.zip files, basically any files within the folder structure you create (matches the system structure) will be replaced when flashed. So be careful not to include things I haven't listed here unless you know what you're doing. And be sure to test these things before even thinking about a release.
Create the following folder that can be re-used with any new theme port, it's the easiest way to keep things organized and not lose track of files.
Create a new folder on your desktop called New Theme
Within that folder paste in the META-INF folder from another EE19 theme.
Create a new folder called "system"
Open system and create two new folders "app" and "framework" (and "media" if you are including the bootanimation.zip from the theme (which typically will work on our phone)
Place approprate files from the NEW folder within theme porter into these folders, respectively
Back up so that you see the META-INF folder and System folder, select those two, right-click and select "add to archive" in the 7zip menu.
Name the file "EE19 ThemeName VX.zip" and select "Store" for the method
Drag this to your desktop and this will be what you will place on your SD card for flashing.
Test the theme thoroughly to make sure everything ported over and everything still works (make sure to test USB, even color XML edits can cause odd issues) and get help from others to make sure the bugs are out.
If you run into issues, check the next post for possible resolutions.
BE SURE TO CREDIT THE PROPER CREATORS!!! I can't express this enough, I have a format for the way I do release posts, feel free to copy it if you'd like but either way make sure you make it known that it's not your work!
FAQ / Common Issues / Other Resources
Common Issues:
Images do not transfer to new framework.apk files.
(typically the applications all have the same folder names, so no problems occur here.)
As stated in the guide, all folders within each res folder within each .apk file used in theme porter must have exact matching folders/files for the .png to actually transfer. If it's been edited with apktool, it typically has the -v4 extension.
Troubleshoot your issue by opening the resulting .apk file in 7zip and comparing to the downloaded theme file in 7zip. You may have to pull the res folders out and look that way to actually see which images didn't transfer.
First thing to check is the folder names within the res folder, if the rom folder's names are "drawable-hdpi" and "drawable-land-hdpi" and the theme has "drawable-hdp-v4" then you need to remove the -v4 from those folders and run theme porter again.
NOTE: I've also run into situations where both folder's existed in the .apk file, meaning both drawable-hdpi and drawable-hdpi-v4 folders were there, but only one actually had the themed .pngs. In this case it was the drawable-hdpi folder that had the themed ones, but I needed it to be -v4, so I deleted the existing -v4 folders and renamed the others to -v4 - this also slimmed the rom because you really don't need the extra folders/files (nor wan't them!)
Some times icons don't exist on other phones, or they are completely different icons. I.E. with 2.2 fascinate theme's the Silence icon does not exist and therefore would need to be pulled from another theme or created to be fixed. This can be done with 7zip, no need to decompile the file if you're just swapping .png files (in the final framework-res.apk .
[*]Problems after testing theme.
This has happened to me on all sorts of levels;
Problems Restoring - Sometimes after testing theme's you'll go to restore and things will not be right when you boot, FC's and whatnot. Best case scenario you can restore to a vanilla restore (meaning your rom + any app's you wanted, but no theme's) or just flash your rom to fix.
Problems with icon's not being correct on a restore or a flash.
Same as above, sometimes things just go awry when you're flashing theme on top of theme, so i'ts best to start from the rom. Make a restore point with your rom + all your apps, then you can always go back to it and flash your day to day theme - this will give you the least trouble.
Phone stuck in airplane mode, setting is disabled.
I had this happen to me randomly once, no idea why but if you do run into this the only thing that fixed it for me was an odin back to a full build. No restore or flash would fix it. Typically your problem should be solved with a fresh flash of your rom, but sometimes going to a full build with odin is the only way.
FAQ:
Post them and we'll get them answered and edited in here. So far I've tried to cover everything I knew of in the guide .
Reserved
Reserved
Reserved
Other Resourcs:
Great guide by nitsuj17 on how to theme
Hex Colors
Free Photoshop Alternative
XML Color Edit Guide - in case you missed it above - credits to KBanause
wow, you rock bde. thanks for your time and help with this, I will be following it to help you guys out with stuff more.
Sent from my SCH-I500 using Tapatalk
sageDieu said:
wow, you rock bde. thanks for your time and help with this, I will be following it to help you guys out with stuff more.
Sent from my SCH-I500 using Tapatalk
Click to expand...
Click to collapse
Great, and thanks, I'm glad to share what I've learned with the community
Great write up,ive read through it several times. Just wish I hadn't traded my desktop for tattoo work this weekend. ..
Sent from my SCH-I500 using Tapatalk
man you write some good tutorials...
Very thorough and still easy to understand, Great work!!
Very nice! Just fixed the white on white text in my super light port. Big Thanks!
Great write up!
So, I tried using apktool to decompile the framwork-res.apk and it worked fine, recompiled it and everything was good, are these the same steps I would use for other APK's such as in the apps folder (i.e. Settings.apk) because I cannot get them to work I keep getting brut.androlib errors
bwot75 said:
So, I tried using apktool to decompile the framwork-res.apk and it worked fine, recompiled it and everything was good, are these the same steps I would use for other APK's such as in the apps folder (i.e. Settings.apk) because I cannot get them to work I keep getting brut.androlib errors
Click to expand...
Click to collapse
Usually if you get errors in compiling there have been things added or removed after compiling, this is sometimes caused by using theme porter for example.
Apktool works on any apk, but i'ts fussy about what's there before it recompiles. Try decompiling and recompiling with no changes, if it doesn't work then it won't work on that .apk (to my knowledge). You basically will always need to start with one of the deodexed apks from phidelt's pick and pack, then add changes while i'ts decompiled, then run theme porter after it's recompiled if needed.
And glad you all appreciate it
I vote sticky on this how-to...very good write up and it makes my life easier!!!
Definitely sticky
Sent from my SCH-I500 using XDA App
Thanks for the good reading bde. great tutorial.
Hey thanks, glad to share the wealth
Sent from my SCH-I500 using XDA Premium App
I followed this guide and made XML editing for Framework-res.apk to change font colour in the Menu using Notepad++, but after xml edit, cant build the framework.apk, it says sources have changed and does not build the apk. Am using apktool for this. Any suggestions how to go about it. Or somebody can guide, how can I change the menu background so that Menu texts are visible?
trip007in said:
I followed this guide and made XML editing for Framework-res.apk to change font colour in the Menu using Notepad++, but after xml edit, cant build the framework.apk, it says sources have changed and does not build the apk. Am using apktool for this. Any suggestions how to go about it. Or somebody can guide, how can I change the menu background so that Menu texts are visible?
Click to expand...
Click to collapse
As stated in an above post, try decompiling the framework-res.apk you are working with - without any edits and see if it will recompile with no error. If it doesn't then re-read my guide
Ok thanks will check it.
Never mind, I figured it out.
Sent from my SCH-I500 using XDA App
I did some major fixin' on the OP, hope it's more clear!

[GUIDE] Creating a localized SGH-T959V ROM

Hi everyone
I was getting some queries from Arabic, Vietnamese, Portuguese, Turkish and other languages speakers who wish to have their own loacalized SGH-T959V ROM.
So, here is what we did on HebrewValhalla ROM (Gingerbread BML) :
1. We took Valhalla Final as a basic ROM to be translated.
2. We found an SGS i9000 ROM already localized to the language we want.
3. We decompiled all Valhalla Final necessary APKs to be translated.
4. We decompiled all SGS i9000 necessary APKs to take their translations.
5. We recompiled all Valhalla Final APKs with the the new translations.
6. Pushed one APK at a time with language locality selected. verified and moved on. Finally did it for framework-res and chose language.
7. Minor adjustments, packing and publication.
Explanations :
1. First decide what is your ROM to be translated. download it and save it on a PC.
2. Find and download an SGS i9000 localized ROM. If there isn't such you're in trouble.
3. Download APKTOOL read this. Define the base ROM framework according to instructions and decompile all necessary APKs. save them all locally.
4. In a separate folder use another instance of APKTOOL and define the SGS i9000 ROM framework and decompile the corresponding APKs.
5. Find out what is your language 2 chars lang code (English=EN, Hebrew=IW).
Take out all the APKs Resource\values-XX and layout-XX and place them in the destination ROM corresponding APKs resources. for example :
SGSi9000ROM\APKTOOL\Projects\Camera\Resources\Values-XX should be copied to
ValFnl\APKTOOL\Projects\Camera\Resources\Values-XX
Compile all these APKs (take them from "modded apk") and remove the "signed" from the filenames.
6. Install a locality app like "MoreLocale2" with your selected or manually added language (for Hebrew it was IW, Hebrew) and check your APKs translations.
Once you finish compiling framework-res (and push it to framework folder - preferably through flashable zip or ADB) it will have your language inside and you could uninstall the locality app and choose it in the settings.
This will give you full framework UI support.
7.Take all files and put them in the original ROM location.
A) list of needed APKs on BML ROMs can be found here :
Need to take translations to
system apps:
AccountAndSyncSettings
Browser
Contacts
JobManager
MediaProvider
PackageInstaller
PhoneSetupWizard
SamsungApps
SamsungAppsUNA
SamsungWidget_ProgramMonitor
Settings
SnsAccount
SystemUI
TouchWizCalculator
TSMParts
TW4Launcher
Phone
Camera
TouchWiz30Launcher
TouchWizCalendar
Mms
framework:
framework-res.apk
Working directly from SGSi9000
system apps :
Talk
Street
ClockPackage
Music
Gallery3D
MusicPlayer
VideoPlayer
VoiceRecorder
MyFiles
AxT9IME
CallSetting
DialerTabActivity
Email
Gmail
Memo
B) Most of APKs are in system\app but for full UI you also need to handle the Framework\framework-res.apk
C) If you want to add tweaks and stuff : study how to make recovery flashables - search the web and examine tweaks and bootanimations and how their commands are written.
Now you can install your localized ROM.
Good luck!
(P.S - it took us 2 people about 10 days to release the first version).
Right to left languages (Arabic, Hebrew...) will additionally require RTL tweak - read this
You may need to also copy the fonts from SGS i9000 ROM.
Great
Oh great, man...I'm very pleased helping you with vietnamese yay (just tell me what to do ...and thanx for including Vietnamese :x
I just did...
Please follow instructions very carefully, ask me if you don't understand anything and do it yourself according to the GUIDE.
okay, I'll try my best to start something the next two week (have to finish the next exam week @@)...thanx for your guil...oooh and btw, can you give me any basic links as google is very wide that I don't know where to start with build.prop or framework lines...
You're running too fast. Work according to this with a lot of trial and error and then carry on by searching the xda forums. 99.99% of your questions were probably already asked and answered.
Sent from my SGH-T959V using XDA
By the way, even if there is no SGS i9000 ROM for your lanhuage you can still create the translated strings XMLs, it will just take you much much longer. Probably will need to spread the work with other teammates.
Sent from my SGH-T959V using xda premium
Hi Guys
This method is good for translating ICS ROMs as well.
I use it for HebMIUI.
The only thing changed is the version of APKtool to use and the system and framework apps to translate - this is a post I just sent Mataflikas :
Hi Amigo
To be able to translate Erik's MIUI ROM to Spanish,
What you need to do is go to miuiandroid site and download the SGS i9000 Spanish MIUI ROM.
Than download Erik's ROM. Download APKmanager/ APKtool for ICS and aapt ver. 1.5.0 and place aapt in the 'other' folder of apktool in your pc.
Now you need to copy framework-res.apk & framework-miui-res.apk from the Spanish ROM to the 'other' folder. Register both framework files by running in command line '..\other\apktool if framework-res.apk'
& '\other\apktool if framework-miui-res.apk'. Copy all system\app APKs as well as both framework files to the 'files to be modified' folder.
run the apktool batch script.
Decompile all the apks by selecting (option 22) & decompiling (9) one at a time.
Now go to each apk project folder (located in the projects folder) and enter the 'res' (resources) folder. I assume 'es' is the shortcut for Spanish locale - verigy that!
You need to take all the 'values-es', 'layout-es', 'raw-es' etc. These are the Spanish translations. Now repeat this for all the apks. Make a saparated apktool folder for Erik's ROM, register his own frameworks and decompile the same apks there. When you're done, throw every apk translation to the 'res' folder of the same app in Erik's ROM. When done, run script on Erik's and select (22) and compile (11) is this a system app? Choose YES, let me delete only changed data? Choose YES. Then it will make a 'keep' folder, go there and delete 'resources.arsc' file. Press any key and you have a new file 'unsignedAPKNAME' in the 'files to be modified' folder. Done with all apks you can replace them in the ROM zip and try to flash it. If framework-miui-res.apk is not valid you will enter a bootloop so leave it for the end. I didn't even recompile it on HebMIUI. Last things - you can change default locale & region in system\build.prop and change your gps location by changing the system\etc\gps.conf to the one of your country (google it). Good luck and let me know if you have a question.
And If you want to publish your result - talk to Erik first !
sent from me
The complete detailed guide for enabling Hebrew and RTL on CM7/CM9/AOKP based ROMs

[TW][MOD][PORT] MIUI 5 Icons for TW + link to guide.

This stuff comes from SGS3 and some CSC messing, but here it is:
http://forum.xda-developers.com/showthread.php?t=2263939
And here is what i acheived:
http://forum.xda-developers.com/showpost.php?p=45193128&postcount=73
All work is done by decompiling apk, removing all the xml and pictures, placing those back, recompiling.
After regeration of public.xml - you can generate CSCAppResource.xml.
At least we got icon theming in touchwiz.
Look for my port here:
http://www.mediafire.com/?diffphafc33t4iv
this is not a CWM package! unzip to /system/csc/appresource/ (if you don't have folder appresource - then create it)

[Tool] Theme Porter(Optima Team)

THEME PORTER
hey guys i have ported a couple apps from similar devices to mine. One of the main problems is finding missing
libs. And when you go to theme apps like you want to make your systemui look like xperia, you never know what png images you can replace.
I made a small script that will build a list of what you have then you have the option to choose wether you want to delete files with the same name(if you are finding missing libs) or only keep files with the same name
(if you are finding png images to replace you stock ones)
HOW TO
1. Run The exe
2. Copy the base zip or apk in the base folder
3. Copy the port zip or apk in the port folder
4. click ok
5. select whether you want to remove files with same name (for lib or rom porting) or only keep files with same name(for png/theme porting)
6. wait for process to complete
WARNING THIS PROGRAM CAN DELETE FILES AND FOLDER WITHOUT GOING THREW RECYCLE BIN
WHATS TO COME
Next build will clean up empty folders leaving it easier to read​
USING THEME PORTER TO THEME SYSTEMUI OR FRAMEWORK-RES
THINGS YOU NEED
# WinRAR
# Theme Porter
How To
1. Run Theme Porter.exe
2. Copy the Base SystemUI to Base folder
3. Copy Port SystemUI to Port folder
4. Click OK
5. Click on Only Keep Files With Same Name
6. Open Base SystemUI.apk with WinRAR
7. Replace png images in each folder
8. push to your device
VIDEO
Reserve
USING THEME PORTER TO PORT OEM APPS
THINGS YOU NEED
# WinRAR
# Theme Porter
How To
1. Run Theme Porter.exe
2. Copy the Base Rom to Base folder
3. Copy Port RomI to Port folder
4. Click OK
5. Click on Remove Files With Same Name
6. Open Base Rom with WinRAR
7. Copy all libs from Port folder to Base Roms lib folder
8. Copy permissions from port folder to Base Roms permissions folder
9. Copy framework from port folder to Base Roms framework folder
10. Copy the apps you want to port to Base Roms app folder(priv-app folder)
11. Push to device and flash
VIDEO
I used this when first trying to port areffects to my Galaxy Tab 3 10.1 and it worked like a charm​
thanks for the tool
Just one doubt, im trying to port xperia Z systemui to stock Xperia L
In this case which will be base and which will be port?
Will try
Is possible porting all the system UI and launcher from huawei p8 marshmallow to oneplus one cm13? I am interested in emui 4.0.
I want to replace the UI and look of Lenovo P2's stock Android 7 rom with that of Custom rom (Resurrection Remix or AOSP Extended) made for this device. I just want to relace the look and feel of the stock lenovo factory rom with the Custom roms looks. Can I use your method to achieve this?
If not, can you guide me on this?

Categories

Resources