diff options
| author | ManoloFLTK <41016272+ManoloFLTK@users.noreply.github.com> | 2023-06-12 16:55:05 +0200 |
|---|---|---|
| committer | ManoloFLTK <41016272+ManoloFLTK@users.noreply.github.com> | 2023-06-12 16:55:05 +0200 |
| commit | c606914164af2dd596c3ccf17d695723e3e42e45 (patch) | |
| tree | bf1c98e3264a92b450b797d386332326bc7ee620 /fluid | |
| parent | 2b430aa951068b5417bfa67d1541e911400adfd2 (diff) | |
Fix building with -DOPTION_USE_SVG=Off
Diffstat (limited to 'fluid')
| -rw-r--r-- | fluid/Fluid_Image.cxx | 8 |
1 files changed, 6 insertions, 2 deletions
diff --git a/fluid/Fluid_Image.cxx b/fluid/Fluid_Image.cxx index 92f4322ca..dd24bd2d2 100644 --- a/fluid/Fluid_Image.cxx +++ b/fluid/Fluid_Image.cxx @@ -199,7 +199,9 @@ void Fluid_Image::write_static(Fd_Code_Writer& f, int compressed) { size_t nData = write_static_binary(f, "PNG"); f.write_c(";\n"); write_initializer(f, "Fl_PNG_Image", "\"%s\", %s, %d", fl_filename_name(name()), idata_name, nData); - } else if (fl_ascii_strcasecmp(fl_filename_ext(name()), ".svg")==0 || fl_ascii_strcasecmp(fl_filename_ext(name()), ".svgz")==0) { + } +#ifdef FLTK_USE_SVG + else if (fl_ascii_strcasecmp(fl_filename_ext(name()), ".svg")==0 || fl_ascii_strcasecmp(fl_filename_ext(name()), ".svgz")==0) { bool gzipped = (strcmp(fl_filename_ext(name()), ".svgz") == 0); // Write svg image data... if (compressed) { @@ -232,7 +234,9 @@ void Fluid_Image::write_static(Fd_Code_Writer& f, int compressed) { write_file_error(f, "RGB_from_SVG"); } } - } else { + } +#endif // FLTK_USE_SVG + else { write_static_rgb(f, idata_name); } } |
