/** * Install the semantic highlighting on the given editor infrastructure * * @param editor The Java editor * @param sourceViewer The source viewer * @param colorManager The color manager * @param preferenceStore The preference store */ public void install(JavaEditor editor, JavaSourceViewer sourceViewer, IColorManager colorManager, IPreferenceStore preferenceStore) { fEditor= editor; fSourceViewer= sourceViewer; fColorManager= colorManager; fPreferenceStore= preferenceStore; if (fEditor != null) { fConfiguration= editor.createJavaSourceViewerConfiguration(); fPresentationReconciler= (JavaPresentationReconciler) fConfiguration.getPresentationReconciler(sourceViewer); } else { fConfiguration= null; fPresentationReconciler= null; } fPreferenceStore.addPropertyChangeListener(this); if (isEnabled()) enable(); }
/** * Install the semantic highlighting on the given editor infrastructure * * @param editor The Java editor * @param sourceViewer The source viewer * @param colorManager The color manager * @param preferenceStore The preference store */ public void install(JavaEditor editor, JavaSourceViewer sourceViewer, IColorManager colorManager, IPreferenceStore preferenceStore) { fEditor= editor; fSourceViewer= sourceViewer; fColorManager= colorManager; fPreferenceStore= preferenceStore; if (fEditor != null) { fConfiguration= editor.createJavaSourceViewerConfiguration(); fPresentationReconciler= (JavaPresentationReconciler) fConfiguration.getPresentationReconciler(sourceViewer); } else { fConfiguration= null; fPresentationReconciler= null; } fPreferenceStore.addPropertyChangeListener(this); if (isEnabled()) enable(); }
/** * Install the semantic highlighting on the given editor infrastructure * * @param editor The Java editor * @param sourceViewer The source viewer * @param colorManager The color manager * @param preferenceStore The preference store */ public void install(JavaEditor editor, JavaSourceViewer sourceViewer, IColorManager colorManager, IPreferenceStore preferenceStore) { fEditor= editor; fSourceViewer= sourceViewer; fColorManager= colorManager; fPreferenceStore= preferenceStore; if (fEditor != null) { fConfiguration= editor.createJavaSourceViewerConfiguration(); fPresentationReconciler= (JavaPresentationReconciler) fConfiguration.getPresentationReconciler(sourceViewer); } else { fConfiguration= null; fPresentationReconciler= null; } fPreferenceStore.addPropertyChangeListener(this); if (isEnabled()) enable(); }
protected void initializeEditor() { IPreferenceStore store= createCombinedPreferenceStore(null); setPreferenceStore(store); setSourceViewerConfiguration(createJavaSourceViewerConfiguration()); fMarkOccurrenceAnnotations= store.getBoolean(PreferenceConstants.EDITOR_MARK_OCCURRENCES); fStickyOccurrenceAnnotations= store.getBoolean(PreferenceConstants.EDITOR_STICKY_OCCURRENCES); fMarkTypeOccurrences= store.getBoolean(PreferenceConstants.EDITOR_MARK_TYPE_OCCURRENCES); fMarkMethodOccurrences= store.getBoolean(PreferenceConstants.EDITOR_MARK_METHOD_OCCURRENCES); fMarkConstantOccurrences= store.getBoolean(PreferenceConstants.EDITOR_MARK_CONSTANT_OCCURRENCES); fMarkFieldOccurrences= store.getBoolean(PreferenceConstants.EDITOR_MARK_FIELD_OCCURRENCES); fMarkLocalVariableypeOccurrences= store.getBoolean(PreferenceConstants.EDITOR_MARK_LOCAL_VARIABLE_OCCURRENCES); fMarkExceptions= store.getBoolean(PreferenceConstants.EDITOR_MARK_EXCEPTION_OCCURRENCES); fMarkImplementors= store.getBoolean(PreferenceConstants.EDITOR_MARK_IMPLEMENTORS); fMarkMethodExitPoints= store.getBoolean(PreferenceConstants.EDITOR_MARK_METHOD_EXIT_POINTS); fMarkBreakContinueTargets= store.getBoolean(PreferenceConstants.EDITOR_MARK_BREAK_CONTINUE_TARGETS); }