help making/undoing transparent/translucent button effects - Hero CDMA Q&A, Help & Troubleshooting

Hi Guys
How do you make buttons have a transparent look? I have seen both some mods and roms that have made the sense launcher/navbar buttons transparent and or translucent. I have contacted the creators of the mods and roms and asked how they accomplished their effects but my requests for help have gone unanswered.
I imagine that the effects are made possible by an entery in one of the xml files I just don't know which files I should be looking at and what to be looking for inside those files.
Help would be greatly appreciated.

You need to find the PNG files that you want to change and create them so that they are transparent.
As an example, /system/framework/com.htc.resources.apk has a file called "lockscreen_arc.png. *see attached* It is semi-transparent (when viewed in photoshop).
What little I know how to do I learned from THIS, a few questions answered by JsChiSurf and some fearlessness to dig in and hope my nandroid saved me.

kelmar13 said:
You need to find the PNG files that you want to change and create them so that they are transparent.
As an example, /system/framework/com.htc.resources.apk has a file called "lockscreen_arc.png. *see attached* It is semi-transparent (when viewed in photoshop).
What little I know how to do I learned from THIS, a few questions answered by JsChiSurf and some fearlessness to dig in and hope my nandroid saved me.
Click to expand...
Click to collapse
So you are saying that it is the image itself that is transparent or translucent and not an attribute somewhere in one of the xml files?
What I am trying to do is actually undo the transparency/translucency of a an image. I figured it might be the result of an xml attribute since upon replacing the image with one of my own nothing changed (now I may not have replaced the correct image, this is always a possibility)

dsMA said:
So you are saying that it is the image itself that is transparent or translucent and not an attribute somewhere in one of the xml files?
What I am trying to do is actually undo the transparency/translucency of a an image. I figured it might be the result of an xml attribute since upon replacing the image with one of my own nothing changed (now I may not have replaced the correct image, this is always a possibility)
Click to expand...
Click to collapse
Well it can actually be done both ways some are controled by the image itself adn some are controlled my xml.

nfinitefx45 said:
Well it can actually be done both ways some are controled by the image itself adn some are controlled my xml.
Click to expand...
Click to collapse
If it is controlled by xml do you know what files I should be looking at and what inside the files I should be looking for?
Note this is for the laucher/navbar buttons in particular the ones found in konirosie (but I imagine any help could be applied generally)

I am just learning the editing of xml's myself, so I can really help much, this is a question that should be directed to JsChiSurf. That man is the expert on editing the xml's and could probably guide you to what you are looking for.

Related

cant find certain files (for a theme)

i cant find the background for "all programs" in both list view and grid... does anyone know where they are located? preferable grid
and also the background for the all programs header.. i cant seem to find that either!
thanks!
edit*
let me add the background for the smaller people widget i cant find that either lol
maybe no one knows and thats why these arnt changed in other themes? lol
No, I've searched it myself and can't find an answer.
oh thanks for trying!
i wanted to change the background of the programs list also, never found the corresponding image file. please let us know if you find it.
Not sure if i understood this correctly but background for grid view in Launcher ? have a look at pattern_carbon_fiber_dark.png in drawable. Don't use rosie anymore, insteaded i swapped Launcher.apk with advanceLauncher.apk found in the dream section.
fwers said:
Not sure if i understood this correctly but background for grid view in Launcher ? have a look at pattern_carbon_fiber_dark.png in drawable. Don't use rosie anymore, insteaded i swapped Launcher.apk with advanceLauncher.apk found in the dream section.
Click to expand...
Click to collapse
this seems to be the right file for the android stock launcher, since we are talking about rosie/sense launcher this doesn't help... thanks for the hint though.
xsirhc6x said:
and also the background for the all programs header.. i cant seem to find that either!
Click to expand...
Click to collapse
this might be all_programs_header_title.9.png. at least the name suggests it
afaik you can't just alter these *.9.png files, but you'd need to look that up if it doesn't work.
kendong2 said:
this might be all_programs_header_title.9.png. at least the name suggests it
afaik you can't just alter these *.9.png files, but you'd need to look that up if it doesn't work.
Click to expand...
Click to collapse
thanks everyone! maybe il put together a list of where everything is...
and well im not sure but for anyone else who doesnt bother editing .9.png, i find that if the file covers a whole box (like a header) instead of covering part of a box(like bottom rosie buttons) then you can easily change colour by:
(using photoshop)
- create new layer on top of image
- paint it what ever colour
- right click the layer and bring down the transparency so you can see the detail
... this has never given me problems

help editing png files

