congrats Icon
New! Announcing Tabnine Chat Beta
Learn More
Tabnine Logo
TextViewer.addPresentation
Code IndexAdd Tabnine to your IDE (free)

How to use
addPresentation
method
in
org.eclipse.jface.text.TextViewer

Best Java code snippets using org.eclipse.jface.text.TextViewer.addPresentation (Showing top 2 results out of 315)

origin: org.eclipse.scout.sdk.deps/org.eclipse.jface.text

@Override
public void changeTextPresentation(TextPresentation presentation, boolean controlRedraw) {
  if (presentation == null || !redraws())
    return;
  if (fTextWidget == null)
    return;
  /*
   * Call registered text presentation listeners
   * and let them apply their presentation.
   */
  if (fTextPresentationListeners != null) {
    ArrayList<ITextPresentationListener> listeners= new ArrayList<>(fTextPresentationListeners);
    for (int i= 0, size= listeners.size(); i < size; i++) {
      ITextPresentationListener listener= listeners.get(i);
      listener.applyTextPresentation(presentation);
    }
  }
  if (presentation.isEmpty())
    return;
  if (controlRedraw)
    fTextWidget.setRedraw(false);
  if (fReplaceTextPresentation)
    applyTextPresentation(presentation);
  else
    addPresentation(presentation);
  if (controlRedraw)
    fTextWidget.setRedraw(true);
}
origin: org.eclipse.platform/org.eclipse.jface.text

@Override
public void changeTextPresentation(TextPresentation presentation, boolean controlRedraw) {
  if (presentation == null || !redraws())
    return;
  if (fTextWidget == null)
    return;
  /*
   * Call registered text presentation listeners
   * and let them apply their presentation.
   */
  if (fTextPresentationListeners != null) {
    ArrayList<ITextPresentationListener> listeners= new ArrayList<>(fTextPresentationListeners);
    for (int i= 0, size= listeners.size(); i < size; i++) {
      ITextPresentationListener listener= listeners.get(i);
      listener.applyTextPresentation(presentation);
    }
  }
  if (presentation.isEmpty())
    return;
  if (controlRedraw)
    fTextWidget.setRedraw(false);
  if (fReplaceTextPresentation)
    applyTextPresentation(presentation);
  else
    addPresentation(presentation);
  if (controlRedraw)
    fTextWidget.setRedraw(true);
}
org.eclipse.jface.textTextVieweraddPresentation

Javadoc

Adds the given presentation to the viewer's style information.

Popular methods of TextViewer

  • getTextWidget
  • getControl
  • doOperation
  • setDocument
  • modelRange2WidgetRange
    Same as #modelRange2WidgetRange(IRegion) just for a org.eclipse.jface.text.Position.
  • getRewriteTarget
  • getSelection
  • modelLine2WidgetLine
    Implements the contract of ITextViewerExtension5#modelLine2WidgetLine(int).
  • getDocument
  • setSelectedRange
  • setSelection
  • <init>
    Create a new text viewer with the given SWT style bits. The viewer is ready to use but does not have
  • setSelection,
  • <init>,
  • canDoOperation,
  • getVisibleRegion,
  • handleDispose,
  • invalidateTextPresentation,
  • setTopIndex,
  • _getVisibleRegionOffset,
  • activatePlugins

Popular in Java

  • Making http post requests using okhttp
  • setContentView (Activity)
  • onCreateOptionsMenu (Activity)
  • putExtra (Intent)
  • SocketTimeoutException (java.net)
    This exception is thrown when a timeout expired on a socket read or accept operation.
  • ResourceBundle (java.util)
    ResourceBundle is an abstract class which is the superclass of classes which provide Locale-specifi
  • Filter (javax.servlet)
    A filter is an object that performs filtering tasks on either the request to a resource (a servlet o
  • JOptionPane (javax.swing)
  • Reflections (org.reflections)
    Reflections one-stop-shop objectReflections scans your classpath, indexes the metadata, allows you t
  • Logger (org.slf4j)
    The org.slf4j.Logger interface is the main user entry point of SLF4J API. It is expected that loggin
  • Top plugins for WebStorm
Tabnine Logo
  • Products

    Search for Java codeSearch for JavaScript code
  • IDE Plugins

    IntelliJ IDEAWebStormVisual StudioAndroid StudioEclipseVisual Studio CodePyCharmSublime TextPhpStormVimGoLandRubyMineEmacsJupyter NotebookJupyter LabRiderDataGripAppCode
  • Company

    About UsContact UsCareers
  • Resources

    FAQBlogTabnine AcademyTerms of usePrivacy policyJava Code IndexJavascript Code Index
Get Tabnine for your IDE now