Examples of ContentAssistant


Examples of org.eclipse.jface.text.contentassist.ContentAssistant

    reconciler.setRepairer(ndr, partition);
  }

  public IContentAssistant getContentAssistant(ISourceViewer sourceViewer)
  {
    ContentAssistant assistant = new ContentAssistant();
    assistant.setContentAssistProcessor(createCompletionProcessor(),
        IDocument.DEFAULT_CONTENT_TYPE);

    assistant.enableAutoActivation(true);
    assistant.setAutoActivationDelay(500);
    assistant
        .setProposalPopupOrientation(IContentAssistant.PROPOSAL_OVERLAY);
    assistant
        .setContextInformationPopupOrientation(IContentAssistant.CONTEXT_INFO_ABOVE);

    return assistant;
  }
View Full Code Here

Examples of org.eclipse.jface.text.contentassist.ContentAssistant

          processor = getWojJavaCompletionProcessor30(ed);
        }
      }
      if(processor != null) {
        try {
          ContentAssistant assistant = (ContentAssistant) HookUtil.getPrivateAttributeValue(SourceViewer.class, "fContentAssistant", ed.getViewer()); //$NON-NLS-1$
          //HookUtil.callPrivateMethod("org.eclipse.jdt.internal.ui.javaeditor.JavaEditor","initializeEditor", null, ed, null);
          //assistant.install(ed.getViewer());
          assistant.setContentAssistProcessor(processor, IDocument.DEFAULT_CONTENT_TYPE);
          SourceViewerConfiguration conf = (SourceViewerConfiguration) HookUtil.getPrivateAttributeValue(AbstractTextEditor.class, "fConfiguration", ed); //$NON-NLS-1$
          ContentAssistPreference.configure(assistant, (IPreferenceStore) HookUtil.getPrivateAttributeValue(Class.forName("org.eclipse.ui.editors.text.TextSourceViewerConfiguration"),"fPreferenceStore", conf));
        } catch (ClassNotFoundException ex) {
          WojPlugin.log("exception occured while installing content assist processor", ex); //$NON-NLS-1$
        }
View Full Code Here
TOP
Copyright © 2018 www.massapi.com. All rights reserved.
All source code are property of their respective owners. Java is a trademark of Sun Microsystems, Inc and owned by ORACLE Inc. Contact coftware#gmail.com.