Questions tagged [preferencescreen]

Represents a top-level Preference that is the root of a Preference hierarchy. A PreferenceActivity points to an instance of this class to show the preferences.

Represents a top-level Preference that is the root of a Preference hierarchy. A PreferenceActivity points to an instance of this class to show the preferences. To instantiate this class, use createPreferenceScreen(Context).

This class can appear in two places:

  • When a PreferenceActivity points to this, it is used as the root and is not shown (only the contained preferences are shown).
  • When it appears inside another preference hierarchy, it is shown and serves as the gateway to another screen of preferences (either by showing another screen of preferences as a Dialog or via a startActivity(android.content.Intent) from the getIntent()). The children of this PreferenceScreen are NOT shown in the screen that this PreferenceScreen is shown in. Instead, a separate screen will be shown when this preference is clicked.
  • 201 questions
    1
    vote
    1 answer

    Share link via Intent from PreferenceScreen

    I am using this code to display app on play store:
    Michal
    • 3,584
    • 9
    • 47
    • 74
    1
    vote
    1 answer

    extending ListPreference with an onClick handler

    I'd like set up something like RingtonePreference but for vibration patterns, ListPreference seems like a good place to start but does not allow inclusion of an onClick handler. How would I go about extending it to add one? Is that even possible?…
    1
    vote
    2 answers

    Is there something like a VibrationPreference similar to RingtonePreference?

    I'd really like to let a user pick out a vibration to use for my app, I'm already using RingtonePreference in my PreferenceScreen, is there anything similar for Vibrations, or a library that does it? EDIT: Or, if there isn't a library or existing…
    1
    vote
    1 answer

    Changing the look of items

    The question: How do you change the text size used for the android:title attribute when the Preference items are listed in the settings menu? The details: The Settings screen in my app looks good on a Nexus 7 (Jelly Bean) tablet, but is almost…
    Sound Conception
    • 5,263
    • 5
    • 30
    • 47
    1
    vote
    0 answers

    PreferenceScreen theme

    I set preference to preference screen. The main screen is fine, but sub-screens are dark and I can't see the title of elements, only blue descriptions. If I scroll down, the theme is changed to light. I have tried adding…
    Meph-
    • 657
    • 1
    • 8
    • 20
    1
    vote
    2 answers

    Get event on dialog( Ok ,Cancel) button pressed(Android)

    In my Android application I am displaying the dialogbox which contains edittext. This dialogbox is displayed using PreferenceCategory.My xml file looks like
    void
    • 479
    • 2
    • 13
    • 27
    1
    vote
    4 answers

    Setting the text color of preferences screen

    Friends I have created a listpreferences screen ,and it is working fine but I want to change the color of text appearing on the list and the RadioGroup items. So can anyone help me out.
    GOLDEE
    • 2,318
    • 3
    • 25
    • 49
    1
    vote
    1 answer

    read from android SharedPreference

    I know it's been asked before, but it doesn't seem to work for me. I have an XML file preferences.xml in the folder res\xml. It contains an optionscreen like so:
    PoeHaH
    • 1,936
    • 3
    • 28
    • 52
    1
    vote
    0 answers

    Add a List to PreferenceScreen

    My app has a TabHost with various tabs inside. I have added (outside of the TabHost) a button that calls another activity extended from PreferenceActivity to manage the preferences of the app. For the PreferenceActivity I have followed the…
    1
    vote
    0 answers

    Android - launch another PreferenceScreen relative to the package

    I am trying to launch another PreferenceScreen from within a SreferenceScreen
    nLL
    • 5,662
    • 11
    • 52
    • 87
    1
    vote
    1 answer

    Handling BackKeyButton in nested PreferenceScreens in Android

    I have a PreferenceScreens like this
    Kalyan
    • 11
    • 1
    1
    vote
    1 answer

    preference screen doesn't honor NoTitleBar theme

    My preference activity has a preference category that contains multiple preference screens. The screens are added dynamically at run-time. I build each in code and add it to the preference group. The screens don't actually set preferences on the…
    1
    vote
    3 answers

    Why does Android ignore OnPreferenceClickListener() that returns true?

    I defined my preferences in xml file like the following:
    goRGon
    • 4,402
    • 2
    • 43
    • 45
    0
    votes
    1 answer

    PreferenceScreen themed with honeycomb theme

    i want to make to make an PreferenceActivity with the same style that can be found on the image below. Image of Preference Screen Android 3.2…
    Dporem
    • 113
    • 2
    • 11
    0
    votes
    1 answer

    Use in XML even though preference is only edited programmatically?

    I have a working user-preferences screen which is defined in user_prefs.xml. The xml is enclosed in a PreferenceScreen tag. That all makes sense... But I need to save other data which the user will not edit. So I thought I'd create a settings.xml…
    Hap
    • 556
    • 1
    • 6
    • 20