yashsingh1/xdaforums huggingface dataset:
[Nexus 4 Themes and Apps] :
You can add

<LinearLayout android:gravity="center" android:orientation="horizontal" android:layout_width="wrap_content" android:layout_height="fill_parent" android:id="@id/clock">
<com.android.systemui.statusbar.policy.Clock android:textAppearance="@style/TextAppearance.StatusBar.Clock" android:gravity="center" android:id="@id/clock" android:visibility="gone" android:layout_width="wrap_content" android:layout_height="fill_parent" android:singleLine="true" android:paddingStart="6.0dip" />
</LinearLayout>

but You should check if You have

1. com.android.systemui.statusbar.policy.Clock smali

2. style/TextAppearance.StatusBar.Clock

You can add

<style name="TextAppearance.StatusBar.Clock" parent="@*android:style/TextAppearance.StatusBar.Icon">
<!-- Note: must be dp to fit in status bar -->
<item name="android:textSize">16dp</item>
<item name="android:textStyle">normal</item>
<item name="android:textColor">#ffffffff</item>
</style>

3. id/clock

If there's no clock public You should add it and id values
[Nexus 4 Themes and Apps] :
screenshot please? :)
[Nexus 4 Themes and Apps] :
Can You reupload the files... i will do for You :)

--------------------

Hey guys

for Gb look also here .. i'm not really expert on gb :)

http://xdaforums.com/showthread.php?t=1908063

http://xdaforums.com/showpost.php?p=44241841&postcount=2

http://xdaforums.com/showthread.php?t=2206492
[Nexus 4 Themes and Apps] jimmy16:
It is possible to arrange like first signal bars and than wifi bars? like ios7 style
[Nexus 4 Themes and Apps] limyuyang:
Oops, I'm so sorry about it.

Here you go: https://www.dropbox.com/s/p492gn7zj7tlpk3/SystemUI.apk.rar
[Nexus 4 Themes and Apps] Truepeace:
After doing all this I have to recompile the apk and then install it normally like any other apk on my phone?

And is it correct to follow this tutorial for compiling/recompiling? http://xdaforums.com/showthread.php?t=2251719&highlight=guide+apktool
[Nexus 4 Themes and Apps] :
follow this :)

http://xdaforums.com/showpost.php?p=46373043&postcount=27
[Nexus 4 Themes and Apps] :
No... You should push it via a root explorer and give right permissions or using a flashable zip

You can use the one here

http://xdaforums.com/showpost.php?p=46498500&postcount=73

there's already a systemUI.apk inside.... just delete it using 7-zip and replace with your modded systemUI.apk and flash

to use apktool

1) Install the framework

apktool if framework-res.apk

2) decompile systemUI.apk

apktool d SystemUI.apk

3) make Your mods

4) recompile SystemUI

apktool b SystemUI

5) Go to SystemUI>dist folder,

delete the first compiled SystemUI

6) Open SystemUI/build/apk folder

7) Open the original SystemUI.apk using Winrar or 7zip

8)

Drag&Drop META-INF folder and androidmanifest.xml

inside /build/apk folder overwriting everything

9) Recompile back

apktool b SystemUI

10) Use the flashable zip to push /dist/SystemUI.apk via a recovery

done :)
[Nexus 4 Themes and Apps] :
Send me directly the normal SystemUI.apk (not the decompiled one) and also the framework-res.apk :) without it I can't do anything :)
[Nexus 4 Themes and Apps] Truepeace:
sorry I am still a noob but I like to learn like when I flashed a custom rom on my rooted phone a few weeks ago.

What do you mean by "You should push it via a root explorer and give right permissions or using a flashable zip" I should put it on my phone's sd card and then what? Flash it like we flash roms with cwm recovery?

"there's already a systemUI.apk inside.... just delete it using 7-zip and replace with your modded systemUI.apk and flash"

