Displaying two icons for a TreeItem

View: New views
3 Messages — Rating Filter:   Alert me  

Displaying two icons for a TreeItem

by arunkumarsimhadri () :: Rate this Message:

Reply to Author | View Threaded | Show Only this Message

I have a tree (SWT/JFace TreeViewer) implementation that displays a single icon for each TreeItem. Now I have a requirement to display two icons (on the left side) for each TreeItem.

Is there any way to do so? Please help me out of this.

Thanks in advance

RE: Displaying two icons for a TreeItem

by arunkumarsimhadri :: Rate this Message:

Reply to Author | View Threaded | Show Only this Message


And I am using a SWT/JFace TreeViewer.

Thanks & Regards
Arun Kumar Simhadri

-----Original Message-----
From: platform-dev-bounces@...
[mailto:platform-dev-bounces@...] On Behalf Of arunkumarsimhadri
Sent: Friday, November 14, 2008 11:30 AM
To: platform-dev@...
Subject: [platform-dev] Displaying two icons for a TreeItem


I have a tree implementation that displays a single icon for each
TreeItem.
Now I have a requirement to display two icons (on the left side) for
each
TreeItem.

Is there any way to do so? Please help me out of this.

Thanks in advance
--
View this message in context:
http://www.nabble.com/Displaying-two-icons-for-a-TreeItem-tp20361286p203
61286.html
Sent from the Eclipse Platform - General mailing list archive at
Nabble.com.

_______________________________________________
platform-dev mailing list
platform-dev@...
https://dev.eclipse.org/mailman/listinfo/platform-dev

DISCLAIMER:
-----------------------------------------------------------------------------------------------------------------------

The contents of this e-mail and any attachment(s) are confidential and intended for the named recipient(s) only.
It shall not attach any liability on the originator or HCL or its affiliates. Any views or opinions presented in
this email are solely those of the author and may not necessarily reflect the opinions of HCL or its affiliates.
Any form of reproduction, dissemination, copying, disclosure, modification, distribution and / or publication of
this message without the prior written consent of the author of this e-mail is strictly prohibited. If you have
received this email in error please delete it and notify the sender immediately. Before opening any mail and
attachments please check them for viruses and defect.

-----------------------------------------------------------------------------------------------------------------------
_______________________________________________
platform-dev mailing list
platform-dev@...
https://dev.eclipse.org/mailman/listinfo/platform-dev

RE: Displaying two icons for a TreeItem

by portal on behalf of Eric Moffatt :: Rate this Message:

Reply to Author | View Threaded | Show Only this Message


Arun, two suggestions:

- Use a tree with multiple columns. I'm pretty sure each column can be made to support both an image and a 'label' so you may have to make two columns; the first only containing an image and the second column containing the image and the label.

- you could create a new image that is the 'sum' of both the other images on the fly...I've attached a hacked version of SWT snippet279 that show how to combine the images...



Heopthis helps,
Eric



"Arun Simhadri, TLS, Chennai" <arunsimha@...>
Sent by: platform-dev-bounces@...

11/14/2008 01:03 AM
Please respond to
"Eclipse platform general developers list."        <platform-dev@...>

To
"Eclipse platform general developers list." <platform-dev@...>
cc
Subject
RE: [platform-dev] Displaying two icons for a TreeItem






And I am using a SWT/JFace TreeViewer.

Thanks & Regards
Arun Kumar Simhadri

-----Original Message-----
From: platform-dev-bounces@...
[mailto:platform-dev-bounces@...] On Behalf Of arunkumarsimhadri
Sent: Friday, November 14, 2008 11:30 AM
To: platform-dev@...
Subject: [platform-dev] Displaying two icons for a TreeItem


I have a tree implementation that displays a single icon for each
TreeItem.
Now I have a requirement to display two icons (on the left side) for
each
TreeItem.

Is there any way to do so? Please help me out of this.

Thanks in advance
--
View this message in context:
http://www.nabble.com/Displaying-two-icons-for-a-TreeItem-tp20361286p203
61286.html
Sent from the Eclipse Platform - General mailing list archive at
Nabble.com.

_______________________________________________
platform-dev mailing list
platform-dev@...
https://dev.eclipse.org/mailman/listinfo/platform-dev

DISCLAIMER:
-----------------------------------------------------------------------------------------------------------------------

The contents of this e-mail and any attachment(s) are confidential and intended for the named recipient(s) only.
It shall not attach any liability on the originator or HCL or its affiliates. Any views or opinions presented in
this email are solely those of the author and may not necessarily reflect the opinions of HCL or its affiliates.
Any form of reproduction, dissemination, copying, disclosure, modification, distribution and / or publication of
this message without the prior written consent of the author of this e-mail is strictly prohibited. If you have
received this email in error please delete it and notify the sender immediately. Before opening any mail and
attachments please check them for viruses and defect.

-----------------------------------------------------------------------------------------------------------------------
_______________________________________________
platform-dev mailing list
platform-dev@...
https://dev.eclipse.org/mailman/listinfo/platform-dev



_______________________________________________
platform-dev mailing list
platform-dev@...
https://dev.eclipse.org/mailman/listinfo/platform-dev

Snippet279.java (3K) Download Attachment