diff options
| author | Manolo Gouy <Manolo> | 2016-02-05 16:34:42 +0000 |
|---|---|---|
| committer | Manolo Gouy <Manolo> | 2016-02-05 16:34:42 +0000 |
| commit | a8a777ff26dede82ff1b450806608851f63cb79f (patch) | |
| tree | 20cb34a900305355f953d10a00e0de68169eb6f8 /FL | |
| parent | 254cb01f542b554b63c143718215b23f8151080c (diff) | |
New CMake option OPTION_PRINT_SUPPORT turned ON by default
When the option is off, file config.h defines NO_PRINT_SUPPORT
which in turn produces a library without print support, that is,
class Fl_Printer does nothing.
When off, the FLTK library is somewhat smaller.
Can be turned off only when the X11 library is used.
git-svn-id: file:///fltk/svn/fltk/branches/branch-1.3-porting@11127 ea41ed52-d2ee-0310-a9c1-e6b18d33e121
Diffstat (limited to 'FL')
| -rw-r--r-- | FL/Fl_Printer.H | 10 |
1 files changed, 7 insertions, 3 deletions
diff --git a/FL/Fl_Printer.H b/FL/Fl_Printer.H index d133ea7f5..51a947389 100644 --- a/FL/Fl_Printer.H +++ b/FL/Fl_Printer.H @@ -3,7 +3,7 @@ // // Printing support for the Fast Light Tool Kit (FLTK). // -// Copyright 2010-2014 by Bill Spitzak and others. +// Copyright 2010-2016 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 @@ -23,6 +23,7 @@ #ifndef Fl_Printer_H #define Fl_Printer_H +#include "config.h" #include <FL/x.H> #include <FL/Fl_Paged_Device.H> #include <FL/fl_draw.H> @@ -191,6 +192,7 @@ public: const char *class_name() {return class_id;}; /** \brief The constructor */ Fl_Printer(void); +#ifndef NO_PRINT_SUPPORT int start_job(int pagecount, int *frompage = NULL, int *topage = NULL); int start_page(void); int printable_rect(int *w, int *h); @@ -207,8 +209,6 @@ public: void print_window_part(Fl_Window *win, int x, int y, int w, int h, int delta_x=0, int delta_y=0); void set_current(void); Fl_Graphics_Driver* driver(void); - /** \brief The destructor */ - ~Fl_Printer(void); /** \name These attributes are effective under the Xlib platform only. \{ @@ -233,6 +233,9 @@ public: static const char *property_save; static const char *property_cancel; /** \} */ + /** \brief The destructor */ + ~Fl_Printer(void); + private: #if defined(WIN32) || defined(__APPLE__) Fl_System_Printer *printer; @@ -242,6 +245,7 @@ private: #else Fl_PostScript_Printer *printer; #endif +#endif // NO_PRINT_SUPPORT }; #endif // Fl_Printer_H |
