Im trying to build my multiple choice layout according to latest material design guidelines with CheckedTextView widget. But I can't find the way to set left padding for checkbox and textview separately (16dp for icon, 72 for text). The most acceptable solution i could find is to use android:drawablePadding attribute but i think it is not quite right. Is it possible to set padding values separately inside CheckedTextView?
<?xml version="1.0" encoding="utf-8"?>
<CheckedTextView xmlns:android="http://schemas.android.com/apk/res/android"
android:id="@android:id/text1"
android:layout_width="match_parent"
android:layout_height="48dp"
android:gravity="center_vertical"
android:textSize="16sp"
android:textColor="#000000"
android:paddingLeft="16dp"
android:drawableLeft="?android:attr/listChoiceIndicatorMultiple"
android:drawablePadding="36dp"/>
I'm late to the party, but just in case someone is looking for a solution, here is how I did it using the CheckBox widget:
android:layout_marginStart="16dp" sets margin to both icon and text, while android:paddingStart="56dp" sets padding between text and icon.