FLTK 1.4.4

Loading...
Searching...
No Matches
Fl_Printer.H
Go to the documentation of this file.
1//
2// Printing support for the Fast Light Tool Kit (FLTK).
3//
4// Copyright 2010-2016 by Bill Spitzak and others.
5//
6// This library is free software. Distribution and use rights are outlined in
7// the file "COPYING" which should have been included with this file. If this
8// file is missing or damaged, see the license at:
9//
10// https://www.fltk.org/COPYING.php
11//
12// Please see the following page on how to report bugs and issues:
13//
14// https://www.fltk.org/bugs.php
15//
16
20
21#ifndef Fl_Printer_H
22#define Fl_Printer_H
23
24#include <FL/Fl_Paged_Device.H>
25
101 class FL_EXPORT Fl_Printer : public Fl_Paged_Device {
102 private:
103 Fl_Paged_Device *printer;
105 static Fl_Paged_Device* newPrinterDriver(void);
106 public:
108 Fl_Printer(void);
109 int begin_job(int pagecount = 0, int *frompage = NULL, int *topage = NULL, char **perr_message = NULL) FL_OVERRIDE;
110 int begin_page(void) FL_OVERRIDE;
111 int printable_rect(int *w, int *h) FL_OVERRIDE;
112 void margins(int *left, int *top, int *right, int *bottom) FL_OVERRIDE;
113 void origin(int *x, int *y) FL_OVERRIDE;
114 void origin(int x, int y) FL_OVERRIDE;
115 void scale(float scale_x, float scale_y = 0.) FL_OVERRIDE;
116 void rotate(float angle) FL_OVERRIDE;
117 void translate(int x, int y) FL_OVERRIDE;
118 void untranslate(void) FL_OVERRIDE;
119 int end_page (void) FL_OVERRIDE;
120 void end_job (void) FL_OVERRIDE;
121 void set_current(void) FL_OVERRIDE;
122 bool is_current() FL_OVERRIDE;
123
127 static const char *dialog_title;
128 static const char *dialog_printer;
129 static const char *dialog_range;
130 static const char *dialog_copies;
131 static const char *dialog_all;
132 static const char *dialog_pages;
133 static const char *dialog_from;
134 static const char *dialog_to;
135 static const char *dialog_properties;
136 static const char *dialog_copyNo;
137 static const char *dialog_print_button;
138 static const char *dialog_cancel_button;
139 static const char *dialog_print_to_file;
140 static const char *property_title;
141 static const char *property_pagesize;
142 static const char *property_mode;
143 static const char *property_use;
144 static const char *property_save;
145 static const char *property_cancel;
148 ~Fl_Printer(void);
149};
150
151#endif // Fl_Printer_H
Fl_Paged_Device.H
declaration of class Fl_Paged_Device.
Fl_Paged_Device::begin_page
virtual int begin_page(void)
Begins a new printed page.
Definition Fl_Paged_Device.cxx:54
Fl_Paged_Device::scale
virtual void scale(float scale_x, float scale_y=0.)
Changes the scaling of page coordinates.
Definition Fl_Paged_Device.cxx:81
Fl_Paged_Device::margins
virtual void margins(int *left, int *top, int *right, int *bottom)
Computes the dimensions of margins that lie between the printable page area and the full page.
Definition Fl_Paged_Device.cxx:67
Fl_Paged_Device::end_page
virtual int end_page(void)
To be called at the end of each page.
Definition Fl_Paged_Device.cxx:104
Fl_Paged_Device::Fl_Paged_Device
Fl_Paged_Device()
The constructor.
Definition Fl_Paged_Device.H:39
Fl_Paged_Device::begin_job
virtual int begin_job(int pagecount=0, int *frompage=NULL, int *topage=NULL, char **perr_message=NULL)
Begins a print job.
Definition Fl_Paged_Device.cxx:36
Fl_Paged_Device::end_job
virtual void end_job(void)
To be called at the end of a print job.
Definition Fl_Paged_Device.cxx:109
Fl_Paged_Device::rotate
virtual void rotate(float angle)
Rotates the graphics operations relatively to paper.
Definition Fl_Paged_Device.cxx:90
Fl_Printer::property_title
static const char * property_title
[this text may be customized at run-time]
Definition Fl_Printer.H:140
Fl_Printer::dialog_to
static const char * dialog_to
[this text may be customized at run-time]
Definition Fl_Printer.H:134
Fl_Printer::dialog_copyNo
static const char * dialog_copyNo
[this text may be customized at run-time]
Definition Fl_Printer.H:136
Fl_Printer::dialog_all
static const char * dialog_all
[this text may be customized at run-time]
Definition Fl_Printer.H:131
Fl_Printer::dialog_range
static const char * dialog_range
[this text may be customized at run-time]
Definition Fl_Printer.H:129
Fl_Printer::dialog_print_to_file
static const char * dialog_print_to_file
[this text may be customized at run-time]
Definition Fl_Printer.H:139
Fl_Printer::dialog_cancel_button
static const char * dialog_cancel_button
[this text may be customized at run-time]
Definition Fl_Printer.H:138
Fl_Printer::property_mode
static const char * property_mode
[this text may be customized at run-time]
Definition Fl_Printer.H:142
Fl_Printer::dialog_from
static const char * dialog_from
[this text may be customized at run-time]
Definition Fl_Printer.H:133
Fl_Printer::dialog_properties
static const char * dialog_properties
[this text may be customized at run-time]
Definition Fl_Printer.H:135
Fl_Printer::property_save
static const char * property_save
[this text may be customized at run-time]
Definition Fl_Printer.H:144
Fl_Printer::Fl_Printer
Fl_Printer(void)
The constructor.
Definition Fl_Printer.cxx:152
Fl_Printer::property_pagesize
static const char * property_pagesize
[this text may be customized at run-time]
Definition Fl_Printer.H:141
Fl_Printer::dialog_title
static const char * dialog_title
[this text may be customized at run-time]
Definition Fl_Printer.H:127
Fl_Printer::dialog_pages
static const char * dialog_pages
[this text may be customized at run-time]
Definition Fl_Printer.H:132
Fl_Printer::dialog_printer
static const char * dialog_printer
[this text may be customized at run-time]
Definition Fl_Printer.H:128
Fl_Printer::dialog_copies
static const char * dialog_copies
[this text may be customized at run-time]
Definition Fl_Printer.H:130
Fl_Printer::dialog_print_button
static const char * dialog_print_button
[this text may be customized at run-time]
Definition Fl_Printer.H:137
Fl_Printer::property_cancel
static const char * property_cancel
[this text may be customized at run-time]
Definition Fl_Printer.H:145
Fl_Printer::property_use
static const char * property_use
[this text may be customized at run-time]
Definition Fl_Printer.H:143
Fl_Surface_Device::is_current
virtual bool is_current()
Is this surface the current drawing surface?
Definition Fl_Device.cxx:103
Fl_Surface_Device::set_current
virtual void set_current(void)
Make this surface the current drawing surface.
Definition Fl_Device.cxx:91
Fl_Widget_Surface::printable_rect
virtual int printable_rect(int *w, int *h)
Computes the width and height of the drawable area of the drawing surface.
Definition Fl_Widget_Surface.cxx:190
Fl_Widget_Surface::origin
virtual void origin(int x, int y)
Sets the position of the origin of graphics in the drawable part of the drawing surface.
Definition Fl_Widget_Surface.cxx:145
Fl_Widget_Surface::untranslate
virtual void untranslate()
Undoes the effect of a previous translate() call.
Definition Fl_Widget_Surface.cxx:121
Fl_Widget_Surface::translate
virtual void translate(int x, int y)
Translates the current graphics origin accounting for the current rotation.
Definition Fl_Widget_Surface.cxx:114
FL_OVERRIDE
#define FL_OVERRIDE
This macro makes it safe to use the C++11 keyword override with older compilers.
Definition fl_attr.h:46