Search in sources :

Example 6 with ITextViewerExtension4

use of org.eclipse.jface.text.ITextViewerExtension4 in project eclipse.platform.text by eclipse.

the class DefaultHyperlinkPresenter method uninstall.

@Override
public void uninstall() {
    fTextViewer.removeTextInputListener(this);
    IDocument document = fTextViewer.getDocument();
    if (document != null)
        document.removeDocumentListener(this);
    if (fColor != null) {
        if (fDisposeColor)
            fColor.dispose();
        fColor = null;
    }
    if (fTextViewer instanceof ITextViewerExtension4)
        ((ITextViewerExtension4) fTextViewer).removeTextPresentationListener(this);
    fTextViewer = null;
    if (fPreferenceStore != null) {
        fPreferenceStore.removePropertyChangeListener(this);
        fPreferenceStore = null;
    }
}
Also used : ITextViewerExtension4(org.eclipse.jface.text.ITextViewerExtension4) IDocument(org.eclipse.jface.text.IDocument)

Aggregations

ITextViewerExtension4 (org.eclipse.jface.text.ITextViewerExtension4)6 StyledText (org.eclipse.swt.custom.StyledText)3 ITextViewerExtension2 (org.eclipse.jface.text.ITextViewerExtension2)2 IDocument (org.eclipse.jface.text.IDocument)1 ISourceViewerExtension5 (org.eclipse.jface.text.source.ISourceViewerExtension5)1 Color (org.eclipse.swt.graphics.Color)1