Skip to main content


Eclipse Community Forums
Forum Search:

Search      Help    Register    Login    Home
Home » Eclipse Projects » Standard Widget Toolkit (SWT) » Buttons in TreeEditor twinkle on item expand/collapse
Buttons in TreeEditor twinkle on item expand/collapse [message #646880] Sun, 02 January 2011 02:27 Go to next message
No real name is currently offline No real nameFriend
Messages: 8
Registered: January 2011
Junior Member
Hi,

I managed to build a tree with check box on some items but not all (and many columns).
I use virtual tree, tree editor for SWT.CHECK buttons, and EraseItem listener on the tree, to make my buttons background follows the tree items background on selection...

it works fine, but there still a little artefact I can't figure to avoid. When I collapse or expand an item in my tree, the button in the item and in items above twinkle, they are erased then redrawn. Any idea on how I can avoid this ?
I think I could find a way to intercept buttons erasing, then I'll be able to select which one to erase or not, but I am not familiar with swt.

[Updated on: Sun, 02 January 2011 02:30]

Report message to a moderator

Re: Buttons in TreeEditor twinkle on item expand/collapse [message #647518 is a reply to message #646880] Thu, 06 January 2011 18:28 Go to previous messageGo to next message
No real name is currently offline No real nameFriend
Messages: 8
Registered: January 2011
Junior Member
No idea ? It is the lastest big artefact I have. If I have a solution I may post a snippet for creating this kind of tree, as I saw it is a features often asked.
But I suppose it is not easy to fix else this snippet would already be available ^^
Re: Buttons in TreeEditor twinkle on item expand/collapse [message #647639 is a reply to message #647518] Fri, 07 January 2011 14:33 Go to previous messageGo to next message
Lakshmi P ShanmugamFriend
Messages: 279
Registered: July 2009
Location: India
Senior Member
Hi,

I could reproduce this behavior. The problem is that all the editors listen to the Tree Expand and Collapse events and are redrawn on every item expand/collapse.
I have opened a bug for this under SWT --> https://bugs.eclipse.org/bugs/show_bug.cgi?id=333748


Lakshmi P Shanmugam
Re: Buttons in TreeEditor twinkle on item expand/collapse [message #647680 is a reply to message #646880] Fri, 07 January 2011 18:06 Go to previous message
No real name is currently offline No real nameFriend
Messages: 8
Registered: January 2011
Junior Member
I didn't thought it was a bug, so thanks you.
I tried on winXP and OSX and both are affected.

Do you know if I can simply remove these listener on editors ? Then I'll be able to manage them my self.
Hmmm... seems that we can't manage listener of these object...

[Updated on: Fri, 07 January 2011 18:12]

Report message to a moderator

Previous Topic:A custom copy/paste operation
Next Topic:What should stay and what should go for packaging a lighter SWT JAR.
Goto Forum:
  


Current Time: Tue Apr 23 06:07:02 GMT 2024

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

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

Back to the top