[How-To] Edit .9.png files for the MT4GS - step-by-step. - T-Mobile myTouch 4G Slide

Return to Contents Page - doubleshot Developers Reference
----
Part 1: Custom Sense Lockring on the MT4GS - easy step-by-step.
Part 2: This thread.
Part 3: Edit Mode10 Files for the MT4GS - step-by-step
--------
This installment will cover working with .9.png files, their special handling requirements, and a little bit about what makes them so special.
This is a slightly more advanced guide, and I won't be over-exaggerating explanation of simple things like copy and paste that were covered in part 1.
Working with .9.png files is easy once you know what steps to take and have the tools set up on your computer - it's just time consuming and tedious. So let's take a look at what you need.
What you need:
1 - Android SDK installed
2 - Java JDK installed.
3 - Apk Manager 4.9
4 - 7-Zip installed and ready.
5 - Photoshop ( or equivalent - directions for photoshop ) installed and ready.
6 - A copy of HTCCamera.apk from the Sense ROM you are changing the graphic in.
* - Guide written for a Windows XP machine, please adjust accordingly if your environment is different.
--------
This is a lot of stuff to manage, but if we take our time and do it in order it'll be a piece of cake. ( ~Tasty! )
First thing is to install the Android SDK and Java JDK - both actions are outside of the scope of this guide but well documented all over XDA.
This guide will pick up assuming both the Android SDK and the Java JDK are installed.
This guide also assumes that Apk Manager is installed. Please see the Apk Manager 4.9 thread for the tool if you have trouble in this area.
Lastly, this guide assumes you have read my guide: Custom Sense Lockring on the MT4GS - easy step-by-step. as I won't be explaining how to do things again that were already covered there.
( ... and of course, that you have Photoshop installed and ready...or another graphics program of your choice - but instructions are for Photoshop. )
--------
Okay, we have everything installed, now we need to get our hands on one of those .9.png files so we can play with it.
Let's talk about them for a minute first. Those .9.png files are pretty special, because they are a stretchable graphic.
This means that Android can use the same graphic in many different places, and these different places can be different sizes.
These graphics have some special information attached to them, outside of the border of the graphic there are black lines and dots that tell Android how far and in which directions it can stretch the graphics.
An important thing to note here: These black lines and dots MUST BE black, and no other shade or color. If they are not perfectly black, it will not work.
If you simply extract the graphic from the .apk file with 7-Zip, edit it, and put it back in, your .apk file will break. The reason being is the extra information about how and where to stretch the graphic gets broken when you do this.
The only way to edit these files correctly is to de-compile the .apk, then edit the graphic, and then re-compile the .apk file.
The example we are going to use is from the HTCCamera.apk, and it is called 'scene_frame_pressed.9.png'. It is in the 'res' -> 'drawable-hdpi' folder in the .apk
--------
Preparation: Setup.
First things first, let's set ourselves up. Make a new folder on your desktop, and call it 'CameraEdit'
Next, get a copy of HTCCamera.apk and put it in this folder.
Now, find your apk_manager_4.9 folder, where you set up this tool, and open it.
You will see a handful of folders in here, but there are only two folders we will be working with:
1 - place-apk-here-for-modding
2 - projects
( There is a third, called 'keep', but it's not there yet. It will be generated later. )
Make a copy of your HTCCamera.apk file, and put it in the 'place-apk-here-for-modding' folder.
Okay, stop.
Now we have:
1 - A new folder on the desktop with a fresh copy of HTCCamera.apk in it. This is our final product when we are finished.
2 - A second copy of HTCCamera.apk in the 'place-apk-here-for-modding' folder in the apk manager tool.
So far, pretty simple.
--------
Part 1: De-compiling your apk.
Now that you have your .apk file in the 'place-apk-here-for-modding' folder, go into the apk_manager_4.9 folder and you will see an MS-DOS batch file called 'script'. Double left click this to open it up.
Now you see a cool green menu, with a lot of numbers and options - but don't worry i'm gonna walk you through it. Just make sure not to close this window until I tell you to - simply ignore it when you aren't using it.
First thing you have to do is type the number '22' and hit enter. This lets us select what .apk file we are going to work with.
The only option on the list is '1 - HTCCamera.apk'
Type the number 1, then press enter.
You now find yourself back at that main menu, and up in the top right corner of the window it will say 'Current-App: HTCCamera.apk |'
Now we are ready to decompile the apk file. Type the number 9 and press enter.
It will say 'decompiling apk' and when it is done you will see the main menu again, with a blinking cursor after 'Please make your decision' at the bottom.
Now, we can forget about this window for a little while. Don't close it, just ignore it.
You can find your de-compiled apk in the 'projects' folder.
--------
Part 2: Coloring.
Open up Photoshop, and once it's loaded go to File-> Open, and navigate to the 'projects' folder in the 'apk_manager_4.9' tool.
You will see a folder called 'HTCCamera.apk', go in here, then into the 'res' folder, and then into the 'drawable-hdpi' folder.
Once there, you will find 'scene_frame_pressed.9.png' - open this file into Photoshop.
Once you have this open, you will notice something you didn't see before - there are solid black lines on each of the four sides of the colored square of the graphic.
You do not want to touch, change, edit or in any way affect these black lines. To alter them even the slightest bit will make your whole .apk file broken - and we don't want that.
So what we are going to do is grab your 'Rectangle Marquee Tool' and select everything EXCEPT the black lines around the outside.
Once you have the whole picture selected, except the black lines, you will go up to the menu at the top of the Photoshop window and select 'Image'. From the drop-down list, select 'Adjustments' and then 'Hue/Saturation'
Now you have a dialog box for the Hue/Saturation control of the graphic.
The only thing we are going to change is the Hue, so make sure the 'Edit' box at the top of the window says 'Master' and then grab the Hue slider and drag it all the way to the right.
The text box above Hue should now say +180, and the color of the square has changed. ( If the color didn't change, make sure the 'preview' box is checked in the Hue/Saturation window )
Click on 'OK' and apply the change.
Save the file, and then close Photoshop.
--------
Pretty easy so far, right? not really that much to it - and we're almost done.
Next up we have to recompile the apk, and i'm going to make you take an extra step at the end of the process to reduce your chances of getting a bad apk from a compile error.
--------
Part 3: Re-compiling your apk.
Okay, find your apk manager window I told you not to close, and bring it back into focus.
You should see a blinking cursor at the bottom after 'Please make your decision'.
We are now going to type the number 11, and then press enter. This will tell it to compile the apk.
It will say 'Building Apk', and this part can take a little while - so just be patient.
When it is ready for you, the next thing it will say is:
Code:
Is this a system apk (y/n)
Type input:
You will type 'y' and press enter. Any apk that came from or goes into the /system/app folder on the device gets this answer.
Then it will say:
Code:
Aside from signatures, would you like to copy
over any additional files that you didn't modify
from the original apk in order to ensure the least
# of errors (y/n)
Type input:
You will again type 'y' and press enter.
A whole mess of text will shoot up in the window, and the very last line will be:
Code:
Press any key to continue...
Don't press anything yet, just ignore this program window for the moment.
Now, what you have to do is go back into the apk_manager_4.9 folder and you will find that 'keep' folder I mentioned before. It wasn't there until now, because it's a temporary folder the apk manager program is using to compile your apk with.
What you have to do is go into it, and delete any files you changed.
In this case it's easy, because we only changed one file.
Go into the 'keep' folder, then the 'res' folder, then the 'drawable-hdpi' folder, and find the 'scene_frame_pressed.9.png' file we edited.
Delete the 'scene_frame_pressed.9.png' file.
Now go back to the apk manager window, and press enter.
Let it do it's thing, and when it's done it'll be back at the main menu with a blinking cursor after 'Please make your decision:'
You can just hit the X in the top right corner to close the window, we're done with this wonderful tool now. ( yes - now you can finally close it. )
--------
Okay, now we have de-compiled, edited, and re-compiled our apk file - but we aren't done yet there are still some things to take care of.
Don't worry, it's almost done - and the hard part is over ( which wasn't really that hard, was it? )
--------
Part 4: Avoiding potential bugs.
Next, go into the 'place-apk-here-for-modding' folder in the apk_manager_4.9 folder.
You will see two .apk files:
1 - HTCCamera.apk
2 - unsignedHTCCamera.apk
The second one is the one you just edited, but you will notice the file size is much smaller then the original one.
Now, you could just copy the unsignedHTCCamera.apk into another folder, rename it deleting the 'unsigned' part at the beginning, and push it to your device.
We're going to add an extra step to the whole process to reduce the chances of a compile error and give you more chance for stability in the larger sense of your Android operating system.
Click to expand...
Click to collapse
Remember that folder on your desktop called 'CameraEdit' I had you make with a fresh copy of HTCCamera.apk in it? I want you to copy 'unsignedHTCCamera.apk' and paste it into this folder.
You now have two apk files in this folder, the fresh un-touched one, and the new one we did our work to.
So, use 7-Zip to extract the newly edited 'scene_frame_pressed.9.png' file from 'unsignedHTCCamera.apk' the way I taught you in Custom Sense Lockring on the MT4GS - easy step-by-step and drag it into the 'CameraEdit' folder.
You now have 3 files in this folder, the two .apk files and your newly edited .9.png graphic.
Simply add this graphic to the original HTCCamera.apk file with 7-Zip, and you can call this project done. All you have to do now is test it.
Install the new HTCCamera.apk file on your Android, take a picture, and then tap the thumbnail in the bottom corner that shows your new picture in the camera app.
It brings you to a screen where you see a full screen preview of the picture, so tap the screen and press 'grid view' from the options at the bottom.
When you see the grid of pictures, touch one and look at the color of the highlight that appears around the picture - this is what we changed.
Congratulations! You just edited your first .9.png file!
* - Don't forget to go back to the Apk Manager 4.9 thread and click thanks!
--------
Conclusion & Thoughts:
The reason we did that last step at the end is because we were only changing one small thing - there is no reason to risk the computer making a mistake while compiling the whole .apk file just to change one graphic.
By removing it from the newly compiled .apk, and placing it in the original one that you know works, you eliminate the potential for a lot of bugs and problems.
You don't have to take this extra step at the end, and could just use your re-compiled apk file - but if you've already put this much effort into it, wouldn't you want to minimize the risk of errors by taking an extra minute to do so?
Above and beyond editing a .9.png file, we have also learned how to de-compile, edit, and re-compile an .apk file for Android.
You can now de-compile an .apk file and change XML files or most anything else inside of it and re-compile a working .apk file.
Look for part 3 of this tutorial series that will teach you about .m10 files and how to work with them. Afterwards you will be able to work with all of the graphics (and most other files!) you come across in your Android system.
The only thing we changed in the graphic during the tutorial was the hue, because this isn't a guide on all the cool things you can do with Photoshop or a graphics program.
There are a lot of other creative things people can do with the graphics, and i'm looking forward to seeing what the rest of you come up with now that editing .9.png stretchable graphics is something the MT4GS community knows how to do.
Hope you all are as excited as I am!
Happy modding!

Question having read this:
A)Can I not just take the .9.png file we worked/saved in Part 2
B)Then by-pass Part 3
C)Then in Part 4 with 7-zip: use the .9.png file directly saved at Part 2 (without recompiling)?
Probably a silly question, but thought I'd ask before diving in.
Sent from my Bulletproof_Doubleshot using XDA App

