[Nexus 7 Themes and Apps] ivn888:
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:

<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" />

<?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"

<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 #DD4814 is Ubuntu Orange

5) Now, the last step:

Navigate to res/values/string

and add this at the end of the file:

<string name="hello">Your text here</string>

ex:

<string name="hello">ivn888</string>

Like this example:

... <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!!

​

CREDITS:

:good:enricocid:good:​