Guide of Transparent Status Bar / Center Clock on 4.2.1 TW for DEVS

Posted by on Aug 16, 2014 in Customization, Dev Guide

Center Clock in Status Bar!

To start with decompile SystemUI.apk
Navigate to res/layout/status_bar.xml

Look for a line that starts with:

<com.android.systemui.statusbar.policy.Clock

and delete it.

Then add these lines:

<LinearLayout android:gravity=”center” android:orientation=”horizontal” android:layout_width=”fill_parent” android:layout_height=”fill_parent”> <com.android.systemui.statusbar.policy.Clock android:textAppearance=”@style/TextAppearance.StatusBar.Clock” android:gravity=”center” android:paddingTop=”3.0px”

android:layout_width=”wrap_content” android:layout_height=”fill_parent” android:singleLine=”true” android:layout_weight=”1.0″ />

</LinearLayout>


Under this line:

xmlns:systemui=”http://schemas.android.com/apk/res/com.android.systemui”>

Now, your clock will probably be blue, to make it white or to change to another color.
Navigate to res/values/styles.xml

From this line:

Change the

android:color/holo_blue_light

to #FFFFFF for white.
And you can add your own hex code for different colors as well.

Now recompile SystemUI.
Your recompiled SystemUI will be in the /dist folder.
Open the SystemUI in the dist folder, and the normal SystemUI that you decompiled with 7zip.
Drag and drop (DO NOT EXTRACT) AndroidManifest and META-INF from the normal one to the one in dist.

That’s it, send your SystemUI through adb or create a flashable zip…
Or copy it to your sdcard, then copy to system/app with root explorer.

Leave a Reply