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

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

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

origin: org.swinglabs.swingx/swingx-all

  @Override
  public Dimension getPreferredSize() {
    if (isRightToLeft()) {
      if(editingComponent != null) {
        Dimension         pSize = editingComponent.getPreferredSize();

        pSize.width += offset + 5;

        Dimension         rSize = (renderer != null) ?
                     renderer.getPreferredSize() : null;

        if(rSize != null)
          pSize.height = Math.max(pSize.height, rSize.height);
        if(editingIcon != null)
          pSize.height = Math.max(pSize.height,
                      editingIcon.getIconHeight());

        // trying to enforce a minimum size leads to field being painted over the icon
        // Make sure width is at least 100.
//                pSize.width = Math.max(pSize.width, 100);
        return pSize;
      }
      return new Dimension(0, 0);
    }
    return super.getPreferredSize();
    
  }
origin: org.codehaus.jtstand/jtstand-desktop

  @Override
  public Dimension getPreferredSize() {
    if (isRightToLeft()) {
      if(editingComponent != null) {
        Dimension         pSize = editingComponent.getPreferredSize();

        pSize.width += offset + 5;

        Dimension         rSize = (renderer != null) ?
                     renderer.getPreferredSize() : null;

        if(rSize != null)
          pSize.height = Math.max(pSize.height, rSize.height);
        if(editingIcon != null)
          pSize.height = Math.max(pSize.height,
                      editingIcon.getIconHeight());

        // trying to enforce a minimum size leads to field being painted over the icon
        // Make sure width is at least 100.
//                pSize.width = Math.max(pSize.width, 100);
        return pSize;
      }
      return new Dimension(0, 0);
    }
    return super.getPreferredSize();
    
  }
origin: org.swinglabs.swingx/swingx-core

  @Override
  public Dimension getPreferredSize() {
    if (isRightToLeft()) {
      if(editingComponent != null) {
        Dimension         pSize = editingComponent.getPreferredSize();

        pSize.width += offset + 5;

        Dimension         rSize = (renderer != null) ?
                     renderer.getPreferredSize() : null;

        if(rSize != null)
          pSize.height = Math.max(pSize.height, rSize.height);
        if(editingIcon != null)
          pSize.height = Math.max(pSize.height,
                      editingIcon.getIconHeight());

        // trying to enforce a minimum size leads to field being painted over the icon
        // Make sure width is at least 100.
//                pSize.width = Math.max(pSize.width, 100);
        return pSize;
      }
      return new Dimension(0, 0);
    }
    return super.getPreferredSize();
    
  }
origin: com.haulmont.thirdparty/swingx-core

  @Override
  public Dimension getPreferredSize() {
    if (isRightToLeft()) {
      if(editingComponent != null) {
        Dimension         pSize = editingComponent.getPreferredSize();

        pSize.width += offset + 5;

        Dimension         rSize = (renderer != null) ?
                     renderer.getPreferredSize() : null;

        if(rSize != null)
          pSize.height = Math.max(pSize.height, rSize.height);
        if(editingIcon != null)
          pSize.height = Math.max(pSize.height,
                      editingIcon.getIconHeight());

        // trying to enforce a minimum size leads to field being painted over the icon
        // Make sure width is at least 100.
//                pSize.width = Math.max(pSize.width, 100);
        return pSize;
      }
      return new Dimension(0, 0);
    }
    return super.getPreferredSize();
    
  }
origin: org.bidib.jbidib.swinglabs.swingx/swingx-core

  @Override
  public Dimension getPreferredSize() {
    if (isRightToLeft()) {
      if(editingComponent != null) {
        Dimension         pSize = editingComponent.getPreferredSize();

        pSize.width += offset + 5;

        Dimension         rSize = (renderer != null) ?
                     renderer.getPreferredSize() : null;

        if(rSize != null)
          pSize.height = Math.max(pSize.height, rSize.height);
        if(editingIcon != null)
          pSize.height = Math.max(pSize.height,
                      editingIcon.getIconHeight());

        // trying to enforce a minimum size leads to field being painted over the icon
        // Make sure width is at least 100.
//                pSize.width = Math.max(pSize.width, 100);
        return pSize;
      }
      return new Dimension(0, 0);
    }
    return super.getPreferredSize();
    
  }
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);
  }
}
 
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: 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-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 doLayout() {
  if (isRightToLeft()) {
    Dimension             cSize = getSize();
    editingComponent.getPreferredSize();
    editingComponent.setLocation(0, 0);
    editingComponent.setBounds(0, 0,
                  cSize.width - offset,
                  cSize.height);
  } else {
    super.doLayout();
  }
}
origin: com.haulmont.thirdparty/swingx-core

@Override
public void doLayout() {
  if (isRightToLeft()) {
    Dimension             cSize = getSize();
    editingComponent.getPreferredSize();
    editingComponent.setLocation(0, 0);
    editingComponent.setBounds(0, 0,
                  cSize.width - offset,
                  cSize.height);
  } else {
    super.doLayout();
  }
}
origin: org.swinglabs.swingx/swingx-core

@Override
public void doLayout() {
  if (isRightToLeft()) {
    Dimension             cSize = getSize();
    editingComponent.getPreferredSize();
    editingComponent.setLocation(0, 0);
    editingComponent.setBounds(0, 0,
                  cSize.width - offset,
                  cSize.height);
  } else {
    super.doLayout();
  }
}
origin: org.codehaus.jtstand/jtstand-desktop

@Override
public void doLayout() {
  if (isRightToLeft()) {
    Dimension             cSize = getSize();
    editingComponent.getPreferredSize();
    editingComponent.setLocation(0, 0);
    editingComponent.setBounds(0, 0,
                  cSize.width - offset,
                  cSize.height);
  } else {
    super.doLayout();
  }
}
origin: org.bidib.jbidib.swinglabs.swingx/swingx-core

@Override
public void doLayout() {
  if (isRightToLeft()) {
    Dimension             cSize = getSize();
    editingComponent.getPreferredSize();
    editingComponent.setLocation(0, 0);
    editingComponent.setBounds(0, 0,
                  cSize.width - offset,
                  cSize.height);
  } else {
    super.doLayout();
  }
}
javax.swing.treeDefaultTreeCellEditor$EditorContainer

Most used methods

  • doLayout
  • getPreferredSize
  • paint

Popular in Java

  • Reactive rest calls using spring rest template
  • onRequestPermissionsResult (Fragment)
  • compareTo (BigDecimal)
  • getSupportFragmentManager (FragmentActivity)
  • FileWriter (java.io)
    A specialized Writer that writes to a file in the file system. All write requests made by calling me
  • Runnable (java.lang)
    Represents a command that can be executed. Often used to run code in a different Thread.
  • MessageFormat (java.text)
    Produces concatenated messages in language-neutral way. New code should probably use java.util.Forma
  • SimpleDateFormat (java.text)
    Formats and parses dates in a locale-sensitive manner. Formatting turns a Date into a String, and pa
  • ThreadPoolExecutor (java.util.concurrent)
    An ExecutorService that executes each submitted task using one of possibly several pooled threads, n
  • Table (org.hibernate.mapping)
    A relational table
  • Best IntelliJ 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