I'm trying to make a battery meter for my rooted Inspire. I downloaded a battery meter to use as a guide template for mine. I have made all the icons and set up my folders exactly the same as the template. I opened the xml file and replaced all the fields with my own information so they are basically the same as the template. When I try to unzip and use it in metamorph, it says that it's not a valid theme file. Can anyone tell me what I'm doing wrong? I've never done this before so I'm trying to learn all I can. I'm not familiar with xml. Is it not ok to just copy the code and change the info? Thanks in advance.
Ok well I'm starting to see my problem isn't editing the xml tags...but the last part of the code, where it's asking for the .apk you're editing and the path. How do I find that information?
Related
I'm wondering how easy it is to replace the names of program launchers. I would like to rename programs in the menu from something like "alarmclock beta 1.0 supa" to something shorter like "alarm clock". Obviously this is just an example. How easy would it be to do this? Is it a simple edit of an xml file or would a full recompile be necessary.
Thanks.
Well I'm not sure about on here. I'm gussing it is stored inside the APK file. I know on the iPhone you just edit a .plist file inside the .app. After a quick look inside the APK file none of the XMLs are editable for me they are just jibberish. Sorry I couldn't help more...
I've been opening up framework-res.apk as a zip file and changing around icons for my status bar with other themes. I just replaced the signal bars icons and the 3G icons, repackaged the framework into a zip file, and applied it via rom manager. No Icon change. I've been able to replace several before, any ideas why it wouldn't work now? I reopened the file and verified the icons had been changed.
The icons you are looking for are in com.htc.resources.apk
If you have something specifically you want changed I can tell you where it is located and what the filename is. I am building some theme tutorial videos because I had a hard time finding all of this information. I want to make it easier for others. I remember all the way back in June when I got frustrated finding what files went where. I am making a list to help others out, let me know what you are looking for.
[email protected] said:
The icons you are looking for are in com.htc.resources.apk
If you have something specifically you want changed I can tell you where it is located and what the filename is. I am building some theme tutorial videos because I had a hard time finding all of this information. I want to make it easier for others. I remember all the way back in June when I got frustrated finding what files went where. I am making a list to help others out, let me know what you are looking for.
Click to expand...
Click to collapse
Subscribed!
Sent from my ADR6300 using XDA App
subscribed as well, a video with some info would be great. I am definitely no developer, but not afraid to mess around a bit. I was also interested in making similar changes as OP.
In fact I am using Jerick's smooth sense mod with white letter mod by squintz, and a couple of the icons were coming up out of order. I was not cool enough to be able to repair the info that points to an icon so I found the icons in framework-res.apk and changed the names of them so that I would get the correct icon in status bar. But obvously that is not the correct fix. However this is where the icons OP is talking about. So if I can make a name change to a png can't you also replace that png. I believe that the apk has to be signed correctly after manipulating?
Anyways any basic info about doing such would be greatly appreciated
spjoneser said:
subscribed as well, a video with some info would be great. I am definitely no developer, but not afraid to mess around a bit. I was also interested in making similar changes as OP.
In fact I am using Jerick's smooth sense mod with white letter mod by squintz, and a couple of the icons were coming up out of order. I was not cool enough to be able to repair the info that points to an icon so I found the icons in framework-res.apk and changed the names of them so that I would get the correct icon in status bar. But obvously that is not the correct fix. However this is where the icons OP is talking about. So if I can make a name change to a png can't you also replace that png. I believe that the apk has to be signed correctly after manipulating?
Anyways any basic info about doing such would be greatly appreciated
Click to expand...
Click to collapse
You don't need to resign the apk unless you completely extract it. Then good luck trying to get a system apk to work. Just open the archive and replace needed imgs then update the archive and you're done. All depends on what os your using. Linux makes it easy to edit apks without extracting. In win you have to rename to .zip then do line I said then rename back to .apk
Sent from my ADR6300 using XDA App
Which files specifically are the signal meter? I just want to change those ones back to the stock icons.
jskolm said:
Which files specifically are the signal meter? I just want to change those ones back to the stock icons.
Click to expand...
Click to collapse
I can tell you later (i dont have the dump on hand) but the signal meter pngs are located in com.htc.resources.apk under /res/drawlablehdpi/ thay have a name like sys_status_cdma1 or something like that. I think if you get that far the images might jump out at you. If you want the exact ones I can tell you when I get back from work.
[email protected] said:
I can tell you later (i dont have the dump on hand) but the signal meter pngs are located in com.htc.resources.apk under /res/drawlablehdpi/ thay have a name like sys_status_cdma1 or something like that. I think if you get that far the images might jump out at you. If you want the exact ones I can tell you when I get back from work.
Click to expand...
Click to collapse
Found them. Thanks for the direction. I was looking through the folders and I couldn't find them, because they are transparent backgrounds, so the white on white blended right in. I changed out the signals for the ones I wanted and everything looks like its working now.
Thanks for your help!
I've been a long time reader and I've learned quite a bit today on Android and its applications. I've been trying to recompile a modified Protips.apk and have it successfully run on my D1. I've been unsuccessful, and would like some pointers on where to looks next.
I'm intrigued by the modified Home Screen Tips widget as seen on Cyanogen and BuglessBeast. I figured I could do it too since it seems rather simple.
I pulled Protips.apk from my D1, archived it somewhere else, and ran apktools to decompile the app. I found that in: res/values/arrays.xml there's all the code I need to start changing text. I wanted to do something basic like Hello World as a test, so I slightly changed the first item to read Hello World! on the first line. So I edited the .xml file and considered the job done.
I recompiled my modified contents using apktools, and pushed the apk to my phone. It didn't show up in the widgets menu, so I figured I needed to sign the thing.
First I tried copying the META-INF data from the original APK into the new one, and though the you could apply the widget to the homescreen, it'd error. "Problem loading widget." Next I took the original manifest and popped it into the new APK. Same thing.
I thought I could try singing the modded APK myself. After recompiling I ran the APK through Auto-Sign. It still errors.
Someone mentioned that if you're modifying XML files, the resources.arsc file should be removed "prior to recompiling." I'm lost at this point, since when you decompile with apktools, you don't have access to that resource. If you remove it from the final apk, the app doesn't show up in the widgets menu.
I'm trying to figure out where I'm going wrong. Surely it has to be something rather simple.
------------------
Resolved
Decided to give Apk Manager a try. Decompiled the APK, edited the arrays.xml file, Compiled (deleting resources.arsc where instructed in the keep folder), signed the app, then pushed it to my phone. It works. I'll attempt the process using apktools again now that I have a working mod.
derik001 said:
I've been a long time reader and I've learned quite a bit today on Android and its applications. I've been trying to recompile a modified Protips.apk and have it successfully run on my D1. I've been unsuccessful, and would like some pointers on where to looks next.
I'm intrigued by the modified Home Screen Tips widget as seen on Cyanogen and BuglessBeast. I figured I could do it too since it seems rather simple.
I pulled Protips.apk from my D1, archived it somewhere else, and ran apktools to decompile the app. I found that in: res/values/arrays.xml there's all the code I need to start changing text. I wanted to do something basic like Hello World as a test, so I slightly changed the first item to read Hello World! on the first line. So I edited the .xml file and considered the job done.
I recompiled my modified contents using apktools, and pushed the apk to my phone. It didn't show up in the widgets menu, so I figured I needed to sign the thing.
First I tried copying the META-INF data from the original APK into the new one, and though the you could apply the widget to the homescreen, it'd error. "Problem loading widget." Next I took the original manifest and popped it into the new APK. Same thing.
I thought I could try singing the modded APK myself. After recompiling I ran the APK through Auto-Sign. It still errors.
Someone mentioned that if you're modifying XML files, the resources.arsc file should be removed "prior to recompiling." I'm lost at this point, since when you decompile with apktools, you don't have access to that resource. If you remove it from the final apk, the app doesn't show up in the widgets menu.
I'm trying to figure out where I'm going wrong. Surely it has to be something rather simple.
------------------
Resolved
Decided to give Apk Manager a try. Decompiled the APK, edited the arrays.xml file, Compiled (deleting resources.arsc where instructed in the keep folder), signed the app, then pushed it to my phone. It works. I'll attempt the process using apktools again now that I have a working mod.
Click to expand...
Click to collapse
Using apktool you must sign after other wise it won't install... I had issues using it to do a status bar mod.. Wondering if I can just sign it using that apkmanager and have it work... I used a kitchen to sign mine and it didn't sign right...
Alright, I am going to try and make this guide as easy to follow as possible for the 1000x people who requested it, lol...
Before starting there is a few things you are going to need/should have:
apk manager...
text editor...
General Idea with How to Work a Computer/Follow Directions
Since we are going to be editing xml's, you have to use apk manager... Hopefully you have some basic knowledge with this "program", since it takes a little getting used to.. If not though, i will try and make this as painless as possible
First, open up apk manager and decompile (9) the framework-res.apk of your choosing.. You can unzip my gingerbread theme and use that framework-res, or any other one that you can find
Now, go to the projects folder, and navigate to "framework-res.apk\res\layout".. This is where, as the name implies, all the layouts for the ticker are placed... They are in xml format, so you can easily use notepad or such...
The XML that we are looking for in order to change the color is "standbymode.xml". Open it up in your text editor... Don't be intimidated, i know it looks confusing lol.. We are only messing with a little part...
Navigate down to the 13th line, aka "<TextView android:textSize="@dimen/time.text.size"... This is where the phone gets its information about the size, font, and color for the Time!
Scroll through that line until you come across android:textColor="blah"... As you can guess the Hex Value within the quotes is the color the clock is! Right now it is ffeaff00, but we can very easily change that
All you have to do now is by googling "Hex value for purple" or whatever color you want, find the hex value that you want to use The code should be exactly six letters/numbers, no more and no less... Now, copy that hex value, and replace the old code from "ff" on! Do not erase those first two letters, because that is telling the phone what transparency value to use, and we would like to keep it fully visible
Easy Enough, right? The hard part is now done!
All we have to do now is recompile the apk, which can be tricky if you don't know what your doing..
P.S if you know how to do this, you are done! I would still scan over these steps though, just to make sure you are doing it right
To compile in apk manager, just type 11! if you get a compile error, then you did something wrong That shouldn't happen though, this is a relatively easy mod....
Wait a while until you get a "Is this a system apk?" message... type "y".... then type y again for the next message... Now do what it says!
Don't forget to delete the "resources.arsc" file, and the "standbymode.xml" file!
Now you are done!! Just replace that framework using whatever method you use, Whether that be with adb when the phone is in recovery, or by replacing the new modified apk with the original within a zip file already made by me
If you make your own, don't be stingy.. Upload it to XDA or whatever, and share it with the community I will put it up on the front page, and give you the credit Make sure though you share with me what kind of framework-res.apk it is, and where you got as in, if you got it from my gingerbread package, or from my stock 2.2 Accurate theme, or Reboot Options, or any other option
fantastic guide! thank you for this!
but im just wondering one thing, why dont you have a donate button for all the hard work you have been giving to the continuum community? hmmm
Trail, is there any code we can get to that's worth modding that's in Java? If so, I can start doing some development.
Sent from my SCH-I400 using XDA App
http://www.mediafire.com/?ajjo09hwxejqsl0
I added my own outlined orange softkeys, and and orange ticker color.
and a few things to the lockscreen text for the lulz
Also I failed to mention that it's based on your accurate gingerbread theme.
Thank you Jakeschweinz for sharing with the community I shall put this in the main mod Thread, and make it easy for everyone to find it And i'll be sure to let you have all the credit
Thanks again!
just a quick link to help you guys out with color
http://html-color-codes.info/
and here's my baby blue clock color
http://dl.dropbox.com/u/30842475/framework-res.apk
6FCAF5 <---- if anybody wants to know the color code for it,
And thanks again Trailblazer for this Guide.
You tricky bugger you figured it out without me lol..
Nice job!
So I'm kinda new to doing this, and I saw the upload that someone has on there for mediafire, and I was wondering, do you just download that, or do you put it in the .apk manager and change it?
This guide is very soon going to be outdated
Sent from my SCH-I400 using xda premium
Hey guys, question is kind of simple. I've been editing my frame work and system apks. Last night I finally figured out how to properly decompile the apks so the apktool creates the .yml file. What my question is, ive edited the framework apk and added more png files to it then edited the xml files except public. What is the easiest way to set the hex ids for the png files? I read recompiling would do it but I didn't have time to try it. Would that work or is there another way?
Sent from my htc evo
Just adding pngs cannot add hex ids to public.xml while recompiling
The pngs should be registered first
e.g: If I want to add 1% battery mod then I will register those pngs in status_battery.xml and then add the pngs and then hex ids are addded automatically.
Anyways what are you trying to do?
Burned from my laser torch using pencil cells
Theming my phone using uot kitchen files from a bunch of different mods on there, so basically I downloaded all the kitchen files I liked then took out the images from each I wanted and combined them into one. After that I also edited my own version of headphones using adobe ps and created a fully working and smooth sync animation. Ive already edited the drawable.xml file and added the animation xmls to the appropriate folders. The only thing I need left is do I have to manually add the hex ids in the value folder or does the recompile do that for me?
Sent from my htc evo
Ok so I figured out how to properly theme but for some reason the animations for wifi in range and sync aren't working. This it's what I did from looking at someone elses mod on uot. Created the xml files and placed them into the res/drawable folder. Added the png files to drawable-hpdi folder and changed the original wifi_in range name to a zero at the end. For sync_anim0, made that a 1. So now the xml files I created reflect the png names starting with those two. Is there anything else I need to do?
Sent from my PC36100 using xda premium