|
|
|
CSftPrintPreview_Main::OnPrintTerminate |
The OnPrintTerminate virtual override is called to end print/preview of one or more pages.
C++
virtual void CSftPrintPreview_Main::OnPrintTerminate( CDC* pDC, LPSFTPRINTPREVIEW_DRAWINFO lpInfo);
Parameters
pDC
The device context used for page rendering.
lpInfo
A pointer to the SFTPRINTPREVIEW_DRAWINFO structure defining additional information about the current previewing and printing operation.
Comments
The OnPrintTerminate virtual override is called to end print/preview of one or more pages.
This function is only used for application-generated output.
Example
C++
void CPreviewPagesView::OnPrintInitialize(CDC* pDC, LPSFTPRINTPREVIEW_DRAWINFO lpInfo) { // 10 point font int height = MulDiv(10, GetDeviceCaps(lpInfo->hDCPrinter, LOGPIXELSY), 72); m_PrintFont.CreateFont(- height, 0, 0, 0, FW_NORMAL, FALSE, FALSE, FALSE, DEFAULT_CHARSET, OUT_DEFAULT_PRECIS, CLIP_DEFAULT_PRECIS, DEFAULT_QUALITY, FF_DONTCARE|DEFAULT_PITCH, _T("Arial")); _ASSERT(m_PrintFont.m_hObject); }
void CPreviewPagesView::OnPrintTerminate(CDC* pDC, LPSFTPRINTPREVIEW_DRAWINFO lpInfo) { m_PrintFont.DeleteObject(); }
See Also C/C++ API | C++ Classes | Notifications