|Re: How to add a separator between two tree items [message #741722 is a reply to message #741412]
||Wed, 19 October 2011 20:48
Registered: October 2011
Grant Gayed wrote on Wed, 19 October 2011 09:58|
Perhaps you could custom draw a separator line across the top of your
second root-level item. For info on using custom draw in Tables and
On 10/18/2011 1:15 PM, svic4ever wrote:
> I have a Jface TreeViewer which contains two roots. I need to add a
> separator between the trees originated from these roots. A naive way is
> to implement a dummy treeitem as a separator but I'm looking for a
> better solution!
Thank you for your advice. I use one of the snippets in the link to solve my other problem About the separator problem, I settle with the naive method above.
Hm, usually trees don't contain separators. Hence there is no direct way to do it. I'd try to avoid it or use your suggested naive way.
I wish I wouldn't have to use separator but using separator seems to be the easiest way to solve my problem.
Moreover, I don't know if I understand the Viewer framework exactly. This is an image I think that describes the framework :http: //i.imgur.com/wx1je.png. In my understanding, when we setInput on an object for a Tree, this object is feeded to the ContentProvider. The elements come out from the ContentProvider will be filtered by various filters. After that, the remaining elements will be sorted. Finally, the tree widget will take these elements and display them. Is it correct ?
Powered by FUDForum
. Page generated in 0.02156 seconds