-
-
Notifications
You must be signed in to change notification settings - Fork 9
SimpleColorPreference
Marc Auberer edited this page Jan 17, 2021
·
1 revision
Integration of Jaewoong Eum`s ColorPickerPreference lib.
SimpleSettings(this).show {
Section {
ColorPref {
title = "ColorPreference"
summary = "Color Summary"
attachAlphaSlideBar = true
}
}
}
Please visit the link to the ColorPickerPreference library above to see all customization options.
There is also a ColorPickerPreference
tag available, which can be used in XML preference configurations.
Here is an example:
<?xml version="1.0" encoding="utf-8"?>
<PreferenceScreen
xmlns:app="http://schemas.android.com/apk/res-auto"
xmlns:android="http://schemas.android.com/apk/res/android">
<com.skydoves.colorpickerpreference.ColorPickerPreference
android:key="color_preference"
android:title="Color Preference"
android:summary="Simple Color Preference"
app:preference_attachAlphaSlideBar="false"
app:preference_attachBrightnessSlideBar="true"
app:preference_colorBox_radius="26dp"
app:preference_dialog_negative="@string/cancel"
app:preference_dialog_positive="@string/ok"
app:preference_dialog_title="Toolbar Color"/>
</PreferenceScreen>
Please visit the link to the ColorPickerPreference library above to see all customization options.
© Marc Auberer 2020-2023