From 4087b8cd9a139664420468c57489cae73c8b830a Mon Sep 17 00:00:00 2001 From: Michael R Sweet Date: Fri, 23 Nov 2001 12:06:36 +0000 Subject: Add code for PNG and JPEG images. git-svn-id: file:///fltk/svn/fltk/branches/branch-1.1@1713 ea41ed52-d2ee-0310-a9c1-e6b18d33e121 --- src/Fl_Bitmap.cxx | 9 +++++++-- 1 file changed, 7 insertions(+), 2 deletions(-) (limited to 'src/Fl_Bitmap.cxx') diff --git a/src/Fl_Bitmap.cxx b/src/Fl_Bitmap.cxx index 887d57603..304f16029 100644 --- a/src/Fl_Bitmap.cxx +++ b/src/Fl_Bitmap.cxx @@ -1,5 +1,5 @@ // -// "$Id: Fl_Bitmap.cxx,v 1.5.2.4.2.4 2001/11/19 20:59:59 easysw Exp $" +// "$Id: Fl_Bitmap.cxx,v 1.5.2.4.2.5 2001/11/23 12:06:36 easysw Exp $" // // Bitmap drawing routines for the Fast Light Tool Kit (FLTK). // @@ -161,6 +161,11 @@ void fl_delete_bitmask(Fl_Bitmask bm) { #endif // WIN32 void Fl_Bitmap::draw(int XP, int YP, int WP, int HP, int cx, int cy) { + if (!array) { + draw_empty(XP, YP); + return; + } + // account for current clip region (faster on Irix): int X,Y,W,H; fl_clip_box(XP,YP,WP,HP,X,Y,W,H); cx += X-XP; cy += Y-YP; @@ -273,5 +278,5 @@ Fl_Image *Fl_Bitmap::copy(int W, int H) { } // -// End of "$Id: Fl_Bitmap.cxx,v 1.5.2.4.2.4 2001/11/19 20:59:59 easysw Exp $". +// End of "$Id: Fl_Bitmap.cxx,v 1.5.2.4.2.5 2001/11/23 12:06:36 easysw Exp $". // -- cgit v1.2.3