Questions tagged [preference]
445 questions
4
votes
0 answers
Android Support Library v7 PreferenceFragment Preference Headers
I have been able to implement a preference screen with the support library v7 using PreferenceFragmentCompat.
However I tried to implement PreferenceHeaders but I have not been able to find the equivalent of
…

Oladipo Olasemo
- 2,010
- 24
- 31
4
votes
1 answer
Android 6.0 not checked Switch preference from layout resource. Android 7.0 work fine
Java
DeviceSwitch.setLayoutResource(R.layout.settings);
DeviceSwitch.setKey(CategoryKey);
DeviceSwitch.setDefaultValue(true);
DeviceSwitch.setEnabled(true);
DeviceSwitch.setSelectable(true);
DevicesShowScreen.addPreference(DeviceSwitch);
if this…

Дмитрий Кудряшов
- 41
- 1
4
votes
2 answers
Android Shared Preferences Type Migration
What to do if the TYPE of preference changed in Android Preferences? For instance if Boolean changed into ListPreference?
Really noone at Google thought about Preference Migrations?
The only sensible way for now seems to version preferences and mark…

CeDeROM
- 506
- 5
- 10
4
votes
2 answers
(Activity+preferencefragment) Error inflating class com.android.internal.widget.ActionBarContainer
I have no idea about this error.
I got these mesaage from google developer console.
Some devices like z3, htc m8 ,m9 can't execute my app. Could someone give me some hint about the error?
Stacktrace :
java.lang.RuntimeException: Unable to start…

Peiting Shih
- 43
- 1
- 4
4
votes
0 answers
PreferenceCategory in CardView
I create an activity program settings using PreferenceFragment. I need every CategoryPreference inside CardView, as shown in the picture. I searched on Google but didn't find anything useful. If anyone has any ideas I would be very grateful

Joe Silent
- 181
- 1
- 5
4
votes
1 answer
Change App Language Settings using PreferenceFragment
I am trying to provide a language setting(English, Traditional Chinese and Simplified Chinese) in the Android app but when the language preference is changed, the app does not have any change, it's still showing the same language. I have referred…

George
- 169
- 1
- 2
- 10
4
votes
1 answer
preference BackupWebStorage reset to default after cordova build
This is my first cordova-based iOS app (using cordova 4.1.2).
I want to deactivate web storage being backed up to the cloud by setting
in /Staging/config.xml.
However, after doing a cordova build…

Sir Hackalot
- 521
- 6
- 16
4
votes
1 answer
sublime text User Preference File Rewritten
My sublime text user preference file get rewritten. (user/Preferences.sublime-settings)
I wrote some comments about the settings that I made (So that I can remember next time I look at the user preference file.) But it removed all the comments and…

NotepadPlusPlus PRO
- 987
- 1
- 8
- 21
4
votes
2 answers
Difference between android:widgetLayout and android:layout for preference?
I'm getting some weird configuration where widgetLayout configures the inner space of a list item and layout configures the whole item list and the screen background? Can someone actually explain what is the widgetLayout?

kyrax
- 1,192
- 3
- 13
- 29
4
votes
1 answer
Change PreferenceActivity background
How can I completely change the color of my preferenceActivity background? Please see my screenshot. On a tablet there is sort of a white border around the window background and listview background. I can't figure out how to change its…

user1055947
- 862
- 3
- 9
- 22
4
votes
1 answer
Open fragment from Preference fragment; Change action bar layout from nested Preference screen on Android
I've got PreferenceFragment added in activity, so I see my preferences (and the most important I see my custom action bar). But this fragment has nested preference screens inside and when I click one of those then action bar is changed to default…

bakua
- 13,704
- 7
- 43
- 62
4
votes
4 answers
Pass reference of one Activity to another Activity
I know that I can pass some values between Activities using intent.
However, if I want to pass whole Activity to another Activity I think it is not good approach.
Is there another way to do that?
I have Settings Activity in which I am changing…

Marek
- 3,935
- 10
- 46
- 70
4
votes
2 answers
Which way of these two pattern matching is more preferred?
I'm just curious, these two functions would do the same thing. But which one should I use?
let f a =
match a with
b -> a;;
let f a =
match a with
b -> b;;
Or it just depends on your preference?
I feel the second one would…

octref
- 6,521
- 7
- 28
- 44
4
votes
5 answers
Android build errors
I'm getting these errors when trying to build my app in Eclipse. Things started going downhill when the compiler warned me that my .project file was missing.
Then I tried to fix the project and now am getting these errors:
Errors occurred during…

Jazzmine
- 1,837
- 8
- 36
- 54
3
votes
1 answer
android compatibility API alternatives to PreferenceFragment
I want to display a main menu on the left and a settings page on the right of the screen. I want to use the Android compatibility API and fragments.
I also want to make use of the Android preferences features and add the preferences from .xml file,…

Gabriel
- 2,054
- 4
- 26
- 34