Tabnine Logo
DefaultTreeCellEditor$EditorContainer.paint
Code IndexAdd Tabnine to your IDE (free)

How to use
paint
method
in
javax.swing.tree.DefaultTreeCellEditor$EditorContainer

Best Java code snippets using javax.swing.tree.DefaultTreeCellEditor$EditorContainer.paint (Showing top 5 results out of 315)

origin: org.swinglabs.swingx/swingx-core

@Override
public void paint(Graphics g) {
  if (isRightToLeft()) {
    Dimension size = getSize();
    // Then the icon.
    if (editingIcon != null) {
      int yLoc = Math.max(0, (size.height - editingIcon
          .getIconHeight()) / 2);
      int xLoc = Math.max(0, size.width - offset);
      editingIcon.paintIcon(this, g, xLoc, yLoc);
    }
    // need to prevent super from painting the icon
    Icon rememberIcon = editingIcon;
    editingIcon = null;
    super.paint(g);
    editingIcon = rememberIcon;
    
  } else {
    super.paint(g);
  }
}
 
origin: com.haulmont.thirdparty/swingx-core

@Override
public void paint(Graphics g) {
  if (isRightToLeft()) {
    Dimension size = getSize();
    // Then the icon.
    if (editingIcon != null) {
      int yLoc = Math.max(0, (size.height - editingIcon
          .getIconHeight()) / 2);
      int xLoc = Math.max(0, size.width - offset);
      editingIcon.paintIcon(this, g, xLoc, yLoc);
    }
    // need to prevent super from painting the icon
    Icon rememberIcon = editingIcon;
    editingIcon = null;
    super.paint(g);
    editingIcon = rememberIcon;
    
  } else {
    super.paint(g);
  }
}
 
origin: org.swinglabs.swingx/swingx-all

@Override
public void paint(Graphics g) {
  if (isRightToLeft()) {
    Dimension size = getSize();
    // Then the icon.
    if (editingIcon != null) {
      int yLoc = Math.max(0, (size.height - editingIcon
          .getIconHeight()) / 2);
      int xLoc = Math.max(0, size.width - offset);
      editingIcon.paintIcon(this, g, xLoc, yLoc);
    }
    // need to prevent super from painting the icon
    Icon rememberIcon = editingIcon;
    editingIcon = null;
    super.paint(g);
    editingIcon = rememberIcon;
    
  } else {
    super.paint(g);
  }
}
 
origin: org.codehaus.jtstand/jtstand-desktop

@Override
public void paint(Graphics g) {
  if (isRightToLeft()) {
    Dimension size = getSize();
    // Then the icon.
    if (editingIcon != null) {
      int yLoc = Math.max(0, (size.height - editingIcon
          .getIconHeight()) / 2);
      int xLoc = Math.max(0, size.width - offset);
      editingIcon.paintIcon(this, g, xLoc, yLoc);
    }
    // need to prevent super from painting the icon
    Icon rememberIcon = editingIcon;
    editingIcon = null;
    super.paint(g);
    editingIcon = rememberIcon;
    
  } else {
    super.paint(g);
  }
}
 
origin: org.bidib.jbidib.swinglabs.swingx/swingx-core

@Override
public void paint(Graphics g) {
  if (isRightToLeft()) {
    Dimension size = getSize();
    // Then the icon.
    if (editingIcon != null) {
      int yLoc = Math.max(0, (size.height - editingIcon
          .getIconHeight()) / 2);
      int xLoc = Math.max(0, size.width - offset);
      editingIcon.paintIcon(this, g, xLoc, yLoc);
    }
    // need to prevent super from painting the icon
    Icon rememberIcon = editingIcon;
    editingIcon = null;
    super.paint(g);
    editingIcon = rememberIcon;
    
  } else {
    super.paint(g);
  }
}
 
javax.swing.treeDefaultTreeCellEditor$EditorContainerpaint

Popular methods of DefaultTreeCellEditor$EditorContainer

  • doLayout
  • getPreferredSize

Popular in Java

  • Making http requests using okhttp
  • setContentView (Activity)
  • orElseThrow (Optional)
    Return the contained value, if present, otherwise throw an exception to be created by the provided s
  • getContentResolver (Context)
  • Point (java.awt)
    A point representing a location in (x,y) coordinate space, specified in integer precision.
  • BufferedWriter (java.io)
    Wraps an existing Writer and buffers the output. Expensive interaction with the underlying reader is
  • NoSuchElementException (java.util)
    Thrown when trying to retrieve an element past the end of an Enumeration or Iterator.
  • Scanner (java.util)
    A parser that parses a text string of primitive types and strings with the help of regular expressio
  • Semaphore (java.util.concurrent)
    A counting semaphore. Conceptually, a semaphore maintains a set of permits. Each #acquire blocks if
  • JComboBox (javax.swing)
  • Top Vim plugins
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