choosefontpage.h

来自「这是WINCE进行字体选择演示的的一个程序」· C头文件 代码 · 共 72 行

H
72
字号
#if !defined(AFX_CHOOSEFONTPAGE_H__43A2F396_2158_4F7E_B820_F6EEF0E309E1__INCLUDED_)
#define AFX_CHOOSEFONTPAGE_H__43A2F396_2158_4F7E_B820_F6EEF0E309E1__INCLUDED_

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

/////////////////////////////////////////////////////////////////////////////
// CChooseFontPage dialog

class CChooseFontPage : public CPropertyPage
{
	DECLARE_DYNCREATE(CChooseFontPage)

// Construction
public:
	CChooseFontPage();
	~CChooseFontPage();

// Dialog Data
	//{{AFX_DATA(CChooseFontPage)
	enum { IDD = IDD_PP_CHOOSE_FONT };
	CComboBox	m_wndSize;
	CComboBox	m_wndFont;
	CString	m_strPreview;
	//}}AFX_DATA
	LOGFONT		m_logFont;
	int			m_nLogPixY;

// Overrides
	// ClassWizard generate virtual function overrides
	//{{AFX_VIRTUAL(CChooseFontPage)
	protected:
	virtual void DoDataExchange(CDataExchange* pDX);    // DDX/DDV support
	//}}AFX_VIRTUAL

// Implementation
protected:
	CFont	m_fontBold,
			m_fontSample;

	void	Underline(CDC &dc, UINT nID);
	void	RenderFont();
	int		MultDiv(int a, int b, int c);

	// Generated message map functions
	//{{AFX_MSG(CChooseFontPage)
	virtual BOOL OnInitDialog();
	afx_msg void OnPaint();
	afx_msg void OnClearType();
	afx_msg void OnBold();
	afx_msg void OnItalic();
	afx_msg void OnUnderline();
	afx_msg void OnSelChangeFontName();
	afx_msg void OnSelChangeFontSize();
	afx_msg void OnEditChangeFontName();
	afx_msg void OnEditChangeFontSize();
	//}}AFX_MSG
	DECLARE_MESSAGE_MAP()

};

int CALLBACK EnumFontFamProc(ENUMLOGFONT *lpelf, TEXTMETRIC *lpntm, 
							 int FontType, LPARAM lParam );

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

#endif // !defined(AFX_CHOOSEFONTPAGE_H__43A2F396_2158_4F7E_B820_F6EEF0E309E1__INCLUDED_)

⌨️ 快捷键说明

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