From ff18c72c670a2cbebba665d78b913f2aba2f8d39 Mon Sep 17 00:00:00 2001 From: Mostafa Ahangarha Date: Fri, 23 Nov 2018 23:34:08 +0330 Subject: Improve RTL support For all the layout elements having margin, padding,... to right or left, releavnt start/end property is added so all the elements are supposed to be displayed properly in RTL mode. There are still minor issues related to some icons such as play, ff and rev. This issue must be addressed separately in future. --- app/src/main/res/layout/nav_listitem.xml | 8 ++++++++ 1 file changed, 8 insertions(+) (limited to 'app/src/main/res/layout/nav_listitem.xml') diff --git a/app/src/main/res/layout/nav_listitem.xml b/app/src/main/res/layout/nav_listitem.xml index d62672c34..c140533e6 100644 --- a/app/src/main/res/layout/nav_listitem.xml +++ b/app/src/main/res/layout/nav_listitem.xml @@ -13,12 +13,14 @@ android:layout_width="@dimen/thumbnail_length_navlist" android:layout_height="@dimen/thumbnail_length_navlist" android:layout_alignParentLeft="true" + android:layout_alignParentStart="true" android:layout_centerVertical="true" android:adjustViewBounds="true" android:cropToPadding="true" android:scaleType="centerInside" android:padding="4dp" android:layout_marginLeft="@dimen/listitem_icon_leftpadding" + android:layout_marginStart="@dimen/listitem_icon_leftpadding" android:layout_marginTop="4dp" android:layout_marginBottom="4dp" tools:src="@drawable/ic_new_releases_white_24dp" @@ -36,8 +38,11 @@ android:layout_width="wrap_content" android:layout_height="wrap_content" android:layout_marginLeft="@dimen/listitem_iconwithtext_textleftpadding" + android:layout_marginStart="@dimen/listitem_iconwithtext_textleftpadding" android:layout_marginRight="48dp" + android:layout_marginEnd="48dp" android:layout_toRightOf="@id/imgvCover" + android:layout_toEndOf="@id/imgvCover" tools:text="Navigation item title" tools:background="@android:color/holo_green_dark" /> @@ -50,8 +55,11 @@ android:textColor="?android:attr/textColorTertiary" android:textSize="@dimen/text_size_navdrawer" android:layout_marginLeft="12dp" + android:layout_marginStart="12dp" android:layout_marginRight="@dimen/listitem_icon_rightpadding" + android:layout_marginEnd="@dimen/listitem_icon_rightpadding" android:layout_alignParentRight="true" + android:layout_alignParentEnd="true" android:layout_centerVertical="true" tools:text="23" tools:background="@android:color/holo_green_dark"/> -- cgit v1.2.3