I have a requirement to add a clickable link to the title of the WinGrid. The link should open a default email client. I was looking at the following possible solution:
1. Create a widget containing wingrid with hidden title and place a label with link instead of title.
2. Generate bitmap for the title and add event handler which will open default email client.
3. Somehow customize WinGrid title, which I don't know how to do because it looks like it take basic Text type only.
What do you think would be be the best way to do it? Did you have similar requirements?
Thank you.
In my opinion, the easiest way to do this would be to turn off the grid's Caption and place a FormattedLinkLabel on top of the grid (option 1 as you listed above).
Option 2 - using a Bitmap, would also be fairly easy to implement, but it's probably not the best implementation since you won't get the hand cursor when you mouse over the link text and clicking will not give the proper visual that you should get when you click on something.
Option 3 would be the best option from a usability standpoint. But this would be a pretty complex and difficult CreationFilter to code, and I probably would not advise going this route unless you have a lot of time to spend on it.
Thanks for the feedback, Mike.
I ended up using FormattedLinkLabel and hiding the caption since I don't really have much time to spend on it and FormattedLinkLabel does everything we need.