[Android Apps and Games] gharrington:
This is the most customizable clock seen to date.

Add individual items so you can have any layout to wish also you can set the following for each item.

Clock position: Left, Right, Center

Changeable for each item:

Text color

Text font

text size

Set gravity top, center, bottom

Selectable items are :

Hour (24) e.g.: 13

Hour (12) e.g.: 1

Minutes

Seconds

Day (numeric) eg: 02

Day (short) e.g.: Tue

Day (long) e.g.: Tuesday

Month (numeric) eg: 01

Month (short) e.g.: Jan

Month (long) e.g.: January

Year (short) e.g.: 15

Year (long) e.g.: 2015

Am-Pm

:

/

-

Space

You can also save/load your clock layouts

I cannot explain the full nature of this mod so give it a go.

1.Unzip the download files and place all of the MinitClock.smali files into SystemUI.apk/com/android/systemui/policy folder.

2.Make the changes to status_bar.xml as seen below. I have also include both the files below so you can run a diff to see the changes.

XML Source Code: status_bar.xml - Original

<com.android.systemui.statusbar.phone.PhoneStatusBarView android:orientation="vertical" android:id="@id/status_bar" android:background="@drawable/system_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">
<FrameLayout android:id="@id/call_background" android:background="@color/call_background_idle_color" android:layout_width="fill_parent" android:layout_height="fill_parent" />
<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="@dimen/status_bar_contents_padding_start" android:paddingEnd="@dimen/status_bar_contents_padding_end">
<com.android.systemui.statusbar.AlphaOptimizedFrameLayout android:orientation="horizontal" android:id="@id/notification_icon_area" android:layout_width="0.0dip" android:layout_height="fill_parent" android:layout_weight="1.0">
<com.android.keyguard.AlphaOptimizedLinearLayout android:id="@id/notification_icon_area_inner" android:layout_width="fill_parent" android:layout_height="fill_parent">
<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" />
</com.android.keyguard.AlphaOptimizedLinearLayout>
</com.android.systemui.statusbar.AlphaOptimizedFrameLayout>
<com.android.keyguard.AlphaOptimizedLinearLayout android:orientation="horizontal" android:id="@id/system_icon_area" android:layout_width="wrap_content" android:layout_height="fill_parent">
<TextView android:textSize="12.0dip" android:textColor="#ffffffff" android:gravity="center_vertical" android:id="@id/knoxCustomStatusBarText" android:visibility="gone" android:layout_width="wrap_content" android:layout_height="fill_parent" android:includeFontPadding="false" />
<include layout="@layout/system_icons" />
<com.android.systemui.statusbar.policy.Clock android:textAppearance="@style/TextAppearance.StatusBar.Clock" android:gravity="start|center" android:id="@id/clock" android:layout_width="wrap_content" android:layout_height="fill_parent" android:singleLine="true" android:paddingStart="@dimen/status_bar_clock_padding_start" />
</com.android.keyguard.AlphaOptimizedLinearLayout>
</LinearLayout>
</com.android.systemui.statusbar.phone.PhoneStatusBarView>

XML Source Code: status_bar.xml - Modded

<?xml version="1.0" encoding="utf-8"?>
<com.android.systemui.statusbar.phone.PhoneStatusBarView android:orientation="vertical" android:id="@id/status_bar" android:background="@drawable/system_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"
[COLOR="red"]xmlns:threeminit="http://threeminit.com">[/COLOR]
[COLOR="red"]<com.android.systemui.statusbar.policy.MinitClock threeminit:position="1" android:id="@+id/minitclock" android:gravity="center" android:layout_width="fill_parent" android:layout_height="fill_parent" android:singleLine="true" />[/COLOR]
<FrameLayout android:id="@id/call_background" android:background="@color/call_background_idle_color" android:layout_width="fill_parent" android:layout_height="fill_parent" />
<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="@dimen/status_bar_contents_padding_start" android:paddingEnd="@dimen/status_bar_contents_padding_end">
<com.android.systemui.statusbar.AlphaOptimizedFrameLayout android:orientation="horizontal" android:id="@id/notification_icon_area" android:layout_width="0.0dip" android:layout_height="fill_parent" android:layout_weight="1.0">
<com.android.keyguard.AlphaOptimizedLinearLayout android:id="@id/notification_icon_area_inner" android:layout_width="fill_parent" android:layout_height="fill_parent">
[COLOR="red"]<com.android.systemui.statusbar.policy.MinitClock threeminit:position="2" android:gravity="left|center" android:id="@+id/minitclock" android:layout_width="wrap_content" android:layout_height="fill_parent" />[/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" />
</com.android.keyguard.AlphaOptimizedLinearLayout>
</com.android.systemui.statusbar.AlphaOptimizedFrameLayout>
<com.android.keyguard.AlphaOptimizedLinearLayout android:orientation="horizontal" android:id="@id/system_icon_area" android:layout_width="wrap_content" android:layout_height="fill_parent">
<TextView android:textSize="12.0dip" android:textColor="#ffffffff" android:gravity="center_vertical" android:id="@id/knoxCustomStatusBarText" android:visibility="gone" android:layout_width="wrap_content" android:layout_height="fill_parent" android:includeFontPadding="false" />
<include layout="@layout/system_icons" />
<com.android.systemui.statusbar.policy.Clock android:textAppearance="@style/TextAppearance.StatusBar.Clock" android:gravity="start|center" android:id="@id/clock" [COLOR="red"]android:layout_width="0dp" android:layout_height="0dp" [/COLOR]android:singleLine="true" android:paddingStart="@dimen/status_bar_clock_padding_start" />
[COLOR="red"]<com.android.systemui.statusbar.policy.MinitClock threeminit:position="0" android:gravity="start|center" android:id="@+id/minitclock" android:layout_width="wrap_content" android:layout_height="fill_parent" android:singleLine="true" android:paddingStart="@dimen/status_bar_clock_padding_start" />[/COLOR]
</com.android.keyguard.AlphaOptimizedLinearLayout>
</LinearLayout>
</com.android.systemui.statusbar.phone.PhoneStatusBarView>

Note there are 4 added lines 5,6,12,21 dont miss line 5 or your apk wont recompile. Also note the attributes threeminit:position="0" these mean:

threeminit:position="0" = right clock

threeminit:position="1" = center clock

threeminit:position="2" = left clock

adjust these as you need them.

3. Install the included apk.

You are free to use and bake this mod and app into your rom provided you give full and proper credits and you provide a link to this thread. Also, you cannot alter in any way without permission from me first.

This is not a open source project and I share with you as is. All codes belong to me and are copyrighted.

3Minit Clock Mod v2.0

3Minit Clock Mod Git

My wife and kids for giving up their time with me so I can do this. Love you guys.

@pas2001 for icons and testing

​

XDA:DevDB Information

3Minit Clock Mod, App for all devices (see above for details)

Contributors

gharrington

Version Information

Status: Stable

Current Stable Version: 2.0

Created 2016-06-17

Last Updated 2016-06-21

XDA:DevDB Information

3Minit Clock Mod, App for all devices (see above for details)

Contributors

gharrington

Source Code: https://github.com/gharrington/3Minit_Clock_Mod.git

Version Information

Status: Stable

Current Stable Version: 2.0

Created 2016-06-17

Last Updated 2016-06-23