Codota Logo
DefaultTableCellRenderer.paintComponent
Code IndexAdd Codota to your IDE (free)

How to use
paintComponent
method
in
javax.swing.table.DefaultTableCellRenderer

Best Java code snippets using javax.swing.table.DefaultTableCellRenderer.paintComponent (Showing top 13 results out of 315)

  • Common ways to obtain DefaultTableCellRenderer
private void myMethod () {
DefaultTableCellRenderer d =
  • Codota Iconnew DefaultTableCellRenderer()
  • Smart code suggestions by Codota
}
origin: com.github.insubstantial/substance

  @Override
  protected final void paintComponent(Graphics g) {
    super.paintComponent(g);
  }
}
origin: org.java.net.substance/substance

  @Override
  protected final void paintComponent(Graphics g) {
    super.paintComponent(g);
  }
}
origin: com.github.insubstantial/substance

@Override
protected final void paintComponent(Graphics g) {
  super.paintComponent(g);
}
origin: org.java.net.substance/substance

@Override
protected final void paintComponent(Graphics g) {
  super.paintComponent(g);
}
origin: org.netbeans.modules/org-netbeans-modules-bugtracking-commons

@Override
protected void paintComponent(Graphics g) {        
  processText(this);
  super.paintComponent(g);
}
origin: khuxtable/seaglass

/**
 * @see javax.swing.JComponent#paintComponent(java.awt.Graphics)
 */
@Override
public void paintComponent(Graphics g) {
  if (sortArrow != null) {
    // emptyIcon is used so that if the text in the header is right
    // aligned, or if the column is too narrow, then the text will
    // be sized appropriately to make room for the icon that is
    // about to be painted manually here.
    emptyIcon.width  = sortArrow.getIconWidth();
    emptyIcon.height = sortArrow.getIconHeight();
    Point position = computeIconPosition(g);
    super.paintComponent(g);
    sortArrow.paintIcon(this, g, position.x, position.y);
  } else {
    super.paintComponent(g);
  }
}
origin: xyz.cofe/gui.swing

@Override
public void paintComponent(Graphics g) {
  boolean b = DefaultLookup.getBoolean(this, ui,
      "TableHeader.rightAlignSortArrow", false);
  if (b && sortArrow != null) {
    //emptyIcon is used so that if the text in the header is right
    //aligned, or if the column is too narrow, then the text will
    //be sized appropriately to make room for the icon that is about
    //to be painted manually here.
    emptyIcon.width = sortArrow.getIconWidth();
    emptyIcon.height = sortArrow.getIconHeight();
    setIcon(emptyIcon);
    super.paintComponent(g);
    Point position = computeIconPosition(g);
    sortArrow.paintIcon(this, g, position.x, position.y);
  } else {
    super.paintComponent(g);
  }
}
origin: bedatadriven/activityinfo

@Override
protected void paintComponent(Graphics g) {
  if (!matched && isSource()) {
    paintUnmatchedCell(g);
  } else {
    super.paintComponent(g);
  } 
}
origin: net.sf.sfac/sfac-core

@Override
public void paintComponent(Graphics g) {
  super.paintComponent(g);
  if ((sortModel != null) && sortModel.isColumnSorted(columnIndex)) {
    Icon sortIcon = (sortModel.getSortDirection(columnIndex) == SortModel.SORT_NORMAL) ? sortUpIcon : sortDownIcon;
    int x = 4;
    if (sortModel.getNumberOfSortedColumns() > 1) {
      String sortIndex = String.valueOf(sortModel.getSortIndex(columnIndex) + 1);
      int height = g.getFontMetrics().getHeight() - 2;
      g.drawString(sortIndex, x, height);
      x += charWidth + 1;
      // } else {
      // x+=charWidth/2 ;
    }
    sortIcon.paintIcon(this, g, x, 1);
  }
}
origin: net.sf.squirrel-sql.thirdparty-non-maven/skinlf

 /**
  * Description of the Method
  *
  * @param g  Description of Parameter
  */
 protected void paintComponent(Graphics g) {
  if (isSelected || hasFocus) {
   itemSelected.paint(g, this);
  } else {
   itemUnselected.paint(g, this);
  }
  super.paintComponent(g);
 }
}
origin: org.netbeans.modules/org-netbeans-modules-dlight-visualizers

@Override
protected void paintComponent(Graphics g) {
  super.paintComponent(g);
  FontMetrics fm = g.getFontMetrics();
  int strw = (int) HtmlRenderer.renderHTML(node.getHtmlDisplayName() + ' ',
      scratchGraphics, 0, 0, cellwidth, 0,
      getFont(), Color.black, HtmlRenderer.STYLE_CLIP, false);
  if (cellwidth < strw) {
    int dotsw = (int) g.getFontMetrics().getStringBounds(dots, g).getMaxX();
    ((Graphics2D) g).setBackground(getBackground());
    g.setColor(getContrastGrayColor(htmlDisabledForeground, getBackground()));
    g.clearRect(cellwidth - dotsw, 0, dotsw, cellheight);
    g.drawString(dots, cellwidth - dotsw,
        fm.getHeight() + fm.getLeading() - fm.getDescent());
  }
}
origin: icza/scelight

@Override
protected void paintComponent( final Graphics g ) {
  if ( barCodeView == null ) {
    super.paintComponent( g );
    return;
  super.paintComponent( g );
origin: org.bitbucket.goalhub.simpleide/jedit

super.paintComponent(g);
javax.swing.tableDefaultTableCellRendererpaintComponent

Popular methods of DefaultTableCellRenderer

  • getTableCellRendererComponent
  • <init>
  • setHorizontalAlignment
  • setBackground
  • setForeground
  • setValue
  • setText
  • setBorder
  • getText
  • paint
  • getBackground
  • getFont
  • getBackground,
  • getFont,
  • getForeground,
  • setFont,
  • setHorizontalTextPosition,
  • setOpaque,
  • setIcon,
  • getBorder,
  • paintBorder

Popular in Java

  • Finding current android device location
  • startActivity (Activity)
  • getOriginalFilename (MultipartFile)
    Return the original filename in the client's filesystem.This may contain path information depending
  • scheduleAtFixedRate (ScheduledExecutorService)
    Creates and executes a periodic action that becomes enabled first after the given initial delay, and
  • HttpURLConnection (java.net)
    An URLConnection for HTTP (RFC 2616 [http://tools.ietf.org/html/rfc2616]) used to send and receive d
  • ServerSocket (java.net)
    This class represents a server-side socket that waits for incoming client connections. A ServerSocke
  • SocketException (java.net)
    This SocketException may be thrown during socket creation or setting options, and is the superclass
  • TimeUnit (java.util.concurrent)
    A TimeUnit represents time durations at a given unit of granularity and provides utility methods to
  • Modifier (javassist)
    The Modifier class provides static methods and constants to decode class and member access modifiers
  • HttpServlet (javax.servlet.http)
    Provides an abstract class to be subclassed to create an HTTP servlet suitable for a Web site. A sub
Codota Logo
  • Products

    Search for Java codeSearch for JavaScript codeEnterprise
  • IDE Plugins

    IntelliJ IDEAWebStormAndroid StudioEclipseVisual Studio CodePyCharmSublime TextPhpStormVimAtomGoLandRubyMineEmacsJupyter
  • Company

    About UsContact UsCareers
  • Resources

    FAQBlogCodota Academy Plugin user guide Terms of usePrivacy policyJava Code IndexJavascript Code Index
Get Codota for your IDE now