www.pudn.com > glyphbutton_src.zip > GlyphButton.h


#if !defined(AFX_GLYPHBUTTON_H__1610B772_0D8D_4496_90B2_D2E08AA48EED__INCLUDED_) 
#define AFX_GLYPHBUTTON_H__1610B772_0D8D_4496_90B2_D2E08AA48EED__INCLUDED_ 
 
#if _MSC_VER > 1000 
#pragma once 
#endif // _MSC_VER > 1000 
// GlyphButton.h : header file 
// 
 
///////////////////////////////////////////////////////////////////////////// 
// CGlyphButton window 
 
class CGlyphButton : public CButton 
{ 
// Construction 
public: 
	CGlyphButton(); 
 
	enum {BTN_DELETE, BTN_EDIT}; 
 
	void SetGlyph(int cGlyph); 
	void SetFont(LOGFONT* plf); 
	void SetFont(CFont* pFont); 
	void SetHeight(LONG lHeight); 
	void SetWeight(LONG lWeight); 
	void SetCharSet(BYTE bCharSet); 
	void SetFaceName(CString strFaceName); 
 
	void SetGlyphEx(LOGFONT* plf, int cGlyph); 
	void SetGlyphEx(CFont* pFont, int cGlyph); 
	void SetGlyphEx(LONG lHeight, LONG lWeight, CString strFaceName, int cGlyph); 
	void SetButtonType(int nType); 
	virtual ~CGlyphButton(); 
 
// Overrides 
	// ClassWizard generated virtual function overrides 
	//{{AFX_VIRTUAL(CGlyphButton) 
	protected: 
	virtual void PreSubclassWindow(); 
	//}}AFX_VIRTUAL 
 
	// Generated message map functions 
protected: 
	//{{AFX_MSG(CGlyphButton) 
	//}}AFX_MSG 
 
	DECLARE_MESSAGE_MAP() 
 
private: 
	void ReconstructFont(); 
 
	LOGFONT		m_lf; 
	int			m_cGlyph; 
	CFont		m_font; 
}; 
 
///////////////////////////////////////////////////////////////////////////// 
 
//{{AFX_INSERT_LOCATION}} 
// Microsoft Visual C++ will insert additional declarations immediately before the previous line. 
 
#endif // !defined(AFX_GLYPHBUTTON_H__1610B772_0D8D_4496_90B2_D2E08AA48EED__INCLUDED_)