[Q] Title Bar removal - Android Apps and Games

How do I remove the gray title bar for my app in the xml file for layout?
I cannot find anything I understand, doesn't error, or at least does not require a re-write of too much code.
thanks to anyone with this answer.

LuvinAndroid said:
How do I remove the gray title bar for my app in the xml file for layout?
I cannot find anything I understand, doesn't error, or at least does not require a re-write of too much code.
thanks to anyone with this answer.
Click to expand...
Click to collapse
The title bat background is determined by what is in the ROM's framework-res.apk, not the individual app.
Go to framework-res.apk/drawable-hdpi and replace the activity_title_bar.9 and bottom_bar.9 with the one's you like. Remember, these are .9 files, broken files may give you FCs.

In your AndroidManifest.xml add:
Code:
android:theme="@android:style/Theme.NoTitleBar"
To the <activty ...> tag
Example:
Code:
<activity android:name=".Foo"
android:theme="@android:style/Theme.NoTitleBar" />

ah, thanks guys, the xml file edit was the one that woked for me.
On another note, I am playing around with the SkellyAPP to learn the pricnipals behind Java/Android structures.
How would I load in an image NOT loaded by the xml but one loaded in that I can re-assign placement based on random numbers so I can wrap my head around a "main loop" with action going on.
Sorry for my noobishness, but I learn by taking baby steps and I promise not to spam the forum with too much trivial stuff

Related

Assigning identities to files in values/public.xml within framework-res.apk

So I'm making some edits to the framework-res.apk, adding new graphics files. When I compile them, APK Manager is not assigning identities to the files within public.xml.
How do I assign these identities? Looks like they're in hex....
Sent from my little black box using XDA App
This Rom is awesome!!! Been 4 days without a charge!!
Sent from my PC36100 using XDA App
kbizzle said:
This Rom is awesome!!! Been 4 days without a charge!!
Sent from my PC36100 using XDA App
Click to expand...
Click to collapse
Yea, it's pretty sweet. Thanks OP.
BTW, is there a Themes forum I could ask for help in? I really want to theme this ROM.
kbizzle said:
This Rom is awesome!!! Been 4 days without a charge!!
Sent from my PC36100 using XDA App
Click to expand...
Click to collapse
roflmao !!!! !
sirmx said:
Yea, it's pretty sweet. Thanks OP.
BTW, is there a Themes forum I could ask for help in? I really want to theme this ROM.
Click to expand...
Click to collapse
I heard the theme forum is for questions about this Rom. I suggest putting your theme in the "general" forum.
Sent from my PC36100 using XDA App
MadDogMaddux said:
So I'm making some edits to the framework-res.apk, adding new graphics files. When I compile them, APK Manager is not assigning identities to the files within public.xml.
How do I assign these identities? Looks like they're in hex....
Sent from my little black box using XDA App
Click to expand...
Click to collapse
The way I do it is I think about what I'm gong to post and if there is a question mark anywhere in there I don't post it in the development section. The whole site is supposed to be for devs so there is no need to seek out this section to ask question.
Since I've spent a good portion of my day so far messing with that dmnd framework-res.apk I guess I'll share what I've found...
http://forum.xda-developers.com/showpost.php?p=7380557&postcount=68
Brut.all said:
Don't do that! I think I should explain the purpose of public.xml file in the project wiki, because many people are confused. Note that you don't need this file when you build an apk from sources and apktool building mechanisms are very similar, so guess what: you could remove this file from decoded application and apktool will rebuild it without any problems. I had a reason why to generate public.xml - it's a feature, not a bug! ;-)
Well, the reason is: there may be references to resources in the application code. If resources ids will change after build, then code will reference different resources than in original apk. public.xml file gives us sureness that resources will get same ids after build - it's the only one reason to use this file. And you want to manually modify these ids ;-)
Adding or removing new resources is somewhat tricky. Yeah, I should write about that in the wiki.
You could remove any line from public.xml (even making a "hole" in the ids) at any moment, but you must be sure, that resource isn't referenced in the code.
There is never much sense in modifying ids in public.xml, because then modified lines lose their purpose.
If you want to add new resources, e.g. drawables and use them in the XML files - you don't have to change anything in the public.xml file.
If you want to add new resources and use them in your code, then you have to add them into public.xml, because you need to reference them somehow. Or you could use Resources.getIdentifier() method, but this is ugly.
And now the most tricky part: if you want to remove some resources, you have to remove info about them from public.xml as well. So first you have to be sure that they aren't referenced in the code. But there is also this "hole" problem, so:
If these resources are at the end of ids stack, then there is no problem.
If resources are near the end of ids stack and you are sure, that all resources after them aren't referenced in the code as well, then you could just remove them all. Actually you have did virtually the same, cause after modifying ids you made these lines totally useless, you broke them, so you could just remove them.
If you want to remove some resources, but add same or greater quantity of new ones (of the same type), then there is no problem - new resources will automatically fill in "holes" in ids. You don't have to add them to public.xml .
If none of above conditions are met, then you have holes and you have to fill them by something. But you don't have to add "useless .pngs" - just add:
Code:
<item type="drawable" name="DUMMY1" />
<item type="drawable" name="DUMMY2" />
<item type="drawable" name="DUMMY3" />
...
Like above, you don't have to add these resources to the public.xml .
Ufff... that's all
Click to expand...
Click to collapse
Also see...
http://forum.xda-developers.com/showthread.php?t=671883
Thanks for not being a douche, Xhausx!
Sent from my little black box using XDA App

