29 #include <wx/wfstream.h>
30 #include <wx/except.h>
44 #include <Carbon/Carbon.h>
45 extern "C" {
void CPSEnableForegroundOperation( ProcessSerialNumber* psn ); }
58 va_start( args, fmt );
59 fprintf( stderr,
"Verbose: " );
60 vfprintf( stderr, fmt, args );
61 fprintf( stderr,
"\n" );
79 va_start( args, fmt );
80 fprintf( stderr,
"Debug: " );
81 vfprintf( stderr, fmt, args );
82 fprintf( stderr,
"\n" );
102 "wxwidgets:wxWidgets Driver:1:wxwidgets:51:wxwidgets\n"
105 "wxpng:wxWidgets PNG Driver:0:wxwidgets:52:wxpng\n"
123 #ifndef ENABLE_DYNDRIVERS
152 throw(
"plD_init_wxwidgets called when a initialization has already occurred." );
155 static PLINT text = 1;
156 static PLINT hrshsym = 0;
157 static char *mfo = NULL;
160 {
"hrshsym",
DRV_INT, &hrshsym,
"Use Hershey symbol set (hrshsym=0|1)" },
161 {
"text",
DRV_INT, &text,
"Use own text routines (text=0|1)" },
162 {
"mfo",
DRV_STR, &mfo,
"output metafile" },
174 device =
new wxPLDevice( pls, mfo, text, hrshsym );
184 catch (
char *message )
191 plabort(
"unknown error in plD_init_wxwidgets." );
195 #endif // PLD_wxwidgets
207 #ifndef ENABLE_DYNDRIVERS
233 dev = common_init( pls );
247 dev->showGUI =
false;
248 dev->bitmapType = wxBITMAP_TYPE_PNG;
267 throw(
"plD_line_wxwidgets called before initialization." );
268 device->
DrawLine( x1a, y1a, x2a, y2a );
270 catch (
char* message )
276 plabort(
"unknown error in plD_line_wxwidgets." );
294 throw(
"plD_polyline_wxwidgets called before initialization." );
297 catch (
char* message )
303 plabort(
"unknown error in plD_polyline_wxwidgets." );
323 throw(
"plD_eop_wxwidgets called before initialization." );
326 catch (
char* message )
332 plabort(
"unknown error in plD_eop_wxwidgets." );
353 throw(
"plD_bop_wxwidgets called before initialization." );
356 catch (
char* message )
362 plabort(
"unknown error in plD_bop_wxwidgets." );
387 catch (
char* message )
393 plabort(
"unknown error in plD_tidy_wxwidgets." );
427 catch (
char* message )
433 plabort(
"unknown error in plD_state_wxwidgets." );
456 throw(
"plD_esc_wxwidgets called before initialization." );
474 device->
SetDC( pls, (wxDC *) ptr );
483 wxSize* size = (wxSize *) ptr;
484 device->
SetSize( pls, size->GetWidth(), size->GetHeight() );
494 device->
Flush( pls );
509 catch (
char* message )
515 plabort(
"unknown error in plD_tidy_wxwidgets." );