[MOD] Various Carrier Label Style

feed3

Senior Member
Nov 17, 2011
1,040
727
0
The Land of Hornbill...
I dont know if there's any other thread has been created for this but i didnt see it.
So just want to share this little thing to whoever want it. Anyone are welcome to improvise it and make it even better/nicer.

This is just one quick mod i did during my 1 hour lunch time. :)
This only for stock ROM or Custom ROM based on STOCK. You already have "compact carrier label" features if you are using cm7.

NOTE: 1st thing 1st, please BACKUP the file that we will change (SystemUI.apk from /system/app/)!

STYLE #1:

How it looks:



The "No notification" and "On going" Title is covered by carrier label intentionally.

The easy way:

- Download the file from attachment,extract it and put the compiled xml file inside into your SystemUI.apk at res/layout/
- if you are linux user, then just open that apk file, drag and drop that xml to the stated folder (res/layout)
- I dont know how to do it from windows box since i didnt use windows but i believe you need to open the apk using 7zip.

DIY way (you need to know how to use apktool, decompiling/recompiling an apk. It is easy, trust me :) ):

If you wish to do it yourself, then you need to decompile SystemUI.apk.
(i use apktool and method by TheGrammarFreak HERE that also applied for centering the date and clock)

- open status_bar_expanded.xml from layout folder.

- on the line 4, you will see
Code:
     <LinearLayout android:orientation="horizontal" android:background="@drawable/title_bar_portrait" android:paddingTop="3.0dip" android:paddingRight="3.0dip" android:paddingBottom="5.0dip" android:layout_width="fill_parent" android:layout_height="wrap_content">
highlight the whole line until line 7 that consist
Code:
</LinearLayout>
and delete it (yes, delete!)



so it will looks like these


find line start with
Code:
<LinearLayout android:orientation="vertical" android:id="@id/latestItems"
create new line below it and paste this code into that new line
Code:
                <TextView android:layout_gravity="right|center" android:id="@id/clear_all_button" android:background="@android:drawable/btn_default_small" android:paddingLeft="15.0dip" android:paddingRight="15.0dip" android:layout_width="wrap_content" android:layout_height="wrap_content" android:layout_marginTop="4.0dip" android:layout_marginBottom="1.0dip" android:text="@string/status_bar_clear_all_button" style="?android:attr/buttonStyle" />


That is for "clear button". We repositioned it to the bottom.

Now, find line consist
Code:
</ScrollView>
and paste these code exactly below it

Code:
        <LinearLayout android:orientation="horizontal" android:layout_width="fill_parent" android:layout_height="wrap_content">
            <com.android.systemui.statusbar.CarrierLabel android:textAppearance="@style/TextAppearance.StatusBar.Title" android:gravity="bottom|center|center" android:background="@drawable/shade_bgcolor" android:layout_width="fill_parent" android:layout_height="wrap_content" android:singleLine="true" />
        </LinearLayout>
It should look like this;


That is for the Carrier Label. I made it centered by this line
Code:
android:gravity="bottom|center|center"
Save it and recompile back. I use TheGrammarFreak method to replace the compiled xml file.

Enjoy.. :)

STYLE #2:

How it looks like:



How to apply:

Download file carrier_label_mod2.zip in attachment,
unzip/extract it,
drag and drop files extracted into your SystemUI.apk, inside folder res / layout

** Lazy to add :p ** Ask me if anyone want to try it themself, want to change any line etc. :) **
 

Attachments

Last edited:

Black_jackss

Senior Member
Aug 25, 2011
706
115
0
Pekanbaru
I dont know if there's any other thread has been created for this but i didnt see it.
So just want to share this little thing to whoever want it. Anyone are welcome to improvise it and make it even better/nicer.

This is just one quick mod i did during my 1 hour lunch time. :)
This only for stock ROM. You already have "compact carrier label" features if you are using cm7.

NOTE: 1st thing 1st, please BACKUP the file that we will change (SystemUI.apk from /system/app/)!

How it looks:



The "No notification" and "On going" Title is covered by carrier label intentionally.

The easy way:

- Download the file from attachment,extract it and put the compiled xml file inside into your SystemUI.apk at res/layout/
- if you are linux user, then just open that apk file, drag and drop that xml to the stated folder (res/layout)
- I dont know how to do it from windows box since i didnt use windows but i believe you need to open the apk using 7zip.

DIY way (you need to know how to use apktool, decompiling/recompiling an apk. It is easy, trust me :) ):

