Skip to content
Marc Auberer edited this page Feb 3, 2021 · 10 revisions

Welcome to the simple-settings wiki!

Introduction

Most Android developers would agree, that building a settings screen is quite painful. You have to create the xml file, the activity and the settings fragment where the preferences are getting rendered. Especially realizing dynamic preferences for certain purposes is a small challenge and the resulting code is everything, but not clean. This library offers a simplification for it! You now can speficy your preference configuration directly in your Kotlin / Java file and we tried to design the library to save you typing work where we can. If you want to stick with the xml version, be happy: It's also possible and recommended for large and nested preference configurations!

Get started

In the README of this repo is described, how to start with this library from scratch. The basic default configuration allows you to fully setup a simple preferences screen without understanding the underlying structures. If you want to customize your preferences and know more about the preference types, read the following section.

Customization

The customization of the activity itself can be done, by passing a SimpleSettingsConfig object to the SimpleSettings builder. Visit the wiki page 'Activity configuration' to learn more about the individual configuration options. The preferences, which you define in your Kotlin / Java code just work the same way as the coherent Preference, you would declare in xml. But there are some additional preference types that were added by this library. To learn more about the individual preference types, visit the corresponding page for each type.

Table of contents