I downloaded your file there are two folders one of them has systemui.apk in it. But why did you tell me to download it? What is it? And isn't it specific to your phone/rom ? Note: When I wanted to start your tutorial, I found the systemui.apk in the cyanogenmod rom zip file but then I had to search for tutorials for decompiling/recompiling.

"to use apktool" So I guess with apktool I can compile recompile like in the video I watched here http://xdaforums.com/showthread.php?t=2527867

Sorry for my questions, they may seem very stupid to you but I like to learn new things and I couldn't find a full noob friendly tutorial for that.
[Nexus 4 Themes and Apps] :
What do you mean by "You should push it via a root explorer and give right permissions or using a flashable zip" I should put it on my phone's sd card and then what? Flash it like we flash roms with cwm recovery?

You can copy the modded .apk in /system/app folder and give rw r r permissions

like here

http://cdn.droidviews.com/wp-content/uploads/2013/04/sec-launcher-permission.jpg

or You can directly flash the modded .apk using the zip

"there's already a systemUI.apk inside.... just delete it using 7-zip and replace with your modded systemUI.apk and flash"

I downloaded your file there are two folders one of them has systemui.apk in it. But why did you tell me to download it? What is it? And isn't it specific to your phone/rom ? Note: When I wanted to start your tutorial, I found the systemui.apk in the cyanogenmod rom zip file but then I had to search for tutorials for decompiling/recompiling.

This is a flashable zip to flash the modded .apk

You can delete the SystemUI.apk from the zip using 7zip and place Your modded SystemUI.apk inside /system/app folder

then You reboot to recovery and flash Your mod ;)

"to use apktool" So I guess with apktool I can compile recompile like in the video I watched here http://xdaforums.com/showthread.php?t=2527867

Sorry for my questions, they may seem very stupid to you but I like to learn new things and I couldn't find a full noob friendly tutorial for that.

Exactly! :)

Yon can follow that video if You want, it's the same ;)
[Nexus 4 Themes and Apps] Ic3y83:
I tried, but then the clock is over my signal and wifi icon. Real messy.:silly:

I tried "Xposed framework - Wanam Xposed" to change the clock position, but that didn't work either. (clock stays in same position if i try right, center or left.:confused:

I forgot to mention that i have an Galaxy S3.:p

Thnx for your help! Really appreciated. Maybe it's better if i ask it in the thread where i downloaded the ROM. (Smart Droid);)
[Nexus 4 Themes and Apps] limyuyang:
Alright, now here you go.

Systemui.apk : https://www.dropbox.com/s/mcakx8055kytuj4/SystemUI.apk

Framework-res.apk :https://www.dropbox.com/s/mm6zw9hlmd1oduo/framework-res.apk
[Nexus 4 Themes and Apps] :
ah.touchwiz :)

Try to make same mods in tw_status_bar.xml ;)
[Nexus 4 Themes and Apps] Ic3y83:
I'am at work now. I try when I get home. I'll let you now. ;)

Thnx!
[Nexus 4 Themes and Apps] :
https://www.dropbox.com/sh/0s03ddcgcwnbfti/ow_-3Gnn3h

this folder contains

signal+txt

txt+signal

signal+txt+centerclock (don't know if it works)

txt+signal+centerclock

revert
[Nexus 4 Themes and Apps] limyuyang:
What does the signal means ? Do you mean left signal icons ?

What's the difference between signal+text and text+signal ? Do you mean the arrangement of signal and text ?

Thank you for your hard work. Tomorrow I'll text it and give you a feedback. :good:
[Nexus 4 Themes and Apps] :
Exactly :)
[Nexus 4 Themes and Apps] Truepeace:
Error when recompiling

I have this error when recompiling

