View | Details | Raw Unified | Return to bug 22712 | Differences between
and this patch

Collapse All | Expand All

(-)ui/org/eclipse/jdt/internal/ui/javaeditor/JavaEditor.java (-1 / +6 lines)
Lines 7-12 Link Here
7
 * 
7
 * 
8
 * Contributors:
8
 * Contributors:
9
 *     IBM Corporation - initial API and implementation
9
 *     IBM Corporation - initial API and implementation
10
 *     Sebastian Davids <sdavids@gmx.de> - bug 22712
10
 *******************************************************************************/
11
 *******************************************************************************/
11
12
12
package org.eclipse.jdt.internal.ui.javaeditor;
13
package org.eclipse.jdt.internal.ui.javaeditor;
Lines 1061-1066 Link Here
1061
	protected final static String MATCHING_BRACKETS=  PreferenceConstants.EDITOR_MATCHING_BRACKETS;
1062
	protected final static String MATCHING_BRACKETS=  PreferenceConstants.EDITOR_MATCHING_BRACKETS;
1062
	/** Preference key for matching brackets color */
1063
	/** Preference key for matching brackets color */
1063
	protected final static String MATCHING_BRACKETS_COLOR=  PreferenceConstants.EDITOR_MATCHING_BRACKETS_COLOR;
1064
	protected final static String MATCHING_BRACKETS_COLOR=  PreferenceConstants.EDITOR_MATCHING_BRACKETS_COLOR;
1065
	/** Preference key for whitespace painter. */
1066
	protected final static String WHITESPACE= PreferenceConstants.EDITOR_WHITESPACE;
1067
	/** Preference key for whitespace painter color. */
1068
	protected final static String WHITESPACE_COLOR= PreferenceConstants.EDITOR_WHITESPACE_COLOR;	
1064
	/** Preference key for highlighting current line */
1069
	/** Preference key for highlighting current line */
1065
	protected final static String CURRENT_LINE= PreferenceConstants.EDITOR_CURRENT_LINE;
1070
	protected final static String CURRENT_LINE= PreferenceConstants.EDITOR_CURRENT_LINE;
1066
	/** Preference key for highlight color of current line */
1071
	/** Preference key for highlight color of current line */
Lines 2138-2144 Link Here
2138
		fSourceViewerDecorationSupport.setAnnotationPainterPreferenceKeys(AnnotationType.WARNING, WARNING_INDICATION_COLOR, WARNING_INDICATION, WARNING_INDICATION_IN_OVERVIEW_RULER, 4);
2143
		fSourceViewerDecorationSupport.setAnnotationPainterPreferenceKeys(AnnotationType.WARNING, WARNING_INDICATION_COLOR, WARNING_INDICATION, WARNING_INDICATION_IN_OVERVIEW_RULER, 4);
2139
		fSourceViewerDecorationSupport.setAnnotationPainterPreferenceKeys(AnnotationType.ERROR, ERROR_INDICATION_COLOR, ERROR_INDICATION, ERROR_INDICATION_IN_OVERVIEW_RULER, 5);
2144
		fSourceViewerDecorationSupport.setAnnotationPainterPreferenceKeys(AnnotationType.ERROR, ERROR_INDICATION_COLOR, ERROR_INDICATION, ERROR_INDICATION_IN_OVERVIEW_RULER, 5);
2140
				
2145
				
2141
		
2146
		fSourceViewerDecorationSupport.setWhitespacePainterPreferenceKeys(WHITESPACE, WHITESPACE_COLOR);
2142
		fSourceViewerDecorationSupport.setCursorLinePainterPreferenceKeys(CURRENT_LINE, CURRENT_LINE_COLOR);
2147
		fSourceViewerDecorationSupport.setCursorLinePainterPreferenceKeys(CURRENT_LINE, CURRENT_LINE_COLOR);
2143
		fSourceViewerDecorationSupport.setMarginPainterPreferenceKeys(PRINT_MARGIN, PRINT_MARGIN_COLOR, PRINT_MARGIN_COLUMN);
