Examples of IInformationControlCreator


Examples of org.eclipse.jface.text.IInformationControlCreator

  /*
   * @see org.eclipse.jface.text.source.IAnnotationHoverExtension#getHoverControlCreator()
   */
  public IInformationControlCreator getHoverControlCreator() {
    return new IInformationControlCreator() {
      public IInformationControl createInformationControl(Shell parent) {
        SourceViewerInformationControl control= new SourceViewerInformationControl(parent, SWT.NO_TRIM | SWT.TOOL, SWT.NONE, JFaceResources.TEXT_FONT, EditorsUI.getTooltipAffordanceString());
        control.setHorizontalScrollPixel(fLastScrollIndex);
        return control;
      }
View Full Code Here

Examples of org.eclipse.jface.text.IInformationControlCreator

  /*
   * @see org.eclipse.jface.text.information.IInformationProviderExtension2#getInformationPresenterControlCreator()
   * @since 3.3
   */
  public IInformationControlCreator getInformationPresenterControlCreator() {
    return new IInformationControlCreator() {
      public IInformationControl createInformationControl(Shell parent) {
        int shellStyle= SWT.RESIZE | SWT.TOOL;
        int style= SWT.V_SCROLL | SWT.H_SCROLL;
        return new SourceViewerInformationControl(parent, shellStyle, style, JFaceResources.TEXT_FONT, null);
      }
View Full Code Here

Examples of org.eclipse.jface.text.IInformationControlCreator

   *
   * @return the information control creator
   * @since 3.3
   */
  private IInformationControlCreator getQuickAssistAssistantInformationControlCreator() {
    return new IInformationControlCreator() {
      public IInformationControl createInformationControl(Shell parent) {
        return new DefaultInformationControl(parent, SWT.NONE, new HTMLTextPresenter(true));
      }
    };
  }
View Full Code Here

Examples of org.eclipse.jface.text.IInformationControlCreator

    /*
     * @see org.eclipse.jface.text.ITextHoverExtension#getHoverControlCreator()
     */
    public IInformationControlCreator getHoverControlCreator() {
      return new IInformationControlCreator() {
        public IInformationControl createInformationControl(Shell parent) {
          return new DefaultInformationControl(parent, SWT.NONE, new HTMLTextPresenter(true), EditorsUI.getTooltipAffordanceString());
        }
      };
    }
View Full Code Here

Examples of org.eclipse.jface.text.IInformationControlCreator

        if (hoverRegion == null)
          return false;

        String hoverInfo= textHover.getHoverInfo(sourceViewer, hoverRegion);

        IInformationControlCreator controlCreator= null;
        if (textHover instanceof IInformationProviderExtension2)
          controlCreator= ((IInformationProviderExtension2)textHover).getInformationPresenterControlCreator();

        IInformationProvider informationProvider= new InformationProvider(hoverRegion, hoverInfo, controlCreator);
View Full Code Here

Examples of org.eclipse.jface.text.IInformationControlCreator

        // hover region: the beginning of the concerned line to place the control right over the line
        IDocument document= sourceViewer.getDocument();
        int offset= document.getLineOffset(line);
        String contentType= TextUtilities.getContentType(document, getSourceViewerConfiguration().getConfiguredDocumentPartitioning(getSourceViewer()), offset, true);

        IInformationControlCreator controlCreator= null;
        if (annotationHover instanceof IInformationProviderExtension2)
          controlCreator= ((IInformationProviderExtension2) annotationHover).getInformationPresenterControlCreator();
        else if (annotationHover instanceof IAnnotationHoverExtension)
          controlCreator= ((IAnnotationHoverExtension) annotationHover).getHoverControlCreator();
       
View Full Code Here

Examples of org.eclipse.jface.text.IInformationControlCreator

   
    IVerticalRuler ruler= getVerticalRuler();
    if (ruler instanceof CompositeRuler)
      updateContributedRulerColumns((CompositeRuler) ruler);
   
    IInformationControlCreator informationControlCreator= new IInformationControlCreator() {
      public IInformationControl createInformationControl(Shell shell) {
        boolean cutDown= false;
        int style= cutDown ? SWT.NONE : (SWT.V_SCROLL | SWT.H_SCROLL);
        return new DefaultInformationControl(shell, SWT.RESIZE | SWT.TOOL, style, new HTMLTextPresenter(cutDown));
      }
View Full Code Here

Examples of org.eclipse.jface.text.IInformationControlCreator

  public IEditorPart getEditor() {
    return fEditor;
  }

  private IInformationControlCreator getInformationControlCreator() {
    return new IInformationControlCreator() {
      public IInformationControl createInformationControl(Shell parent) {
        return new DefaultInformationControl(parent, new HTMLTextPresenter());
      }
    };
  }
View Full Code Here

Examples of org.eclipse.jface.text.IInformationControlCreator

    return fCodeScanner.affectsBehavior(event) || fStringScanner.affectsBehavior(event)
            || fCommentScanner.affectsBehavior(event);
  }

  private IInformationControlCreator getHierarchyPresenterControlCreator(ISourceViewer sourceViewer) {
    return new IInformationControlCreator() {
      public IInformationControl createInformationControl(Shell parent) {
        int shellStyle = SWT.RESIZE;
        int treeStyle = SWT.V_SCROLL | SWT.H_SCROLL;
        return new RutaHierarchyInformationControl(parent, shellStyle, treeStyle);
      }
View Full Code Here

Examples of org.eclipse.jface.text.IInformationControlCreator

  }

  @Override
  protected IInformationControlCreator getOutlinePresenterControlCreator(
          ISourceViewer sourceViewer, final String commandId) {
    return new IInformationControlCreator() {
      public IInformationControl createInformationControl(Shell parent) {
        int shellStyle = SWT.RESIZE;
        int treeStyle = SWT.V_SCROLL | SWT.H_SCROLL;
        return new RutaOutlineInformationControl(parent, shellStyle, treeStyle, commandId);
      }
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.