ive been having some trouble editing the .png files from the Facebook.apk.....
all im trying to do is replace the widget background png but it keeps sizing it wrong once its changed...
I am guessing this has to do with the fact that it's a .9.png but ive messed with it in draw9patch and i just cant seem to make it work
Are you compiling your .9's?
Had exactly the same problem, tried exactly the same solution
It turns out that the all draw9patch tool does is adding 1 pixel wide black stripes that define which area is resizable and which is fixed plus it shows you a preview. But you can as well do this in normal graphic editing program. The real magic happens when you compile a project containing png's with these black bars: the image is cropped from 1 pixel border containing the extra bars and necessary information is stored in the image itself.
I don't know if there even is a method of converting only the png's without setting up an entire development environment, so reading on how to do that might be a good starting point. Note that you don't need any fancy programming skills here, just compiling some simple example app should do the trick if you add your png's to it. Can't give you any details on the process since it's still something i have to try myself
Or is there a simpler way - just running the png's trough the compiler without actually setting up a project?
ffff00 said:
Are you compiling your .9's?
Click to expand...
Click to collapse
no i wasn't .. and obviously that was my problem.. got it all sorted out now though

[HELP] Landscape Framework Elements

Big question. When you rotate the phone, the status bar background (in themes like Darkness, with a design) gets messed up because it's shaped for our screen and not a small piece that gets tiled like the original. Can you make a landscape version of the background? I noticed in TouchWiz30Launcher.apk there is a homescreen_icon_bg.png and homescreen_icon_bg_h.png the latter being for a horizontal orientation of the launcher. Can we apply this concept to a custom made portrait AND landscape drawer background in twframework-res.apk? I would really like to know if it is possible, but am not asking for the creation of the background. I can make my own, but I need to know how to make it work.
I think you have to create a layout-land and layout-port folder and put something in there. Hopefully someone else will chime in.
A simpler idea might be to modify status_bar_expanded.xml to have multiple images for the background and bottom bar, like 3 where the center is fixed and the outer 2 are tiled matched up to look seamless of course. Or just allow certain parts to be stretched and some not with draw9patch.
CuriousTech said:
I think you have to create a layout-land and layout-port folder and put something in there. Hopefully someone else will chime in.
A simpler idea might be to modify status_bar_expanded.xml to have multiple images for the background and bottom bar, like 3 where the center is fixed and the outer 2 are tiled matched up to look seamless of course. Or just allow certain parts to be stretched and some not with draw9patch.
Click to expand...
Click to collapse
Thanks a lot for your post, I looked into status_bar_expanded but couldn't find anything applicable. Looked at status_bar.xml and it contains all the info on status_bar_background in the vertical position. How would you put it all into horizontal? Would you have to edit the existing xml or make a new one in layout-land? Could I just copy it into layout-land and edit in some new filenames and stuff?
EDIT: You know how to signify a file it says @drawable/statusbar_background? Does this actually refer to status_bar_background.9.png? And how would you signify a drawlable-land destination? @drawable-land/statusbar_background?
That's mostly what I don't understand yet. In framework-res there are 3 folders:
layout
layout-land
layout-port
icon_menu_layout.xml is in land and port and not in just layout. I think because layout is default for both, and land or port is used for those modes if the file doesn't exist in layout. Just like an xml in drawable can replace an image if the same name is used. But I think there's more to it than that. I tried creating a layout-land and layout-port and moved status_bar_expanded.xml to both and it looked normal both ways. I would think that layout-land would automatically use the drawable-land images too. Something else is missing.
EDIT: Oh yes @drawable/statusbar_background is the png in drawable-hdpi, unless there's actually a drawable/statusbar_background.xml which would make it use that instead. I just don't know where drawable-land-hdpi fits in.
Inside the XML there is a "vertical" and "horizontal" section, you'd have to change that too. I have changed it and will try it tonight in my framework. I just don't understand the references it makes too well...
I've been trying to find a simple reference, but I guess most of it's here:
http://developer.android.com/guide/topics/ui/layout-objects.html
Or around that area of the docs. The vertical/horizontal I think is the alignment of objects in a group. I don't think it has to do with land/port.
This looks interesting too. I just found it. It looks like a way to view layouts on the computer.
http://developer.android.com/guide/developing/tools/hierarchy-viewer.html
CuriousTech said:
I've been trying to find a simple reference, but I guess most of it's here:
http://developer.android.com/guide/topics/ui/layout-objects.html
Or around that area of the docs. The vertical/horizontal I think is the alignment of objects in a group. I don't think it has to do with land/port.
This looks interesting too. I just found it. It looks like a way to view layouts on the computer.
http://developer.android.com/guide/developing/tools/hierarchy-viewer.html
Click to expand...
Click to collapse
I honestly don't know what that stuff means with a headache, so I can't understand what the links refer to, sorry
It's all really disorganized or I'm just used to Microsoft docs. The xml corelates with the android classes for coding java. So xml is used sort of like html tables where everything is nested so you can have rows or collumns of buttons (horiz/vert) or menus or whatever, but the elements used are all the members of the android class. It's just so hard to find the meaning of each one.
CuriousTech said:
It's all really disorganized or I'm just used to Microsoft docs. The xml corelates with the android classes for coding java. So xml is used sort of like html tables where everything is nested so you can have rows or collumns of buttons (horiz/vert) or menus or whatever, but the elements used are all the members of the android class. It's just so hard to find the meaning of each one.
Click to expand...
Click to collapse
Crap 10char