dillalade said:
Question having read this:
A)Can I not just take the .9.png file we worked/saved in Part 2
B)Then by-pass Part 3
C)Then in Part 4 with 7-zip: use the .9.png file directly saved at Part 2 (without recompiling)?
Probably a silly question, but thought I'd ask before diving in.
Sent from my Bulletproof_Doubleshot using XDA App
Click to expand...
Click to collapse
No, in order for it to work correctly you must perform step 3.
What happens is when you de-compile the app, it takes that system information and translates that into those black lines or dots around the outside of the graphic file.
When you re-compile the app, it turns those black lines or dots back into the machine code it translates into - the system doesn't see them as simple black lines or dots.
If you were to put the graphic back into the .apk file through 7-Zip without actually re-compiling it, the system would see those black lines and dots, not the machine code instructions they should be, and treat it like a regular graphic file.
It then would not be able to stretch it, try to fit it in whatever situation it was trying to use it in, and then you could get any number of results from nothing to a never-ending loop you have to battery pull and re-install the ROM to get past.
( and yea, I found out about that never ending loop first-hand, there was nothing I could do to make it stop, short of that drastic solution )
Basically what it boils down to is those markers around the border of the graphic are you writing machine code without actually typing it - the compile operation translates your dots and lines into the code for you, but only during compiling.
If it wasn't for that, you could just extract and replace them the same way you did in part 1 of the guide. 7-Zip is incapable of this operation, as awesome as it is for other stuff.
This is the same principle behind trying to use 7-Zip to pull an XML file from an .apk file - try it, and then open the XML file in notepad++ and see what you get - it won't be what you want.
That's a good question, and I wanted to go into more detail about that in the guide, but this one was already getting pretty long and I didn't want to make it too much to read through.
--------
Now, if you are not going to edit the graphic, then that's a totally different story - you can feel free to pull it out with 7-Zip and put it back in, or in another .apk file.
That's only if you don't change it at all though. If you want to edit the graphic you have to follow the steps outlined above.
Because we aren't changing it when I have you pull it from your re-compiled .apk and put it into the fresh one at the end of the guide, that's an acceptable action.
I think that might be the piece of information that was lacking that caused you to ask your question.

