List of usage examples for org.eclipse.jface.preference IPreferenceStore setDefault
void setDefault(String name, boolean value);
From source file:com.github.caofangkun.bazelipse.preferences.BazelPreferenceInitializer.java
License:Open Source License
@Override public void initializeDefaultPreferences() { IPreferenceStore store = Activator.getDefault().getPreferenceStore(); store.setDefault("BAZEL_PATH", Activator.DEFAULT_BAZEL_PATH); }
From source file:com.github.parzonka.ccms.preferences.PreferenceInitializer.java
License:Open Source License
@Override public void initializeDefaultPreferences() { final IPreferenceStore store = Activator.getDefault().getPreferenceStore(); store.setDefault(INVOCATION_ORDERING_STRATEGY, INVOCATION_ORDERING_STRATEGY_DEPTH_FIRST); store.setDefault(INVOCATION_STARTPOINT_STRATEGY, INVOCATION_STARTPOINT_STRATEGY_HEURISTIC); store.setDefault(CLUSTER_GETTER_SETTER, false); store.setDefault(RESPECT_BEFORE_AFTER, true); store.setDefault(CLUSTER_OVERLOADED_METHODS, false); store.setDefault(METHOD_ORDERING_PRIORITIES, join(getDefaultMethodOrderingPriorities(), "#")); }
From source file:com.github.picologger.eclipse.syslogcat.preference.PreferenceInitializer.java
License:Apache License
@Override public void initializeDefaultPreferences() { IPreferenceStore store = DdmsPlugin.getDefault().getPreferenceStore(); store.setDefault(ATTR_DEBUG_PORT_BASE, DdmPreferences.DEFAULT_DEBUG_PORT_BASE); store.setDefault(ATTR_SELECTED_DEBUG_PORT, DdmPreferences.DEFAULT_SELECTED_DEBUG_PORT); store.setDefault(ATTR_DEFAULT_THREAD_UPDATE, DdmPreferences.DEFAULT_INITIAL_THREAD_UPDATE); store.setDefault(ATTR_DEFAULT_HEAP_UPDATE, DdmPreferences.DEFAULT_INITIAL_HEAP_UPDATE); store.setDefault(ATTR_THREAD_INTERVAL, DdmUiPreferences.DEFAULT_THREAD_REFRESH_INTERVAL); String homeDir = System.getProperty("user.home"); //$NON-NLS-1$ store.setDefault(ATTR_IMAGE_SAVE_DIR, homeDir); store.setDefault(ATTR_LOG_LEVEL, DdmPreferences.DEFAULT_LOG_LEVEL.getStringValue()); store.setDefault(ATTR_LOGCAT_FONT, new FontData("Courier", 10, SWT.NORMAL).toString()); //$NON-NLS-1$ store.setDefault(ATTR_HPROF_ACTION, HProfHandler.ACTION_OPEN); store.setDefault(ATTR_TIME_OUT, DdmPreferences.DEFAULT_TIMEOUT); }
From source file:com.google.cloud.tools.eclipse.preferences.PreferenceInitializer.java
License:Apache License
@Override public void initializeDefaultPreferences() { IPreferenceStore store = Activator.getDefault().getPreferenceStore(); store.setDefault(AnalyticsPreferences.ANALYTICS_OPT_IN, false); }
From source file:com.google.code.t4eclipse.tools.prefenence.EclipseTestLibPref.java
License:Open Source License
public static void initDefaults(IPreferenceStore prefs) { Collection<String> vs = Utility.eventMap.values(); Iterator<String> i = vs.iterator(); while (i.hasNext()) { String tmp = i.next();//ww w .java 2 s . c o m prefs.setDefault(tmp, checkInit(tmp)); } }
From source file:com.google.dart.tools.search.internal.ui.SearchPreferencePage.java
License:Open Source License
public static void initDefaults(IPreferenceStore store) { RGB gray = new RGB(85, 85, 85); store.setDefault(EMPHASIZE_POTENTIAL_MATCHES, true); store.setDefault(IGNORE_POTENTIAL_MATCHES, false); PreferenceConverter.setDefault(store, POTENTIAL_MATCH_FG_COLOR, gray); store.setDefault(REUSE_EDITOR, true); store.setDefault(BRING_VIEW_TO_FRONT, true); store.setDefault(DEFAULT_PERSPECTIVE, NO_DEFAULT_PERSPECTIVE); store.setDefault(TEXT_SEARCH_ENGINE, ""); //default search engine is empty string //$NON-NLS-1$ store.setDefault(TEXT_SEARCH_QUERY_PROVIDER, ""); // default query provider is empty string //$NON-NLS-1$ store.setDefault(LIMIT_HISTORY, 10); }
From source file:com.google.dart.tools.ui.internal.cleanup.CleanUpConstants.java
License:Open Source License
public static void initDefaults(IPreferenceStore store) { CleanUpOptions settings = DartToolsPlugin.getDefault().getCleanUpRegistry() .getDefaultOptions(CleanUpConstants.DEFAULT_CLEAN_UP_OPTIONS); for (Iterator<String> iterator = settings.getKeys().iterator(); iterator.hasNext();) { String key = iterator.next(); store.setDefault(key, settings.getValue(key)); }//from w w w .j ava 2 s . c o m store.setDefault(SHOW_CLEAN_UP_WIZARD, true); store.setDefault(CLEANUP_PROFILE, DEFAULT_PROFILE); store.setDefault(CLEANUP_ON_SAVE_PROFILE, DEFAULT_SAVE_PARTICIPANT_PROFILE); }
From source file:com.google.dart.tools.ui.internal.text.editor.SemanticHighlightings.java
License:Open Source License
/** * Initialize default preferences in the given preference store. * // ww w .j a v a 2 s .c o m * @param store The preference store */ public static void initDefaults(IPreferenceStore store) { SemanticHighlighting[] semanticHighlightings = getSemanticHighlightings(); for (SemanticHighlighting highlighting : semanticHighlightings) { setDefaultAndFireEvent(store, getColorPreferenceKey(highlighting), highlighting.getDefaultTextColor()); store.setDefault(getBoldPreferenceKey(highlighting), highlighting.isBoldByDefault()); store.setDefault(getItalicPreferenceKey(highlighting), highlighting.isItalicByDefault()); store.setDefault(getStrikethroughPreferenceKey(highlighting), highlighting.isStrikethroughByDefault()); store.setDefault(getUnderlinePreferenceKey(highlighting), highlighting.isUnderlineByDefault()); store.setDefault(getEnabledPreferenceKey(highlighting), highlighting.isEnabledByDefault()); } }
From source file:com.google.dart.tools.ui.PreferenceConstants.java
License:Open Source License
/** * Initializes the given preference store with the default values. * //from w ww . ja va 2s .co m * @param store the preference store to be initialized */ @SuppressWarnings("deprecation") public static void initializeDefaultValues(IPreferenceStore store) { ColorRegistry registry = getColorRegistry(); store.setDefault(PreferenceConstants.EDITOR_SHOW_SEGMENTS, false); // JavaBasePreferencePage store.setDefault(PreferenceConstants.DOUBLE_CLICK, PreferenceConstants.DOUBLE_CLICK_EXPANDS); store.setDefault(PreferenceConstants.UPDATE_JAVA_VIEWS, PreferenceConstants.UPDATE_WHILE_EDITING); store.setToDefault(PreferenceConstants.UPDATE_JAVA_VIEWS); // clear // preference, // update on save // not supported // anymore store.setDefault(PreferenceConstants.LINK_BROWSING_PROJECTS_TO_EDITOR, true); store.setDefault(PreferenceConstants.LINK_BROWSING_PACKAGES_TO_EDITOR, true); store.setDefault(PreferenceConstants.LINK_BROWSING_TYPES_TO_EDITOR, true); store.setDefault(PreferenceConstants.LINK_BROWSING_MEMBERS_TO_EDITOR, true); store.setDefault(PreferenceConstants.SEARCH_USE_REDUCED_MENU, true); // AppearancePreferencePage store.setDefault(PreferenceConstants.APPEARANCE_COMPRESS_PACKAGE_NAMES, false); store.setDefault(PreferenceConstants.APPEARANCE_METHOD_RETURNTYPE, false); store.setDefault(PreferenceConstants.APPEARANCE_METHOD_TYPEPARAMETERS, true); store.setDefault(PreferenceConstants.APPEARANCE_CATEGORY, false); store.setDefault(PreferenceConstants.BROWSING_STACK_VERTICALLY, false); store.setDefault(PreferenceConstants.APPEARANCE_PKG_NAME_PATTERN_FOR_PKG_VIEW, ""); //$NON-NLS-1$ // ImportOrganizePreferencePage store.setDefault(PreferenceConstants.ORGIMPORTS_IMPORTORDER, "java;javax;org;com"); //$NON-NLS-1$ store.setDefault(PreferenceConstants.ORGIMPORTS_ONDEMANDTHRESHOLD, 99); store.setDefault(PreferenceConstants.ORGIMPORTS_STATIC_ONDEMANDTHRESHOLD, 99); store.setDefault(PreferenceConstants.ORGIMPORTS_IGNORELOWERCASE, true); // TypeFilterPreferencePage store.setDefault(PreferenceConstants.TYPEFILTER_ENABLED, ""); //$NON-NLS-1$ store.setDefault(PreferenceConstants.TYPEFILTER_DISABLED, ""); //$NON-NLS-1$ // ClasspathVariablesPreferencePage // CodeFormatterPreferencePage // CompilerPreferencePage // no initialization needed // RefactoringPreferencePage store.setDefault(PreferenceConstants.REFACTOR_ERROR_PAGE_SEVERITY_THRESHOLD, PreferenceConstants.REFACTOR_WARNING_SEVERITY); store.setDefault(PreferenceConstants.REFACTOR_SAVE_ALL_EDITORS, false); store.setDefault(PreferenceConstants.REFACTOR_LIGHTWEIGHT, true); // TemplatePreferencePage store.setDefault(PreferenceConstants.TEMPLATES_USE_CODEFORMATTER, true); // CodeGenerationPreferencePage // compatibility code if (store.getBoolean(PreferenceConstants.CODEGEN_USE_GETTERSETTER_PREFIX)) { String prefix = store.getString(PreferenceConstants.CODEGEN_GETTERSETTER_PREFIX); if (prefix.length() > 0) { DartCore.getPlugin().getPluginPreferences().setValue(JavaScriptCore.CODEASSIST_FIELD_PREFIXES, prefix); store.setToDefault(PreferenceConstants.CODEGEN_USE_GETTERSETTER_PREFIX); store.setToDefault(PreferenceConstants.CODEGEN_GETTERSETTER_PREFIX); } } if (store.getBoolean(PreferenceConstants.CODEGEN_USE_GETTERSETTER_SUFFIX)) { String suffix = store.getString(PreferenceConstants.CODEGEN_GETTERSETTER_SUFFIX); if (suffix.length() > 0) { DartCore.getPlugin().getPluginPreferences().setValue(JavaScriptCore.CODEASSIST_FIELD_SUFFIXES, suffix); store.setToDefault(PreferenceConstants.CODEGEN_USE_GETTERSETTER_SUFFIX); store.setToDefault(PreferenceConstants.CODEGEN_GETTERSETTER_SUFFIX); } } store.setDefault(PreferenceConstants.CODEGEN_KEYWORD_THIS, false); store.setDefault(PreferenceConstants.CODEGEN_IS_FOR_GETTERS, true); store.setDefault(PreferenceConstants.CODEGEN_EXCEPTION_VAR_NAME, "e"); //$NON-NLS-1$ store.setDefault(PreferenceConstants.CODEGEN_ADD_COMMENTS, false); store.setDefault(PreferenceConstants.CODEGEN_USE_OVERRIDE_ANNOTATION, true); // MembersOrderPreferencePage store.setDefault(PreferenceConstants.APPEARANCE_MEMBER_SORT_ORDER, "T,SF,SI,SM,F,I,C,M"); //$NON-NLS-1$ store.setDefault(PreferenceConstants.APPEARANCE_VISIBILITY_SORT_ORDER, "B,V,R,D"); //$NON-NLS-1$ store.setDefault(PreferenceConstants.APPEARANCE_ENABLE_VISIBILITY_SORT_ORDER, false); // JavaEditorPreferencePage store.setDefault(PreferenceConstants.EDITOR_MATCHING_BRACKETS, true); setDefaultAndFireEvent(store, PreferenceConstants.EDITOR_MATCHING_BRACKETS_COLOR, findRGB(registry, IJavaThemeConstants.EDITOR_MATCHING_BRACKETS_COLOR, new RGB(192, 192, 192))); store.setDefault(PreferenceConstants.EDITOR_CORRECTION_INDICATION, true); store.setDefault(PreferenceConstants.EDITOR_SYNC_OUTLINE_ON_CURSOR_MOVE, true); store.setDefault(PreferenceConstants.EDITOR_EVALUTE_TEMPORARY_PROBLEMS, true); PreferenceConverter.setDefault(store, PreferenceConstants.EDITOR_LINKED_POSITION_COLOR, new RGB(121, 121, 121)); store.setDefault(PreferenceConstants.EDITOR_TAB_WIDTH, 2); store.setDefault(PreferenceConstants.EDITOR_SPACES_FOR_TABS, true); setDefaultAndFireEvent(store, PreferenceConstants.EDITOR_MULTI_LINE_COMMENT_COLOR, findRGB(registry, IJavaThemeConstants.EDITOR_MULTI_LINE_COMMENT_COLOR, new RGB(63, 127, 95))); store.setDefault(PreferenceConstants.EDITOR_MULTI_LINE_COMMENT_BOLD, false); store.setDefault(PreferenceConstants.EDITOR_MULTI_LINE_COMMENT_ITALIC, false); setDefaultAndFireEvent(store, PreferenceConstants.EDITOR_SINGLE_LINE_COMMENT_COLOR, findRGB(registry, IJavaThemeConstants.EDITOR_SINGLE_LINE_COMMENT_COLOR, new RGB(63, 127, 95))); store.setDefault(PreferenceConstants.EDITOR_SINGLE_LINE_COMMENT_BOLD, false); store.setDefault(PreferenceConstants.EDITOR_SINGLE_LINE_COMMENT_ITALIC, false); setDefaultAndFireEvent(store, PreferenceConstants.EDITOR_DART_KEYWORD_COLOR, findRGB(registry, IJavaThemeConstants.EDITOR_JAVA_KEYWORD_COLOR, new RGB(127, 0, 85))); store.setDefault(PreferenceConstants.EDITOR_JAVA_KEYWORD_BOLD, true); store.setDefault(PreferenceConstants.EDITOR_JAVA_KEYWORD_ITALIC, false); PreferenceConverter.setDefault(store, PreferenceConstants.EDITOR_JAVA_ANNOTATION_COLOR, new RGB(100, 100, 100)); store.setDefault(PreferenceConstants.EDITOR_JAVA_ANNOTATION_BOLD, false); store.setDefault(PreferenceConstants.EDITOR_JAVA_ANNOTATION_ITALIC, false); setDefaultAndFireEvent(store, PreferenceConstants.EDITOR_STRING_COLOR, findRGB(registry, IJavaThemeConstants.EDITOR_STRING_COLOR, new RGB(42, 0, 255))); setDefaultAndFireEvent(store, PreferenceConstants.EDITOR_MULTI_LINE_STRING_COLOR, findRGB(registry, IJavaThemeConstants.EDITOR_MULTI_LINE_STRING_COLOR, new RGB(42, 0, 255))); store.setDefault(PreferenceConstants.EDITOR_STRING_BOLD, false); store.setDefault(PreferenceConstants.EDITOR_STRING_ITALIC, false); setDefaultAndFireEvent(store, PreferenceConstants.EDITOR_DART_DEFAULT_COLOR, findRGB(registry, IJavaThemeConstants.EDITOR_JAVA_DEFAULT_COLOR, new RGB(0, 0, 0))); store.setDefault(PreferenceConstants.EDITOR_JAVA_DEFAULT_BOLD, false); store.setDefault(PreferenceConstants.EDITOR_JAVA_DEFAULT_ITALIC, false); setDefaultAndFireEvent(store, PreferenceConstants.EDITOR_JAVA_METHOD_NAME_COLOR, new RGB(0, 0, 0)); store.setDefault(PreferenceConstants.EDITOR_JAVA_METHOD_NAME_BOLD, false); store.setDefault(PreferenceConstants.EDITOR_JAVA_METHOD_NAME_ITALIC, false); setDefaultAndFireEvent(store, PreferenceConstants.EDITOR_DART_KEYWORD_RETURN_COLOR, findRGB(registry, IJavaThemeConstants.EDITOR_JAVA_KEYWORD_RETURN_COLOR, new RGB(127, 0, 85))); store.setDefault(PreferenceConstants.EDITOR_JAVA_KEYWORD_RETURN_BOLD, true); store.setDefault(PreferenceConstants.EDITOR_JAVA_KEYWORD_RETURN_ITALIC, false); setDefaultAndFireEvent(store, PreferenceConstants.EDITOR_DART_OPERATOR_COLOR, findRGB(registry, IJavaThemeConstants.EDITOR_JAVA_OPERATOR_COLOR, new RGB(0, 0, 0))); store.setDefault(PreferenceConstants.EDITOR_JAVA_OPERATOR_BOLD, false); store.setDefault(PreferenceConstants.EDITOR_JAVA_OPERATOR_ITALIC, false); setDefaultAndFireEvent(store, PreferenceConstants.EDITOR_DART_BRACKET_COLOR, findRGB(registry, IJavaThemeConstants.EDITOR_JAVA_BRACKET_COLOR, new RGB(0, 0, 0))); store.setDefault(PreferenceConstants.EDITOR_JAVA_BRACKET_BOLD, false); store.setDefault(PreferenceConstants.EDITOR_JAVA_BRACKET_ITALIC, false); setDefaultAndFireEvent(store, PreferenceConstants.EDITOR_TASK_TAG_COLOR, findRGB(registry, IJavaThemeConstants.EDITOR_TASK_TAG_COLOR, new RGB(127, 159, 191))); store.setDefault(PreferenceConstants.EDITOR_TASK_TAG_BOLD, true); store.setDefault(PreferenceConstants.EDITOR_TASK_TAG_ITALIC, false); setDefaultAndFireEvent(store, PreferenceConstants.EDITOR_DARTDOC_KEYWORD_COLOR, findRGB(registry, IJavaThemeConstants.EDITOR_JAVADOC_KEYWORD_COLOR, new RGB(127, 159, 191))); store.setDefault(PreferenceConstants.EDITOR_JAVADOC_KEYWORD_BOLD, true); store.setDefault(PreferenceConstants.EDITOR_JAVADOC_KEYWORD_ITALIC, false); setDefaultAndFireEvent(store, PreferenceConstants.EDITOR_DARTDOC_TAG_COLOR, findRGB(registry, IJavaThemeConstants.EDITOR_JAVADOC_TAG_COLOR, new RGB(127, 127, 159))); store.setDefault(PreferenceConstants.EDITOR_JAVADOC_TAG_BOLD, false); store.setDefault(PreferenceConstants.EDITOR_JAVADOC_TAG_ITALIC, false); setDefaultAndFireEvent(store, PreferenceConstants.EDITOR_DARTDOC_LINKS_COLOR, findRGB(registry, IJavaThemeConstants.EDITOR_JAVADOC_LINKS_COLOR, new RGB(63, 63, 191))); store.setDefault(PreferenceConstants.EDITOR_JAVADOC_LINKS_BOLD, false); store.setDefault(PreferenceConstants.EDITOR_JAVADOC_LINKS_ITALIC, false); setDefaultAndFireEvent(store, PreferenceConstants.EDITOR_DARTDOC_DEFAULT_COLOR, findRGB(registry, IJavaThemeConstants.EDITOR_JAVADOC_DEFAULT_COLOR, new RGB(63, 95, 191))); store.setDefault(PreferenceConstants.EDITOR_JAVADOC_DEFAULT_BOLD, false); store.setDefault(PreferenceConstants.EDITOR_JAVADOC_DEFAULT_ITALIC, false); store.setDefault(PreferenceConstants.CODEASSIST_AUTOACTIVATION, true); store.setDefault(PreferenceConstants.CODEASSIST_AUTOACTIVATION_DELAY, 300); store.setDefault(PreferenceConstants.CODEASSIST_AUTOINSERT, false); setDefaultAndFireEvent(store, PreferenceConstants.CODEASSIST_PROPOSALS_BACKGROUND, findRGB(registry, IJavaThemeConstants.CODEASSIST_PROPOSALS_BACKGROUND, new RGB(255, 255, 255))); setDefaultAndFireEvent(store, PreferenceConstants.CODEASSIST_PROPOSALS_FOREGROUND, findRGB(registry, IJavaThemeConstants.CODEASSIST_PROPOSALS_FOREGROUND, new RGB(0, 0, 0))); setDefaultAndFireEvent(store, PreferenceConstants.CODEASSIST_PARAMETERS_BACKGROUND, findRGB(registry, IJavaThemeConstants.CODEASSIST_PARAMETERS_BACKGROUND, new RGB(255, 255, 255))); setDefaultAndFireEvent(store, PreferenceConstants.CODEASSIST_PARAMETERS_FOREGROUND, findRGB(registry, IJavaThemeConstants.CODEASSIST_PARAMETERS_FOREGROUND, new RGB(0, 0, 0))); setDefaultAndFireEvent(store, PreferenceConstants.CODEASSIST_REPLACEMENT_BACKGROUND, findRGB(registry, IJavaThemeConstants.CODEASSIST_REPLACEMENT_BACKGROUND, new RGB(255, 255, 0))); setDefaultAndFireEvent(store, PreferenceConstants.CODEASSIST_REPLACEMENT_FOREGROUND, findRGB(registry, IJavaThemeConstants.CODEASSIST_REPLACEMENT_FOREGROUND, new RGB(255, 0, 0))); store.setDefault(PreferenceConstants.CODEASSIST_AUTOACTIVATION_TRIGGERS_JAVA, "."); //$NON-NLS-1$ store.setDefault(PreferenceConstants.CODEASSIST_AUTOACTIVATION_TRIGGERS_JAVADOC, "@#"); //$NON-NLS-1$ store.setDefault(PreferenceConstants.CODEASSIST_SHOW_VISIBLE_PROPOSALS, true); store.setDefault(PreferenceConstants.CODEASSIST_CASE_SENSITIVITY, false); store.setDefault(PreferenceConstants.CODEASSIST_ADDIMPORT, false); store.setDefault(PreferenceConstants.CODEASSIST_INSERT_COMPLETION, true); store.setDefault(PreferenceConstants.CODEASSIST_FILL_ARGUMENT_NAMES, true); store.setDefault(PreferenceConstants.CODEASSIST_GUESS_METHOD_ARGUMENTS, true); store.setDefault(PreferenceConstants.CODEASSIST_PREFIX_COMPLETION, false); // can't believe embedded null is used as a delimiter store.setDefault(PreferenceConstants.CODEASSIST_EXCLUDED_CATEGORIES, "com.google.dart.tools.ui.spellingProposalCategory\0com.google.dart.tools.ui.textProposalCategory\0"); //$NON-NLS-1$ store.setDefault(PreferenceConstants.CODEASSIST_CATEGORY_ORDER, "com.google.dart.tools.ui.spellingProposalCategory:65545\0com.google.dart.tools.ui.javaTypeProposalCategory:65540\0com.google.dart.tools.ui.javaNoTypeProposalCategory:65539\0com.google.dart.tools.ui.textProposalCategory:65541\0com.google.dart.tools.ui.templateProposalCategory:2\0"); //$NON-NLS-1$ store.setDefault(PreferenceConstants.CODEASSIST_LRU_HISTORY, ""); //$NON-NLS-1$ store.setDefault(PreferenceConstants.CODEASSIST_SORTER, "com.google.dart.tools.ui.RelevanceSorter"); //$NON-NLS-1$ store.setDefault(PreferenceConstants.CODEASSIST_FAVORITE_STATIC_MEMBERS, ""); //$NON-NLS-1$ store.setDefault(PreferenceConstants.EDITOR_SUB_WORD_NAVIGATION, true); store.setDefault(PreferenceConstants.EDITOR_SMART_PASTE, true); store.setDefault(PreferenceConstants.EDITOR_IMPORTS_ON_PASTE, true); store.setDefault(PreferenceConstants.EDITOR_CLOSE_STRINGS, true); store.setDefault(PreferenceConstants.EDITOR_CLOSE_BRACKETS, true); store.setDefault(PreferenceConstants.EDITOR_CLOSE_BRACES, true); store.setDefault(PreferenceConstants.EDITOR_CLOSE_JAVADOCS, true); store.setDefault(PreferenceConstants.EDITOR_WRAP_STRINGS, true); store.setDefault(PreferenceConstants.EDITOR_ESCAPE_STRINGS, false); store.setDefault(PreferenceConstants.EDITOR_ADD_JAVADOC_TAGS, true); store.setDefault(PreferenceConstants.EDITOR_FORMAT_JAVADOCS, false); store.setDefault(PreferenceConstants.EDITOR_REMOVE_TRAILING_WS, false); int sourceHoverModifier = SWT.MOD2; String sourceHoverModifierName = Action.findModifierString(sourceHoverModifier); // Shift int nlsHoverModifier = SWT.MOD1 + SWT.MOD3; String nlsHoverModifierName = Action.findModifierString(SWT.MOD1) + "+" //$NON-NLS-1$ + Action.findModifierString(SWT.MOD3); // Ctrl + Alt store.setDefault(PreferenceConstants.EDITOR_TEXT_HOVER_MODIFIERS, "com.google.dart.tools.ui.BestMatchHover;0;com.google.dart.tools.ui.JavaSourceHover;" //$NON-NLS-1$ + sourceHoverModifierName + ";com.google.dart.tools.ui.NLSStringHover;" //$NON-NLS-1$ + nlsHoverModifierName); store.setDefault(PreferenceConstants.EDITOR_TEXT_HOVER_MODIFIER_MASKS, "com.google.dart.tools.ui.BestMatchHover;0;com.google.dart.tools.ui.JavaSourceHover;" //$NON-NLS-1$ + sourceHoverModifier + ";com.google.dart.tools.ui.NLSStringHover;" + nlsHoverModifier); //$NON-NLS-1$ store.setDefault(PreferenceConstants.EDITOR_SMART_TAB, true); store.setDefault(PreferenceConstants.EDITOR_SMART_BACKSPACE, true); store.setDefault(PreferenceConstants.EDITOR_ANNOTATION_ROLL_OVER, false); store.setDefault(EDITOR_SOURCE_HOVER_BACKGROUND_COLOR_SYSTEM_DEFAULT, true); DartX.todo(); // store.setDefault(PreferenceConstants.FORMATTER_PROFILE, // FormatterProfileManager.DEFAULT_PROFILE); // mark occurrences boolean disableMarks = DartCoreDebug.DISABLE_MARK_OCCURRENCES; store.setDefault(PreferenceConstants.EDITOR_MARK_OCCURRENCES, !disableMarks); store.setDefault(PreferenceConstants.EDITOR_STICKY_OCCURRENCES, false); store.setDefault(PreferenceConstants.EDITOR_MARK_TYPE_OCCURRENCES, true); store.setDefault(PreferenceConstants.EDITOR_MARK_METHOD_OCCURRENCES, true); store.setDefault(PreferenceConstants.EDITOR_MARK_CONSTANT_OCCURRENCES, true); store.setDefault(PreferenceConstants.EDITOR_MARK_FIELD_OCCURRENCES, true); store.setDefault(PreferenceConstants.EDITOR_MARK_LOCAL_VARIABLE_OCCURRENCES, true); store.setDefault(PreferenceConstants.EDITOR_MARK_EXCEPTION_OCCURRENCES, true); store.setDefault(PreferenceConstants.EDITOR_MARK_METHOD_EXIT_POINTS, true); store.setDefault(PreferenceConstants.EDITOR_MARK_BREAK_CONTINUE_TARGETS, true); store.setDefault(PreferenceConstants.EDITOR_MARK_IMPLEMENTORS, true); // folding store.setDefault(PreferenceConstants.EDITOR_FOLDING_ENABLED, true); store.setDefault(PreferenceConstants.EDITOR_FOLDING_PROVIDER, "com.google.dart.tools.ui.text.defaultFoldingProvider"); //$NON-NLS-1$ store.setDefault(PreferenceConstants.EDITOR_FOLDING_JAVADOC, false); store.setDefault(PreferenceConstants.EDITOR_FOLDING_INNERTYPES, false); store.setDefault(PreferenceConstants.EDITOR_FOLDING_METHODS, false); store.setDefault(PreferenceConstants.EDITOR_FOLDING_IMPORTS, true); store.setDefault(PreferenceConstants.EDITOR_FOLDING_HEADERS, true); // properties file editor setDefaultAndFireEvent(store, PreferenceConstants.PROPERTIES_FILE_COLORING_KEY, findRGB(registry, IJavaThemeConstants.PROPERTIES_FILE_COLORING_KEY, new RGB(0, 0, 0))); store.setDefault(PreferenceConstants.PROPERTIES_FILE_COLORING_KEY_BOLD, false); store.setDefault(PreferenceConstants.PROPERTIES_FILE_COLORING_KEY_ITALIC, false); setDefaultAndFireEvent(store, PreferenceConstants.PROPERTIES_FILE_COLORING_VALUE, findRGB(registry, IJavaThemeConstants.PROPERTIES_FILE_COLORING_VALUE, new RGB(42, 0, 255))); store.setDefault(PreferenceConstants.PROPERTIES_FILE_COLORING_VALUE_BOLD, false); store.setDefault(PreferenceConstants.PROPERTIES_FILE_COLORING_VALUE_ITALIC, false); setDefaultAndFireEvent(store, PreferenceConstants.PROPERTIES_FILE_COLORING_ASSIGNMENT, findRGB(registry, IJavaThemeConstants.PROPERTIES_FILE_COLORING_ASSIGNMENT, new RGB(0, 0, 0))); store.setDefault(PreferenceConstants.PROPERTIES_FILE_COLORING_ASSIGNMENT_BOLD, false); store.setDefault(PreferenceConstants.PROPERTIES_FILE_COLORING_ASSIGNMENT_ITALIC, false); setDefaultAndFireEvent(store, PreferenceConstants.PROPERTIES_FILE_COLORING_ARGUMENT, findRGB(registry, IJavaThemeConstants.PROPERTIES_FILE_COLORING_ARGUMENT, new RGB(127, 0, 85))); store.setDefault(PreferenceConstants.PROPERTIES_FILE_COLORING_ARGUMENT_BOLD, true); store.setDefault(PreferenceConstants.PROPERTIES_FILE_COLORING_ARGUMENT_ITALIC, false); setDefaultAndFireEvent(store, PreferenceConstants.PROPERTIES_FILE_COLORING_COMMENT, findRGB(registry, IJavaThemeConstants.PROPERTIES_FILE_COLORING_COMMENT, new RGB(63, 127, 95))); store.setDefault(PreferenceConstants.PROPERTIES_FILE_COLORING_COMMENT_BOLD, false); store.setDefault(PreferenceConstants.PROPERTIES_FILE_COLORING_COMMENT_ITALIC, false); store.setDefault(PreferenceConstants.PREF_DEFAULT_EXPAND_WITH_CONSTRUCTORS_MEMBERS, ""); //$NON-NLS-1$ // semantic highlighting SemanticHighlightings.initDefaults(store); // do more complicated stuff DartX.todo(); // NewJavaProjectPreferencePage.initDefaults(store); // reset preferences that are not settable by editor any longer // see AbstractDecoratedTextEditorPreferenceConstants store.setToDefault(EDITOR_SMART_HOME_END); // global store.setToDefault(EDITOR_LINE_NUMBER_RULER); // global store.setToDefault(EDITOR_LINE_NUMBER_RULER_COLOR); // global store.setToDefault(EDITOR_OVERVIEW_RULER); // removed -> true store.setToDefault(AbstractDecoratedTextEditorPreferenceConstants.EDITOR_USE_CUSTOM_CARETS); // accessibility store.setToDefault(PreferenceConstants.EDITOR_CURRENT_LINE); // global store.setToDefault(PreferenceConstants.EDITOR_CURRENT_LINE_COLOR); // global store.setToDefault(PreferenceConstants.EDITOR_PRINT_MARGIN); // global store.setToDefault(PreferenceConstants.EDITOR_PRINT_MARGIN_COLUMN); // global store.setToDefault(PreferenceConstants.EDITOR_PRINT_MARGIN_COLOR); // global store.setToDefault(PreferenceConstants.EDITOR_FOREGROUND_COLOR); // global store.setToDefault(PreferenceConstants.EDITOR_FOREGROUND_DEFAULT_COLOR); // global store.setToDefault(PreferenceConstants.EDITOR_BACKGROUND_COLOR); // global store.setToDefault(PreferenceConstants.EDITOR_BACKGROUND_DEFAULT_COLOR); // global store.setToDefault(PreferenceConstants.EDITOR_FIND_SCOPE_COLOR); // global store.setToDefault( AbstractDecoratedTextEditorPreferenceConstants.EDITOR_SELECTION_FOREGROUND_DEFAULT_COLOR); // global store.setToDefault( AbstractDecoratedTextEditorPreferenceConstants.EDITOR_SELECTION_BACKGROUND_DEFAULT_COLOR); // global store.setToDefault(PreferenceConstants.EDITOR_DISABLE_OVERWRITE_MODE); // global store.setToDefault(PreferenceConstants.EDITOR_SEMANTIC_HIGHLIGHTING_ENABLED); // removed store.setToDefault(PreferenceConstants.EDITOR_SHOW_TEXT_HOVER_AFFORDANCE); // global // Code Clean Up DartX.todo(); CleanUpConstants.initDefaults(store); }
From source file:com.google.dart.tools.ui.theme.preferences.PreferenceInitializer.java
License:Open Source License
@Override public void initializeDefaultPreferences() { IPreferenceStore store = Activator.getDefault().getPreferenceStore(); store.setDefault("colorTheme", "default"); // $NON-NLS-1$ // $NON-NLS-2$ }