C:\Users\Fadi\Downloads\Compressed\New folder\Apktool>apktool b SystemUI
I: Using Apktool 2.0.0-Beta7 on SystemUI
I: Checking whether sources has changed...
I: Smaling...
I: Checking whether resources has changed...
I: Building resources...
C:\Users\Fadi\Downloads\Compressed\New folder\Apktool\SystemUI\res\layout\status
_bar.xml:8: error: Error: No resource found that matches the given name (at 'tex
t' with value '@string/hello').
Exception in thread "main" brut.androlib.AndrolibException: brut.androlib.Androl
ibException: brut.common.BrutException: could not exec command: [C:\Users\Fadi\A
ppData\Local\Temp\brut_util_Jar_8473521526562042154.tmp, p, --forced-package-id,
127, --min-sdk-version, 17, --target-sdk-version, 17, --version-code, 17, --ver
sion-name, 4.2.2-eng.jenkins.20130923.184428, -F, C:\Users\Fadi\AppData\Local\Te
mp\APKTOOL6566898991623935652.tmp, -0, arsc, -I, C:\Users\Fadi\apktool\framework
\1.apk, -S, C:\Users\Fadi\Downloads\Compressed\New folder\Apktool\SystemUI\res,
-M, C:\Users\Fadi\Downloads\Compressed\New folder\Apktool\SystemUI\AndroidManife
st.xml]
at brut.androlib.Androlib.buildResourcesFull(Androlib.java:434)
at brut.androlib.Androlib.buildResources(Androlib.java:362)
at brut.androlib.Androlib.build(Androlib.java:285)
at brut.androlib.Androlib.build(Androlib.java:258)
at brut.apktool.Main.cmdBuild(Main.java:233)
at brut.apktool.Main.main(Main.java:88)
Caused by: brut.androlib.AndrolibException: brut.common.BrutException: could not
exec command: [C:\Users\Fadi\AppData\Local\Temp\brut_util_Jar_84735215265620421
54.tmp, p, --forced-package-id, 127, --min-sdk-version, 17, --target-sdk-version
, 17, --version-code, 17, --version-name, 4.2.2-eng.jenkins.20130923.184428, -F,
C:\Users\Fadi\AppData\Local\Temp\APKTOOL6566898991623935652.tmp, -0, arsc, -I,
C:\Users\Fadi\apktool\framework\1.apk, -S, C:\Users\Fadi\Downloads\Compressed\Ne
w folder\Apktool\SystemUI\res, -M, C:\Users\Fadi\Downloads\Compressed\New folder
\Apktool\SystemUI\AndroidManifest.xml]
at brut.androlib.res.AndrolibResources.aaptPackage(AndrolibResources.jav
a:481)
at brut.androlib.Androlib.buildResourcesFull(Androlib.java:415)
... 5 more
Caused by: brut.common.BrutException: could not exec command: [C:\Users\Fadi\App
Data\Local\Temp\brut_util_Jar_8473521526562042154.tmp, p, --forced-package-id, 1
27, --min-sdk-version, 17, --target-sdk-version, 17, --version-code, 17, --versi
on-name, 4.2.2-eng.jenkins.20130923.184428, -F, C:\Users\Fadi\AppData\Local\Temp
\APKTOOL6566898991623935652.tmp, -0, arsc, -I, C:\Users\Fadi\apktool\framework\1
.apk, -S, C:\Users\Fadi\Downloads\Compressed\New folder\Apktool\SystemUI\res, -M
, C:\Users\Fadi\Downloads\Compressed\New folder\Apktool\SystemUI\AndroidManifest
.xml]
at brut.util.OS.exec(OS.java:89)
at brut.androlib.res.AndrolibResources.aaptPackage(AndrolibResources.jav
a:475)
... 6 more
[Nexus 4 Themes and Apps] :
You missed the string value
[Nexus 4 Themes and Apps] Ic3y83:
Unfortunatly that file don't exist.

Only these:

"tw_status_bar_no_recent_apps.xml"

"tw_status_bar_recent_panel.xml"

"tw_system_bar_no_recent_apps.xml"

"tw_system_bar_recent_panel.xml"

ricky310711 (1 of the developers on that ROM) will look at it when he have the time.

Thnx for your help anyway! :good:
[Nexus 4 Themes and Apps] Truepeace:
Which one because I copied <string name="hello">Your text here</string> and I replaced "Your text here" with my text in the strings.xml file.
[Nexus 4 Themes and Apps] :
can You post the 8th line from status_bar.xml?
[Nexus 4 Themes and Apps] Truepeace:
These are lines 7,8,9,10

<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">
<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" />	<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_alignParentLeft="true" />
</LinearLayout>
[Nexus 4 Themes and Apps] :
It seems like You have 2 lines in the same line... line n°8 You have the textview with your custom text and <com.android.systemui.statusbar.StatusBarIconView

It should be like this ;)

