bug caption with PANGO IM 6.7.6.0

Post any defects you find in the released or beta versions of the ImageMagick software here. Include the ImageMagick version, OS, and any command-line required to reproduce the problem. Got a patch for a bug? Post it here.
User avatar
fmw42
Posts: 25562
Joined: 2007-07-02T17:14:51-07:00
Authentication code: 1152
Location: Sunnyvale, California, USA

bug caption with PANGO IM 6.7.6.0

Post by fmw42 »

IM 6.7.6.0 Mac OSX Snow Leopard

Caption with PANGO is not honoring gravity.

I tried Anthony's command from http://www.imagemagick.org/Usage/text/#caption



convert -background lightblue -fill blue -font Candice -pointsize 40 \
-size 320x -gravity Center caption:'ImageMagick Rules OK!' \
caption_centered.gif

But the result is left justified.

Image
User avatar
fmw42
Posts: 25562
Joined: 2007-07-02T17:14:51-07:00
Authentication code: 1152
Location: Sunnyvale, California, USA

Re: bug caption with PANGO IM 6.7.6.0

Post by fmw42 »

No rush on my part, but has this been verified?
User avatar
magick
Site Admin
Posts: 11064
Joined: 2003-05-31T11:32:55-07:00

Re: bug caption with PANGO IM 6.7.6.0

Post by magick »

We have not had a chance to review this problem. Stand by...
User avatar
fmw42
Posts: 25562
Joined: 2007-07-02T17:14:51-07:00
Authentication code: 1152
Location: Sunnyvale, California, USA

Re: bug caption with PANGO IM 6.7.6.0

Post by fmw42 »

magick wrote:We have not had a chance to review this problem. Stand by...
OK. Not urgent on my part. Just wanted to know if you had seen this report.

Thanks.
User avatar
magick
Site Admin
Posts: 11064
Joined: 2003-05-31T11:32:55-07:00

Re: bug caption with PANGO IM 6.7.6.0

Post by magick »

We can reproduce the problem you posted and have a patch. Look for it in ImageMagick-6.7.6-1 Beta by sometime tomorrow.
User avatar
magick
Site Admin
Posts: 11064
Joined: 2003-05-31T11:32:55-07:00

Re: bug caption with PANGO IM 6.7.6.0

Post by magick »

It looks like we're going to need to separate caption: into two coders, caption: and pango: as Anthony recommends. There are a number of minor differences between Pango rendering and Freetype rendering.
User avatar
fmw42
Posts: 25562
Joined: 2007-07-02T17:14:51-07:00
Authentication code: 1152
Location: Sunnyvale, California, USA

Re: bug caption with PANGO IM 6.7.6.0

Post by fmw42 »

OK. Probably best to separate them anyway.

Will the new pango: support -gravity (properly)?

Fred
User avatar
magick
Site Admin
Posts: 11064
Joined: 2003-05-31T11:32:55-07:00

Re: bug caption with PANGO IM 6.7.6.0

Post by magick »

Yes.
User avatar
anthony
Posts: 8883
Joined: 2004-05-31T19:27:03-07:00
Authentication code: 8675308
Location: Brisbane, Australia

Re: bug caption with PANGO IM 6.7.6.0

Post by anthony »

Caption with pango formated text is now broken.

convert -define caption:markup=true -define caption:justify=center caption:"`cat im/STORE/pango_test.txt`" show:

convert: must specify image size `<markup>.....

That is -size is not needed for pango, but the if I give a -size then the text is not interpreted as pango text but a string caption.


Also... Can we PLEASE: make pango a different coder to that of normal caption: It would make the above problems easier to deal with, and more backward compatible.
Anthony Thyssen -- Webmaster for ImageMagick Example Pages
https://imagemagick.org/Usage/
User avatar
magick
Site Admin
Posts: 11064
Joined: 2003-05-31T11:32:55-07:00

Re: bug caption with PANGO IM 6.7.6.0

Post by magick »

Already done. Pango is now a separate coder. We'll fix the other problem you reported sometime today.
User avatar
anthony
Posts: 8883
Joined: 2004-05-31T19:27:03-07:00
Authentication code: 8675308
Location: Brisbane, Australia

Re: bug caption with PANGO IM 6.7.6.0

Post by anthony »

magick wrote:Already done. Pango is now a separate coder. We'll fix the other problem you reported sometime today.
I see it in IMv7 but I don't think you have commited the changes to IMv6
Anthony Thyssen -- Webmaster for ImageMagick Example Pages
https://imagemagick.org/Usage/
User avatar
fmw42
Posts: 25562
Joined: 2007-07-02T17:14:51-07:00
Authentication code: 1152
Location: Sunnyvale, California, USA

Re: bug caption with PANGO IM 6.7.6.0

Post by fmw42 »

I just upgraded to IM 6.7.6.1 Q16 Mac OSX Snow Leopard. The changelog appears to indicate that CAPTION and PANGO have been separated and that they are now gravity sensitive again.


I have pango installed. But from convert -list format

CAPTION* CAPTION r-- Caption (Pangoft2 1.28.4)

There is no PANGO listed.

So something is wrong as CAPTION is still using Pango



Also neither of the following work correctly:


# this one is still left justified (as posted in the first messages above)
convert -background lightblue -fill blue -font Candice -pointsize 40 \
-size 320x -gravity Center caption:'ImageMagick Rules OK!' \
caption_centered.gif

# this one gives an error message
convert -background lightblue -fill blue -font Candice -pointsize 40 \
-size 320x -gravity Center pango:'ImageMagick Rules OK!' \
pango_centered.gif

convert: no decode delegate for this image format `ImageMagick Rules OK!' @ error/constitute.c/ReadImage/532.
User avatar
magick
Site Admin
Posts: 11064
Joined: 2003-05-31T11:32:55-07:00

Re: bug caption with PANGO IM 6.7.6.0

Post by magick »

We can reproduce the problem you reported and have a patch. Look for it by sometime tomorrow. Thanks.
User avatar
anthony
Posts: 8883
Joined: 2004-05-31T19:27:03-07:00
Authentication code: 8675308
Location: Brisbane, Australia

Re: bug caption with PANGO IM 6.7.6.0

Post by anthony »

I can't seem to get "pango" to interpret the text as "pango text".


convert pango:`cat pango_test.txt` show:

Code: Select all

Use of assignment to $[ is deprecated at /usr/bin/html2ps line 3408.
...lots more errors... only the first bit is displays as unformated text

Code: Select all

convert pango:'@pango_test.txt' show:
...the markup itself as unformated text...

Code: Select all

convert -define pango:markup=true pango:'@pango_test.txt' show:
.. no change...

For pango, the use of markup should be default action, there is no need for a pango:markup define!
Anthony Thyssen -- Webmaster for ImageMagick Example Pages
https://imagemagick.org/Usage/
User avatar
magick
Site Admin
Posts: 11064
Joined: 2003-05-31T11:32:55-07:00

Re: bug caption with PANGO IM 6.7.6.0

Post by magick »

We applied a patch to fix the problem you reported. Also note, we will support color markup soon.
Post Reply