contents up previous next

wxpreviewframe

this class provides the default method of managing the print preview interface. member functions may be overridden to replace functionality, or the class may be used without derivation.

derived from

wxframe
wxwindow
wxevthandler
wxobject

include files

<wx/print.h>

see also

wxpreviewcanvas, wxpreviewcontrolbar, wxprintpreview

members

wxpreviewframe::wxpreviewframe
wxpreviewframe::~wxpreviewframe
wxpreviewframe::createcontrolbar
wxpreviewframe::createcanvas
wxpreviewframe::initialize
wxpreviewframe::onclosewindow


wxpreviewframe::wxpreviewframe

wxpreviewframe(wxprintpreview* preview, wxwindow* parent, const wxstring& title, const wxpoint& pos = wxdefaultposition, const wxsize& size size = wxdefaultsize, long style = wxdefault_frame_style, const wxstring& name = "frame")

constructor. pass a print preview object plus other normal frame arguments. the print preview object will be destroyed by the frame when it closes.


wxpreviewframe::~wxpreviewframe

~wxpreviewframe()

destructor.


wxpreviewframe::createcontrolbar

void createcontrolbar()

creates a wxpreviewcontrolbar. override this function to allow a user-defined preview control bar object to be created.


wxpreviewframe::createcanvas

void createcanvas()

creates a wxpreviewcanvas. override this function to allow a user-defined preview canvas object to be created.


wxpreviewframe::initialize

void initialize()

creates the preview canvas and control bar, and calls wxwindow::makemodal(true) to disable other top-level windows in the application.

this function should be called by the application prior to showing the frame.


wxpreviewframe::onclosewindow

void onclosewindow(wxcloseevent& event)

enables the other frames in the application, and deletes the print preview object, implicitly deleting any printout objects associated with the print preview object.