<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">
<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" />	[COLOR="Red"]
<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" />[/COLOR]
<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_alignParentLeft="true" />
</LinearLayout>
[Nexus 4 Themes and Apps] Truepeace:
Here are my two files
[Nexus 4 Themes and Apps] :
this is an error :)

<string name="status_bar_help_text">"Access them anytime by swiping down.
<string name="hello">Fadi B.</string>
[COLOR="Red"]Swipe down again for system controls."</string>[/COLOR]

<string name="status_bar_help_text">"Access them anytime by swiping down.[COLOR="Red"]Swipe down again for system controls."</string>[/COLOR]
<string name="hello">Fadi B.</string>
</resources>
[Nexus 4 Themes and Apps] Truepeace:
Please please help me :'(

I corrected this and I got the new apk but then I wanted to put it on my phone following this tuto http://xdaforums.com/showthread.php?t=2235956

Now my phone keeps putting "Unfortunately, System UI has stopped." I tried rebooting, same thing. What did I do wrong? Maybe in the signing? The video tutorial http://xdaforums.com/showthread.php?t=2527867 used "zipalign -fv 4 ...." command while I read on other tutorials you should copy the original manifest and I don't know which files but in the video he didn't do it...

EDIT: I managed to have access to CWM by fast clicking before the error appears so I could reboot into recovery, does this help?

EDIT 2: The video told us to replace old meta-inf and android manifest in the new apk but he didn't show it so I didn't do it, was that the problem? :(

EDIT 3 :

I re edited systemui.apk with signing this time then I put it the flashable zip you gave me and then I sideloaded it in CWM and flashed it. Now I can use my phone but my status bar has disappeared.

What do you advise me to do? To reflash the original SystemUI.apk of my rom? I will try all this tomorrow.

EDIT4: I tried reputting my original SystemUI.apk and flashing it but I still didn't have the status bar.I don't know if I should reflash my custom ROM, do you have any advice?
[Nexus 4 Themes and Apps] limyuyang:
Thanks for helping me to add text. Unfortunately, there's a message pops up and showed : systemui.apk has stopped working. Besides, my status bar is gone. And I'm being forced to flash the revert zip. So I guess my phone can't add the text. :(

Well, forget about it. I think my phone can't add the text. Thanks for your work. Appreciate it. Have a nice day. :)
[Nexus 4 Themes and Apps] :
you should add meta-inf folder and androidmanifest :)

Sometimes,when you mod systemui and get FCs the only way to revert is to reflash the ROM...

if you post the systemui and framework-res.apk i will do the mod while you reflash the ROM

next time make a.backup before flash ;)
[Nexus 4 Themes and Apps] PigFire:
[MENTION=5266287]enricocid[/MENTION] what code if i want my service provider to center? thanks
[Nexus 4 Themes and Apps] Truepeace:
After messing up with the first file, I disabled SystemUI in settings, I rebooted, the error disappeared but I had no toolbar now. Then I went into recovery, I did a new SystemUI.apk signed this time and flashed it with your zip but it didn't change anything, when I enabled SystemUI the error kept popping and when I disabled it and rebooted there was no toolbar. I was desperate so I tried putting the original SystemUI.apk, same results, and here's what surprised me : I reflashed my full custom rom after wiping cache, dalvik cache and formatting only system without doing factory reset so I won't lose my apps' data, but again it didn't fix the error :( :(

