Closed chitgoks closed 3 years ago
The pref_currentColor
attribute's value must be a reference to a color value (i.e. @color/your_color
).
ok. somehow e.g. android:defaultValue="#FF00FF" and/or
app:currentColor(R.color.default_color_picker) doesnt work
Anyway, my purpose is that i thought android:defaultValue or app:currentColor will show the check icon on the color if i set any of those as the default color. but i guess since neither of the 2 attributes work, there is no check icon
Please see screenshot. it's still red.
This is the xml
<com.takisoft.preferencex.ColorPickerPreference
android:defaultValue="#FF00FF"
android:icon="@null"
android:key="@string/fill_division_color"
android:title="@string/fill_division_color"
app:iconSpaceReserved="false"
app:pref_currentColor="@color/default_color_picker" />
There's no check mark on the preference. The only place where the check mark is visible is in the dialog where the user selects the color.
yes that's true. ok. so this is FAD. im not keen on changing the default color anway so im closing this. thank you for the clarification.
what is the correct value for this? if basing on the link provided, 0 is default color but even specifying that in xml doesnt work. it says
error: '0' is incompatible with attribute pref_currentColor (attr) reference [weak].
i only wish to set the default value checked icon on the default color specified.