⭐ 欢迎来到虫虫下载站! | 📦 资源下载 📁 资源专辑 ℹ️ 关于我们
⭐ 虫虫下载站

📄 dlgpreview.h

📁 用VC编写的立体仓库的管理软件源程序和设计说明书。
💻 H
字号:
#if !defined(AFX_DLGPREVIEW_H__CE162E5D_5FFC_4859_8E6A_9E67FB7013D4__INCLUDED_)
#define AFX_DLGPREVIEW_H__CE162E5D_5FFC_4859_8E6A_9E67FB7013D4__INCLUDED_

#if _MSC_VER > 1000
#pragma once
#endif // _MSC_VER > 1000
// DlgPreview.h : header file
//

/////////////////////////////////////////////////////////////////////////////
// CDlgPreview dialog
#if defined (WIN32)
    #define IS_WIN32 TRUE
#else
    #define IS_WIN32 FALSE
#endif

#define MAX_DEBUG_STRING    256
#define IS_NT      (0 != (IS_WIN32 && ((BOOL)(GetVersion() < 0x80000000))) )
#define IS_WIN32S  (0 != (IS_WIN32 && (BOOL)(!(IS_NT) && (LOBYTE(LOWORD(GetVersion()))<4))))
#define IS_WIN95   (0 != ((BOOL)(!(IS_NT) && !(IS_WIN32S)) && IS_WIN32))

class CDlgPreview : public CDialog
{
// Construction
public:
	void SetCallBackFun(PRINTPREVIEW pFun, PRNINFO sPrnInfo);
	void PrintDoc();
	void SetCurrentPage(int nCountPage, int nCurPage);
	CDlgPreview(CWnd* pParent = NULL);   // standard constructor

// Dialog Data
	//{{AFX_DATA(CDlgPreview)
	enum { IDD = IDD_PREVIEW };
		// NOTE: the ClassWizard will add data members here
	//}}AFX_DATA


// Overrides
	// ClassWizard generated virtual function overrides
	//{{AFX_VIRTUAL(CDlgPreview)
	public:
	virtual BOOL DestroyWindow();
	protected:
	virtual void DoDataExchange(CDataExchange* pDX);    // DDX/DDV support
	virtual BOOL OnCommand(WPARAM wParam, LPARAM lParam);
	//}}AFX_VIRTUAL

// Implementation
protected:
	PRINTPREVIEW	pDrawInfo;
	PRNINFO			PrnInfo;

	CBitmap		cBmp;
	CBrush		m_brush;
	CPen		cPen;
	int			nW, nH;
	CRect		WndRect;
	int			m_CountPage;	//共多少页
	int			m_CurPage;		//当前页

    SCROLLINFO  si;	
	int			iDeltaPerLine, iAccumDelta, xPt, yPt;

	void SetScrollbar(int cx, int cy);
	LPTSTR GetRegistryString(HKEY hKeyClass, LPTSTR lpszSubKey, LPTSTR lpszValueName);
	LPTSTR CopyString(LPTSTR  lpszSrc);
	PDEVMODE GetDefaultPrinterDevMode(LPTSTR lpszPrinterName);
	void DebugMsg (LPTSTR lpszMessage,...);
	void DebugMsgA (LPSTR lpszMessage,...);
	HDC GetPrinterDC(LPTSTR lpszFriendlyName, PDEVMODE pDevMode);
	HDC GetDefaultPrinterDC();
	LPTSTR GetDefaultPrinterName(void);

	// Generated message map functions
	//{{AFX_MSG(CDlgPreview)
	afx_msg HBRUSH OnCtlColor(CDC* pDC, CWnd* pWnd, UINT nCtlColor);
	afx_msg void OnHScroll(UINT nSBCode, UINT nPos, CScrollBar* pScrollBar);
	virtual BOOL OnInitDialog();
	afx_msg BOOL OnMouseWheel(UINT nFlags, short zDelta, CPoint pt);
	afx_msg void OnPaint();
	afx_msg void OnSize(UINT nType, int cx, int cy);
	afx_msg void OnVScroll(UINT nSBCode, UINT nPos, CScrollBar* pScrollBar);
	//}}AFX_MSG
	DECLARE_MESSAGE_MAP()
};

//{{AFX_INSERT_LOCATION}}
// Microsoft Visual C++ will insert additional declarations immediately before the previous line.

#endif // !defined(AFX_DLGPREVIEW_H__CE162E5D_5FFC_4859_8E6A_9E67FB7013D4__INCLUDED_)

⌨️ 快捷键说明

复制代码 Ctrl + C
搜索代码 Ctrl + F
全屏模式 F11
切换主题 Ctrl + Shift + D
显示快捷键 ?
增大字号 Ctrl + =
减小字号 Ctrl + -