2148
		fSourceViewerDecorationSupport.setMarginPainterPreferenceKeys(PRINT_MARGIN, PRINT_MARGIN_COLOR, PRINT_MARGIN_COLUMN);
2144
		fSourceViewerDecorationSupport.setMatchingCharacterPainterPreferenceKeys(MATCHING_BRACKETS, MATCHING_BRACKETS_COLOR);
2149
		fSourceViewerDecorationSupport.setMatchingCharacterPainterPreferenceKeys(MATCHING_BRACKETS, MATCHING_BRACKETS_COLOR);
(-)ui/org/eclipse/jdt/internal/ui/preferences/JavaEditorPreferencePage.java (+7 lines)
Lines 7-12 Link Here
7
 * 
7
 * 
8
 * Contributors:
8
 * Contributors:
9
 *     IBM Corporation - initial API and implementation
9
 *     IBM Corporation - initial API and implementation
10
 *     Sebastian Davids <sdavids@gmx.de> - bug 22712
10
 *******************************************************************************/
11
 *******************************************************************************/
11
12
12
package org.eclipse.jdt.internal.ui.preferences;
13
package org.eclipse.jdt.internal.ui.preferences;
Lines 131-136 Link Here
131
				
132
				
132
		new OverlayPreferenceStore.OverlayKey(OverlayPreferenceStore.STRING, PreferenceConstants.EDITOR_MATCHING_BRACKETS_COLOR),
133
		new OverlayPreferenceStore.OverlayKey(OverlayPreferenceStore.STRING, PreferenceConstants.EDITOR_MATCHING_BRACKETS_COLOR),
133
		new OverlayPreferenceStore.OverlayKey(OverlayPreferenceStore.BOOLEAN, PreferenceConstants.EDITOR_MATCHING_BRACKETS),
134
		new OverlayPreferenceStore.OverlayKey(OverlayPreferenceStore.BOOLEAN, PreferenceConstants.EDITOR_MATCHING_BRACKETS),
135
136
		new OverlayPreferenceStore.OverlayKey(OverlayPreferenceStore.STRING, PreferenceConstants.EDITOR_WHITESPACE_COLOR),
137
		new OverlayPreferenceStore.OverlayKey(OverlayPreferenceStore.BOOLEAN, PreferenceConstants.EDITOR_WHITESPACE),
134
		
138
		
135
		new OverlayPreferenceStore.OverlayKey(OverlayPreferenceStore.STRING, PreferenceConstants.EDITOR_CURRENT_LINE_COLOR),
139
		new OverlayPreferenceStore.OverlayKey(OverlayPreferenceStore.STRING, PreferenceConstants.EDITOR_CURRENT_LINE_COLOR),
136
		new OverlayPreferenceStore.OverlayKey(OverlayPreferenceStore.BOOLEAN, PreferenceConstants.EDITOR_CURRENT_LINE),
140
		new OverlayPreferenceStore.OverlayKey(OverlayPreferenceStore.BOOLEAN, PreferenceConstants.EDITOR_CURRENT_LINE),
Lines 240-245 Link Here
240
		{PreferencesMessages.getString("JavaEditorPreferencePage.findScopeColor2"), PreferenceConstants.EDITOR_FIND_SCOPE_COLOR}, //$NON-NLS-1$
244
		{PreferencesMessages.getString("JavaEditorPreferencePage.findScopeColor2"), PreferenceConstants.EDITOR_FIND_SCOPE_COLOR}, //$NON-NLS-1$
241
		{PreferencesMessages.getString("JavaEditorPreferencePage.linkedPositionColor2"), PreferenceConstants.EDITOR_LINKED_POSITION_COLOR}, //$NON-NLS-1$
245
		{PreferencesMessages.getString("JavaEditorPreferencePage.linkedPositionColor2"), PreferenceConstants.EDITOR_LINKED_POSITION_COLOR}, //$NON-NLS-1$