XML Marker and Metamorph

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?

Themed Calendar

I really didn't like that wooden calendar and it's colors, so I changed it a little bit.
There is only one color that I couldn't find. (picture number 2)
Special Thanks to biopsin for helping me to build this,
and thanks to cheatman for looking in to it.
If you want to try it, just download the zip file and flash it via recovery.
Does anyone know why I can't change those colors?
Hey guy,
I'm sorry but I can't help you. But i like your app. Please don't give up!
odysseus84 said:
Hey guy,
I'm sorry but I can't help you. But i like your app. Please don't give up!
Click to expand...
Click to collapse
I'm trying, but I haven't found a way to edit that xml. I don't have any problem
with other xmls but this one... I don't know what's wrong.
Looks like some great work there mate. As for your odd xml file problem, I'm not sure there's much you can do. I've had problems like that with a couple of apk's and I've never found a reliable fix. Sorry
Decompile the apk using apktool or apkmanager .... n den edit the xml....n compile agn
Sent from my GT-P1000 using XDA Premium App
agc93 said:
Looks like some great work there mate. As for your odd xml file problem, I'm not sure there's much you can do. I've had problems like that with a couple of apk's and I've never found a reliable fix. Sorry
Click to expand...
Click to collapse
Yeah, I've had this problem before with a framework.
Thats a nice theme. The wooden calendar wasnt really bad, but your theme makes it really nice!
I realy like your theme. The contacts.apk and the phone.apk are "woody ugly" too. Would you theme theese apps too?
Can you post your said XML alone as an attachment (the already modified and original)? I'd like to take a look at it.
As some resources (files in the /res folder) are shared between apps through the framework, changing anything shared might result in an inconsistency and FC the app.
A workaround might be to completely decompile the framework as a dependency and modify it there. It would result in a more dramatic change, but it would cross over to other apps such as the contacts, dialer and calendar simultaneously.
PS: this also applies to the browser, email app, contacts and so on, depending on what you change.
cheatman said:
completely decompile the framework as a dependency and modify it there.
Click to expand...
Click to collapse
but How?
by using what software?
I face similar issue and tried with apktool and apkmanager with no hope.
Would u give me a hand?
odysseus84 said:
I realy like your theme. The contacts.apk and the phone.apk are "woody ugly" too. Would you theme theese apps too?
Click to expand...
Click to collapse
I've already woked on both of them, you can find them in Themes and Apps section.
cheatman said:
Can you post your said XML alone as an attachment (the already modified and original)? I'd like to take a look at it.
As some resources (files in the /res folder) are shared between apps through the framework, changing anything shared might result in an inconsistency and FC the app.
A workaround might be to completely decompile the framework as a dependency and modify it there. It would result in a more dramatic change, but it would cross over to other apps such as the contacts, dialer and calendar simultaneously.
PS: this also applies to the browser, email app, contacts and so on, depending on what you change.
Click to expand...
Click to collapse
So there are lots of things that should be checked.
I uploded the xml here. There are 3 colors in this xml and I can't change any of
them. The xml is in layout folder and there is another xml with the same name in
layout-land folder. I've tried working on this one as well but the result is the
same as the other one.
Anyway, thanks for looking in to it, mate.
sohrab1985 said:
I've already woked on both of them, you can find them in Themes and Apps section.
Click to expand...
Click to collapse
Yes, i know that. They are nice but they don't look as good as the calendar (cause blue). Maybe you can change the colours to a few dark colours like your calendar (it's perfect for Meizu's Dark Theme)
What ever is come... thanks for your work
Sent from my GT-P1000 using Tapatalk
odysseus84 said:
Yes, i know that. They are nice but they don't look as good as the calendar (cause blue). Maybe you can change the colours to a few dark colours like your calendar (it's perfect for Meizu's Dark Theme)
What ever is come... thanks for your work
Sent from my GT-P1000 using Tapatalk
Click to expand...
Click to collapse
I see what I can do.
Ok, in the XML I can see you have three variations of brown/orange. Judging by the colors, I suspect this is the default XML, before editing it.
The colors are #ffbe801d, #ffede3c2 and #ff503200. What values are you trying to set instead of these? What I mean is, how EXACTLY are you replacing the actual text in the XML:
#ffbe801d becomes: ???
#ffede3c2 becomes: ???
#ff503200 becomes: ???
This is important as the color representation is not the basic HEX code encountered in regular web dev (for example). It's a 16-bit hex representation with alpha. The first two elements (ff) stand for 100% opacity.
C.
cheatman said:
Ok, in the XML I can see you have three variations of brown/orange. Judging by the colors, I suspect this is the default XML, before editing it.
The colors are #ffbe801d, #ffede3c2 and #ff503200. What values are you trying to set instead of these? What I mean is, how EXACTLY are you replacing the actual text in the XML:
#ffbe801d becomes: ???
#ffede3c2 becomes: ???
#ff503200 becomes: ???
This is important as the color representation is not the basic HEX code encountered in regular web dev (for example). It's a 16-bit hex representation with alpha. The first two elements (ff) stand for 100% opacity.
C.
Click to expand...
Click to collapse
Yeah, that's right, this is the default xml.
I edit the xml same as other xmls which I edit without any problem, I just open
the xml in a text file and change the value I want to edit and then I save it and
after that I compile it with Apk Manager.
I just want to change them to something like gray, for example I want to change
#ffbe801d to #ff787878 and #ffede3c2 to #ffbcbcbc. It dosen't matter if they
are not exactly these colors, like I said before I just want to make them gray
For the third one, I don't think it changes those two colors that I want to change.
Btw, thanks for helping.
Well, I've looked into it and I can:
1. Fully Decompile the APK. It doesn't need any shared resources from external packages.
2. Edit the XMLs accordingly. I have also seen that you were very thorough in your theme creation process.
It's all good apparently, however, I am unable to recompile everything back. The APK tool reports some missing resources. For some reason, there is a dependency that is not satisfied, although the package decompiles correctly (I have never seen a similar package before).
I'll have to scour some Google documentation before I'll come up with a relevant result, so it may take a while. I'm not gonna let it fly, though. The entire process should be plain smooth and must be doable anyway.
Hi
I have no issues bulding the calendar. If u send me your edited files i can try build it for you..also chech if apktool is up to date, using older ver. will hand out errors..
Edit
Tested these colors
#ffbe801d becomes: ff6090bf
#ffede3c2 becomes: ff9198b1
#ff503200 becomes: ff001d50
ref. : http://www.color-hex.com/
and it builded ok
Sent from my GT-P1000 using XDA Premium App
cheatman said:
Well, I've looked into it and I can:
1. Fully Decompile the APK. It doesn't need any shared resources from external packages.
2. Edit the XMLs accordingly. I have also seen that you were very thorough in your theme creation process.
It's all good apparently, however, I am unable to recompile everything back. The APK tool reports some missing resources. For some reason, there is a dependency that is not satisfied, although the package decompiles correctly (I have never seen a similar package before).
I'll have to scour some Google documentation before I'll come up with a relevant result, so it may take a while. I'm not gonna let it fly, though. The entire process should be plain smooth and must be doable anyway.
Click to expand...
Click to collapse
I'm sorry for putting you throurgh all of this, it's not really a big deal, mate.

