Pango text not centering

Questions and postings pertaining to the usage of ImageMagick regardless of the interface. This includes the command-line utilities, as well as the C and C++ APIs. Usage questions are like "How do I use ImageMagick to create drop shadows?".
Post Reply
coloring
Posts: 82
Joined: 2015-08-27T10:17:36-07:00
Authentication code: 1151

Pango text not centering

Post by coloring »

Hi, I have a little problem with Pango when trying to draw text on a picture. The text doesn't center on it, it just goes in the upper left corner.

Example command:

convert -background black -fill white -font HelveticaNeueCond -pointsize 42 -size 1280x720 -gravity center -density 72 pango:"<span font="HelveticaNeueCond><b>test</b></span>" -type truecolormatte PNG32:pic.png

Thanks!

Version: ImageMagick 7.0.6-3 Q16 arm 2017-07-28 http://www.imagemagick.org
Copyright: © 1999-2017 ImageMagick Studio LLC
License: http://www.imagemagick.org/script/license.php
Features: Cipher DPC HDRI OpenMP
Delegates (built-in): fftw fontconfig freetype jng jp2 jpeg lcms lzma pangocairo png tiff xml zlib
Post Reply