Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

+antialias is ignored with "pango" format #3906

Closed
joshuakraemer opened this issue Jul 6, 2021 · 5 comments
Closed

+antialias is ignored with "pango" format #3906

joshuakraemer opened this issue Jul 6, 2021 · 5 comments

Comments

@joshuakraemer
Copy link

ImageMagick version

7.0.11-12

Operating system

Linux

Operating system, version and so on

Void Linux, kernel 5.12.13_1

Description

Disabling antialiasing by +antialias does not work with the "pango" format.

Steps to Reproduce

magick -font Helvetica -density 72 -pointsize 32 +antialias label:'test' -resize 200% /tmp/label.png

label

magick -font Helvetica -density 72 -pointsize 32 +antialias pango:'test' -resize 200% /tmp/pango.png

pango

Images

No response

@fmw42
Copy link

fmw42 commented Jul 6, 2021

I do not believe this is a bug. It is just a limitation of PANGO. PANGO has limited features that must be called within PANGO. All text features in Imagemagick are not available for PANGO. See https://developer.gnome.org/pygtk/stable/pango-markup-language.html for what is implemented.

@joshuakraemer
Copy link
Author

Then please consider it as a feature request. I think only the following would need to be added to https://github.com/ImageMagick/ImageMagick/blob/main/coders/pango.c:

if (draw_info->text_antialias == MagickFalse)
	cairo_font_options_set_antialias(font_options, CAIRO_ANTIALIAS_NONE);

@fmw42
Copy link

fmw42 commented Jul 6, 2021

I will leave further comment to the Imagemagick developers.

@dlemstra
Copy link
Member

dlemstra commented Jul 8, 2021

We just added support for this. This will become available in the next release of ImageMagick 7.

@dlemstra dlemstra closed this as completed Jul 8, 2021
@joshuakraemer
Copy link
Author

Thank you, @dlemstra!

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Development

No branches or pull requests

3 participants