diff options
| author | Albrecht Schlosser <albrechts.fltk@online.de> | 2010-03-14 18:07:24 +0000 |
|---|---|---|
| committer | Albrecht Schlosser <albrechts.fltk@online.de> | 2010-03-14 18:07:24 +0000 |
| commit | 998cc6df521a115454727d1ecf6bc7d4fee96f68 (patch) | |
| tree | 70a1c9afffb294a75bd38484c2e6e4a042ac3426 /src/Fl_Image.cxx | |
| parent | 5bc66fafc348c547870bbf51c9c4a7215ad4ff25 (diff) | |
Merge of branch-1.3-Fl_Printer, with the following main changes:
(1) adding Fl_Device class (and more) for device abstraction
(2) adding Fl_Pinter class (and more) for printing support.
Todo: Code cleanup, update dependencies, remove/replace test print window.
I'm looking into converting the test window popup in a global shortcut
that would pop up the print dialog now...
git-svn-id: file:///fltk/svn/fltk/branches/branch-1.3@7263 ea41ed52-d2ee-0310-a9c1-e6b18d33e121
Diffstat (limited to 'src/Fl_Image.cxx')
| -rw-r--r-- | src/Fl_Image.cxx | 5 |
1 files changed, 5 insertions, 0 deletions
diff --git a/src/Fl_Image.cxx b/src/Fl_Image.cxx index 849d43f90..b11ba0ce5 100644 --- a/src/Fl_Image.cxx +++ b/src/Fl_Image.cxx @@ -31,6 +31,7 @@ #include <FL/Fl_Widget.H> #include <FL/Fl_Menu_Item.H> #include <FL/Fl_Image.H> +#include <FL/Fl_Printer.H> #include "flstring.h" #ifdef WIN32 @@ -434,6 +435,10 @@ static void alpha_blend(Fl_RGB_Image *img, int X, int Y, int W, int H, int cx, i #endif // !WIN32 && !USE_QUARTZ void Fl_RGB_Image::draw(int XP, int YP, int WP, int HP, int cx, int cy) { + if(fl_device->type() == Fl_Device::postscript_device) { + ((Fl_Virtual_Printer*)fl_device)->draw(this, XP, YP, WP, HP, cx, cy); + return; + } // Don't draw an empty image... if (!d() || !array) { draw_empty(XP, YP); |
