TableCellRenderer in netbeans.

View: New views
4 Messages — Rating Filter:   Alert me  

TableCellRenderer in netbeans.

by Sowade Kayode :: Rate this Message:

Reply to Author | View Threaded | Show Only this Message

Hi,
i have a customTableCellRenderer class. how do i point to this calss as the default renderer from the properties tab of the design view. i am actually new to netbeans
thank you.

__________________________________________________
Do You Yahoo!?
Tired of spam? Yahoo! Mail has the best spam protection around
http://mail.yahoo.com


Re: TableCellRenderer in netbeans.

by Patrizio Cannoni-3 :: Rate this Message:

Reply to Author | View Threaded | Show Only this Message

In jtable properties, you can use Code --> Post Creation Code, inserting
something like this:
jTable1.setDefaultRenderer(Object.class, new MyDefaultCellRenderer());

Patrizio

Sowade Kayode escreveu:

> Hi,
> i have a customTableCellRenderer class. how do i point to this calss
> as the default renderer from the properties tab of the design view. i
> am actually new to netbeans
> thank you.
>
> __________________________________________________
> Do You Yahoo!?
> Tired of spam? Yahoo! Mail has the best spam protection around
> http://mail.yahoo.com
>

Re: TableCellRenderer in netbeans.

by Sowade Kayode :: Rate this Message:

Reply to Author | View Threaded | Show Only this Message

thanks so much .. it worked. in my country (Nigeria) when we want to hail people like you we say "Brosss ye, you are too much!"

Patrizio Cannoni <patrizio@...> wrote:
In jtable properties, you can use Code --> Post Creation Code, inserting
something like this:
jTable1.setDefaultRenderer(Object.class, new MyDefaultCellRenderer());

Patrizio

Sowade Kayode escreveu:

> Hi,
> i have a customTableCellRenderer class. how do i point to this calss
> as the default renderer from the properties tab of the design view. i
> am actually new to netbeans
> thank you.
>
> __________________________________________________
> Do You Yahoo!?
> Tired of spam? Yahoo! Mail has the best spam protection around
> http://mail.yahoo.com
>

__________________________________________________
Do You Yahoo!?
Tired of spam? Yahoo! Mail has the best spam protection around
http://mail.yahoo.com


Re: TableCellRenderer in netbeans.

by Tim Boudreau :: Rate this Message:

Reply to Author | View Threaded | Show Only this Message

Sowade Kayode wrote:
> Hi,
> i have a customTableCellRenderer class. how do i point to this calss as
> the default renderer from the properties tab of the design view. i am
> actually new to netbeans

You don't;  you want to provide custom property editors (which can
include custom painting code) for the properties you want to display.
Have a look at the JavaBeans spec, and the Nodes API, specifically
Node.Property.

-Tim