Skip to main content


Eclipse Community Forums
Forum Search:

Search      Help    Register    Login    Home
Home » Eclipse Projects » Standard Widget Toolkit (SWT) » Mulitple cell editors in a table column?
Mulitple cell editors in a table column? [message #438310] Mon, 21 June 2004 15:18 Go to next message
Eclipse UserFriend
Originally posted by: lew.atg.com

Is there a standard way (or just a good one) to configure or implement a
table viewer with multiple cell editors in a column? (i.e., So a column
can handle different data types in each row.)

Any pointers appreciated,
Lew
Re: Mulitple cell editors in a table column? [message #440234 is a reply to message #438310] Mon, 26 July 2004 23:47 Go to previous messageGo to next message
Paul E. Keyser is currently offline Paul E. KeyserFriend
Messages: 878
Registered: July 2009
Senior Member
This is pretty tricky, actually. We have done something like this, but
it wasn't easy, since the Eclipse TableViewer and TableTreeViewer
classes assume that the CellEditor type is constant in a given column.
The full code dump would be many classes of hundreds of lines, and since
we also had other cell-editor requirements, it's pretty tangled up. But
the basic issue is that in the canModify() method of your ICellModifier
implementation you have to swap out the old and swap in the new
cell-editors; plus you have to do some complex dancing if you have more
than one kind of ComboBoxCellEditor (where a "kind" of
ComboBoxCellEditor is defined here by its String[] of values) ...

HTH,
Paul

Lew Miller wrote:

> Is there a standard way (or just a good one) to configure or implement a
> table viewer with multiple cell editors in a column? (i.e., So a column
> can handle different data types in each row.)
>
> Any pointers appreciated,
> Lew
>
Re: Mulitple cell editors in a table column? [message #443035 is a reply to message #440234] Thu, 16 September 2004 19:32 Go to previous message
Eclipse UserFriend
Originally posted by: lew.atg.com

Thanks for your response. I'd given up on hearing from anyone but
you've inspired me to try again on the eclipse.platform newsgroup
which I gather is where jface questions belong.

Paul Keyser wrote:
> This is pretty tricky, actually. We have done something like this, but
> it wasn't easy, since the Eclipse TableViewer and TableTreeViewer
> classes assume that the CellEditor type is constant in a given column.
> The full code dump would be many classes of hundreds of lines, and since
> we also had other cell-editor requirements, it's pretty tangled up. But
> the basic issue is that in the canModify() method of your ICellModifier
> implementation you have to swap out the old and swap in the new
> cell-editors; plus you have to do some complex dancing if you have more
> than one kind of ComboBoxCellEditor (where a "kind" of
> ComboBoxCellEditor is defined here by its String[] of values) ...
>
> HTH,
> Paul
>
> Lew Miller wrote:
>
>> Is there a standard way (or just a good one) to configure or implement
>> a table viewer with multiple cell editors in a column? (i.e., So a
>> column can handle different data types in each row.)
>>
>> Any pointers appreciated,
>> Lew
>>
Previous Topic:SWT Browser Text Selection Event
Next Topic:Can you control which system browser the Browser widget uses?
Goto Forum:
  


Current Time: Fri Apr 26 22:14:21 GMT 2024

Powered by FUDForum. Page generated in 0.02414 seconds
.:: Contact :: Home ::.

Powered by: FUDforum 3.0.2.
Copyright ©2001-2010 FUDforum Bulletin Board Software

Back to the top