[Guide]Change the Ticker Clock Color!

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

Brightness slider in notification bar pull down?

This thread talks about the ability to add the brightness slider to the pull down notification area by doing the following mod in SystemUI.apk:
Open res/layout/tw_status_bar_expanded.xml and removing the android:visibility="gone" from the following line:
Code:
<LinearLayout android:orientation="horizontal" android:focusable="true" android:visibility="gone" android:clickable="true" android:layout_width="fill_parent" android:layout_height="56.0dip">
Well, Ninjamorph cannot handle this task since you need to decompile tw_status_bar_expanded.xml to edit that code line, so if anyone could use my attached already highly modded SystemUI.apk (it has a toggle edits, GPS icon removed, battery icons) and decompile, edit the code line, recompile and repost, I would much appreciate it.
Thanks in advance!
Lock-N-Load said:
This thread talks about the ability to add the brightness slider to the pull down notification area by doing the following mod in SystemUI.apk:
Open res/layout/tw_status_bar_expanded.xml and removing the android:visibility="gone" from the following line:
Code:
<LinearLayout android:orientation="horizontal" android:focusable="true" android:visibility="gone" android:clickable="true" android:layout_width="fill_parent" android:layout_height="56.0dip">
Well, Ninjamorph cannot handle this task since you need to decompile tw_status_bar_expanded.xml to edit that code line, so if anyone could use my attached already highly modded SystemUI.apk (it has a toggle edits, GPS icon removed, battery icons) and decompile, edit the code line, recompile and repost, I would much appreciate it.
Thanks in advance!
Click to expand...
Click to collapse
This should work. There were 2 errors while de-compiling regarding your e911 cross hair images. No errors on building though so should be ok.
mastamoon said:
This should work. There were 2 errors while de-compiling regarding your e911 cross hair images. No errors on building though so should be ok.
Click to expand...
Click to collapse
Thanks.. I will try it out and report back. Likely, the errors were the fact that the 2 GPS crosshair images were deleted that stops those annoying crosshairs from showing up
UPDATE: so... yes the 2 errors were the missing png files for the GPS icon. I could fix that easy though with Ninjamorph.
Now, you got the brightness slider in place BUT it does not work it doesn't do anything. I don't blame this on you so no worries as it seems to mean that some other additinal edit needs to be made as this just put the slider in place BUT does not actually activate it's function. So.. kinda worthless sadly
Lock-N-Load said:
UPDATE: so... yes the 2 errors were the missing png files for the GPS icon. I could fix that easy though with Ninjamorph.
Now, you got the brightness slider in place BUT it does not work it doesn't do anything. I don't blame this on you so no worries as it seems to mean that some other additinal edit needs to be made as this just put the slider in place BUT does not actually activate it's function. So.. kinda worthless sadly
Click to expand...
Click to collapse
Half way there
mastamoon said:
Half way there
Click to expand...
Click to collapse
true that.. but I dont know the other half and it would no doubt require deeper edited code to make the slider actually do something
oh well, thanks for the help as I did not expect this would be the outcome.
Lock-N-Load said:
true that.. but I dont know the other half and it would no doubt require deeper edited code to make the slider actually do something
oh well, thanks for the help as I did not expect this would be the outcome.
Click to expand...
Click to collapse
Yeah it looks like the Power Widget edits are what actually do the stuff that slider is requesting. Unfortunately I don't have time to do much smali'ing now, but maybe somebody can finish it up for you. Or in reverse, take a completed one and move your images over to it.
mastamoon said:
Yeah it looks like the Power Widget edits are what actually do the stuff that slider is requesting. Unfortunately I don't have time to do much smali'ing now, but maybe somebody can finish it up for you. Or in reverse, take a completed one and move your images over to it.
Click to expand...
Click to collapse
agreed 100%. I would have to carry over my battery images and the GPS cross hair mod - which I can do with Ninjamorph easy - but then I need to use whatever toggle setup comes in the completed one that has the brightness slider and I rather like the ones I got.
So, for now, I guess I will just sit tight on what I have.
If you like your current toggles, it's only a matter of swapping out the images of lidroid.
Sent from my SCH-I535

Categories

Resources