I use a hidden span to calculate text width to temporarily avoid the
problem. Some sample code: http://pastebin.com/3DiYJANZ
--
王欣 (Xin Wang)
blog: http://dram.me/
Thanks for your work on this.
I am now in the process of solving the bounding box problem for PointText, while also adding support for multi-line text.
Expect a commit for this soon!
Best,
Jürg
https://github.com/paperjs/paper.js/commit/b114f71dda13a5c8d2dea7ea21f9f4d600f9df7b
The way the internal _getBounds works was changed and simplified a lot, as part of the process of adding matrix support to all items and allow nested matrices (discussed earlier on this list).
lineHeight is affected by ParagraphStyle#leading, to use the same wording as in Scriptographer.
J