Search in sources :

Example 1 with MarkerResoltionQuickAssistProcessor

use of org.eclipse.ui.internal.genericeditor.markers.MarkerResoltionQuickAssistProcessor in project eclipse.platform.text by eclipse.

the class ExtensionBasedTextViewerConfiguration method getQuickAssistAssistant.

@Override
public IQuickAssistAssistant getQuickAssistAssistant(ISourceViewer sourceViewer) {
    QuickAssistAssistant quickAssistAssistant = new QuickAssistAssistant();
    CompositeQuickAssistProcessor processor = new CompositeQuickAssistProcessor(Arrays.asList(new MarkerResoltionQuickAssistProcessor(), new SpellingCorrectionProcessor()));
    quickAssistAssistant.setQuickAssistProcessor(processor);
    // $NON-NLS-1$
    quickAssistAssistant.setRestoreCompletionProposalSize(EditorsPlugin.getDefault().getDialogSettingsSection("quick_assist_proposal_size"));
    quickAssistAssistant.setInformationControlCreator(parent -> new DefaultInformationControl(parent, EditorsPlugin.getAdditionalInfoAffordanceString()));
    return quickAssistAssistant;
}
Also used : MarkerResoltionQuickAssistProcessor(org.eclipse.ui.internal.genericeditor.markers.MarkerResoltionQuickAssistProcessor) DefaultInformationControl(org.eclipse.jface.text.DefaultInformationControl) SpellingCorrectionProcessor(org.eclipse.ui.texteditor.spelling.SpellingCorrectionProcessor) QuickAssistAssistant(org.eclipse.jface.text.quickassist.QuickAssistAssistant) IQuickAssistAssistant(org.eclipse.jface.text.quickassist.IQuickAssistAssistant)

Aggregations

DefaultInformationControl (org.eclipse.jface.text.DefaultInformationControl)1 IQuickAssistAssistant (org.eclipse.jface.text.quickassist.IQuickAssistAssistant)1 QuickAssistAssistant (org.eclipse.jface.text.quickassist.QuickAssistAssistant)1 MarkerResoltionQuickAssistProcessor (org.eclipse.ui.internal.genericeditor.markers.MarkerResoltionQuickAssistProcessor)1 SpellingCorrectionProcessor (org.eclipse.ui.texteditor.spelling.SpellingCorrectionProcessor)1