public SyntaxColoringPreferencePage() {
   super();
   LogManager.logDebug("Start SyntaxColoringPreferencePage:", this);
   setPreferenceStore(IDEPlugin.getDefault().getPreferenceStore());
   setDescription(Localization.getString("SyntaxColoringPreferencePage.SyntaxColoringOptions"));
   LogManager.logDebug("End SyntaxColoringPreferencePage:", this);
 }
Esempio n. 2
0
  public IPresentationReconciler getPresentationReconciler(ISourceViewer sourceViewer) {
    LogManager.logDebug("Start getPresentationReconciler: sourceViewer-" + sourceViewer, this);
    PresentationReconciler reconciler = new PresentationReconciler();

    DefaultDamagerRepairer dr = new DefaultDamagerRepairer(getCScanner());
    reconciler.setDamager(dr, IDocument.DEFAULT_CONTENT_TYPE);
    reconciler.setRepairer(dr, IDocument.DEFAULT_CONTENT_TYPE);
    IPreferenceStore store = IDEPlugin.getDefault().getPreferenceStore();
    RGB comment = PreferenceConverter.getColor(store, IDEPreferenceConstants.P_C_COMMENT_COLOR);
    NonRuleBasedDamagerRepairer ndr =
        new NonRuleBasedDamagerRepairer(new TextAttribute(colorManager.getColor(comment)));
    reconciler.setDamager(ndr, CPartitionScanner.C_COMMENT);
    reconciler.setRepairer(ndr, CPartitionScanner.C_COMMENT);

    LogManager.logDebug("End getPresentationReconciler: returnVal-" + reconciler, this);
    return reconciler;
  }