diff options
| author | Albrecht Schlosser <albrechts.fltk@online.de> | 2022-03-20 15:37:48 +0100 |
|---|---|---|
| committer | Albrecht Schlosser <albrechts.fltk@online.de> | 2022-03-20 15:52:08 +0100 |
| commit | 4bcd5c467b4bf14b4f07e36ce00b639a0cc81ec8 (patch) | |
| tree | 24339f0ee1b9ffca49af12d4795305dd704d16e5 /src/Fl_Image.cxx | |
| parent | 7758020edb65b5dc2197110b7d70b48764e940a6 (diff) | |
Improve documentation of Fl_Image::copy()
Mention the new Fl_Image::release() method to delete all types of
images.
Diffstat (limited to 'src/Fl_Image.cxx')
| -rw-r--r-- | src/Fl_Image.cxx | 15 |
1 files changed, 11 insertions, 4 deletions
diff --git a/src/Fl_Image.cxx b/src/Fl_Image.cxx index 81a15416e..69c9727ab 100644 --- a/src/Fl_Image.cxx +++ b/src/Fl_Image.cxx @@ -76,10 +76,17 @@ void Fl_Image::draw_empty(int X, int Y) { } /** -Creates a resized copy of the specified image. -The image should be deleted (or in the case of Fl_Shared_Image, released) -when you are done with it. - \param W,H width and height of the returned copied image + Creates a resized copy of the specified image. + The image should be released when you are done with it. + + Note: since FLTK 1.4.0 you can use Fl_Image::release() for + all types of images (i.e. all subclasses of Fl_Image) instead + of operator \em delete for Fl_Image's and release() for + Fl_Shared_Image's. + + \see Fl_Image::release() + + \param[in] W,H Requested width and height of the copied image */ Fl_Image *Fl_Image::copy(int W, int H) { return new Fl_Image(W, H, d()); |
