Groups | Search | Server Info | Keyboard shortcuts | Login | Register [http] [https] [nntp] [nntps]


Groups > comp.lang.java.gui > #1899

Re: Why there is no setCe

From "RC" <rc@THRWHITE.remove-dii-this>
Subject Re: Why there is no setCe
Message-ID <46816424.1080609@nospam.noaa.gov> (permalink)
Newsgroups comp.lang.java.gui
References <1182884216.334575.70140@w5g2000hsg.googlegroups.com>
Date 2011-04-27 15:35 +0000
Organization TDS.net

Show all headers | View raw


  To: Adrian Hands, Raleigh NC
Adrian Hands, Raleigh NC USA wrote:
> On Jun 26, 2:48 pm, RC <raymond.c...@nospam.noaa.gov> wrote:
> 
>> public class LabelDefaultTableCellRenderer extends JLabel
> 
> no, don't extend JLabel

Then what I should extends?

I got the example from this page

http://java.sun.com/docs/books/tutorial/uiswing/examples/components/TableDialogEditDemoProject/src/components/ColorRenderer.java


> 
>>         public Component getTableCellRendererComponent(JTable table,
>>                                                 Object color,
>>                                                 boolean isSelected,
>>                                                 boolean hasFocus,
>>                                                 int row,
>>                                                 int column) {
>>
>>         java.awt.Component comp =
>>                 super.getTableCellRendererComponent( table,
>>                                                 color,
>>                                                 isSelected,
>>                                                 hasFocus,
>>                                                 row,
>>                                                 column;
>>
>>                 // Color newColor = (Color)color;
>>
>>                 comp.setForeground( column == 1 ? Color.red : Color.black );
>>
>>                 return comp;
>

---
 * Synchronet * The Whitehouse BBS --- whitehouse.hulds.com --- check it out free usenet!
--- Synchronet 3.15a-Win32 NewsLink 1.92
Time Warp of the Future BBS - telnet://time.synchro.net:24

Back to comp.lang.java.gui | Previous | NextPrevious in thread | Next in thread | Find similar | Unroll thread


Thread

Why there is no setCellRe "RC" <rc@THRWHITE.remove-dii-this> - 2011-04-27 15:35 +0000
  Re: Why there is no setCe "Adrian Hands, Raleigh NC" <adrian.hands,.raleigh.nc@THRWHITE.remove-dii-this> - 2011-04-27 15:35 +0000
    Re: Why there is no setCe "RC" <rc@THRWHITE.remove-dii-this> - 2011-04-27 15:35 +0000
      Re: Why there is no setCe "Adrian Hands, Raleigh NC" <adrian.hands,.raleigh.nc@THRWHITE.remove-dii-this> - 2011-04-27 15:36 +0000
  Re: Why there is no setCe "Tom Hawtin" <tom.hawtin@THRWHITE.remove-dii-this> - 2011-04-27 15:36 +0000
  Re: Why there is no setCe "Roedy Green" <roedy.green@THRWHITE.remove-dii-this> - 2011-04-27 15:36 +0000
    Re: Why there is no setCe "Tom Hawtin" <tom.hawtin@THRWHITE.remove-dii-this> - 2011-04-27 15:36 +0000
      Re: Why there is no setCe "Tom Hawtin" <tom.hawtin@THRWHITE.remove-dii-this> - 2011-04-27 15:36 +0000

csiph-web