]>
git.saurik.com Git - wxWidgets.git/blob - src/palmos/dcprint.cpp
1 /////////////////////////////////////////////////////////////////////////////
2 // Name: src/palmos/dcprint.cpp
3 // Purpose: wxPrinterDC class
4 // Author: William Osborne
8 // Copyright: (c) William Osborne
9 // Licence: wxWindows licence
10 /////////////////////////////////////////////////////////////////////////////
12 // ============================================================================
14 // ============================================================================
16 // ----------------------------------------------------------------------------
18 // ----------------------------------------------------------------------------
20 #if defined(__GNUG__) && !defined(NO_GCC_PRAGMA)
21 #pragma implementation "dcprint.h"
24 // For compilers that support precompilation, includes "wx.h".
25 #include "wx/wxprec.h"
32 #include "wx/string.h"
34 #include "wx/window.h"
35 #include "wx/dcmemory.h"
39 #if wxUSE_PRINTING_ARCHITECTURE
41 #include "wx/palmos/private.h"
44 #include "wx/palmos/dib.h"
47 #include "wx/dcprint.h"
49 // ----------------------------------------------------------------------------
51 // ----------------------------------------------------------------------------
53 IMPLEMENT_CLASS(wxPrinterDC
, wxDC
)
55 // ============================================================================
57 // ============================================================================
59 // ----------------------------------------------------------------------------
60 // wxPrinterDC construction
61 // ----------------------------------------------------------------------------
63 // This form is deprecated
64 wxPrinterDC::wxPrinterDC(const wxString
& driver_name
,
65 const wxString
& device_name
,
72 wxPrinterDC::wxPrinterDC(const wxPrintData
& printData
)
77 wxPrinterDC::wxPrinterDC(WXHDC dc
)
81 void wxPrinterDC::Init()
85 // ----------------------------------------------------------------------------
86 // wxPrinterDC {Start/End}{Page/Doc} methods
87 // ----------------------------------------------------------------------------
89 bool wxPrinterDC::StartDoc(const wxString
& message
)
94 void wxPrinterDC::EndDoc()
98 void wxPrinterDC::StartPage()
102 void wxPrinterDC::EndPage()
106 // Returns default device and port names
107 static bool wxGetDefaultDeviceName(wxString
& deviceName
, wxString
& portName
)
112 // Gets an HDC for the specified printer configuration
113 WXHDC WXDLLEXPORT
wxGetPrinterDC(const wxPrintData
& printDataConst
)
118 // ----------------------------------------------------------------------------
119 // wxPrinterDC bit blitting/bitmap drawing
120 // ----------------------------------------------------------------------------
122 // helper of DoDrawBitmap() and DoBlit()
124 bool DrawBitmapUsingStretchDIBits(HDC hdc
,
126 wxCoord x
, wxCoord y
)
131 void wxPrinterDC::DoDrawBitmap(const wxBitmap
& bmp
,
132 wxCoord x
, wxCoord y
,
137 bool wxPrinterDC::DoBlit(wxCoord xdest
, wxCoord ydest
,
138 wxCoord width
, wxCoord height
,
140 wxCoord
WXUNUSED(xsrc
), wxCoord
WXUNUSED(ysrc
),
141 int WXUNUSED(rop
), bool useMask
,
142 wxCoord
WXUNUSED(xsrcMask
), wxCoord
WXUNUSED(ysrcMask
))
148 // wxUSE_PRINTING_ARCHITECTURE