I'm trying to place text and then put text bubbles around them. To preserve the text bubble corner curves, I'm using shape keys. But sizing their width and height is a problem. I calculated width and height of the text bounding box and tried driving the shape keys, but that wasn't accurate for some reason.
Below is my second attempt. This time I'm calculating the width and height of both the text and bubble bounding box.
In the picture below;
- I increase iterate a number of times to incrementally approach the correct size.
- The result is used to increase the bubble size
- The code seems to work but gets caught in a loop somehow. The bubble flickers through the sizes after hitting it's limit.
I'm missing something with the loop structure I'm sure. Any help would be appreciated.
If you know of a better, more elegant way to size the text bubbles around text, I'm open for that too.