Skip to main content


Eclipse Community Forums
Forum Search:

Search      Help    Register    Login    Home
Home » Eclipse Projects » Nebula » [NatTable]Color Change due to Editing
[NatTable]Color Change due to Editing [message #1718908] Sat, 02 January 2016 05:00 Go to next message
Annamalai Mising name is currently offline Annamalai Mising nameFriend
Messages: 126
Registered: July 2009
Senior Member
Hi

I am a newbie to NatTable. I have a fairly simple requirement.
I am displaying Person Data on the Table and have enabled Editing
Functionality on the Table. Now cells which i have edited should alone
be displayed using ForeGround as RED.

I understand the usage of CellStyleAttribute but in that case, each Cell
needs to have a unique label assigned to it using the LabelAccumulator.
I cannot do this as i need to turn the ForeGround RED after editing has
been performed on a particular CELL.

Looks like a fairly simple requirement when it comes to TableViewer. Not
sure how to do it using NatTable.

Looking for support. I have used EditingSupportExample and
CustomCellStylingExample also.

Regards
Malai
Re: [NatTable]Color Change due to Editing [message #1718910 is a reply to message #1718908] Sat, 02 January 2016 08:42 Go to previous message
Dirk Fauth is currently offline Dirk FauthFriend
Messages: 2903
Registered: July 2012
Senior Member
First, NatTable has its own forum.

I'm not sure why this is a simple requirement to solve with TableViewer, but maybe just because I haven't used TableViewer in such scenarios for quite a while.

If you already know about cell labels and label accumulator, the only missing part is how to know about a cell was edited. NatTable does not have a mechanism that stores if a cell was edited. So you need to add that yourself and then apply a label if the cell was edited.

So you need to implement a custom label accumulator that stores the information which cells have been edited and applies a special label for such cells. To store that information you could use a custom UpdateDataCommandHandler or a custom IDataProvider for example.

The blinking cell examples add temporary labels if a cell value has updated using a property listener mechanism, which could also be an option.
Previous Topic:XYGraph: Make major ticks of multiple Y-Axis overlap
Next Topic:Drag on Copy an Excel like feature inside Nebula Grid
Goto Forum:
  


Current Time: Wed Oct 09 22:42:29 GMT 2024

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

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

Back to the top