Search Results

Search found 877 results on 36 pages for 'preference'.

Page 1/36 | 1 2 3 4 5 6 7 8 9 10 11 12  | Next Page >

  • Change Preference Item Summary Text Color in Android 4

    - by AntounG
    I have the below sample of preference items <CheckBoxPreference android:key="chkSound" android:summary="Sound is Off" android:title="Sound" /> I use a theme in the res/values to change the Summary text color <style name="ThemeDarkText"> <item name="android:textColor">#000000</item> </style> And in the code I write this line setTheme(R.style.ThemeDarkText); Its working fine in Android 2.1 but when I tried to run it on a different os (ex Android 4.0) It didn't change the summary text color just the title color only..!! Any help?

    Read the article

  • Android XML Preference issue. Can't make it persistent

    - by Budius
    I have a very simple activity just to show the preference fragment: public class PreferencesActivity extends Activity { Fragment frag = null; @Override public void onCreate(Bundle savedInstanceState) { super.onCreate(savedInstanceState); FragmentTransaction ft = getFragmentManager().beginTransaction(); if (frag == null) { // If not, instantiate and add it to the activity frag = new PrefsFragment(); ft.add(android.R.id.content, frag, frag.getClass().getName()); } else { // If it exists, simply attach it in order to show it ft.attach(frag); } ft.commit(); } private static class PrefsFragment extends PreferenceFragment { @Override public void onCreate(Bundle savedInstanceState) { super.onCreate(savedInstanceState); addPreferencesFromResource(R.xml.preferences); } } } and preferences.xml with persistent to true: <?xml version="1.0" encoding="utf-8"?> <PreferenceScreen xmlns:android="http://schemas.android.com/apk/res/android" android:enabled="true" android:persistent="true" android:title="@string/settings" > <EditTextPreference android:dialogTitle="@string/dialog_ip" android:negativeButtonText="@android:string/cancel" android:persistent="true" android:positiveButtonText="@android:string/ok" android:title="@string/ip" /> </PreferenceScreen> if I open the EditTextPreference, write something, close the dialog and open it again. The value is still there. But that's it... if I click the Back button, and enter the again on the preferences screen, I already lost what was written. If you exit the application also doesn't save. Am I missing something here? Running on: Android 4.0.3 Asus TF300

    Read the article

  • Mac OS X, MySQL Preference Pane doesn't work

    - by Steve Kuo
    I downloaded and installed MySQL 5.1.47 for OS X 10.6 using the DMG archive: mysql-5.1.47-osx10.6-x86_64.dmg I also installed MySQL.prefPane and MySQLStartupItem.pkg. MySQL.prefPane is a Preference Pane. The problem is, whenever I attempt to start/stop MySQL from the Preference Pane, System Preferences just hangs. It runs at about 50% CPU forever, eventually I have for force quit System Preferences. The same thing happens if I toggle "Automatically Start MySQL Server on Startup". Basically the MySQL Preference Pane is not functional. Note that I have no problem starting MySQL from the command line: sudo /usr/local/mysql/bin/mysqld_safe I have tried reinstalling MySQL and the Preference Pane. I'm using the standard installation location, nothing out of the ordinary. Every time the MySQL Preference Pane just hangs. I'm doing this on a Macbook Pro (Intel) running OS X 10.6.3. There are no old versions of MySQL on this machine.

    Read the article

  • Mac OS X, MySQL Preference Pane doesn't work

    - by Steve Kuo
    I downloaded and installed MySQL 5.1.47 for OS X 10.6 using the DMG archive: mysql-5.1.47-osx10.6-x86_64.dmg I also installed MySQL.prefPane and MySQLStartupItem.pkg. MySQL.prefPane is a Preference Pane. The problem is, whenever I attempt to start/stop MySQL from the Preference Pane, System Preferences just hangs. It runs at about 50% CPU forever, eventually I have for force quit System Preferences. The same thing happens if I toggle "Automatically Start MySQL Server on Startup". Basically the MySQL Preference Pane is not functional. Note that I have no problem starting MySQL from the command line: sudo /usr/local/mysql/bin/mysqld_safe I have tried reinstalling MySQL and the Preference Pane. I'm using the standard installation location, nothing out of the ordinary. Every time the MySQL Preference Pane just hangs. I'm doing this on a Macbook Pro (Intel) running OS X 10.6.3. There are no old versions of MySQL on this machine.

    Read the article

  • LINQ Style preference

    - by Erin
    I have come to use LINQ in my every day programming a lot. In fact, I rarely, if ever, use an explicit loop. I have, however, found that I don't use the SQL like syntax anymore. I just use the extension functions. So rather then saying: from x in y select datatransform where filter I use: x.Where(c => filter).Select(c => datatransform) Which style of LINQ do you prefer and what are others on your team are comfortable with?

    Read the article

  • Data base preference for network based C# windows application [on hold]

    - by Sinoop Joy
    I'm planning to develop a C# widows based application for an academy. The academy will have different instances of application running in different machines. The database should have shared access. All the application instances can do update, delete or insert. I've not done any network based application. Anybody can give any useful link to where to start with ? Which database would give max performance with all required features i said for this scenario ?

    Read the article

  • Where to store Android preference keys?

    - by pixel
    When I create preference activity I define all preferences in xml file. Every preference has a key defined in this xml. But when I access preference I write: SharedPreferences appPreferences = PreferenceManager.getDefaultSharedPreferences(this); boolean foo_value = appPreferences.getBoolean("foo_key_defined_in_xml", false); Is there any way to avoid acessing "foo_key_defined_in_xml" in hard-coded way? Maybe there is a possibility to access it in R style way?

    Read the article

  • How do I display the current value of an Android Preference in the Preference summary?

    - by nyenyec
    This must come up very often. When the user is editing preferences in an Android app, I'd like them to be able to see the currently set value of the preference in the Preference summary. Example: if I have a Preference setting for "Discard old messages" that specifies the number of days after which messages need to be cleaned up. In the PreferenceActivity I'd like the user to see: "Discard old messages" <- title "Clean up messages after x days" <- summary where x is the current Preference value Extra credit: make this reusable, so I can easily apply it to all my preferences regardless of their type (so that it work with EditTextPreference, ListPreference etc. with minimal amount of coding).

    Read the article

  • Security System Preference won't open on Macos 10.6 Snow Leopard

    - by adambox
    When I try to open the Security preference pane on my iMac running Mac OS 10.6.6, it says "loading..." and it never opens. I get this in the console: 3/5/11 4:16:56 PM System Preferences[724] Could not connect the action resetLocationWarningsSheetOk: to target of class AppleSecurity_Pref 3/5/11 4:16:56 PM System Preferences[724] Could not connect the action resetLocationWarningsSheetCancel: to target of class AppleSecurity_Pref 3/5/11 4:16:56 PM System Preferences[724] *** -[NSCFDictionary initWithObjects:forKeys:count:]: attempt to insert nil value at objects[0] (key: NSFont)

    Read the article

  • Need to pick contact from a dialog preference

    - by MLW
    I would like to add a preference setting that uses an ACTION_PICK intent. My goal is to acquire the phone number of a contact in my phone by using a preference. Is this possible? I can run this code from my activity but I discovered I cannot run it from a class that extends DialogPreference. Intent intentContact = new Intent(Intent.ACTION_PICK, ContactsContract.Contacts.CONTENT_URI); startActivityForResult(intentContact, PICK_CONTACT); Or is there a way to start a new activity from a preference? Then that activity could execute the above two lines of code?

    Read the article

  • Nested preference screens lose theming

    - by stealthcopter
    I have a preference screen for my application and in the manifest I have given it a theme using: android:theme="@android:style/Theme.Light.WallpaperSettings" However when I nest another preference screen inside this one such as: <?xml version="1.0" encoding="utf-8"?> <PreferenceScreen xmlns:android="http://schemas.android.com/apk/res/android" android:title="@string/setting_title" android:key="..."> <PreferenceCategory android:title="@string/title_themes" > <PreferenceScreen android:title="@string/title_themes_opt" > <ListPreference android:key="Setting_BG" android:title="@string/setting_bg" android:summary="@string/setting_bg_summary" android:entries="@array/bg_titles" android:defaultValue="0" android:entryValues="@array/bg_values" /> </PreferenceScreen> </PreferenceCategory> </PreferenceScreen> The nested preference screen loses the theme of the parent. How can this be prevented? Thanks in advance.

    Read the article

  • When is it ever ok to write your own development tools? (editor into IDE)

    - by mario
    So I'm foremost using a text editor for coding. It's a very bare bones editor; provides mostly just syntax highlighting. But on rare occasions I also need to debug something. And that's when I have to resort to an IDE (mostly Netbeans, but got fiddly Eclipse/Aptana working as second fallback). For general use however IDEs feel not workable to me. It's a visual thing, being used to console UIs etc. And switching back and forth between a text editor and an IDE is slightly cumbersome too. That's why I'm considering extending the editor, not really into a full-fledged IDE - but at the very least integrate a debug feature. Since I'm working on PHP, it seems not that much effort. The DBGp allows to externalize a debug handler from the editor, so it's just minor integration work and figuring out how to shoehorn a breakpoint feature into the editor (joe btw). And while I've also got time to do that, I'm wondering if this is really worthwhile. In this case it's not a needed development tool. It's just for convenience. And the cause for doing it is basically just not liking the existing solution. While over time I might extend and adapt this debugger thing, it initially will be as circumstantial as Eclipse. It inevitably starts out as poor development tool. Furthermore there is likely not much reuse. (Okay, this is not an important point. Most such software exists sans much of a use case. And also obviously, similar extensions already exist for emacs and vim, so it cannot be completely pointless.) But what's a general guideline on attempting to conoct custom development tools, particularily if they are not really needed but satisfy personal preferences? (Usability enhancement not certain.)

    Read the article

  • Override System Preference Pane?

    - by DisappointedIdealist
    Is there a way to override / disable a system preference pane? I'm wanting to put an application together that would disable or override the Energy Saver preference pane, and would put it's own rules in place for putting a machine into standby, turning off the monitor, or other various energy saving activities.

    Read the article

  • Changing printer preference using vb6?

    - by Mahmoud
    I am having a problem when my program is installed to another computer, where its printer preference is different, where my data report accepts Letter size 8.2 * 11 in, because when the printer preference is different the data report well not show and gives an error saying the page width is larger than paper width, does anyone know how to fix this problem. i tried this code but it didn't work Printer.PaperSize = vbPRPSLetter

    Read the article

  • Android preferencesActivity setDefaultValue() not working?

    - by Nick
    I'm extending PreferenceActivity for my settings screen. In this preference activity i have a couple of preferences one of which is custom made. The problem is as follows: in this custom preference (which extends from ListPreference) i want to be able to set the default value, so i override the setDefaultValue() method. In this method i do some parsing so it'll take the correct value. When i'm trying to read this value with the getValue() function it just returns null. So i figured, what happens when i just put some hardcoded value in there (you know, maybe i did something wrong, wouldn't be the first time). Well, i still get null back. Any ideas what i'm doing wrong? Edit: Setting the defaultValue in the xml file isn't really an option because the values aren't known until i retrieve them. I made a workaround: When app is started for the first time: get data Set the values in the preference. This way i set the default preference when i'm collection the data

    Read the article

  • Update existing Preference-item in a PreferenceActivity upon returning from a (sub)PreferenceScreen

    - by aioobe
    I have a PreferenceActivity with a bunch of (Sub)PreferenceScreens. Each such (Sub)PreferenceScreen represents an account and has the account-username as its title. PreferenceScreen root = mgr.createPreferenceScreen(this); for (MyAccountClass account : myAccounts) { final PreferenceScreen accScreen = mgr.createPreferenceScreen(this); accScreen.setTitle(account.getUsername()); // add Preferences to the accScreen // (for instance a "change username"-preference) ... root.add(accScreen); } As the user enters sub-PreferenceScreen, and edits the account user-name, I want the outer PreferenceScreen to update it's PreferenceScreen-title for the account in question. I've tried to add... usernamePref.setOnPreferenceChangeListener(new OnPreferenceChangeListener() { public boolean onPreferenceChange(Preference preference, Object newValue) { accScreen.setTitle(newValue.toString()); return true; } }); ...but the accScreen.setTitle does not seem to take effect on the outer PreferenceScreen. I've note that calling onContentChanged(); actually makes it work, but I realize that this is probably not the preferred way of doing it. I suspect I should call postInvalidate() on some view somewhere, but I really can't figure out on what view and when to do it. http://stackoverflow.com/questions/2396153/preferencescreen-androidsummary-update may be experiening the same problem as me. Any help appreciated.

    Read the article

  • Preference List only shows first element

    - by jmunoz
    I am developing a PreferenceActivity with custom Preference views. My problem is that I created a view with a ListView and it only shows the first element. I post my code and an image: http://imageshack.us/photo/my-images/545/sc20120307161530.png/ xml: <?xml version="1.0" encoding="utf-8"?> <PreferenceScreen xmlns:android="http://schemas.android.com/apk/res/android" > <PreferenceCategory android:key="player_settings" android:title="@string/settings_player_config" > <EditTextPreference android:defaultValue="@string/settings_player_default_name" android:dialogMessage="@string/settings_player_summary" android:dialogTitle="@string/settings_playersname" android:key="player_name" android:summary="@string/settings_player_summary" android:title="@string/settings_playersname" /> </PreferenceCategory> <PreferenceCategory android:key="volume" android:title="@string/settings_volume" > <com.battleship.preferences.SeekBarPreferences android:defaultValue="50" android:key="volume" android:title="@string/settings_volume" /> </PreferenceCategory> <PreferenceCategory android:key="shine" android:title="@string/settings_shine" > <com.battleship.preferences.SeekBarPreferences android:defaultValue="50" android:key="shine" android:title="@string/settings_shine" /> </PreferenceCategory> <PreferenceCategory android:key="themeTitle" android:title="@string/settings_group_themes" > <com.battleship.preferences.ListPreferences android:key="theme" /> </PreferenceCategory> <PreferenceCategory android:key="fontsTitle" android:title="@string/settings_group_font_size" > <com.battleship.preferences.ListPreferences android:key="font" /> </PreferenceCategory> </PreferenceScreen> The Custom ListPreference: package com.battleship.preferences; import com.battleship.R; import android.content.Context; import android.content.SharedPreferences; import android.media.AudioManager; import android.preference.Preference; import android.util.AttributeSet; import android.view.View; import android.view.ViewGroup; import android.widget.ArrayAdapter; import android.widget.LinearLayout; import android.widget.ListView; import android.widget.RadioButton; import android.widget.RadioGroup; import android.widget.RadioGroup.OnCheckedChangeListener; import android.widget.Toast; public class ListPreferences extends Preference implements OnCheckedChangeListener { public ListPreferences(Context context) { super(context); } public ListPreferences(Context context, AttributeSet attrs) { super(context, attrs); } public ListPreferences(Context context, AttributeSet attrs, int defStyle) { super(context, attrs, defStyle); } @Override protected void onClick() { super.onClick(); Toast t = Toast.makeText(getContext(), "HOLA!", 3); t.show(); } @Override protected View onCreateView(ViewGroup parent) { String[] contentString = new String[3]; if (getKey().equals("theme")) { contentString = new String[] { (getContext().getString(R.string.settings_theme_default)), (getContext().getString(R.string.settings_theme_black)), (getContext().getString(R.string.settings_theme_white)) }; } else { contentString = new String[] { (getContext().getString(R.string.settings_font_big)), (getContext().getString(R.string.settings_font_medium)), (getContext().getString(R.string.settings_font_little)) }; } ListView listView = new ListView(getContext()); ArrayAdapter<String> array = new ArrayAdapter<String>(getContext(), android.R.layout.simple_list_item_single_choice, android.R.id.text1, contentString); listView.setAdapter(array); listView.setChoiceMode(ListView.CHOICE_MODE_SINGLE); return listView; } private void updatePreference(int intRadio) { SharedPreferences.Editor editor = getEditor(); editor.putInt(getKey(), intRadio); editor.commit(); } }

    Read the article

  • Specifying path in a preference file in Unison

    - by Curious2learn
    I am using Unison to sync a folder on my local computer with one on a server. I am using a unison preference file for this. If I specify the path of the local folder using Method 1 (see below) things work well. But Method 2 does not work. I would like to use something like Method 2 because I want to use the same preference file (synced using Dropbox) on two different computers. But the usernames are different on these two computers and I cannot change the usernames. Any ideas how this can be achieved? Thank you. METHOD 1 (works) root = /Users/username1/Dropbox/path_to_folder/folder METHOD 2a (Does not work) root = ~/Dropbox/path_to_folder/folder METHOD 2b (Does not work) root = $HOME/Dropbox/path_to_folder/folder

    Read the article

  • Windows XP, Preference menu's hidden for many programs

    - by Jestep
    I don't know when this started happening, but it has been several months since I first noticed it. Basically, when I go to a preferences menu of some programs, the preferences window is completely hidden, but the program see's it as being open. This prevents me from interacting with the preferences and the actual program. So far I've noticed it on Adobe Illustrator and Netbeans. Illustrator when I select edit - Preferences - An Option. On Netbeans it happens when I right click on a site and select properties. Here's a link to a screen shot after I click on the preferences menu (I don't have enough points to post an image yet): http://www.jestep.com/images/screen-2.jpg. Note that the main workspace is grayed out. I have to hit Escape to close the hidden preferences window. I've tried unstinstalling, completely wiping the registry of any trace of the program and reinstalling. Thought it may have been a multi-monitor issue when I switched from 2 monitors down to 1, but menu's were not on other monitor when I plugged one back in. I've reset workspaces, windows display, windows performance settings, changed resolution, safe mode, everything I can think of. I cannot figure out what would cause the same problem on completely unrelated software, and I cannot reset it by reinstalling. Any help would be greatly appreciated.

    Read the article

  • Word is ignoring my 'Match Destination Formatting' preference when pasting text

    - by CreeDorofl
    I'm stuck using word 2007 at the office. It has options for retaining formatting, pasting as plain text, and pasting text to match the destination's formatting. That last option is the one I want, but word is blatantly ignoring it. I copy some text from a PDF, paste into word, and it retains the PDF's formatting... even though I went into options -- advanced -- changed all the dropdowns to "Match Destination Formatting". It also ignores "text only" option... It retains the exact mix of bold, italic, normal text & fonts. I can work around it by pasting to a plain text file, then pasting into word. Or I can do paste special -- unformatted text. But this is so irritating... I just want to ctrl+V and not hassle with it every single time. Is there a better fix?

    Read the article

1 2 3 4 5 6 7 8 9 10 11 12  | Next Page >