[SOLVED] possible bug with read("label:") and strokewidth

Magick++ is an object-oriented C++ interface to ImageMagick. Use this forum to discuss, make suggestions about, or report bugs concerning Magick++.
Post Reply
Posts: 28
Joined: 2012-01-14T11:46:55-07:00
Authentication code: 8675308

[SOLVED] possible bug with read("label:") and strokewidth

Post by tsftd »

Edit: Solved via update to latest IM version. Will leave up in case anyone else has the same issue in the future.

OK, so I've searched the forums and found a couple of somewhat related threads over in the IM-user forum:
viewtopic.php?f=1&t=8522&p=26248&hilit= ... dth#p26248
viewtopic.php?f=1&t=8413&p=26009&hilit= ... dth#p26009

However, they are both incredibly old (~ a decade), and dealing with the CLI, not the API.

Magick++ does not appear to use the strokeWidth setting when using read("label:") -- as in this code:

Code: Select all

It appears to respect ALL other settings; I have confirmed:

It seems a bit odd that it would let you change the stroke color, but not the stroke width. I also confirmed that the commandline version of IM does allow you to specify stroke width with label (as the threads linked above indicate), so it's not a problem there. I also tried a variety of sizes -- from .1 to 500 (on a font size of 38).

I even tried specifying the strokewidth in the label call, e.g.:

Code: Select all

llayer.image[subloc].read("-strokewidth 8 label:"+text);
llayer.image[subloc].read("strokewidth 8 label:"+text);
Unsurprisingly, this crashed (maybe I'm wrong, but I don't think that you can add anything to the "label:" -- apart from the text to create).

Does anyone know how to get strokewidth to work here, or if this is a bug, or if it's working as intended, and they just don't want label to have strokewidth support? Admittedly, I'm using ImageMagick-6.9.2-7, so it's possible that it's been fixed in a newer version, but it's a pain in the butt to upgrade it, so I'd rather not go through the trouble unless someone knows that it's the problem.
Post Reply