I don't know what to do now, I hope you know how to help so here are the two files you asked me for, I extracted them from the custom rom zip.
[Nexus 4 Themes and Apps] :
I think YOu can try something like that

<?xml version="1.0" encoding="utf-8"?>
<com.android.systemui.statusbar.phone.PhoneStatusBarView android:id="@id/status_bar" android:background="@drawable/status_bar_background" android:focusable="true" android:fitsSystemWindows="true" android:descendantFocusability="afterDescendants" android:layout_width="fill_parent" android:layout_height="fill_parent"
xmlns:android="http://schemas.android.com/apk/res/android"
xmlns:systemui="http://schemas.android.com/apk/res/com.android.systemui">
[COLOR="Red"]<LinearLayout android:gravity="center" android:orientation="horizontal" android:layout_width="wrap_content" android:layout_height="fill_parent">
<com.android.systemui.statusbar.phone.CarrierLabel android:textAppearance="@style/TextAppearance.StatusBar.Clock" android:gravity="center" android:layout_width="wrap_content" android:layout_height="fill_parent" android:singleLine="true" />
</LinearLayout>[/COLOR]

I think You should make a backup of Your apps+data and make a full wipe to solve Your problems...

wipe data/factory reset

wipe cache

format system

format data

format cache

wipe dalvik cache

I will make You the mod tomorrow, now I'm out for work, what text You want? :)
[Nexus 4 Themes and Apps] Truepeace:
Thanks a lot for your quick reply and for your assistance. I really appreciate that. Ok I wanted to write from the beginning "Fadi B." like I did on my ipad but on the ipad it was much easier I only needed to have a tweak (fakecarrier) but here I messed up with my phone :(

How do you advise me to backup my app date? I know I can do that with Titanium Backup but it will take me some time since I have around 100 apps so backing them one after one will take time. I won't backup the contacts because they are synced with my gmail and the photos are on the sd card not on the phone memory.

Take your time, I hope everything will be fine :)
[Nexus 4 Themes and Apps] :
I really don't know... I never flash Roms, I always choose one Rom, a stock ... so I don't know what to use...

I used Super backup sms... but I don't know if it will allow You to make a full backup

maybe Rom toolbox or Titanium (pro version)
[Nexus 4 Themes and Apps] Truepeace:
Finally I made it :D

I factory reset the phone and wiped cache but the root was gone so I re rooted it and reflashed my custom rom and gaaps and kernel,

Then I followed this tuto http://xdaforums.com/showthread.php?t=2203166 that was much simpler and easier than the video one I saw previously for editing systemUI.apk and how to compile/recompile.

I pushed it through via file manager after I set the correct permissions and rebooted my phone. Now the status bar has my text in it :D

Thanks a lot and sorry if I asked you a lot these two days but now I am very happy I could do it on my own and with your help of course.
[Nexus 4 Themes and Apps] Gundozz:
hy....

I just wanna try tutor like this screen shoot .. but nothing happend.. my clock in status bar still right position...

can help me ?? I use lenovo A706 ...

sorry for bad language..

I'm from indonesia.. thanks
[Nexus 4 Themes and Apps] :
this guide was tested for Jellybean 4.3... and don't know if it works on previous versions...

what Android version are You using?

post your status_bar.xml here

If You have ICS try to look here

http://xdaforums.com/showpost.php?p=19760562&postcount=3

or If You're on Gingerbread try here:

http://xdaforums.com/showthread.php?t=1908063
[Nexus 4 Themes and Apps] Gundozz:
-----

Thanks for responds

my phone version 4.1.2

can't work ya ?

this my status_bar ..
[Nexus 4 Themes and Apps] :
I think You should follow some ICS guide because the layouts in first JB releases was really similar to it ...

here is modded status_bar.xml

try to use it and let me know ;)

