|
Mailing Lists
|
Home /
Groups /
ColdFusion Talk (CF-Talk)
Imagettfbbox
Hello,Thomas Stichnoth 10/17/12 04:02 A No, not that I am aware of.Gerald Guido 10/17/12 01:11 P Hello, does anyone know a coldfusion function like the PHP Imagettffbbox (http://php.net/manual/en/function.imagettfbbox.php) ? Regards vom Germany Thomas stichnoth.net Internetkonzepte und -lösungen Gretchenstr. 7 30161 Hannover <http://www.stichnoth.net/> http://www.stichnoth.net Tel. 0511 7601528 Fax 0511 7601530 No, not that I am aware of. This may help: http://cfsearching.blogspot.com/2008/01/measuring-image-text-width-and-height.html Or this: http://www.bennadel.com/blog/1150-GetTextDimensions-For-Finding-ColdFusion-Image-Text-Dimensions.htm If that doesn't do the trick you would most probably have to dig around in the Java API to tease that info out. http://docs.oracle.com/javase/6/docs/api/ HTH G! On Wed, Oct 17, 2012 at 4:02 AM, Thomas Stichnoth <info@stichnoth.net>wrote: ----- Excess quoted text cut - see Original Post for more ----- You are right, there is no built in CF function. You will need to use java as shown in those two links. If it is only a single line of text, all you need is Textlayout or FontMetrics.getStringBounds(). Both return the bounding box, with slight differences ie visual versus logical bounds. -Leigh
|
May 25, 2013
|
|
|||||||||||||||||||||||||||||||||||||||||||||||||||||||