Page 2 of 2

Re: Caption no longer works

Posted: 2012-01-27T13:12:55-07:00
by fmw42
If you have Pango on your system, you may have to compile IM without it to get caption: to work. Add --without-pango to your ./configure command. See the posts above. Seems like it does now work unless you have a version of Pango higher than what is available from MacPorts (or perhaps it is a Mac issue). I had the same problem as discussed above and just disabled pango and it worked fine. If you have Pango 1.29.4 or higher then it should work as magick had reported above. If you do have that version of Pango or higher and it still does not work, then report back here. Last time I installed Pango from Macports it was only 1.28.4 and that did not seem to allow caption to work on my Mac.

Re: Caption no longer works

Posted: 2012-02-04T12:35:45-07:00
by fmw42
Caption: for those using Pango now seems to be working properly and not give a blank output image in IM 6.7.5.1 Q16 Mac OSX Snow Leopard with Pango 1.28.4

Re: Caption no longer works

Posted: 2012-02-04T20:04:58-07:00
by anthony
fmw42 wrote:Caption: for those using Pango now seems to be working properly and not give a blank output image in IM 6.7.5.1 Q16 Mac OSX Snow Leopard with Pango 1.28.4
Yes Magick was able to find the fault and fix it. However while pango is working, it does not handle other colors.

This is my current pango testing text
https://dl.dropbox.com/u/9500683/pango_test.txt
Which should produce this.

Code: Select all

pango-view -q --dpi=72 -o pango_test_good.png --markup pango_test.txt 
Image

But caption: produces this

Code: Select all

convert -define caption:markup=true caption:"`cat pango_test.txt`" pango_test_bad.png
Image
ASIDE: the "caption:@filename" syntax also is also not working for pango markup.

So it is almost right, but not quite there yet.

Re: Caption no longer works

Posted: 2012-02-04T20:20:27-07:00
by fmw42
Thanks Anthony. My test was too simple with only black letters on white background. So never saw the color issue.

Re: Caption no longer works

Posted: 2012-02-05T04:27:21-07:00
by anthony
The main problem I have with pango markup is that justification is an all or nothing action.
That is center all lines, or none of the lines, You can not for example center a title or one paragraph.
Or at least I have found not recode of it in the two descriptions of the markup language.

This 'all justification' should be done in IM using
-define caption:justify=center
But that also is not working yet (nor is -gravity)

As I said I think I would have preferred pango markup to have been a separate coder to caption:

The other lesser problem is while 'TAB' characters can be used in pango text, and it is understood.
You can not set the tab spacing width, so you can not create tables easily in pango markup,

Both problems are however solvable using the pango API, just not the markup which is more for complex 'label' or 'caption' type generation, just as IM is using it.

Re: Caption no longer works

Posted: 2012-02-05T09:02:26-07:00
by magick
caption:justify requires 0, 1, true, or false. It does not permit 'center'. Gravity is caption:gravity-hint which allows 'natural', 'strong', or 'line'.

Re: Caption no longer works

Posted: 2012-02-05T19:03:42-07:00
by anthony
magick wrote:caption:justify requires 0, 1, true, or false. It does not permit 'center'. Gravity is caption:gravity-hint which allows 'natural', 'strong', or 'line'.
I see something that was not explained in the markup documents I saw. Pango is after all more API oriented.

I'll do more experimentation.

Okay caption:justify is for 'justification' of long paragraphs (with a -size Wx)
More research for gravity-hint