Friday, March 16, 2007

New JFace API is in place

After ~8 months of work we checked in the new JFace-API with many exciting features in to CVS just a few hours ago. To see how powerful this new API is take a look at the this snippet. Test it and report us back problems if there are any.

5 comments:

Chris Aniszczyk (zx) said...

congrats, that's quite the achievement!

Anonymous said...

I just installed JFace M6, and implemented the ColumnViewer, along with double click editing and tabbing support. I am very impressed, this is a tremendous improvement in both functionality and API.

I have tried implementing tooltips by overriding the ColumnLabelProvider.getToolTipText() without success. Is there a switch somewhere that I need to set.

Thank you for doing a great job.

GB

Tom said...

Hi,

I think you forgot to call:
ColumnViewerToolTipSupport.enableFor(v,ToolTip.NO_RECREATE);

As an example see:
http://dev.eclipse.org/viewcvs/index.cgi/org.eclipse.jface.snippets/Eclipse%20JFace%20Snippets/org/eclipse/jface/snippets/viewers/Snippet011CustomTooltips.java?revision=1.6&view=markup

Anonymous said...

I am using the TreeViewer in M6 and can't get multi-select to work with your code snippet. I tried adding SWT.MULTI to the construction as in previous releases. Is there there something else required with the new API. I looked around but didn't find anything.

Tom said...

The default implementation provided by SWTFocusCellManager doesn't know how to deal with multi-selections! You need to implement your own Manager and coloring strategy.