Nice write up bro! This would have been very useful to me about a year ago lol. I get questions about 9s all the time and now I have somewhere to send them! Keep up the great work bro!
Sent from my BluMagic CM7 Glacier using the Blu Premium App

Blue6IX said:
No, in order for it to work correctly you must perform step 3.
What happens is when you de-compile the app, it takes that system information and translates that into those black lines or dots around the outside of the graphic file.
When you re-compile the app, it turns those black lines or dots back into the machine code it translates into - the system doesn't see them as simple black lines or dots.
If you were to put the graphic back into the .apk file through 7-Zip without actually re-compiling it, the system would see those black lines and dots, not the machine code instructions they should be, and treat it like a regular graphic file.
It then would not be able to stretch it, try to fit it in whatever situation it was trying to use it in, and then you could get any number of results from nothing to a never-ending loop you have to battery pull and re-install the ROM to get past.
( and yea, I found out about that never ending loop first-hand, there was nothing I could do to make it stop, short of that drastic solution )
Basically what it boils down to is those markers around the border of the graphic are you writing machine code without actually typing it - the compile operation translates your dots and lines into the code for you, but only during compiling.
If it wasn't for that, you could just extract and replace them the same way you did in part 1 of the guide. 7-Zip is incapable of this operation, as awesome as it is for other stuff.
This is the same principle behind trying to use 7-Zip to pull an XML file from an .apk file - try it, and then open the XML file in notepad++ and see what you get - it won't be what you want.
That's a good question, and I wanted to go into more detail about that in the guide, but this one was already getting pretty long and I didn't want to make it too much to read through.
--------
Now, if you are not going to edit the graphic, then that's a totally different story - you can feel free to pull it out with 7-Zip and put it back in, or in another .apk file.
That's only if you don't change it at all though. If you want to edit the graphic you have to follow the steps outlined above.
Because we aren't changing it when I have you pull it from your re-compiled .apk and put it into the fresh one at the end of the guide, that's an acceptable action.
I think that might be the piece of information that was lacking that caused you to ask your question.
Click to expand...
Click to collapse
Yes... I can see clearly now Blue!
Great stuff.
I'm gonna do some lockrings, some theming over stock apps, then look to dive into building a theme... progress through naturally with your tutorials.
Thanks
Sent from my Bulletproof_Doubleshot using XDA App

