[Q] Need help with "Couldn't resolve resource @string/edit_message" - Android Studio

So I have just started of building my first app in Android Studio but already gotten problems. I'm following the guide on https://developer.android.com/training/basics/firstapp/building-ui.html to go along and learn stuff. This is all the code I have so far:
Code:
<LinearLayout xmlns:android="http://schemas.android.com/apk/res/android"
xmlns:tools="http://schemas.android.com/tools"
android:layout_width="match_parent"
android:layout_height="match_parent"
android:orientation="horizontal" >
<EditText android:id="@+id/edit_message"
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:hint= [user=936943]@string[/user]/edit_message"
/>
</LinearLayout>
Bur for some reasen I get the error " Rendering Problems Couldn't resolve resource @string/edit_message" I guess there is a problem with the string id but I don't know why. Even if I copy paste the code from the website it does not work.

Your missing the first quote symbol which is probably why you're getting the error. It should look like this...
Code:
android:hint="@string/edit_message"
Also make sure you added the string to your strings.xml file correctly for edit_message.

Related

ic_lockscreen_outerring.PNG help ASAP

I'm to the part of editing my theme where I created a ic_lockscreen_outerring_img.png and put it in the framework-res\res\drawable-hdpi folder, now I'm absolutely stuck, I attempted to add the code android:[email protected]/ic_lockscreen_outerring_img so it looks like this in the keyguard.xml:
<?xml version="1.0" encoding="utf-8"?>
<LinearLayout android:ic_lockscreen_outerring_img="@drawable/ic_lockscreen_outerring_img androidrientation="vertical" android:background="#ff000000" androidaddingLeft="20.0dip" androidaddingTop="20.0dip" androidaddingRight="20.0dip" androidaddingBottom="20.0dip" android:layout_width="wrap_content" android:layout_height="wrap_content"
xmlns:android="http://schemas.android.com/apk/res/android">
<TextView android:textSize="16.0sp" android:textStyle="bold" android:textColor="#ff62ff00" android:id="@id/label" android:layout_width="wrap_content" android:layout_height="wrap_content" android:text="@string/keyguard_label_text"/>
</LinearLayout>
I know I need to add it to every xml with keyguard and I've attempted to do so and tried to recompile and apktool tells me: Error parsing XML: not well formed (invalid token) for all the keyguard xmls I've put this code into, I'm pretty sure I'm doing something wrong but no tutorial really goes in depth on what exactly the code is supposed to be for a modified lock screen outer ring nor tells you what line in the xml to put it on PLEASE HELP!!!
You may have a reference on evilisto's honeycomb style lockscreen tutorial, you can simply remove the outerring xml since you added the outerring png
Sent from my Galaxy Nexus using XDA

[HOW-TO]Remove carrier name (GB/ICS AOSP...)

