I am currently working on an application that uses a TableViewer in several places to display formatted tabular data. Each table must have an export feature where all its content is exported in an Excel file.
In order to avoid unnecessery code duplication, I thought it would be nice to rely upon the viewer framework of SWT and use it to get the formatted tabular data using the registered label providers.
This approach works well with standard read-only tables, either with table-level and column-level label providers. However, I am stuck when an EditingSupport or TableEditors have been set on the table.
In such cases, we often had label providers to return blank values and let the TableViewer deal with the EditingSupport or the TableEditor to get the representation of the cell data.
Is there any way for me to access a TableEditor or an EditingSupport that has been attached to a TableViewer (without keeping a separate reference to said objects) so I can use them to retrieve a proper representation of the cell data ?
If not, we will probably rewrite our label providers so that they handle columns with EditingSupport as well, but it would be nice if we did not have to.