Tabnine Logo
DefaultTableCellRenderer.getForeground
Code IndexAdd Tabnine to your IDE (free)

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

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

origin: org.geotools/gt2-widgets-swing

/**
 * Creates a default cell renderer for {@link CoordinateTableModel}.
 */
public CellRenderer() {
  super();
  foreground = super.getForeground();
  background = super.getBackground();			
}
origin: org.geotools/gt2-widgets-swing

/**
 * Construct a new cell renderer.
 */
public CellRenderer() {
  foreground = super.getForeground();
  background = super.getBackground();
  table.getColumnModel().addColumnModelListener(this);
}
origin: opengeospatial/geoapi

/**
 * Creates a default cell renderer for {@link ResultTableModel}.
 */
ResultCellRenderer() {
  super();
  foreground   = super.getForeground();
  background   = super.getBackground();
  ignoreColor  = Color.GRAY;
  failureColor = Color.RED;
  coverage     = new Coverage();
}
origin: stackoverflow.com

setForeground(adaptee.getForeground());
setBackground(adaptee.getBackground());
setBorder(adaptee.getBorder());
origin: triplea-game/triplea

@Override
public Component getTableCellRendererComponent(final JTable table, final Object obj, final boolean isSelected,
  final boolean hasFocus, final int row, final int column) {
 // set the colors, etc. using the standard for that platform
 adaptee.getTableCellRendererComponent(table, obj, isSelected, hasFocus, row, column);
 setForeground(adaptee.getForeground());
 setBackground(adaptee.getBackground());
 setBorder(adaptee.getBorder());
 setFont(adaptee.getFont());
 setText(adaptee.getText());
 // This line was very important to get it working with JDK1.4
 final TableColumnModel columnModel = table.getColumnModel();
 setSize(columnModel.getColumn(column).getWidth(), 100000);
 int heightWanted = (int) getPreferredSize().getHeight();
 addSize(table, row, column, heightWanted);
 heightWanted = findTotalMaximumRowSize(table, row);
 if (heightWanted != table.getRowHeight(row)) {
  table.setRowHeight(row, heightWanted);
 }
 return this;
}
javax.swing.tableDefaultTableCellRenderergetForeground

Popular methods of DefaultTableCellRenderer

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

Popular in Java

  • Updating database using SQL prepared statement
  • getOriginalFilename (MultipartFile)
    Return the original filename in the client's filesystem.This may contain path information depending
  • getExternalFilesDir (Context)
  • getSharedPreferences (Context)
  • Color (java.awt)
    The Color class is used to encapsulate colors in the default sRGB color space or colors in arbitrary
  • BufferedImage (java.awt.image)
    The BufferedImage subclass describes an java.awt.Image with an accessible buffer of image data. All
  • List (java.util)
    An ordered collection (also known as a sequence). The user of this interface has precise control ove
  • Reference (javax.naming)
  • JComboBox (javax.swing)
  • IOUtils (org.apache.commons.io)
    General IO stream manipulation utilities. This class provides static utility methods for input/outpu
  • Github Copilot alternatives
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