diff options
author | Matthias Clasen <mclasen@redhat.com> | 2021-12-29 09:15:26 -0500 |
---|---|---|
committer | Matthias Clasen <mclasen@redhat.com> | 2021-12-29 09:15:26 -0500 |
commit | b41206ababb74a7152f7f67f81f4f217b97ce576 (patch) | |
tree | d0869a369cff18cf5e2095030e33e029779cc509 /tests | |
parent | a9013febcf3dec6091fde6424431f0eeeff23568 (diff) | |
download | gtk+-b41206ababb74a7152f7f67f81f4f217b97ce576.tar.gz |
tests: Make fontchooser test build on macOS
Not sure what changed here, but we want to
be able to build this without fontconfig too.
Diffstat (limited to 'tests')
-rw-r--r-- | tests/testfontchooserdialog.c | 7 |
1 files changed, 7 insertions, 0 deletions
diff --git a/tests/testfontchooserdialog.c b/tests/testfontchooserdialog.c index 6b1f894b26..110e3fff52 100644 --- a/tests/testfontchooserdialog.c +++ b/tests/testfontchooserdialog.c @@ -15,10 +15,15 @@ * License along with this library. If not, see <http://www.gnu.org/licenses/>. */ +#include "config.h" + #include <string.h> +#ifdef HAVE_PANGOFT #include <pango/pangofc-fontmap.h> +#endif #include <gtk/gtk.h> + static gboolean monospace_filter (const PangoFontFamily *family, const PangoFontFace *face, @@ -86,6 +91,7 @@ main (int argc, char *argv[]) font_button = gtk_font_button_new (); +#ifdef HAVE_PANGOFT if (argc > 0) { FcConfig *config; @@ -103,6 +109,7 @@ main (int argc, char *argv[]) pango_fc_font_map_set_config (PANGO_FC_FONT_MAP (fontmap), config); gtk_font_chooser_set_font_map (GTK_FONT_CHOOSER (font_button), fontmap); } +#endif gtk_font_button_set_use_font (GTK_FONT_BUTTON (font_button), TRUE); |