timdream / wordcloud2.js

Tag cloud/Wordle presentation on 2D canvas or HTML
https://wordcloud2-js.timdream.org/
MIT License
2.34k stars 510 forks source link

treat words as a single rectangle to avoid overlapping? #208

Open Offbeatmammal opened 3 months ago

Offbeatmammal commented 3 months ago

especially in relation to this scenario: https://github.com/timdream/wordcloud2.js/issues/179#issuecomment-2008868006_

is it possible to treat each word/tag as a solid rectangle so layout doesn't have any overlap or words within letters etc? when drawing, would also good to have the ability to use classes to format things like the rectangle border, background colors etc