242
		{PreferencesMessages.getString("JavaEditorPreferencePage.linkColor2"), PreferenceConstants.EDITOR_LINK_COLOR}, //$NON-NLS-1$
246
		{PreferencesMessages.getString("JavaEditorPreferencePage.linkColor2"), PreferenceConstants.EDITOR_LINK_COLOR}, //$NON-NLS-1$
247
		{PreferencesMessages.getString("TextEditorPreferencePage.whitespaceColor"), PreferenceConstants.EDITOR_WHITESPACE_COLOR}, //$NON-NLS-1$
243
	};
248
	};
244
	
249
	
245
	private final String[][] fAnnotationColorListModel= new String[][] {
250
	private final String[][] fAnnotationColorListModel= new String[][] {
Lines 629-634 Link Here
629
		label= PreferencesMessages.getString("JavaEditorPreferencePage.showPrintMargin"); //$NON-NLS-1$
634
		label= PreferencesMessages.getString("JavaEditorPreferencePage.showPrintMargin"); //$NON-NLS-1$
630
		addCheckBox(appearanceComposite, label, PreferenceConstants.EDITOR_PRINT_MARGIN, 0);
635
		addCheckBox(appearanceComposite, label, PreferenceConstants.EDITOR_PRINT_MARGIN, 0);
631
636
637
		label= PreferencesMessages.getString("JavaEditorPreferencePage.showWhitespace"); //$NON-NLS-1$
638
		addCheckBox(appearanceComposite, label, PreferenceConstants.EDITOR_WHITESPACE, 0);
632
639
633
		Label l= new Label(appearanceComposite, SWT.LEFT );
640
		Label l= new Label(appearanceComposite, SWT.LEFT );
634
		GridData gd= new GridData(GridData.HORIZONTAL_ALIGN_FILL);
641
		GridData gd= new GridData(GridData.HORIZONTAL_ALIGN_FILL);
(-)ui/org/eclipse/jdt/internal/ui/preferences/PreferencesMessages.properties (+2 lines)
Lines 110-115 Link Here
110
JavaEditorPreferencePage.javaDocLinks=Javadoc links
110
JavaEditorPreferencePage.javaDocLinks=Javadoc links
111
JavaEditorPreferencePage.javaDocOthers=Javadoc others
111
JavaEditorPreferencePage.javaDocOthers=Javadoc others
112
JavaEditorPreferencePage.backgroundColor=Background color
112
JavaEditorPreferencePage.backgroundColor=Background color
113
TextEditorPreferencePage.whitespaceColor=Whitespace
113
JavaEditorPreferencePage.systemDefault=S&ystem Default
114
JavaEditorPreferencePage.systemDefault=S&ystem Default
114
JavaEditorPreferencePage.custom=C&ustom:
115
JavaEditorPreferencePage.custom=C&ustom:
115
JavaEditorPreferencePage.foreground=Fo&reground:
116
JavaEditorPreferencePage.foreground=Fo&reground:
Lines 122-127 Link Here
122
JavaEditorPreferencePage.highlightMatchingBrackets=Highlight &matching brackets
123
JavaEditorPreferencePage.highlightMatchingBrackets=Highlight &matching brackets
123
JavaEditorPreferencePage.highlightCurrentLine=Hi&ghlight current line
124
JavaEditorPreferencePage.highlightCurrentLine=Hi&ghlight current line
124
JavaEditorPreferencePage.showPrintMargin=Sho&w print margin
125
JavaEditorPreferencePage.showPrintMargin=Sho&w print margin
126
JavaEditorPreferencePage.showWhitespace=Show w&hitespace
125
JavaEditorPreferencePage.printMarginColumn=Print margin col&umn:
127
JavaEditorPreferencePage.printMarginColumn=Print margin col&umn:
126
JavaEditorPreferencePage.insertSingleProposalsAutomatically=Insert single &proposals automatically
128
JavaEditorPreferencePage.insertSingleProposalsAutomatically=Insert single &proposals automatically
127
JavaEditorPreferencePage.showOnlyProposalsVisibleInTheInvocationContext=Show only proposals &visible in the invocation context
129
JavaEditorPreferencePage.showOnlyProposalsVisibleInTheInvocationContext=Show only proposals &visible in the invocation context
(-)ui/org/eclipse/jdt/ui/PreferenceConstants.java (+26 lines)
Lines 7-12 Link Here
7
 * 
7
 * 
8
 * Contributors:
8
 * Contributors:
9
 *     IBM Corporation - initial API and implementation
9
 *     IBM Corporation - initial API and implementation
10
 *     Sebastian Davids <sdavids@gmx.de> - bug 22712
10
 *******************************************************************************/
11
 *******************************************************************************/
11
package org.eclipse.jdt.ui;
12
package org.eclipse.jdt.ui;
12
13
Lines 527-532 Link Here
527
	public final static String EDITOR_MATCHING_BRACKETS_COLOR=  "matchingBracketsColor"; //$NON-NLS-1$
528
	public final static String EDITOR_MATCHING_BRACKETS_COLOR=  "matchingBracketsColor"; //$NON-NLS-1$
528
529
529
	/**
530
	/**
531
	 * A named preference that controls if whitespace is decorated in the UI
532
	 * (value <code>"whitespace"</code>).
533
	 * <p>
534
	 * The preference value is of type <code>Boolean</code>.
535
	 * </p>
536
	 */
537
	public final static String EDITOR_WHITESPACE= "whitespace"; //$NON-NLS-1$
538
539
	/**
540
	 * A named preference that holds the color used to decorate whitespace in the editor
541
	 * (value <code>"whitespaceColor"</code>).
542
	 * <p>
543
	 * The preference value is of type <code>String</code>. A RGB color value encoded as a string
544
	 * using class <code>PreferenceConverter</code>.
545
	 * </p>
546
	 * @see org.eclipse.jface.resource.StringConverter
547
	 * @see org.eclipse.jface.preference.PreferenceConverter
548
	 * @see #EDITOR_WHITESPACE
549
	 */
550
	public final static String EDITOR_WHITESPACE_COLOR= "whitespaceColor"; //$NON-NLS-1$	
551
	
552
	/**
530
	 * A named preference that controls whether the current line highlighting is turned on or off.
553
	 * A named preference that controls whether the current line highlighting is turned on or off.
531
	 * <p>
554
	 * <p>
532
	 * Value is of type <code>Boolean</code>.
555
	 * Value is of type <code>Boolean</code>.
Lines 1811-1816 Link Here
1811
		store.setDefault(PreferenceConstants.EDITOR_MATCHING_BRACKETS, true);
1834
		store.setDefault(PreferenceConstants.EDITOR_MATCHING_BRACKETS, true);
1812
		PreferenceConverter.setDefault(store, PreferenceConstants.EDITOR_MATCHING_BRACKETS_COLOR, new RGB(192, 192,192));
1835
		PreferenceConverter.setDefault(store, PreferenceConstants.EDITOR_MATCHING_BRACKETS_COLOR, new RGB(192, 192,192));
1813
1836
1837
		store.setDefault(PreferenceConstants.EDITOR_WHITESPACE, false);
1838
		PreferenceConverter.setDefault(store, PreferenceConstants.EDITOR_WHITESPACE_COLOR, new RGB(176, 180 , 185));
1839
		
1814
		store.setDefault(PreferenceConstants.EDITOR_CURRENT_LINE, true);
1840
		store.setDefault(PreferenceConstants.EDITOR_CURRENT_LINE, true);
1815
		PreferenceConverter.setDefault(store, PreferenceConstants.EDITOR_CURRENT_LINE_COLOR, new RGB(225, 235, 224));
1841
		PreferenceConverter.setDefault(store, PreferenceConstants.EDITOR_CURRENT_LINE_COLOR, new RGB(225, 235, 224));
1816
1842

Return to bug 22712