umbrella
umbrella copied to clipboard
[hiccup-canvas] Text with colored background
There should be a way to specify a background color for text.
Note: The text needs to be re-measured when either the font or the actual text changes. So I think we could have 2 attributes (eg:
__lastTextand__lastFont), and only re-measure when one of those isn't in sync with the actual data.
I don't know what a good name for the background color attribute would be (backgroundFill?). In my self-implemented version I also have some padding for the background, so an attribute for that would be nice as well.
Would this be a good addition? If yes I can implement it myself and open a pr.