]> git.saurik.com Git - wxWidgets.git/blob - src/os2/print.cpp
Switched wxCheckWindowWndProc to always use the window class name for
[wxWidgets.git] / src / os2 / print.cpp
1 /////////////////////////////////////////////////////////////////////////////
2 // Name: src/os2/print.cpp
3 // Purpose: Print framework
4 // Author: David Webster
5 // Modified by:
6 // Created: 10/14/99
7 // RCS-ID: $Id$
8 // Copyright: (c) David Webster
9 // Licence: wxWindows licence
10 /////////////////////////////////////////////////////////////////////////////
11
12 #include "wx/wxprec.h"
13
14 #ifndef WX_PRECOMP
15 #include <stdio.h>
16 #include "wx/setup.h"
17 #include "wx/list.h"
18 #include "wx/utils.h"
19 #include "wx/app.h"
20 #endif
21
22 #if wxUSE_PRINTING_ARCHITECTURE
23
24 #include "wx/os2/printos2.h"
25 #include "wx/generic/prntdlgg.h"
26
27 IMPLEMENT_DYNAMIC_CLASS(wxOS2Printer, wxPrinterBase)
28 IMPLEMENT_CLASS(wxOS2PrintPreview, wxPrintPreviewBase)
29
30 /*
31 * Printer
32 */
33
34 wxOS2Printer::wxOS2Printer(wxPrintDialogData *data):
35 wxPrinterBase(data)
36 {
37 }
38
39 wxOS2Printer::~wxOS2Printer()
40 {
41 }
42
43 bool wxOS2Printer::Print(wxWindow *WXUNUSED(parent),
44 wxPrintout *WXUNUSED(printout),
45 bool WXUNUSED(prompt))
46 {
47 // TODO. See wxPostScriptPrinter::Print for hints.
48 return false;
49 }
50
51 wxDC* wxOS2Printer::PrintDialog(wxWindow *WXUNUSED(parent))
52 {
53 // TODO:
54 /*
55 wxPrintDialog dialog(parent, & m_printData);
56 return (dialog.GetPrintDC());
57 */
58 return NULL;
59 }
60
61 bool wxOS2Printer::Setup(wxWindow *WXUNUSED(parent))
62 {
63 // TODO:
64 /*
65 wxPrintDialog dialog(parent, & m_printData);
66 #if WXWIN_COMPATIBILITY_2_4
67 dialog.GetPrintData().SetSetupDialog(true);
68 #endif
69 return (dialog.ShowModal() == wxID_OK);
70 */
71 return false;
72 }
73
74 /*
75 * Print preview
76 */
77
78 wxOS2PrintPreview::wxOS2PrintPreview(wxPrintout *printout, wxPrintout *printoutForPrinting, wxPrintDialogData *data):
79 wxPrintPreviewBase(printout, printoutForPrinting, data)
80 {
81 DetermineScaling();
82 }
83
84 wxOS2PrintPreview::wxOS2PrintPreview(wxPrintout *printout, wxPrintout *printoutForPrinting, wxPrintData *data):
85 wxPrintPreviewBase(printout, printoutForPrinting, data)
86 {
87 DetermineScaling();
88 }
89
90 wxOS2PrintPreview::~wxOS2PrintPreview()
91 {
92 }
93
94 bool wxOS2PrintPreview::Print(bool WXUNUSED(interactive))
95 {
96 if (!m_printPrintout)
97 return false;
98 // wxOS2Printer printer(&m_printData);
99 // return printer.Print(m_previewFrame, m_printPrintout, interactive);
100 return false;
101 }
102
103 void wxOS2PrintPreview::DetermineScaling()
104 {
105 // TODO
106 }
107
108 #endif //wxUSE_PRINTING_ARCHITECTURE