From ffeaeec5bd5bcc9d4180438869b00eed14d13f13 Mon Sep 17 00:00:00 2001 From: ManoloFLTK <41016272+ManoloFLTK@users.noreply.github.com> Date: Fri, 9 Feb 2024 13:36:16 +0100 Subject: [PATCH] Move FLTK_USE_SVG from config.h to FL/fl_config.h --- configh.cmake.in | 9 +-------- configh.in | 9 +-------- fl_config.cmake.in | 13 ++++++++++++- fl_config.in | 13 ++++++++++++- test/pixmap_browser.cxx | 9 +++------ 5 files changed, 29 insertions(+), 24 deletions(-) diff --git a/configh.cmake.in b/configh.cmake.in index 99ff77ca8..0dc1b9f6c 100644 --- a/configh.cmake.in +++ b/configh.cmake.in @@ -2,7 +2,7 @@ /* * Configuration file for the Fast Light Tool Kit (FLTK). * - * Copyright 1998-2021 by Bill Spitzak and others. + * Copyright 1998-2024 by Bill Spitzak and others. * * This library is free software. Distribution and use rights are outlined in * the file "COPYING" which should have been included with this file. If this @@ -264,13 +264,6 @@ #cmakedefine HAVE_PNG_GET_VALID 1 #cmakedefine HAVE_PNG_SET_TRNS_TO_ALPHA 1 -/* -* FLTK_USE_SVG -* -* Do we want FLTK to read and write SVG-formatted files ? -*/ - -#cmakedefine FLTK_USE_SVG 1 /* * Do we have POSIX threading? diff --git a/configh.in b/configh.in index f8a6e39b2..54ade6c6a 100644 --- a/configh.in +++ b/configh.in @@ -1,7 +1,7 @@ /* * Configuration file for the Fast Light Tool Kit (FLTK). * - * Copyright 1998-2021 by Bill Spitzak and others. + * Copyright 1998-2024 by Bill Spitzak and others. * * This library is free software. Distribution and use rights are outlined in * the file "COPYING" which should have been included with this file. If this @@ -263,13 +263,6 @@ #undef HAVE_PNG_GET_VALID #undef HAVE_PNG_SET_TRNS_TO_ALPHA -/* -* FLTK_USE_SVG -* -* Do we want FLTK to read and write SVG-formatted files ? -*/ - -#undef FLTK_USE_SVG /* * Do we have POSIX threading? diff --git a/fl_config.cmake.in b/fl_config.cmake.in index 3fdcea274..f5eea672c 100644 --- a/fl_config.cmake.in +++ b/fl_config.cmake.in @@ -2,7 +2,7 @@ /* * Build configuration file for the Fast Light Tool Kit (FLTK). * - * Copyright 1998-2023 by Bill Spitzak and others. + * Copyright 1998-2024 by Bill Spitzak and others. * * This library is free software. Distribution and use rights are outlined in * the file "COPYING" which should have been included with this file. If this @@ -97,4 +97,15 @@ #cmakedefine01 FLTK_USE_STD + +/* + * FLTK_USE_SVG + * + * Do we want FLTK to read and write SVG-formatted files ? + * + */ + +#cmakedefine01 FLTK_USE_SVG + + #endif /* _FL_fl_config_h_ */ diff --git a/fl_config.in b/fl_config.in index 03c3abf57..7fd92dee3 100644 --- a/fl_config.in +++ b/fl_config.in @@ -1,7 +1,7 @@ /* * Build configuration file for the Fast Light Tool Kit (FLTK). * - * Copyright 1998-2023 by Bill Spitzak and others. + * Copyright 1998-2024 by Bill Spitzak and others. * * This library is free software. Distribution and use rights are outlined in * the file "COPYING" which should have been included with this file. If this @@ -96,4 +96,15 @@ #define FLTK_USE_STD 0 + +/* + * FLTK_USE_SVG + * + * Do we want FLTK to read and write SVG-formatted files ? + * + */ + +#undef FLTK_USE_SVG + + #endif /* _FL_fl_config_h_ */ diff --git a/test/pixmap_browser.cxx b/test/pixmap_browser.cxx index 9478540cd..c76dcd99a 100644 --- a/test/pixmap_browser.cxx +++ b/test/pixmap_browser.cxx @@ -1,7 +1,7 @@ // // A shared image test program for the Fast Light Tool Kit (FLTK). // -// Copyright 1998-2023 by Bill Spitzak and others. +// Copyright 1998-2024 by Bill Spitzak and others. // // This library is free software. Distribution and use rights are outlined in // the file "COPYING" which should have been included with this file. If this @@ -14,7 +14,7 @@ // https://www.fltk.org/bugs.php // -#include +#include #include #include #include @@ -91,10 +91,7 @@ void button_cb(Fl_Widget *,void *) { fl_file_chooser_callback(file_cb); const char *fname = fl_file_chooser("Image file?","*.{bm,bmp,gif,ico,jpg,pbm,pgm,png,ppm,xbm,xpm" #ifdef FLTK_USE_SVG - ",svg" -#ifdef HAVE_LIBZ - ",svgz" -#endif // HAVE_LIBZ + ",svg,svgz" #endif // FLTK_USE_SVG "}", name); puts(fname ? fname : "(null)"); fflush(stdout);