If you wish to do it yourself, then you need to decompile SystemUI.apk.
(i use apktool and method by TheGrammarFreak HERE that also applied for centering the date and clock)

- open status_bar_expanded.xml from layout folder.

- on the line 4, you will see
Code:
     <LinearLayout android:orientation="horizontal" android:background="@drawable/title_bar_portrait" android:paddingTop="3.0dip" android:paddingRight="3.0dip" android:paddingBottom="5.0dip" android:layout_width="fill_parent" android:layout_height="wrap_content">
highlight the whole line until line 7 that consist
Code:
</LinearLayout>
and delete it (yes, delete!)



so it will looks like these


find line start with
Code:
<LinearLayout android:orientation="vertical" android:id="@id/latestItems"
create new line below it and paste this code into that new line
Code:
                <TextView android:layout_gravity="right|center" android:id="@id/clear_all_button" android:background="@android:drawable/btn_default_small" android:paddingLeft="15.0dip" android:paddingRight="15.0dip" android:layout_width="wrap_content" android:layout_height="wrap_content" android:layout_marginTop="4.0dip" android:layout_marginBottom="1.0dip" android:text="@string/status_bar_clear_all_button" style="?android:attr/buttonStyle" />


That is for "clear button". We repositioned it to the bottom.

Now, find line consist
Code:
</ScrollView>
and paste these code exactly below it

Code:
        <LinearLayout android:orientation="horizontal" android:layout_width="fill_parent" android:layout_height="wrap_content">
            <com.android.systemui.statusbar.CarrierLabel android:textAppearance="@style/TextAppearance.StatusBar.Title" android:gravity="bottom|center|center" android:background="@drawable/shade_bgcolor" android:layout_width="fill_parent" android:layout_height="wrap_content" android:singleLine="true" />
        </LinearLayout>
It should look like this;


That is for the Carrier Label. I made it centered by this line
Code:
android:gravity="bottom|center|center"
Save it and recompile back. I use TheGrammarFreak method to replace the compiled xml file.

Enjoy.. :)
Hey could you attach your statusbar.xml with centered date? :D
 

feed3

Senior Member
Nov 17, 2011
1,040
727
0
The Land of Hornbill...
Hey could you attach your statusbar.xml with centered date? :D
Sure.. SystemUI.apk attached. But, it is a bit messed inside. :p
and, many things are added to my like such as statusbar background. Im pretty sure you know which xml file to take if you only need the centered clock and date right? :)

As a side note, the background for date when you expand the statusbar will be black because i dont like it being overlapping with other icons,clock etc. Let me know if you need to find which line to change for that. :)

EDIT: Opss.. didnt read your post carefully. :p My head become a bit blur for the very long hours in front of my workstation. statusbar.xml in zip file attached. :)
 

Attachments

Last edited:
  • Like
Reactions: Black_jackss

Black_jackss

Senior Member
Aug 25, 2011
706
115
0
Pekanbaru
Sure.. SystemUI.apk attached. But, it is a bit messed inside. :p
and, many things are added to my like such as statusbar background. Im pretty sure you know which xml file to take if you only need the centered clock and date right? :)

As a side note, the background for date when you expand the statusbar will be black because i dont like it being overlapping with other icons,clock etc. Let me know if you need to find which line to change for that. :)

EDIT: Opss.. didnt read your post carefully. :p My head become a bit blur for the very long hours in front of my workstation. statusbar.xml in zip file attached. :)
I edited a few line,hope u will be okay with that,;)
Thanks,im so lazyyy :p
 

feed3

Senior Member
Nov 17, 2011
1,040
727
0
The Land of Hornbill...
I reverted it back,because it's not like i want :mad::mad::mad::mad:
Thanks man:D
I assume you made the carrier background to transparent, then align it to the right (to make it exactly like in cm7)?

I have done it before, but once you have many notifications, it will just stay there (i dont like it), but putting it into scrollview doesnt work either. Thats why I made it just centered since "no notification" and "on going" title doesnt serve any purpose to me personally. :)

Sent from my SK17i using XDA App
 

Black_jackss

Senior Member
Aug 25, 2011
706
115
0
Pekanbaru
I assume you made the carrier background to transparent, then align it to the right (to make it exactly like in cm7)?

I have done it before, but once you have many notifications, it will just stay there (i dont like it), but putting it into scrollview doesnt work either. Thats why I made it just centered since "no notification" and "on going" title doesnt serve any purpose to me personally. :)

Sent from my SK17i using XDA App
Close one :)
Please continue sharing the progress in ths thread :)

Sent from my SK17i