Add AttributedString to Tooltip

You know what would be really handy? Allowing the TooltipClient / TooltipWindow to accept AttributedString as well as String.

I know the BubbleMessageComponent does this, but there you have to manage the timers yourself, something the regular ToolTip class does wonderfully already.

I could probably make something up myself but I'm sure lots of people would appreciate it as well.

Thanks for at least thinking about it.

/Michael

1 Like

That's probably a very good idea!

Apologies for resurrecting this old thread, but I’d love to use AttributedStrings on tooltips. Has this ever been added? I can’t find anything besides this forum thread.

+1

1 Like

In the meantime I worked around this by patching my LookAndFeel. I override LookAndFeel::drawTooltip and then during my own layoutTooltipText I convert the string to an attributedString. I only wanted support for bold text, so I use the markdown syntax **bold** to indicate bold words in tooltips and just go through the string to build my AttributedString with bold words.

I did quite the same thing :slight_smile: