Wednesday, December 03, 2008

Creating a Tag Cloud in Silverlight

For one of our Data Visualization projects I wanted to create a Tag Cloud type UI in Silverlight. Googling around I found this very nice article on this.

I decided to reproduce the user control so I could learn more about Silverlight and also added few customizations and some mouse enter and leave events to highlight the selected tag.
I also made some other small modifications to clean up the code a bit.

Here is the screen of the control :


You can download the source code from here.


fred said...

great piece of code thank to share it !!!

Could you help on this issue ?
I try to allow dynamic width of the wrappanel without success in order to display always the tags
is that possible ????

Jomit Vaghela said...

Not sure what you are exactly asking. Could you please provide more details.

fred said...

sorry, i will try to be more clear.

When I insert a treView in a tabControl, the width of the tabControl is changing according to the size of the item in a way that you always can see all the item.
But when i insert the tagCloud in the tabControl, I cannot see all the items in the tag cloud.

fred said...

thanks for the prompt response...
if I insert a treeView in a tabControl, the width of the tabcontrol is changing according to the size of the biggest item in the treeView - but if i insert the tagCloud in the tabcontrol the width is fixed - i can put a sample in a ftp...