Word wrapping, something like comic bubble.

MagickWand for PHP is an object-oriented PHP interface to ImageMagick. Use this forum to discuss, make suggestions about, or report bugs concerning MagickWand for PHP.
Post Reply
User avatar
magick
Site Admin
Posts: 11064
Joined: 2003-05-31T11:32:55-07:00

Post by magick »

MagickWand returns the font metrics, not sure if MagickWand for PHP does. With the font metrics you can figure out word wrapping yourself. An easier method is to use the caption: format. From the command line:
  • convert -size 300x caption:'Some long caption...' image.png
ali

Re:

Post by ali »

hi,
magick wrote:MagickWand returns the font metrics, not sure if MagickWand for PHP does. With the font metrics you can figure out word wrapping yourself. An easier method is to use the caption: format. From the command line:
  • convert -size 300x caption:'Some long caption...' image.png
im currently using the caption-method for automatic wraping AND sizeing of text in a rectangle! its all command-line based, but i want to switch completly to magickwand for php.

i wrote 1year ago a method, that does the same, wraping and sizeing of text in a rectangle with GDlib in php. but it ist REALLY slow, slower then c++ and other languages. (~500 words) so i switched to imagemagick and wrote command-line commands in php.

why isnt there a function in "magickwand for php" for this caption-format? is it possible to add this feature in the next releases of magickwand for php? i dont want to use exec() command, because i want to create images in php on-the-fly for better integration and dont wanna mixxing command-line and magickwand-commands.
Post Reply