[Q] Help with resolving mis-aligned text.

Another user on this forum is having an issue with mis-alligned text. Originally they felt it was an issue with malformed .9.pngs, but I have replaced all the pngs in the framework with stock pngs and the issue is still ongoing.
Question I have is what controls the text alignment (an xml in framework? or elsewhere such as services.jar)
I have recently learned how to theme the Andoid OS. I understand how to de-compile an apk, make xml edits (color edits using word pad), re-compile the apk. (replace the android-manifest and meta folders from the recompiled apk with the originals).
I know how run baksmali on services.jar make the appropriate edit to change the clock color. (as far as the services.jar, That is truely all I know).
I would like like to help this person, but need a sense of direction as to where to begin looking to fix.
Any and all help regarding this would be greatly appreciated.
Below is a link to the original thread they posted with screen shots of the mis-aligned text.
http://forum.xda-developers.com/showthread.php?t=991105
Update:
Had him test another framework-res.apk and services.jar file from another rom and he still has the same results with mis-aligned text.
Where else should I look?
This is truely out of my realm, but I am always interested in learning, so I would like to see if I can come to the resolution.

[Q] How to remove the left and right margins from stock mms?

Hello all! I have been making some UI changes to the stock Mms.apk app on my Nexus S. Nothing huge, just a few tweaks. I have been trying to figure out how or where to remove the left and right margins on messages in the message list. I would like each message to span the width of the entire screen. I have decompiled the the apk and I'm not sure where this can be edited. I am using APK Manager 4.9. I have looked in every file that references "MessageListItem" in its title.
Any ideas? Please and thank you!
See the attached image for what margins I am talking about. The margins are highlighted in red.
pixelswim said:
Hello all! I have been making some UI changes to the stock Mms.apk app on my Nexus S. Nothing huge, just a few tweaks. I have been trying to figure out how or where to remove the left and right margins on messages in the message list. I would like each message to span the width of the entire screen. I have decompiled the the apk and I'm not sure where this can be edited. I am using APK Manager 4.9. I have looked in every file that references "MessageListItem" in its title.
Any ideas? Please and thank you!
See the attached image for what margins I am talking about. The margins are highlighted in red.
Click to expand...
Click to collapse
Does that include all the xmls that have list in the title?
Sent from my Nexus S 4G using XDA App
ZiggSVO said:
Does that include all the xmls that have list in the title?
Click to expand...
Click to collapse
Thanks for responding Zigg. Yes, I have opened all xml files with list in the title. I have edited several of the layout xml files including "message_list_item.xml" in the layout folder, which I feel might be related somehow to those margins.
But, when I edit any file in the /res/layout folder and I compile the apk again it results in a force close on whatever screen that layout xml applies to. So, I make any change to the "message_list_item.xml" file and it will force close when I try to enter the message list but not on the main conversation thread screen.
I don't know either if these margins can be altered by way of a theme and, if so, how to add that style.
Thanks for any feedback you may have!
pixelswim said:
Thanks for responding Zigg. Yes, I have opened all xml files with list in the title. I have edited several of the layout xml files including "message_list_item.xml" in the layout folder, which I feel might be related somehow to those margins.
But, when I edit any file in the /res/layout folder and I compile the apk again it results in a force close on whatever screen that layout xml applies to. So, I make any change to the "message_list_item.xml" file and it will force close when I try to enter the message list but not on the main conversation thread screen.
I don't know either if these margins can be altered by way of a theme and, if so, how to add that style.
Thanks for any feedback you may have!
Click to expand...
Click to collapse
Are you signing the apk after recompiling it?
Sent from my Nexus S 4G using XDA App
ZiggSVO said:
Are you signing the apk after recompiling it?
Click to expand...
Click to collapse
I was able to successfully edit the layout XML files, compile the apk and the Mms.apk app is working and being pushed to the system/app folder just fine.
My issue now is I don't know where those margins are being declared or set in the layout or XML files. I don't know if there is a parent element creating them. I have been pouring over the files and maybe it might be somewhere in "compose_message_activity.xml" but I'm not sure.
Thanks again for your help!
Got it!
Thanks for your help Zigg.
I believe that I have figured it out. In "compose_message_activity.xml" there is a view tag referencing MessageListView where I edited the scrollbar properties that were adding space and I also set some negative margins all around.

Categories

Resources