summaryrefslogtreecommitdiff
path: root/FL
diff options
context:
space:
mode:
authorManoloFLTK <41016272+ManoloFLTK@users.noreply.github.com>2022-11-15 10:09:01 +0100
committerManoloFLTK <41016272+ManoloFLTK@users.noreply.github.com>2022-11-15 10:09:01 +0100
commit7f8f7c5b851f4e15cf95c6e819bff284b7fda7ca (patch)
tree48a51de221358f977c494a955b73ceca6cd679be /FL
parent433a8e71e81c51a96f1d617fae5a3a4aac4efaeb (diff)
Add support of .svgz image files to fluid
The prototype of the public Fl_SVG_Image constructor is expanded to allow construction from in-memory, gzip'ed binary data.
Diffstat (limited to 'FL')
-rw-r--r--FL/Fl_SVG_Image.H7
1 files changed, 4 insertions, 3 deletions
diff --git a/FL/Fl_SVG_Image.H b/FL/Fl_SVG_Image.H
index d09f3882b..530c51a82 100644
--- a/FL/Fl_SVG_Image.H
+++ b/FL/Fl_SVG_Image.H
@@ -1,7 +1,7 @@
//
// SVG Image header file for the Fast Light Tool Kit (FLTK).
//
-// Copyright 2017-2020 by Bill Spitzak and others.
+// Copyright 2017-2022 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
@@ -147,13 +147,14 @@ private:
float svg_scaling_(int W, int H);
void rasterize_(int W, int H);
virtual void cache_size_(int &width, int &height);
- void init_(const char *filename, const char *filedata, const Fl_SVG_Image *copy_source);
+ void init_(const char *filename, const unsigned char *filedata, const Fl_SVG_Image *copy_source,
+ size_t length);
Fl_SVG_Image(const Fl_SVG_Image *source);
public:
/** Set this to \c false to allow image re-scaling that alters the image aspect ratio.
Upon object creation, proportional is set to \c true, and the aspect ratio is kept constant.*/
bool proportional;
- Fl_SVG_Image(const char *filename, const char *svg_data = NULL);
+ Fl_SVG_Image(const char *filename, const char *svg_data = NULL, size_t length = 0);
virtual ~Fl_SVG_Image();
virtual Fl_Image *copy(int W, int H) const;
Fl_Image *copy() const {