Wow. I haven't seen that guide since I had the G1.

Related

editing the lockscreen

I want to make a minor change to the way the lockscreen looks and want to see if its something easy enough for me to do.
I'm looking to make the gray part with the dots on ether side slightly transparent. I would also like to keep the clock solid. Also not lose any of the functionality of the htc lockscreen.
Is this easy enough for someone with no theming experience to do?
Assuming you are rooted and if you are just changing images it is not difficult at all.
The lockscreen slider is actually in
/system/framework/com.htc.resources.apk
and there are 3 that start with lockscreen_arc
You need to copy the apk to your PC and open it with 7zip (my preferences) and extract the res folder to the PC. Do your graphic changes in that folder. Then reopen the apk in 7zip and drag the modified res folder over the window and drop it in.
Then you just do and adb push to put it back on the phone
You can use the same process to modify other images in the
/system/app/HtcLockScreen.apk
Changes that are not just graphics become very difficult and require de-compiling the apk to edit xml files.
AND Do a nand backup before just in case you mess up.
Awesome, sounds like a good guide. I'll post my results once I finish it.
it seems this is going to be harder than i thought.
I made the part that I wanted translucent only to find that the two pngs under it are not editable enough to remove them from behind it, so I'm left with this. I'm assuming that the only way to fix this is to do some xml editing which is a little above me.
I actually like that
If I could just get rid of the straight parts near the top of the time, I would like it. But simply editing the pngs won't cut it as I have a feeling that the xml extends the top graphic straight down because what is seen there doesn't match up with what the png looks like.
You would be correct. The problem you're running into is the 2 images behind the main lock bar are actually .9.png images and not regular .png images.
Quick, very rough explanation: To save space these images are stretched by xml files at certain points in the image to create a background. When an apk is decoded, these stretch points are represented by a 1px border around the image. This does not show up when you just use a program like 7zip.
Something to try if you want to cheat, not sure if it'll work.. Treat it all as one image instead of 3 separate ones. Make lockscreen_arc.png a taller image, and then put the top and bottom bars on it that way. Then just make the other two .9.png files completely transparent. Since it's a regular .png, it wont get stretched. I know making it smaller works out, so I'm assuming you could also make it larger.
Edit: Just thought about it some more, and that might not work, because if I had to guess, the Verizon and date text are probably set up in the xml relative to that image.
I'll mess around a little more today and see if I can't come up with something.
i also would like to do this but not the stock lock screen but this one..
To look like this...
Just the green and yellow to blue..
If all else fails, you could use the theme kitchen (http://uot.dakra.lt/kitchen). It'll allow basic changes to the whole theme (specifically the lockscreen).
Dude this thread is almost a year old and some people like to do stuff manually

[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

Want to make the Smart Notice widget transparent? Here's a how-to!

I posted this as a comment elsewhere, but thought it would do more justice as it's own thread. So here it is. This is ONLY for those who feel comfortable with rolling up their sleeves and tinkering with system files. Do not attempt this if you feel uncomfortable in any way. If you feel you are up for this project, read on...here's how to make the Smart Notice widget transparent!
Follow my instructions CAREFULLY. If possible, do this in front of a computer or other display so you can easily follow along. What's great about doing it this way is that you don't need Photoshop or to even do it on a computer.
First, go to recovery and BACK UP. Always do this. You will be glad you did if you screw this up. You could also go to Root Explorer before editing, go to the path/folder I specify a bit later and copy the specified files I also specify later to an external sd card, then replace them if things go awry or if you hate your changes. This can take time, though, and you will need to change permissions for each file as you go. Restoring via recovery is a safe way to restore everything back with little hassle and in less time than it would to replace each file and change permissions. Less room for error, too.
Get the Image Editor and Root Explorer apps at the Play Store. When you get them, go to Image Editor click on "open photo". When you do, scroll down the side panel till you see Root Explorer. Click. Go to /system/etc/mrg_default_forms/ConciergeBoard/default_view/container/res/drawable-xxxdpii/img/.
You will find your images to edit there. You will be editing the following, one by one:
concierge_default_bg_daily_brief.png
concierge_default_bg_time.png concierge_default_bg_weather.png concierge_blue_bg_time.png concierge_blue_bg_weather.png.
Once you choose the pic to start working with, you will be in the main editor. Click on the picture of the sun on top. A drop down menu will appear. Choose "effects". If you want to change the opacity to transparent, choose "opacity" (scroll the menu to the side to see it). Then choose "opacity" again. You can fiddle with transparency that way. Always click the checkmark on top to save changes. If you want to fiddle with color, choose "effects", then "colors" and then "hue". Use the sliders to adjust the colors. Again, click the checkmark above to save changes. I recommend changing color first if you wish to have both transparency and color changes. You'll be able to see color changes better this way and get a good idea of what you're working with.
Once you are done with EVERYTHING and are back on the main editing page (you'll be there every time you save changes), click on the checkmark above and click on "save" in the drop down. When it prompts you to save to Gallery or to choose where to save, CHOOSE GALLERY. ALWAYS. Choosing to choose where to save will result in a prompt to install another app called Computer. Don't. It's not necessary and runs very poorly.
Okay. Now it's time to roll up our sleeves. Go to Root Explorer once you are done editing all the pics. Go to the ImageEditor folder in your onboard storage (sdcard0). That's where your images are. Check them all off and click on the copy icon on bottom. The copy icon looks like two rectangles overlapping each other. Once that's done, go to the same path I mentioned earlier when we were editing photos: /system/etc/mrg_default_forms/ConciergeBoard/default_view/container/res/drawable-xxxdpii/img/. You may see a "root" tab toward the top of the app. If you see it, great: that is actually the easiest way to get to the above path. Once you are in the img folder, click on where it says "copy here" in the lower left corner. You will get a prompt to switch to r/w, first. Go ahead and okay that. Then it will ask if you wish to replace your files. Do it. It's fine: you backed up first, remember?
Okay. Once that's done, go to each file that is marked rw-rw-rw. Click on each check mark, then click on the three dotted menu button on your far right. Choose "permissions". You will choose rw-r-r (that's read/write for owner, read for group and read for others) for each file you edited/replaced. Save your changes and then make sure each file there is rw-r-r. Then exit. You can reboot now. You should see changes after reboot.
If at first you see the widget looking as if it hadn't changed at all, don't panic. That's normal. Just give it a few seconds to refresh. If after text appears the widget looks funky or unchanged, you messed up a bit. That's okay, too. Just go back and make sure you followed every step I detailed. Or you can go to recovery, restore and start over.
If the widget happens to force close (or crash...it shouldn't), restore. Something funky happened and you'll need to start from scratch. It's a little complicated for newer folks, but it won't screw up your phone so badly it will be unusable if you mess up. It will just mess up the widget. And that can be fixed by restoring a backup.
You may discover the text on the smart card portion of the widget is a bit light after all this. You can either choose a wallpaper to accomodate, make your concierge_default_bg_daily_brief.png file less transparent or choose a solid, light color, OR you could edit the concierge.css file in
/system/etc/mrg_default_forms/ConciergeBoard/default_view/container/, but I don't recommend that unless you really know what you are doing and feel comfortable monkeying with CSS. If you or anyone else really wishes to, I can explain how to do that next time. But again, do that only if you know what to do. You CAN restore if you mess that file up, but seriously, CSS can be intimidating and confusing to a novice. A screw up could make you need to restore and start over. Very frustrating. To be safe, copy and store your edited files in a different location, like an external sd card or computer. That way, those files will always be there in case you need them.
Happy editing. Let me know if something needs further explaining.
Sent from my LG-D851 using Tapatalk
Can't someone who has done this just post the modded apk?
Sent from my LG-D851
Or post flashable zip lol
Skizzy034 said:
Can't someone who has done this just post the modded apk?
Sent from my LG-D851
Click to expand...
Click to collapse
Except this isn't an apk. It is system files that affect the widget itself. I did not tinker with an apk to do this.
Sent from my LG-D851 using Tapatalk
CheesyNutz said:
Or post flashable zip lol
Click to expand...
Click to collapse
I don't know how to make flashable zips, or I'd have just done that. Also, there is another thread regarding this very subject. They haven't come up with a flashable file, either.
So okay. Let's just use this tut as a guide for others to follow who DO want to put in the work for their own phones. If someone comes up with a flashable, cool. But I took the time to type all this up. Try to keep the laughing at a dull roar, okay?
Sent from my LG-D851 using Tapatalk
Requested to close thread. Thanks anyway.

[Tutorial][Keyboards!]MAKE YOUR OWN SWIFTKEY THEME FOR KEYBOARDS!!!

HEY THERE XDA!
ahmad89098 here and this is my first tutorial
In this tutorial, I am going to show you guys how to make your own custom theme for SwiftKey!
Note: I am not allowed to post links. So you will be needing to find source files yourself.
The hell is SwiftKey?
Swiftkey is an Android app which customizes your keyboard. You can buy themes for it. These themes are around $1.25. The SwiftKey app is very fun to use and gives an appelaing look to your keyboard!
There was a post on XDA as well in which, there were hundreds of more themes. The developer(s) called it Super SwiftKey.
At this point you might be wondering, how do you make your theme for it? Well, your'e gonna learn that today!
This tutorial is compatible for the following:
Complete Android Beginners (and above)
For Android Noobs (and above)
People who really want to get into keyboard design
People you want their own keyboard for SwiftKey
So without further ado, lets get started! :laugh:
1. GET YOUR TOOLS![/SIZE]
For making the keyboard, we will be needing the apk itself. We will later on install it once it has keyboards.
To download the apk go to google and google: download swiftkey apk and use the first link whose link says apk4fun. Donwload apk.
Once we have the apk file, we will need our tools. Download WinRAR and Notepad++ (Don't be lazy!)
2. GET READY TO WORK!
Now, we will need to get the files out of the apk.
Move the apk from your Downloads to your Desktop (for conveniance.)
Open Winrar. When you open it, it gives you the files on your desktop. Find the apk, open it. A new windows pops up, with some folders.
Now make a new folder on your Desktop. Name it Swiftkey.
Extract them files using WinRAR.
Once extracted, open up your folder. Should look something like this:
Congratulations! Your working space has now been set up!
2. NOW START TO WORK!
OK guys! We will now start our work.
Remember: The language we will be dealing in is xml. If you know about it, then you will be at an advantage. If you don't know problem!
Open the folder named "assets"
Then open "themes"
Now opens up a list of folder. If you are familiar with SwiftKey, then you know that when we open the themes menu, these are the exact names of the themes.
For beginner conveniance, we will work using the "pumpkin template". because it has a jpg background which can easily be replaced.
Now copy the "pumpkin" folder and paste in the same location.
We will be working in the new pumpkin folder. Name it whatever you like!
When we open the working folder, there are some folders. Open "hdpi"
Now open a list of xml files with a blank icon.
Open key_special.xml with notepad++ .
As you can see, the first line says,
<item state_pressed="true" drawable="key_base_pressed.9.png" />
This means that when a key on the keyboard is pressed, the key should look like the png specified. In this case, the png is
key_base_pressed.9.png.
Keeping this window open, go back to the working folder and open "key_base_pressed.9.png"
If you look at more files in the folder, you will find key_base_normal.9
When you compare these two png's, you will find that key_base_pressed is just a highlighted version of key_base_normal.
Now, edit key_base_normal.9 to whatever color you want your keys to be. Use Paint, Photoshop, or any other image editor.
After this, edit key_base_pressed.9 to what color you want a pressed key to be. Usually, a highlighted version of the color you have chosen is suitable. The whole thing, however, entirely depends on you.
Now, it is time to chose the background of the whole keyboard. This background will be overlapped by the keys.
To choose this, open the file"popup_background.xml" in Notepad++
We will now edit the line where it says: "<solid color="#333333" />"
#333333 is the color code. Now, when you decide the color you want, you need to find out the code for your color.
Now enter the code. Done!
We now have our own:
a solid background key color
a color for the key
and for when the key is pressed.
The only thing left is the text color. I am just getting to that.
there is a .png file, flip_left. Its like a wifi signal tilted. Orange is growing from lighter to darker.
Along with it is another png, flip_right. It is an inverted image of flip_left.
Edit these to your liking.
Chose your color. E.g blue.
Open flip_left.png in any image editor. We will use Paint
Zoom in as the image is very small.
Start working on your "triangles"
Do the same thing for flip_right.png. Note: these should be exactly the same tint of white in both.
Once completed, copy all these png's and edited xml files to the folders "hdpi" "ldpi" " xhdpi" "mhdpi". These are located in "pumpkin"
:laugh: CONGRATULATIONS :laugh:
WE HAVE FINISHED ALL THE EDITING :highfive: :victory:
The only thing now left is to compile all these files back into the apk. It is now time to wrap up.
Change your folder name to: "Whatever you want.."
Open the SwiftKey apk in WinRar.
Copy the folder "SwiftKey" to the apk.
Now delete all the original files in the apk.
Once deleted, copy the edited files from the SwiftKey folder from dekstop to the apk.
Delete the folder in the apk.
Done!!!!!!
You now have a custom keyboard! Install the apk on your phone and boom!
I hope you learned stuff.
Support me by liking and making use of this thread!
Goodbye!
AHMAD SALEEM MIRZA
I can't find the key_special.xml file. where is this located exactly?

Watch Face XML editing.

Has anyone successfully edited the XML on a custom watch face and imported it back into GWD? Is it possible to borrow some options from the stock watch faces, like the stylize button? GWD is seriously lacking in a few places but it seems to be possible, with some tweaking, to add some customer features in. Hopefully something as simple as changing the color of some watch hands by double tapping.......
Anyone have any tips on editing the XML???
absolutcarcrazy said:
Has anyone successfully edited the XML on a custom watch face and imported it back into GWD? Is it possible to borrow some options from the stock watch faces, like the stylize button? GWD is seriously lacking in a few places but it seems to be possible, with some tweaking, to add some customer features in. Hopefully something as simple as changing the color of some watch hands by double tapping.......
Anyone have any tips on editing the XML???
Click to expand...
Click to collapse
Yes, I have done this, but a very limited, specific task.
First I changed the xyz.gwd filename to be xyz.zip. Extracted the watchface.xml file. I took the watchface.xml into my xml editor (XML Marker ver 1.1) and discovered how the "swap background on tap" was coded. It involves using an image-set tag, and an action tag. I then used this to make a swap-on-tap Hour hand. Saved the updated xml code, and inserted this back into the xyz.zip. Then renamed this to xyz.gwd and put back into GearWatchDesigner\workspace\.
Open the design inside GWD. You can then look at the hour hand and see the button action to change image, although you cannot create this action within GWD, only an xlm editor. Did the usual build and Run on Device. Once the watchface was on my watch, I did have to reboot the watch for the functionality to work. But it DOES WORK. Tapping the hour hand did change the appearance of the hour hand (black/white swap).
This was a very simple test. But the basic idea of modifying the xml to do other things does work. HOWEVER, you need to know what other options are available. I have no idea if the xml codeset, that is understood by GWD when building the .tpk file, supports double-tap, stylize, or other complications. And if so, what the actual xml code would be for these functions.
Thanks for the information.
I had tried most of this but I failed to notice that hour hand would have the button action change. Guess I'll give it another go!
absolutcarcrazy said:
Thanks for the information.
I had tried most of this but I failed to notice that hour hand would have the button action change. Guess I'll give it another go!
Click to expand...
Click to collapse
The details of the modified XML
for the watch hand to be swapped, in the group\part\ replace the <image> with a <image-set>
<image>basic_clock_hands_hr_shadow.png</image>​becomes:
<image-set><image>basic_clock_hands_hr_shadow.png</image><image>action/image/basic_clock_hands_hr.png</image></image-set>​
Add the new action to the hour hand part
<action on_event="tap" target_part_id="basic_clock_hands_hr_shadow" type="image-set-show-next"/>​
and I have added a couple of watch screen shots. As I said, a very simple example.
Thanks again. I'll give this a try when I get home.
Sent from my SM-G925T using Tapatalk
Need some guidance again......
cnguinn said:
The details of the modified XML
for the watch hand to be swapped, in the group\part\ replace the <image> with a <image-set>
<image>basic_clock_hands_hr_shadow.png</image>​becomes:
<image-set><image>basic_clock_hands_hr_shadow.png</image><image>action/image/basic_clock_hands_hr.png</image></image-set>​
Add the new action to the hour hand part
<action on_event="tap" target_part_id="basic_clock_hands_hr_shadow" type="image-set-show-next"/>​
and I have added a couple of watch screen shots. As I said, a very simple example.
Click to expand...
Click to collapse
I really appreciate this example that you previously provided for me. Unfortunately, the newest update to GWD has broken this. I assume its because the XML schema has updated from 0.1 to 1.0. I cannot figure out how to write the new image set code to display the same thing with the updated watch face. Any help would be appreciated!! :fingers-crossed:
It Worked
Thanks to "cnguinn" for the instructions, followed these and it worked.
I had been scratching my head over this most of the morning, but what I hadn't done was rename the gwd file to a zip and save within the zip and then rename back to gwd.
I used the program "XmlPad3_02a" to edit the xml files.
adding the relevant lines to refer to the image file and changed the action set
I added the image file in the appropriate folders, ( res and debug/tpk)
and then just saved the whole folders ( rather than just the individual xml files) within the zip file.
Tested on the laptop and worked fine, exported up to the Gear S3 and perfect, new colour added to background on tap function.
Ryley199 said:
Thanks to "cnguinn" for the instructions, followed these and it worked.
I had been scratching my head over this most of the morning, but what I hadn't done was rename the gwd file to a zip and save within the zip and then rename back to gwd.
I used the program "XmlPad3_02a" to edit the xml files.
adding the relevant lines to refer to the image file and changed the action set
I added the image file in the appropriate folders, ( res and debug/tpk)
and then just saved the whole folders ( rather than just the individual xml files) within the zip file.
Tested on the laptop and worked fine, exported up to the Gear S3 and perfect, new colour added to background on tap function.
Click to expand...
Click to collapse
Sorry if you could tell me more.
It’s impossible for me to change the color of the hands along the anchor (pictures).
Please post the entire code of the hml file.
Thank you very much

Categories

Resources