Package org.eclipse.jface.text.contentassist

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


    }
    return proposalsList.toArray(new ICompletionProposal[0]);
  }
  private CompletionProposal createCompletionProposal(String keyWord, WordPartDetector wordPart, String wordType)
  {
    IContextInformation info =
      new ContextInformation(keyWord, getContentInfoString(keyWord));

    // TODO: get descriptions from Django web site
    String descr = "Django template tag";
    if (wordType.equals("FILTER"))
View Full Code Here


    return proposalsList.toArray(new ICompletionProposal[0]);
  }
  private CompletionProposal createCompletionProposal(String keyWord, WordPartDetector wordPart, String wordType)
  {
    String aInfoStr = getContentInfoString(keyWord);
    IContextInformation info = new ContextInformation(keyWord, aInfoStr);

    // TODO: get descriptions from Django web site
    String descr = "Django template tag";
    if (wordType.equals("FILTER"))
      descr = "Django template filter";
View Full Code Here

    IJavaCompletionProposal javaProposal = super.createJavaCompletionProposal(proposal);
    proposal.getDeclarationSignature();
    Image image = javaProposal.getImage();
    String displayString = javaProposal.getDisplayString();
    displayString = getTranslation().fixupMangledName(displayString);
    IContextInformation contextInformation = javaProposal.getContextInformation();
    // don't do this, it's slow
    // String additionalInfo = javaProposal.getAdditionalProposalInfo();
    int relevance = javaProposal.getRelevance();
   
    boolean updateLengthOnValidate = true;
View Full Code Here

    IJavaCompletionProposal javaProposal = super.createJavaCompletionProposal(proposal);
    proposal.getDeclarationSignature();
    Image image = javaProposal.getImage();
    String displayString = javaProposal.getDisplayString();
    displayString = getTranslation().fixupMangledName(displayString);
    IContextInformation contextInformation = javaProposal.getContextInformation();
    // String additionalInfo = javaProposal.getAdditionalProposalInfo();
   
    /* the context information is calculated with respect to the java document
     * thus it needs to be updated in respect of the JSP document.
     */
 
View Full Code Here

    IJavaCompletionProposal javaProposal = super.createJavaCompletionProposal(proposal);
    proposal.getDeclarationSignature();
    Image image = javaProposal.getImage();
    String displayString = javaProposal.getDisplayString();
    displayString = getTranslation().fixupMangledName(displayString);
    IContextInformation contextInformation = javaProposal.getContextInformation();
    // String additionalInfo = javaProposal.getAdditionalProposalInfo();
   
    /* the context information is calculated with respect to the java document
     * thus it needs to be updated in respect of the JSP document.
     */
 
View Full Code Here

      String type = dp.getPartition(documentOffset).getType();
      if (type == IJSPPartitions.JSP_DEFAULT || type == IJSPPartitions.JSP_CONTENT_JAVA) {
        // get context info from completion results...
        List proposals = computeCompletionProposals(context,monitor);
        for (int i = 0; i < proposals.size(); i++) {
          IContextInformation ci = ((ICompletionProposal)proposals.get(i)).getContextInformation();
          if (ci != null)
            results.add(ci);
        }
      }
    }
View Full Code Here

     *      org.eclipse.jface.text.ITextViewer, int)
     */
    public void install(IContextInformation info, ITextViewer viewer, int documentPosition) {
      // install either the validator in the info, or all validators
      fValidator = getValidator(info);
      IContextInformation realInfo = getContextInformation(info);
      if (fValidator != null)
        fValidator.install(realInfo, viewer, documentPosition);
      else {
        for (Iterator it = fValidators.iterator(); it.hasNext();) {
          IContextInformationValidator v = (IContextInformationValidator) it.next();
View Full Code Here

      return null;
    }

    IContextInformation getContextInformation(IContextInformation info) {
      IContextInformation realInfo = info;
      if (info instanceof WrappedContextInformation) {
        WrappedContextInformation wrap = (WrappedContextInformation) info;
        realInfo = wrap.getContextInformation();
      }
View Full Code Here

     *      IContentAssistSubjectControl, int)
     */
    public void install(IContextInformation info, IContentAssistSubjectControl contentAssistSubjectControl, int documentPosition) {
      // install either the validator in the info, or all validators
      fValidator = getValidator(info);
      IContextInformation realInfo = getContextInformation(info);
      if (fValidator instanceof ISubjectControlContextInformationValidator)
        ((ISubjectControlContextInformationValidator) fValidator).install(realInfo, contentAssistSubjectControl, documentPosition);
      else {
        for (Iterator it = fValidators.iterator(); it.hasNext();) {
          if (it.next() instanceof ISubjectControlContextInformationValidator)
View Full Code Here

     *      IContentAssistSubjectControl, int)
     */
    public void install(IContextInformation info, IContentAssistSubjectControl contentAssistSubjectControl, int documentPosition) {
      // install either the validator in the info, or all validators
      fValidator = getValidator(info);
      IContextInformation realInfo = getContextInformation(info);

      if (fValidator instanceof ISubjectControlContextInformationValidator)
        ((ISubjectControlContextInformationValidator) fValidator).install(realInfo, contentAssistSubjectControl, documentPosition);
      else {
        for (Iterator it = fValidators.iterator(); it.hasNext();) {
View Full Code Here

TOP

Related Classes of org.eclipse.jface.text.contentassist.IContextInformation

Copyright © 2018 www.massapicom. 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.