Here is a method for removing the carrier name from various locations.
These are the proper xml files to edit on AT&T Moto GB and Verizon Moto ICS for sure - not so sure about other builds, but the technique can probably be used across the board for all sorts of builds... or for removing other text I suppose.. and, yes, there are other ways of accomplishing this - but this way works by reducing the text size to nothingness.
NOTES:
-Use a text editor like Notepad++ or Geany, and watch your spaces!
-Look for the line containing android:id="@id/onsText", android:id="@id/carrierLabel", or android:id="@id/carrier".
**THIS WILL ALSO REMOVE THE "No Service/Internet Connection/Emergency Calls Only/etc" TEXT LINES THAT ARE LOCATED IN THE SAME PLACE AS THE CARRIER NAME (but not status bar notifications)**
(Not sure of a work around that works on all devices and doesn't remove the other text lines - but on some devices you can just edit the eri.xml or strings.xml and put a blank space instead of the carrier name)
Remove carrier name from status bar
-Decompile SystemUI.apk
-Open /res/layout/status_bar.xml with Notepad++ (or similar)
-Look for the line as shown in red (taken from stock 2.3.6 Moto, but will be similar to ICS):
Code:
<com.android.systemui.statusbar.StatusBarView android:orientation="vertical" android:background="@drawable/statusbar_background" android:focusable="true" android:descendantFocusability="afterDescendants"
xmlns:android="http://schemas.android.com/apk/res/android">
<LinearLayout android:orientation="horizontal" android:id="@id/icons" android:layout_width="fill_parent" android:layout_height="fill_parent">
[COLOR="Red"]<TextView android:textAppearance="@android:style/TextAppearance.StatusBar.Icon" android:textSize="16.0sp" android:textStyle="bold" android:gravity="left|center" android:id="@id/onsText" android:paddingLeft="6.0px" android:layout_width="wrap_content" android:layout_height="fill_parent" android:singleLine="true" android:maxLength="18" />[/COLOR]
-Change the values for android:textSize and android:maxLength to zero as shown here:
Code:
<TextView android:textAppearance="@android:style/TextAppearance.StatusBar.Icon" android:textSize="0.0sp" android:textStyle="bold" android:gravity="left|center" android:id="@id/onsText" android:paddingLeft="0.0px" android:layout_width="wrap_content" android:layout_height="fill_parent" android:singleLine="true" android:maxLength="0" />
-Save and recompile
Remove carrier name at bottom of pull-down menu
-Decompile SystemUI.apk
-Open res/layout/status_bar_tracking.xml
-Look for the line as shown in red (taken from stock 4.0.4 Moto):
Code:
<?xml version="1.0" encoding="utf-8"?>
<com.android.systemui.statusbar.phone.TrackingView android:orientation="vertical" android:paddingLeft="0.0px" android:paddingRight="0.0px" android:paddingBottom="0.0px" android:focusable="true" android:visibility="gone" android:descendantFocusability="afterDescendants"
xmlns:android="http://schemas.android.com/apk/res/android">
<FrameLayout android:background="@drawable/notification_tracking_bg" android:layout_width="fill_parent" android:layout_height="wrap_content" android:layout_weight="1.0">
<LinearLayout android:layout_gravity="bottom" android:orientation="vertical" android:layout_width="fill_parent" android:layout_height="wrap_content">
[COLOR="Red"]<com.android.systemui.statusbar.phone.CarrierLabel android:textAppearance="@style/TextAppearance.StatusBar.Clock" android:gravity="center" android:id="@id/carrierLabel" android:paddingBottom="20.0dip" android:layout_width="fill_parent" android:layout_height="wrap_content" />[/COLOR]
-Add the values for android:textSize="0.0sp" and android:maxLength="0" as shown here highlighted blue:
Code:
<com.android.systemui.statusbar.phone.CarrierLabel android:textAppearance="@style/TextAppearance.StatusBar.Clock" [COLOR="Blue"]android:textSize="0.0sp"[/COLOR] android:gravity="center" android:id="@id/carrierLabel" android:paddingBottom="20.0dip" android:layout_width="fill_parent" android:layout_height="wrap_content" [COLOR="Blue"]android:maxLength="0" />[/COLOR]
-Save and recompile
Remove carrier name at top of pull-down menu
-Not tested, but look in SystemUI.apk/res/layout/status_bar_expanded.xml
-Use the above method(s)
Remove carrier name from lockscreen
-Decompile framework-res.apk
-Open res/layout/keyguard_screen_tab_unlock.xml
-Look for the line as shown in red (taken from stock 4.0.4 Moto):
Code:
<RelativeLayout android:layout_width="fill_parent" android:layout_height="390.0dip" android:layout_marginTop="-114.0dip">
<LinearLayout android:orientation="vertical" android:layout_width="fill_parent" android:layout_height="wrap_content" android:layout_alignParentBottom="true">
[COLOR="Red"]<TextView android:textAppearance="?textAppearanceMedium" android:textStyle="bold" android:textColor="?textColorSecondary" android:ellipsize="marquee" android:gravity="center_horizontal" android:id="@id/carrier" android:layout_width="fill_parent" android:layout_height="wrap_content" android:layout_marginTop="32.0dip" android:layout_marginBottom="6.0dip" android:singleLine="true" />[/COLOR]
-Add the values for android:textSize="0.0sp" and android:maxLength="0" as shown here highlighted blue:
Code:
<TextView android:textAppearance="?textAppearanceMedium" [COLOR="Blue"]android:textSize="0.0sp"[/COLOR] android:textStyle="bold" android:textColor="?textColorSecondary" android:ellipsize="marquee" android:gravity="center_horizontal" android:id="@id/carrier" android:layout_width="fill_parent" android:layout_height="wrap_content" android:layout_marginTop="32.0dip" android:layout_marginBottom="6.0dip" android:singleLine="true" [COLOR="Blue"]android:maxLength="0"[/COLOR] />
-Save and recompile framework-res.apk
I'm about to try this on my Atrix2 w/ICS OTA rooted... anyone been there done that before?
l0wgray said:
I'm about to try this on my Atrix2 w/ICS OTA rooted... anyone been there done that before?
Click to expand...
Click to collapse
The theory behind this will work on any version of Android. Just as long as you pay attention to what the op's actually doing.
Just remember to always use the latest versions of apktool and aapt. Or use Tickle My Android..ahem..lol
You can also just delete the whole line completely but that can sometimes cause problems. I've had several FC's in the past from trying to remove carrier labels from Froyo and even ICS gets a bit funny sometimes.
Just remember to always backup and then just give it a try!
sent using the xda app!
l0wgray said:
I'm about to try this on my Atrix2 w/ICS OTA rooted... anyone been there done that before?
Click to expand...
Click to collapse
Yea.. been done. (You know I got an A2, right? )
But Ticklefish is correct - the theory should work on any android, and, yes, you can also remove the entire line if you are careful to mind the parents and children
If it's a TextView line, then you are pretty safe removing the entire line - or, like with the lockscreen, just swap the android:id= with something similar - maybe battery charge? (in mine it's id/status1) - that's where your custom text shows up if you go through the system settings lockscreen menu..
Sent from my phone's mind
HAH! LOL, I must have looked over that you are running A2 in your sig!!!
Worked like a charm BTW, I think I'm going to further edit that XML by removing the paddingLeft as well...
Also I did look at Tickle My Android, but I'm not much of a GUI person...
I've been developing on Android for over a year now (writing from the ground up apps) and just got around to messing with a few annoyances with my personal phone. One of which on the A2 is the carrier name. On my phone it says "AT&T Microcell" and takes up nearly the entire status bar. Ugh.
A few notes of caution for anyone doing this, to make things easier for them perhaps.
1.) I'm not a GUI person. If you know how to use your adb shell and cmd or shell prompts do stuff in there. IMHO stuff normally works better because you aren't trusting someone else to interpret your clicks from a gui and then re-write them as "shell commands".
2.) While the instructions in the OPs post below are REALLY GOOD, I think they could be revised a little.
http://forum.xda-developers.com/showthread.php?t=1753659
(edit: sorry wrong link posted, correct one is above)
Mainly, I would just say, recompile your APK according to those instructions, extract the files you've updated and then reinsert them into the original APK (I guess this would depend on what you are doing/modifying however).
In the case of this thread, I just extracted the newly compiled (and edited) resources.arsc and status_bar.xml files and then inserted them into the original SystemUI.apk file, overwriting what was there. I just used "store" compression with rar, (not a 7zip fan).
Then just moved the SystemUI.apk to the proper location, chmod, and reboot. Perfect!
l0wgray said:
2.) While the instructions in the OPs post below are REALLY GOOD, I think they could be revised a little.
Click to expand...
Click to collapse
Lol.. I agree completely.
Glad you got it working!
Ahh.... now that's more like it...
{
"lightbox_close": "Close",
"lightbox_next": "Next",
"lightbox_previous": "Previous",
"lightbox_error": "The requested content cannot be loaded. Please try again later.",
"lightbox_start_slideshow": "Start slideshow",
"lightbox_stop_slideshow": "Stop slideshow",
"lightbox_full_screen": "Full screen",
"lightbox_thumbnails": "Thumbnails",
"lightbox_download": "Download",
"lightbox_share": "Share",
"lightbox_zoom": "Zoom",
"lightbox_new_window": "New window",
"lightbox_toggle_sidebar": "Toggle sidebar"
}
Will be doing this to my atrix HD asap.
Okay, done a lot of reading and mistake-making (had to root phone twice cause unlock put me back to zero), but that's fine. So unlocked, rooted, and CWM 5.0.2.0 on.
Would like to put this on for the statusbar. I copied systemUI.apk off to SD card and to laptop and unzipped it and found the module, but i have read and read (probably right in front of me) but can't find out how to de-compile/compile it and get it out and in of/to the phone. I fired up Tickle My Computer as mention was made of that, but see nothing about that.
Can anyone toss me a few words? (Atrix 4G is 2.3.6 4.5.141) MB860
EDIT: found push "2" and it goes to an interesting menu. What condition is my phone in fastboot and connected?
EDIT2: condition is on and connected.
I went "all the way through it" : pulling it in, backing it up, decompiling it, changing it in working-folder, compiling it, prepping it, zip aligninging it, and pushing it back, but it failed on a read-only error (the target, I believe). Wondering what I missed?
KrisM22 said:
...and pushing it back, but it failed on a read-only error (the target, I believe). Wondering what I missed?
Click to expand...
Click to collapse
Is your FS mounted RW? Also, don't forget to chmod 644 once it is done copying.
It sounds like you got things figured out, but yes the bone was right in front of you, check my reply a few posts up with the link to the OPs instructions. But I think it sounds like tickle my android might be the easier option?
Congrats making it that far w/o help.
l0wgray said:
Is your FS mounted RW? Also, don't forget to chmod 644 once it is done copying.
It sounds like you got things figured out, but yes the bone was right in front of you, check my reply a few posts up with the link to the OPs instructions. But I think it sounds like tickle my android might be the easier option?
Congrats making it that far w/o help.
Click to expand...
Click to collapse
Thanks! But what's a FS and how do I mount it RW(as long as I'm asking.
And the CHMOD - something like
adb shell
chmod 644 /system/app/systemUI.apk
?
Thanks!
EDIT: actually I could change permissions to rw-r--r-- (=644) with Root Browser Pro after copy, yes?
Also systemUI.apk on phone is currently rw-r--r-- - do I need to change that to rw-r--rw- (along with adding write for others for app and system?) with RBP before doing the copy with TMA?
EDIT2: okay, so an official BAH. :
I did redo using notepad++, but no difference.
I changed SystemUI.apk on the phone to rw-rw-rw and that allowed the copy.
However that put me into a loop as it coudn't find the status bar thing.
So I rebooted and it rebooted fine, but no statusbar.
i push the backup copy to the phone and rebooted but still no statusbar.
Yes, I do have a backup on CWM 5.0.2.0, but I have learned not to trust v5 for backups so don't want to try it.
-HELP!-
I'll entertain.
FS is file system.
To mount RW you can use the mount command (but it sounds like you would be better off using something like RBP).
To play with these files you have to do so with root permissions. So either 'su' at the prompt or with an app that has been granted root permissions. Once you are super user there is no need to change permissions before any file operations.
Yes after you copy SystemUI.apk back to it's proper spot with your mods you must make sure root is the owner and the permissions are the same as it was before (rw- r-- r--).
Assuming you decompiled, edited, and recompiled properly, once you have the new SystemUI.apk in place, and reboot your phone you should see the changes.
Likewise, if you put a copy of the original SystemUI.apk back in (and then ensure root owns it and the permissions are (rw- r-- r--), then reboot you should have a status bar again).
(note: case is important).
HTH.
l0wgray said:
I'll entertain.
FS is file system.
To mount RW you can use the mount command (but it sounds like you would be better off using something like RBP).
To play with these files you have to do so with root permissions. So either 'su' at the prompt or with an app that has been granted root permissions. Once you are super user there is no need to change permissions before any file operations.
Yes after you copy SystemUI.apk back to it's proper spot with your mods you must make sure root is the owner and the permissions are the same as it was before (rw- r-- r--).
Assuming you decompiled, edited, and recompiled properly, once you have the new SystemUI.apk in place, and reboot your phone you should see the changes.
Likewise, if you put a copy of the original SystemUI.apk back in (and then ensure root owns it and the permissions are (rw- r-- r--), then reboot you should have a status bar again).
(note: case is important).
HTH.
Click to expand...
Click to collapse
Thanks for entertaining.
0;root owns it and it is rw- r-- r--
original one is in there
but no statusbar.
I have cleared cache (with stock recov - my 5.0.2.0 disappeared just as my v4 disappeared before it - don't know what is stealing CWMs) but no change
it's not in Dalvik so next attempt will be to clear data...
No, with clear data and cache, still no statusbar.
definite help
KrisM22 said:
Thanks for entertaining.
Click to expand...
Click to collapse
NP.
Trace your steps, get back to a good known state.
Start by comparing the file size, stamp, etc. between your backup file and the one currently in place.
Perhaps you don't have an original SystemUI.apk in place. If it's not original (or even if it is, you may want to find a good known copy of it somewhere and try that).
With the original SystemUI.apk in place, root as owner, and correct permissions set I don't see why you wouldn't see a status bar after a reboot, unless you've made changes elsewhere.
Okay since i data cleared I had to re-root, and that gave me a bit of trouble this time but finally went through.
I then took your idea - first thing I had done in all this was to use Root Browser to copy SystemUI.apk to my SD card. Damn glad I did.
I had to change permissions on system and system/app, and the app itself before it RB would allow me to copy/replace and (then redo all those permission settings) reboot and i have stock status bar.
WHEW!
it's possible Tickle my Elmo was not doing something it thought it was doing, or visaversa.
The file in TMA out size shows 259KB on win7, whereas the module on the SD card and in system shows 258KB in the phone, but they could be figuring it differently. I'd have to copy the one in out to the SD card (manually) and look at again to know for sure. But I'm going to let this all rest for a day and take another look at the layout module I'm modifying - it's different from the one in the post.
Meantime thanks for your time and encouragement!
My module after changing both to zero:
Code:
<?xml version="1.0" encoding="utf-8"?>
<com.android.systemui.statusbar.StatusBarView android:orientation="vertical" android:background="@drawable/statusbar_background" android:focusable="true" android:descendantFocusability="afterDescendants"
xmlns:android="http://schemas.android.com/apk/res/android">
<LinearLayout android:orientation="horizontal" android:id="@id/icons" android:layout_width="fill_parent" android:layout_height="fill_parent">
<TextView android:textSize="0.0sp" android:textStyle="bold" android:gravity="left|center" android:id="@id/onsText" android:paddingLeft="6.0px" android:layout_width="wrap_content" android:layout_height="fill_parent" android:singleLine="true" android:maxLength="0" />
<com.android.systemui.statusbar.IconMerger android:gravity="center_vertical" android:orientation="horizontal" android:id="@id/notificationIcons" android:paddingLeft="6.0dip" android:layout_width="0.0dip" android:layout_height="fill_parent" android:layout_weight="1.0" android:layout_alignParentLeft="true" />
<LinearLayout android:gravity="center_vertical" android:orientation="horizontal" android:id="@id/statusIcons" android:paddingRight="6.0dip" android:layout_width="wrap_content" android:layout_height="fill_parent" android:layout_alignParentRight="true" />
<com.android.systemui.statusbar.Clock android:textAppearance="@*android:style/TextAppearance.StatusBar.Icon" android:gravity="left|center" android:paddingRight="6.0dip" android:layout_width="wrap_content" android:layout_height="fill_parent" android:singleLine="true" />
</LinearLayout>
<LinearLayout android:orientation="horizontal" android:id="@id/ticker" android:paddingLeft="6.0dip" android:animationCache="false" android:layout_width="fill_parent" android:layout_height="fill_parent">
<ImageSwitcher android:id="@id/tickerIcon" android:layout_width="wrap_content" android:layout_height="fill_parent" android:layout_marginRight="8.0dip">
<com.android.systemui.statusbar.AnimatedImageView android:layout_width="25.0dip" android:layout_height="25.0dip" />
<com.android.systemui.statusbar.AnimatedImageView android:layout_width="25.0dip" android:layout_height="25.0dip" />
</ImageSwitcher>
<com.android.systemui.statusbar.TickerView android:id="@id/tickerText" android:paddingTop="2.0dip" android:paddingRight="10.0dip" android:layout_width="0.0dip" android:layout_height="wrap_content" android:layout_weight="1.0">
<TextView android:textAppearance="@*android:style/Theme.Holo.Wallpaper" android:layout_width="fill_parent" android:layout_height="wrap_content" android:singleLine="true" />
<TextView android:textAppearance="@*android:style/Theme.Holo.Wallpaper" android:layout_width="fill_parent" android:layout_height="wrap_content" android:singleLine="true" />
</com.android.systemui.statusbar.TickerView>
</LinearLayout>
<com.android.systemui.statusbar.DateView android:textAppearance="@*android:style/TextAppearance.StatusBar.Icon" android:gravity="left|center" android:id="@id/date" android:background="@drawable/statusbar_background" android:paddingLeft="6.0px" android:paddingRight="6.0px" android:layout_width="wrap_content" android:layout_height="fill_parent" android:singleLine="true" />
</com.android.systemui.statusbar.StatusBarView>
Subsequently I did put the modified module on the SD card and it showed the same size as the original.
I went through the same manual procedure to put it in system/app, but no status bar, so I assume the module is bad. I will have to find out how to decompile and compile it manually. Anyway, for now, I'm back to the original module and have the statusbar.
I tried several modified modules but I'm doing something wrong.
So I had a meh moment and flashed MROM. Thanks for all your help!!!
KrisM22 said:
Okay since i data cleared I had to re-root, and that gave me a bit of trouble this time but finally went through.
I then took your idea - first thing I had done in all this was to use Root Browser to copy SystemUI.apk to my SD card. Damn glad I did.
I had to change permissions on system and system/app, and the app itself before it RB would allow me to copy/replace and (then redo all those permission settings) reboot and i have stock status bar.
WHEW!
it's possible Tickle my Elmo was not doing something it thought it was doing, or visaversa.
The file in TMA out size shows 259KB on win7, whereas the module on the SD card and in system shows 258KB in the phone, but they could be figuring it differently. I'd have to copy the one in out to the SD card (manually) and look at again to know for sure. But I'm going to let this all rest for a day and take another look at the layout module I'm modifying - it's different from the one in the post.
Meantime thanks for your time and encouragement!
My module after changing both to zero:
Code:
<?xml version="1.0" encoding="utf-8"?>
<com.android.systemui.statusbar.StatusBarView android:orientation="vertical" android:background="@drawable/statusbar_background" android:focusable="true" android:descendantFocusability="afterDescendants"
xmlns:android="http://schemas.android.com/apk/res/android">
<LinearLayout android:orientation="horizontal" android:id="@id/icons" android:layout_width="fill_parent" android:layout_height="fill_parent">
<TextView android:textSize="0.0sp" android:textStyle="bold" android:gravity="left|center" android:id="@id/onsText" android:paddingLeft="6.0px" android:layout_width="wrap_content" android:layout_height="fill_parent" android:singleLine="true" android:maxLength="0" />
<com.android.systemui.statusbar.IconMerger android:gravity="center_vertical" android:orientation="horizontal" android:id="@id/notificationIcons" android:paddingLeft="6.0dip" android:layout_width="0.0dip" android:layout_height="fill_parent" android:layout_weight="1.0" android:layout_alignParentLeft="true" />
<LinearLayout android:gravity="center_vertical" android:orientation="horizontal" android:id="@id/statusIcons" android:paddingRight="6.0dip" android:layout_width="wrap_content" android:layout_height="fill_parent" android:layout_alignParentRight="true" />
<com.android.systemui.statusbar.Clock android:textAppearance="@*android:style/TextAppearance.StatusBar.Icon" android:gravity="left|center" android:paddingRight="6.0dip" android:layout_width="wrap_content" android:layout_height="fill_parent" android:singleLine="true" />
</LinearLayout>
<LinearLayout android:orientation="horizontal" android:id="@id/ticker" android:paddingLeft="6.0dip" android:animationCache="false" android:layout_width="fill_parent" android:layout_height="fill_parent">
<ImageSwitcher android:id="@id/tickerIcon" android:layout_width="wrap_content" android:layout_height="fill_parent" android:layout_marginRight="8.0dip">
<com.android.systemui.statusbar.AnimatedImageView android:layout_width="25.0dip" android:layout_height="25.0dip" />
<com.android.systemui.statusbar.AnimatedImageView android:layout_width="25.0dip" android:layout_height="25.0dip" />
</ImageSwitcher>
<com.android.systemui.statusbar.TickerView android:id="@id/tickerText" android:paddingTop="2.0dip" android:paddingRight="10.0dip" android:layout_width="0.0dip" android:layout_height="wrap_content" android:layout_weight="1.0">
<TextView android:textAppearance="@*android:style/Theme.Holo.Wallpaper" android:layout_width="fill_parent" android:layout_height="wrap_content" android:singleLine="true" />
<TextView android:textAppearance="@*android:style/Theme.Holo.Wallpaper" android:layout_width="fill_parent" android:layout_height="wrap_content" android:singleLine="true" />
</com.android.systemui.statusbar.TickerView>
</LinearLayout>
<com.android.systemui.statusbar.DateView android:textAppearance="@*android:style/TextAppearance.StatusBar.Icon" android:gravity="left|center" android:id="@id/date" android:background="@drawable/statusbar_background" android:paddingLeft="6.0px" android:paddingRight="6.0px" android:layout_width="wrap_content" android:layout_height="fill_parent" android:singleLine="true" />
</com.android.systemui.statusbar.StatusBarView>
Subsequently I did put the modified module on the SD card and it showed the same size as the original.
I went through the same manual procedure to put it in system/app, but no status bar, so I assume the module is bad. I will have to find out how to decompile and compile it manually. Anyway, for now, I'm back to the original module and have the statusbar.
I tried several modified modules but I'm doing something wrong.
So I had a meh moment and flashed MROM. Thanks for all your help!!!
Click to expand...
Click to collapse
Well, Tickle My Android should work for you. (Tickle My Elmo....thanks for that...:laugh If it doesn't, it'd be handy for me to know about it so I can fix it.
So, by the looks of your code, you just need to change it to:
Code:
<?xml version="1.0" encoding="utf-8"?>
<com.android.systemui.statusbar.StatusBarView android:orientation="vertical" android:background="@drawable/statusbar_background" android:focusable="true" android:descendantFocusability="afterDescendants"
xmlns:android="http://schemas.android.com/apk/res/android">
<LinearLayout android:orientation="horizontal" android:id="@id/icons" android:layout_width="fill_parent" android:layout_height="fill_parent">
<com.android.systemui.statusbar.IconMerger android:gravity="center_vertical" android:orientation="horizontal" android:id="@id/notificationIcons" android:paddingLeft="6.0dip" android:layout_width="0.0dip" android:layout_height="fill_parent" android:layout_weight="1.0" android:layout_alignParentLeft="true" />
<LinearLayout android:gravity="center_vertical" android:orientation="horizontal" android:id="@id/statusIcons" android:paddingRight="6.0dip" android:layout_width="wrap_content" android:layout_height="fill_parent" android:layout_alignParentRight="true" />
<com.android.systemui.statusbar.Clock android:textAppearance="@*android:style/TextAppearance.StatusBar.Icon" android:gravity="left|center" android:paddingRight="6.0dip" android:layout_width="wrap_content" android:layout_height="fill_parent" android:singleLine="true" />
</LinearLayout>
<LinearLayout android:orientation="horizontal" android:id="@id/ticker" android:paddingLeft="6.0dip" android:animationCache="false" android:layout_width="fill_parent" android:layout_height="fill_parent">
<ImageSwitcher android:id="@id/tickerIcon" android:layout_width="wrap_content" android:layout_height="fill_parent" android:layout_marginRight="8.0dip">
<com.android.systemui.statusbar.AnimatedImageView android:layout_width="25.0dip" android:layout_height="25.0dip" />
<com.android.systemui.statusbar.AnimatedImageView android:layout_width="25.0dip" android:layout_height="25.0dip" />
</ImageSwitcher>
<com.android.systemui.statusbar.TickerView android:id="@id/tickerText" android:paddingTop="2.0dip" android:paddingRight="10.0dip" android:layout_width="0.0dip" android:layout_height="wrap_content" android:layout_weight="1.0">
<TextView android:textAppearance="@*android:style/Theme.Holo.Wallpaper" android:layout_width="fill_parent" android:layout_height="wrap_content" android:singleLine="true" />
<TextView android:textAppearance="@*android:style/Theme.Holo.Wallpaper" android:layout_width="fill_parent" android:layout_height="wrap_content" android:singleLine="true" />
</com.android.systemui.statusbar.TickerView>
</LinearLayout>
<com.android.systemui.statusbar.DateView android:textAppearance="@*android:style/TextAppearance.StatusBar.Icon" android:gravity="left|center" android:id="@id/date" android:background="@drawable/statusbar_background" android:paddingLeft="6.0px" android:paddingRight="6.0px" android:layout_width="wrap_content" android:layout_height="fill_parent" android:singleLine="true" />
</com.android.systemui.statusbar.StatusBarView>
Then recompile, prepare and push. If that's not working for you, can I suggest using the zip maker option? It's a lot more convenient than pushing as it creates a flashable backup zip automatically. Which saves a lot of time having to put things back to normal. It also sorts out permissions as well, which could be part of the problem.
I'd like to help solve this problem for you if I can.
Ticklefish said:
Well, Tickle My Android should work for you. (Tickle My Elmo....thanks for that...:laugh If it doesn't, it'd be handy for me to know about it so I can fix it.
So, by the looks of your code, you just need to change it to:
Code:
<?xml version="1.0" encoding="utf-8"?>
<com.android.systemui.statusbar.StatusBarView android:orientation="vertical" android:background="@drawable/statusbar_background" android:focusable="true" android:descendantFocusability="afterDescendants"
xmlns:android="http://schemas.android.com/apk/res/android">
<LinearLayout android:orientation="horizontal" android:id="@id/icons" android:layout_width="fill_parent" android:layout_height="fill_parent">
<com.android.systemui.statusbar.IconMerger android:gravity="center_vertical" android:orientation="horizontal" android:id="@id/notificationIcons" android:paddingLeft="6.0dip" android:layout_width="0.0dip" android:layout_height="fill_parent" android:layout_weight="1.0" android:layout_alignParentLeft="true" />
<LinearLayout android:gravity="center_vertical" android:orientation="horizontal" android:id="@id/statusIcons" android:paddingRight="6.0dip" android:layout_width="wrap_content" android:layout_height="fill_parent" android:layout_alignParentRight="true" />
<com.android.systemui.statusbar.Clock android:textAppearance="@*android:style/TextAppearance.StatusBar.Icon" android:gravity="left|center" android:paddingRight="6.0dip" android:layout_width="wrap_content" android:layout_height="fill_parent" android:singleLine="true" />
</LinearLayout>
<LinearLayout android:orientation="horizontal" android:id="@id/ticker" android:paddingLeft="6.0dip" android:animationCache="false" android:layout_width="fill_parent" android:layout_height="fill_parent">
<ImageSwitcher android:id="@id/tickerIcon" android:layout_width="wrap_content" android:layout_height="fill_parent" android:layout_marginRight="8.0dip">
<com.android.systemui.statusbar.AnimatedImageView android:layout_width="25.0dip" android:layout_height="25.0dip" />
<com.android.systemui.statusbar.AnimatedImageView android:layout_width="25.0dip" android:layout_height="25.0dip" />
</ImageSwitcher>
<com.android.systemui.statusbar.TickerView android:id="@id/tickerText" android:paddingTop="2.0dip" android:paddingRight="10.0dip" android:layout_width="0.0dip" android:layout_height="wrap_content" android:layout_weight="1.0">
<TextView android:textAppearance="@*android:style/Theme.Holo.Wallpaper" android:layout_width="fill_parent" android:layout_height="wrap_content" android:singleLine="true" />
<TextView android:textAppearance="@*android:style/Theme.Holo.Wallpaper" android:layout_width="fill_parent" android:layout_height="wrap_content" android:singleLine="true" />
</com.android.systemui.statusbar.TickerView>
</LinearLayout>
<com.android.systemui.statusbar.DateView android:textAppearance="@*android:style/TextAppearance.StatusBar.Icon" android:gravity="left|center" android:id="@id/date" android:background="@drawable/statusbar_background" android:paddingLeft="6.0px" android:paddingRight="6.0px" android:layout_width="wrap_content" android:layout_height="fill_parent" android:singleLine="true" />
</com.android.systemui.statusbar.StatusBarView>
Then recompile, prepare and push. If that's not working for you, can I suggest using the zip maker option? It's a lot more convenient than pushing as it creates a flashable backup zip automatically. Which saves a lot of time having to put things back to normal. It also sorts out permissions as well, which could be part of the problem.
I'd like to help solve this problem for you if I can.
Click to expand...
Click to collapse
It is a moot point now as i'm on MROM. I do not trust CWMR v5 enough to go back to 2.3.6 (it has blown restores on me before). Sorry. I looked at your version of layout and see that i would have to study it for a bit side by side to see what you have done. I did a TMA compile of mine and then prep, zip align and push. No joy. Then I started playing with apktool and then looking at how to get it the framework stuff it needed to compile it. All of this was new to me and I could have been making perhaps 10 mistakes, so i opted for flashing 2 files and onward. sure, it's always fun to find a fix, but stock 2.3.6 was seeming to have a bit of data overhead on it and I would have wanted to try a custom ROM anyway. Sorry
Worked for GB 2.3.6 65.1.40.XT910AsiaRetail.en.03 Razr Maxx
Thanks for your excellent post!
Just reporting that I could successfully remove carrier name from status bar (just that step) on my Motorola Razr Maxx running rooted stock GB 2.3.6 65.1.40.XT910AsiaRetail.en.03 - however I had to use modified instructions.
When I changed the android:textSize to zero and the android:maxLength to zero, my status bar was completely empty.
So I only changed the android:maxLength to zero, and this got rid of the carrier name, but kept the signal bars / battery icon.
Now I need to get onto the battery mod...!
Thanks but I think my room is different with yours
Ex:
1. Remove carrier name from status bar
Open res/layout/status_bar.xml I can not find your red line:
<TextView android:textAppearance="@android:style/TextAppearance.StatusBar.Icon" android:textSize="16.0sp" android:textStyle="bold" android:gravity="left|center" android:id="@id/onsText" androidaddingLeft="6.0px" android:layout_width="wrap_content" android:layout_height="fill_parent" android:singleLine="true" android:maxLength="18" />
Click to expand...
Click to collapse
This is my code:
<?xml version="1.0" encoding="utf-8"?>
<com.android.systemui.statusbar.phone.PhoneStatusBarView androidrientation="vertical" android:background="@drawable/status_bar_background" android:focusable="true" android:descendantFocusability="afterDescendants"
xmlns:android="http://schemas.android.com/apk/res/android"
xmlns:systemui="http://schemas.android.com/apk/res/com.android.systemui">
<LinearLayout androidrientation="horizontal" android:id="@id/icons" androidaddingLeft="6.0dip" androidaddingRight="6.0dip" android:layout_width="fill_parent" android:layout_height="fill_parent">
<LinearLayout androidrientation="horizontal" android:layout_width="0.0dip" android:layout_height="fill_parent" android:layout_weight="1.0">
<com.android.systemui.statusbar.StatusBarIconView android:id="@id/moreIcon" android:visibility="gone" android:layout_width="@dimen/status_bar_icon_size" android:layout_height="fill_parent" android:src="@drawable/stat_notify_more" />
<com.android.systemui.statusbar.phone.IconMerger android:gravity="center_vertical" androidrientation="horizontal" android:id="@id/notificationIcons" android:layout_width="fill_parent" android:layout_height="fill_parent" android:layout_alignParentLeft="true" />
</LinearLayout>
<LinearLayout android:gravity="center_vertical" androidrientation="horizontal" android:id="@id/statusIcons" android:layout_width="wrap_content" android:layout_height="fill_parent" />
<LinearLayout android:gravity="center" androidrientation="horizontal" android:id="@id/signal_battery_cluster" androidaddingLeft="2.0dip" android:layout_width="wrap_content" android:layout_height="fill_parent">
<include android:id="@id/signal_cluster" android:layout_width="wrap_content" android:layout_height="wrap_content" layout="@layout/signal_cluster_view" />
<ImageView android:id="@id/battery" androidaddingLeft="4.0dip" android:layout_width="wrap_content" android:layout_height="wrap_content" />
</LinearLayout>
<com.android.systemui.statusbar.policy.Clock android:textAppearance="@style/TextAppearance.StatusBar.Clock" android:gravity="left|center" android:id="@id/clock" androidaddingLeft="6.0dip" android:layout_width="wrap_content" android:layout_height="fill_parent" android:singleLine="true" />
</LinearLayout>
<LinearLayout androidrientation="horizontal" android:id="@id/ticker" androidaddingLeft="6.0dip" android:animationCache="false" android:layout_width="fill_parent" android:layout_height="fill_parent">
<ImageSwitcher android:id="@id/tickerIcon" android:layout_width="@dimen/status_bar_icon_size" android:layout_height="@dimen/status_bar_icon_size" android:layout_marginRight="4.0dip">
<com.android.systemui.statusbar.AnimatedImageView android:layout_width="@dimen/status_bar_icon_size" android:layout_height="@dimen/status_bar_icon_size" android:scaleType="center" />
<com.android.systemui.statusbar.AnimatedImageView android:layout_width="@dimen/status_bar_icon_size" android:layout_height="@dimen/status_bar_icon_size" android:scaleType="center" />
</ImageSwitcher>
<com.android.systemui.statusbar.phone.TickerView android:id="@id/tickerText" androidaddingTop="2.0dip" androidaddingRight="10.0dip" android:layout_width="0.0dip" android:layout_height="wrap_content" android:layout_weight="1.0">
<TextView android:textAppearance="@style/TextAppearance.StatusBar.PhoneTicker" android:layout_width="fill_parent" android:layout_height="wrap_content" android:singleLine="true" />
<TextView android:textAppearance="@style/TextAppearance.StatusBar.PhoneTicker" android:layout_width="fill_parent" android:layout_height="wrap_content" android:singleLine="true" />
</com.android.systemui.statusbar.phone.TickerView>
</LinearLayout>
</com.android.systemui.statusbar.phone.PhoneStatusBarView>
Click to expand...
Click to collapse
2. Remove carrier name at bottom of pull-down menu
Open res/layout/status_bar_tracking.xml I can find your red line. Very good. But it litte different:
<?xml version="1.0" encoding="utf-8"?>
<com.android.systemui.statusbar.phone.TrackingView androidrientation="vertical" androidaddingLeft="0.0px" androidaddingRight="0.0px" androidaddingBottom="0.0px" android:focusable="true" android:visibility="gone" android:descendantFocusability="afterDescendants"
xmlns:android="http://schemas.android.com/apk/res/android">
<FrameLayout android:background="@drawable/notification_tracking_bg" android:layout_width="fill_parent" android:layout_height="wrap_content" android:layout_weight="1.0">
<com.android.systemui.statusbar.phone.CarrierLabel android:textAppearance="@style/TextAppearance.StatusBar.Clock" android:gravity="center" android:layout_gravity="bottom" androidaddingBottom="20.0dip" android:layout_width="fill_parent" android:layout_height="wrap_content" />
</FrameLayout>
<com.android.systemui.statusbar.phone.CloseDragHandle androidrientation="vertical" android:id="@id/close" android:layout_width="fill_parent" android:layout_height="wrap_content">
<ImageView android:layout_gravity="bottom" android:layout_width="fill_parent" android:layout_height="wrap_content" android:src="@drawable/status_bar_close_on" android:scaleType="fitXY" />
</com.android.systemui.statusbar.phone.CloseDragHandle>
</com.android.systemui.statusbar.phone.TrackingView>
Click to expand...
Click to collapse
3. Remove carrier name at top of pull-down menu
I do not know
4. Remove carrier name from lockscreen
-Decompile framework-res.apk
-Open res/layout/keyguard_screen_tab_unlock.xml.
I can find your red line. Very good. But it litte different:
<?xml version="1.0" encoding="utf-8"?>
<GridLayout android:gravity="center_horizontal" androidrientation="vertical" android:layout_width="fill_parent" android:layout_height="fill_parent"
xmlns:android="http://schemas.android.com/apk/res/android">
<com.android.internal.widget.DigitalClock android:layout_gravity="right" android:id="@id/time" android:layout_marginTop="@dimen/keyguard_lockscreen_status_line_clockfont_top_margin" android:layout_marginRight="@dimen/keyguard_lockscreen_status_line_font_right_margin" android:layout_marginBottom="12.0dip">
<TextView android:textAppearance="?textAppearanceMedium" android:textSize="@dimen/keyguard_lockscreen_clock_font_size" android:textColor="@color/lockscreen_clock_background" android:ellipsize="none" android:id="@id/timeDisplayBackground" android:layout_width="wrap_content" android:layout_height="wrap_content" android:layout_marginBottom="6.0dip" android:singleLine="true" />
<TextView android:textAppearance="?textAppearanceMedium" android:textSize="@dimen/keyguard_lockscreen_clock_font_size" android:textColor="@color/lockscreen_clock_foreground" android:ellipsize="none" android:id="@id/timeDisplayForeground" android:layout_width="wrap_content" android:layout_height="wrap_content" android:layout_marginBottom="6.0dip" android:singleLine="true" android:layout_alignLeft="@id/timeDisplayBackground" android:layout_alignTop="@id/timeDisplayBackground" />
<TextView android:textSize="14.0sp" android:textColor="@color/lockscreen_clock_foreground" android:ellipsize="none" android:id="@id/am_pm" android:layout_width="wrap_content" android:layout_height="wrap_content" android:layout_marginLeft="8.0dip" android:layout_marginTop="18.0dip" android:singleLine="true" android:layout_toRightOf="@id/timeDisplayForeground" android:layout_alignBottom="@id/timeDisplayForeground" />
</com.android.internal.widget.DigitalClock>
<LinearLayout android:layout_gravity="right" androidrientation="horizontal" android:layout_marginRight="@dimen/keyguard_lockscreen_status_line_font_right_margin">
<TextView android:textAppearance="?textAppearanceMedium" android:textSize="@dimen/keyguard_lockscreen_status_line_font_size" android:ellipsize="marquee" android:id="@id/date" android:layout_width="wrap_content" android:layout_height="wrap_content" android:singleLine="true" />
<TextView android:textAppearance="?textAppearanceMedium" android:textSize="@dimen/keyguard_lockscreen_status_line_font_size" android:ellipsize="marquee" android:id="@id/alarm_status" android:layout_width="wrap_content" android:layout_height="wrap_content" android:layout_marginLeft="16.0dip" android:singleLine="true" android:drawablePadding="4.0dip" />
</LinearLayout>
<TextView android:textAppearance="?textAppearanceMedium" android:textSize="@dimen/keyguard_lockscreen_status_line_font_size" android:ellipsize="marquee" android:layout_gravity="right" android:id="@id/status1" android:layout_marginRight="@dimen/keyguard_lockscreen_status_line_font_right_margin" android:singleLine="true" android:drawablePadding="4.0dip" />
<TextView android:textAppearance="?textAppearanceMedium" android:textSize="@dimen/keyguard_lockscreen_status_line_font_size" android:ellipsize="marquee" android:layout_gravity="right" android:id="@id/dm_lock_prompt" android:visibility="gone" android:layout_marginRight="@dimen/keyguard_lockscreen_status_line_font_right_margin" android:singleLine="true" android:drawablePadding="4.0dip" />
<Space android:layout_gravity="fill" />
<Button android:layout_gravity="right" android:id="@id/emergencyCallButton" android:visibility="gone" android:layout_width="wrap_content" android:layout_height="wrap_content" android:layout_marginTop="4.0dip" android:layout_marginRight="16.0dip" android:text="@string/lockscreen_emergency_call" android:drawableLeft="@drawable/lockscreen_emergency_button" android:drawablePadding="4.0dip" style="?android:attr/buttonBarButtonStyle" />
<RelativeLayout android:layout_width="fill_parent" android:layout_height="302.0dip">
<com.android.internal.widget.multiwaveview.MultiWaveView androidrientation="horizontal" android:id="@id/unlock_widget" android:layout_width="fill_parent" android:layout_height="fill_parent" android:layout_alignParentBottom="true" android:targetDescriptions="@array/lockscreen_target_descriptions_with_camera" android:directionDescriptions="@array/lockscreen_direction_descriptions" android:targetDrawables="@array/lockscreen_targets_with_camera" android:handleDrawable="@drawable/ic_lockscreen_handle" android:rightChevronDrawable="@drawable/ic_lockscreen_chevron_right" android:waveDrawable="@drawable/ic_lockscreen_outerring" androiduterRadius="@dimen/multiwaveview_target_placement_radius" android:hitRadius="@dimen/multiwaveview_hit_radius" android:vibrationDuration="20" android:snapMargin="@dimen/multiwaveview_snap_margin" android:feedbackCount="3" android:verticalOffset="60.0dip" android:horizontalOffset="0.0dip" />
<TextView android:textAppearance="?textAppearanceMedium" android:textSize="@dimen/keyguard_lockscreen_status_line_font_size" android:textColor="?textColorSecondary" android:ellipsize="marquee" android:gravity="center_horizontal" android:id="@id/carrier" android:layout_width="fill_parent" android:layout_height="wrap_content" android:layout_marginBottom="12.0dip" android:singleLine="true" android:layout_alignParentBottom="true" />
</RelativeLayout>
<LinearLayout android:gravity="center" androidrientation="horizontal" android:layout_width="fill_parent" android:weightSum="2.0" style="?android:attr/buttonBarStyle">
<Button android:textSize="@dimen/keyguard_lockscreen_status_line_font_size" android:layout_gravity="center_horizontal" android:id="@id/emergencyCallButton" android:visibility="gone" android:layout_width="0.0dip" android:layout_height="wrap_content" android:text="@string/lockscreen_emergency_call" android:drawableLeft="@drawable/lockscreen_emergency_button" android:drawablePadding="0.0dip" android:layout_weight="1.0" style="?android:attr/buttonBarButtonStyle" />
</LinearLayout>
<include android:layout_gravity="fill" android:id="@id/transport" android:layout_width="0.0dip" android:layout_height="0.0dip" android:layout_column="0" android:layout_row="0" android:layout_rowSpan="4" android:layout_columnSpan="1" layout="@layout/keyguard_transport_control" />
</GridLayout>
Click to expand...
Click to collapse
--->>> Thanks you so much. :X good man.
Can you show me cause i am noob and newbie. :*
Worked like a charm !
Didn't know what file to edit at first in the 'android ocean' and thanks to you I now do.
Thank you for that !

[How to][StatusBar] Custom txt/Carrier/center clock/custom icons/left side icons

Hello there
Here is a simple guide to add a Custom name to top-left status bar.
All You need is:
- Know how to decompile/recompiling Apk file
- notepad++
- Tool for decompiling, : apkmanager/apktool/Virtous/apkmultitools ...
1. Decompile SystemUI.apk
2. navigate to res/layout/status_bar.xml
3.Open Status_bar.xml with notepad++
4.Copy this line like the following example:
Code:
<TextView android:textAppearance="@style/TextAppearance.StatusBar.Clock" android:gravity="left|center" android:layout_width="wrap_content" android:layout_height="fill_parent" android:text="@string/hello" android:singleLine="true" />
Code:
<?xml version="1.0" encoding="utf-8"?>
<com.android.systemui.statusbar.phone.PhoneStatusBarView android:orientation="vertical" android:id="@id/status_bar" android:background="@drawable/status_bar_background" android:focusable="true" android:fitsSystemWindows="true" android:descendantFocusability="afterDescendants"
xmlns:android="http://schemas.android.com/apk/res/android"
xmlns:systemui="http://schemas.android.com/apk/res/com.android.systemui">
<ImageView android:id="@id/notification_lights_out" android:paddingBottom="2.0dip" android:visibility="gone" android:layout_width="@dimen/status_bar_icon_size" android:layout_height="fill_parent" android:src="@drawable/ic_sysbar_lights_out_dot_small" android:scaleType="center" android:paddingStart="6.0dip" />
<LinearLayout android:orientation="horizontal" android:id="@id/status_bar_contents" android:layout_width="fill_parent" android:layout_height="fill_parent" android:paddingStart="6.0dip" android:paddingEnd="6.0dip">
<LinearLayout android:orientation="horizontal" android:id="@id/notification_icon_area" android:layout_width="0.0dip" android:layout_height="fill_parent" android:layout_weight="1.0">
[COLOR="Red"][B] <TextView android:textAppearance="@style/TextAppearance.StatusBar.Clock" android:gravity="left|center" android:layout_width="wrap_content" android:layout_height="fill_parent" android:text="@string/hello" android:singleLine="true" />[/B][/COLOR]
<com.android.systemui.statusbar.StatusBarIconView android:id="@id/moreIcon" android:visibility="gone" android:layout_width="@dimen/status_bar_icon_size" android:layout_height="fill_parent" android:src="@drawable/stat_notify_more" />
<com.android.systemui.statusbar.phone.IconMerger android:gravity="center_vertical" android:orientation="horizontal" android:id="@id/notificationIcons" android:layout_width="fill_parent" android:layout_height="fill_parent" android:layout_alignParentStart="true" />
</LinearLayout>
<LinearLayout android:gravity="center" android:orientation="horizontal" android:id="@id/clock" android:layout_width="wrap_content" android:layout_height="fill_parent">
<com.android.systemui.statusbar.policy.Clock android:textAppearance="@style/TextAppearance.StatusBar.Clock" android:gravity="center" android:layout_width="wrap_content" android:layout_height="fill_parent" android:singleLine="true" />
</LinearLayout>
<LinearLayout android:gravity="right|center" android:orientation="horizontal" android:id="@id/system_icon_area" android:layout_width="0.0dip" android:layout_height="fill_parent" android:layout_weight="1.0">
<LinearLayout android:gravity="right|center" android:orientation="horizontal" android:id="@id/statusIcons" android:layout_width="wrap_content" android:layout_height="fill_parent" />
<LinearLayout android:gravity="right|center" android:orientation="horizontal" android:id="@id/signal_battery_cluster" android:paddingLeft="2.0dip" android:layout_width="wrap_content" android:layout_height="fill_parent">
<com.android.systemui.statusbar.policy.Traffic android:textAppearance="@style/TextAppearance.StatusBar.Traffic" android:gravity="left|center" android:id="@id/traffic" android:layout_width="wrap_content" android:layout_height="fill_parent" android:singleLine="true" />
<include android:id="@id/signal_cluster" android:layout_width="wrap_content" android:layout_height="wrap_content" layout="@layout/signal_cluster_view" />
<TextView android:textAppearance="@style/TextAppearance.StatusBar.Battery" android:gravity="center" android:id="@id/battery_text" android:paddingLeft="4.0dip" android:layout_width="wrap_content" android:layout_height="fill_parent" android:singleLine="true" />
<com.erryy.BatteryText android:textAppearance="@style/TextAppearance.StatusBar.Clock" android:textSize="12.0dip" android:gravity="center" android:paddingLeft="4.0dip" android:layout_width="wrap_content" android:layout_height="fill_parent" android:layout_marginRight="-3.0dip" android:singleLine="true" />
<ImageView android:id="@id/battery" android:layout_width="wrap_content" android:layout_height="wrap_content" android:paddingStart="4.0dip" />
</LinearLayout>
</LinearLayout>
</LinearLayout>
<LinearLayout android:orientation="horizontal" android:id="@id/ticker" android:animationCache="false" android:layout_width="fill_parent" android:layout_height="fill_parent" android:paddingStart="6.0dip">
<ImageSwitcher android:id="@id/tickerIcon" android:layout_width="@dimen/status_bar_icon_size" android:layout_height="@dimen/status_bar_icon_size" android:layout_marginEnd="4.0dip">
<com.android.systemui.statusbar.AnimatedImageView android:layout_width="@dimen/status_bar_icon_size" android:layout_height="@dimen/status_bar_icon_size" android:scaleType="center" />
<com.android.systemui.statusbar.AnimatedImageView android:layout_width="@dimen/status_bar_icon_size" android:layout_height="@dimen/status_bar_icon_size" android:scaleType="center" />
</ImageSwitcher>
<com.android.systemui.statusbar.phone.TickerView android:id="@id/tickerText" android:paddingTop="2.0dip" android:layout_width="0.0dip" android:layout_height="wrap_content" android:layout_weight="1.0" android:paddingEnd="10.0dip">
<TextView android:textAppearance="@style/TextAppearance.StatusBar.PhoneTicker" android:layout_width="fill_parent" android:layout_height="wrap_content" android:singleLine="true" />
<TextView android:textAppearance="@style/TextAppearance.StatusBar.PhoneTicker" android:layout_width="fill_parent" android:layout_height="wrap_content" android:singleLine="true" />
</com.android.systemui.statusbar.phone.TickerView>
</LinearLayout>
</com.android.systemui.statusbar.phone.PhoneStatusBarView>
"android:textAppearance="@style/TextAppearance.StatusBar.Clock" means that your custom text will have same colors and dimensions defined for clock (these are defined in /values/styles: 16dip and Holo Blue Light ).
If You want to add Your dip and your preferred color, just replaces above line with this:
android:textSize="15.0dip" android:textColor="#ffa6a6a6"
Code:
<TextView [COLOR="Red"]android:textSize="15.0dip" android:textColor="#ffa6a6a6"[/COLOR] android:gravity="left|center" android:layout_width="wrap_content" android:layout_height="fill_parent" android:text="@string/hello" android:singleLine="true" />
You can change text color and size to fit your needs.
android:textSize="x.0dip"
and android:textColor="#hex code of Your preferred color"
for example #ffdd4814 is Ubuntu Orange
5) Now, the last step:
Navigate to res/values/string
and add this at the end of the file:
Code:
<string name="hello">Your text here</string>
Like this example:
Code:
... <string name="quick_settings_rssi_label">RSSI</string>
<string name="quick_settings_rssi_emergency_only">Emergency Calls Only</string>
<string name="quick_settings_settings_label">Settings</string>
<string name="quick_settings_time_label">Time</string>
<string name="quick_settings_user_label">Me</string>
<string name="quick_settings_wifi_label">Wi-Fi</string>
<string name="quick_settings_wifi_not_connected">Not Connected</string>
<string name="quick_settings_wifi_no_network">No Network</string>
<string name="quick_settings_wifi_off_label">Wi-Fi Off</string>
<string name="quick_settings_wifi_display_label">Wi-Fi Display</string>
<string name="quick_settings_wifi_display_no_connection_label">Wireless Display</string>
<string name="quick_settings_brightness_dialog_title">Brightness</string>
<string name="quick_settings_brightness_dialog_auto_brightness_label">AUTO</string>
<string name="status_bar_help_title">Notifications appear here</string>
<string name="status_bar_help_text">"Access them anytime by swiping down.
Swipe down again for system controls."</string>
<string name="accessibility_sleep_button">Sleep button.</string>
[COLOR="Red"]<string name="hello">Your text here</string>[/COLOR]
</resources>
6) Recompile back ... enjoy!!
Service Provider
White clock & wifi/battery/signal white resources [how to]
Center Clock, left signals and how to replace battery/signal/wifi icons with custom​
Guidelines to correctly set jdk in Windows and Linux​
To flash Your mods... ​
thanks for the awsome guide bro ..:victory::victory:
Added guidelines to add service provider, center clock, change icons with custom, move icons and change colors
Service Provider
White clock & wifi/battery/signal white resources [how to]
Center Clock, left signals and how to replace battery/signal/wifi icons with custom
Any chance of those moved icons options become a xposed module? That would be great!
guigadourado said:
Any chance of those moved icons options become a xposed module? That would be great!
Click to expand...
Click to collapse
This threads are for help people to understand how android resources works
Sure, You can also make a module
https://github.com/rovo89/XposedBridge/wiki/Development-tutorial
but, as You can see, there is very long tutorial ... :silly:
Not now, because i'm very busy with my studies, but When I'll have time I will try to make a module for Xposed :good:

xml self closing tag on a new line

Hi
I would like this to show after typing a xml element
Code:
<TextView
android:layout_width=""
android:layout_height=""
/>
but not this:
Code:
<TextView
android:layout_width=""
android:layout_height=""/>
Is there a way to get Android Studio to do this?
Thank you

[Guide][How to add custom image on lockscreen, our transparent lock]

Ok!
Lets go.
Decompile your framework-res.apk and go to framework-res/res/layout and seach for "keyguard_screen_tab_unlock.xml"
open the xml and seach for this line
HTML:
<RelativeLayout android:gravity="center_horizontal" android:layout_width="fill_parent" android:layout_height="fill_parent"
and replace for this line.
HTML:
<RelativeLayout android:gravity="center_horizontal" android:id="@id/root" android:background="@drawable/yourpng" android:layout_width="fill_parent" android:layout_height="fill_parent"
--> create a png with the resolutions of your device and put the drawable folder.
Remember that in "youpng" is the name that u goes in your image, ok? xD
for transparent lock, just decrease opacidad the png
Don't forget the press buton thanks

Categories

Resources