View attachment status_bar.zip
[Nexus 4 Themes and Apps] Gundozz:
----

[report]

thanks for modded my status bar

but.. still doesn't work..

my clock still in right position ..

this screen shoot my phone .. after use status_bar modd from you
[Nexus 4 Themes and Apps] Gundozz:
thanks to bro [MENTION=5266287]enricocid[/MENTION] to respond my questions..

finally done 98% ..

I'm found to fix my problem n try edit msim_status_bar and work..

but if I not use data conection.. position clock move to replace position data conection...

mean.. clock not 100% center
[Nexus 4 Themes and Apps] Pain-N-Panic:
PLEASE help me lol. I am trying to add a custom image into the top left of my status bar. I used your tutorial but had to modify it a little bit. Here's the code that I placed into line 8 of my status_bar.xml:

<TextView android:background="@drawable/carrier_logo" android:gravity="left|center" android:layout_width="wrap_content" android:layout_height="fill_parent" android:singleLine="true" />

My custom image, named carrier_logo, is a png image that I placed into drawable-xxhdpi

I created a flashable zip with zip themer to enforce my modifications as I usually do (this is not my first time themeing) and when I flash the update.zip my systemui crashes and I cant do anything besides boot back into recovery and flash the undo.zip

I know my zip is working because when I check the drawable-xxhdpi folder within the systemui.apk the carrier_logo.png image is in there....it has to be my XML thats forcing my phone to crash. Below I attached a logcat that I took upon boot....I read through it but don't really know what I am looking at.

Specs-

Nexus 5 4.4.2 KitKat

Stock rooted w/ xposed framework installed.
[Nexus 4 Themes and Apps] Kimbaroth:
I'm trying to mod my systemUI, so I can move signal and battery icons to the left (like on iOS), but every time I try to decompile the APK I get some errors, can you help me with that??? My apk its from ParanoidAndroid 4+ (4.4.2).

Thanks in advance!!!

Edit:

I've uploaded an screenshot with the errors I get when I try to decompile, and my SystemUI.apk
[Nexus 4 Themes and Apps] t8ax:
try

apktool if SystemUI.apk

then

apktool d SystemUI.apk :confused:
[Nexus 4 Themes and Apps] Kimbaroth:
Hey, thanks a lot for your answer, but I get the same error. D=
[Nexus 4 Themes and Apps] t8ax:
try get framework-res.apk from your rom in /system/framerwork

apktool if framwork-res.apk

apktool if SystemUI.apk

apktool d SystemUI.apk

:silly:
[Nexus 4 Themes and Apps] Kimbaroth:
AWESOME!!!!

How do I recompile it??? Do I need to do anything special????
[Nexus 4 Themes and Apps] :
Use the ImageView...

the Textview is for texts only... ;)

and recompile back properly or You will get errors

http://xdaforums.com/showpost.php?p=49359716&postcount=131

To flash Your mods there's already a template in OP

http://xdaforums.com/showpost.php?p=46669740&postcount=78

just delete the apk already inside and replace with yours ;)

<ImageView android:background="@drawable/carrier_logo" android:gravity="left|center" android:layout_width="wrap_content" android:layout_height="fill_parent" android:singleLine="true" />

Use this guide to decompile and recompile back...

don't install the SystemUI.apk ... it doesn't contain the resources to decode itself... resources are contained in framework-res.apk

so to avoid problems delete the installed framework-res.apk in C:\Users\Administrator... delete the apktool folder and reinstall it again

follow carefully these instructions

http://xdaforums.com/showpost.php?p=49359716&postcount=131

--------

sorry for the late in reply, my internet connection is very bad these days :)
[Nexus 4 Themes and Apps] :
too much elements on Your status bar XD I don't know if You can perfectly center the clock, because other icons could move it to get space for correct visualization

Play with margins and padding... :) try to play with these values to center the clock... try also to reduce margins of others elements :)

http://android4beginners.com/2013/0...gins-and-paddings-in-android-layout/#more-363