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

📄 rectanglectl.h

📁 VC++写的一个Activex控件源码
💻 H
字号:
#if !defined(AFX_RECTANGLECTL_H__C85B8F2E_AC81_4159_8ACA_916F097D778E__INCLUDED_)
#define AFX_RECTANGLECTL_H__C85B8F2E_AC81_4159_8ACA_916F097D778E__INCLUDED_

#if _MSC_VER > 1000
#pragma once
#endif // _MSC_VER > 1000

// RectangleCtl.h : Declaration of the CRectangleCtrl ActiveX Control class.

/////////////////////////////////////////////////////////////////////////////
// CRectangleCtrl : See RectangleCtl.cpp for implementation.

class CRectangleCtrl : public COleControl
{
	DECLARE_DYNCREATE(CRectangleCtrl)

// Constructor
public:
	CRectangleCtrl();

// Overrides
	// ClassWizard generated virtual function overrides
	//{{AFX_VIRTUAL(CRectangleCtrl)
	public:
	virtual void OnDraw(CDC* pdc, const CRect& rcBounds, const CRect& rcInvalid);
	virtual void DoPropExchange(CPropExchange* pPX);
	virtual void OnResetState();
	protected:
	virtual BOOL PreCreateWindow(CREATESTRUCT& cs);
	//}}AFX_VIRTUAL

// Implementation
protected:
	OLE_COLOR m_fillColor;
	short m_lineSize;
	BOOL m_bImageHollow;
	OLE_COLOR m_foreColor;
	OLE_COLOR m_backColor;
	~CRectangleCtrl();

	DECLARE_OLECREATE_EX(CRectangleCtrl)    // Class factory and guid
	DECLARE_OLETYPELIB(CRectangleCtrl)      // GetTypeInfo
	DECLARE_PROPPAGEIDS(CRectangleCtrl)     // Property page IDs
	DECLARE_OLECTLTYPE(CRectangleCtrl)		// Type name and misc status

// Message maps
	//{{AFX_MSG(CRectangleCtrl)
		// NOTE - ClassWizard will add and remove member functions here.
		//    DO NOT EDIT what you see in these blocks of generated code !
	afx_msg LRESULT OnMyMessage101(WPARAM wParam, LPARAM lParam);
	//}}AFX_MSG
	DECLARE_MESSAGE_MAP()

// Dispatch maps
	//{{AFX_DISPATCH(CRectangleCtrl)
	afx_msg OLE_COLOR GetBackColor();
	afx_msg void SetBackColor(OLE_COLOR nNewValue);
	afx_msg OLE_COLOR GetForeColor();
	afx_msg void SetForeColor(OLE_COLOR nNewValue);
	afx_msg BOOL GetImageHollow();
	afx_msg void SetImageHollow(BOOL bNewValue);
	afx_msg short GetLineSize();
	afx_msg void SetLineSize(short nNewValue);
	afx_msg OLE_COLOR GetFillColor();
	afx_msg void SetFillColor(OLE_COLOR nNewValue);
	//}}AFX_DISPATCH
	DECLARE_DISPATCH_MAP()

// Event maps
	//{{AFX_EVENT(CRectangleCtrl)
	//}}AFX_EVENT
	DECLARE_EVENT_MAP()

// Dispatch and event IDs
public:
	enum {
	//{{AFX_DISP_ID(CRectangleCtrl)
	dispidBackColor = 1L,
	dispidForeColor = 2L,
	dispidImageHollow = 3L,
	dispidLineSize = 4L,
	dispidFillColor = 5L,
	//}}AFX_DISP_ID
	};
};

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

#endif // !defined(AFX_RECTANGLECTL_H__C85B8F2E_AC81_4159_8ACA_916F097D778E__INCLUDED)

⌨️ 快捷键说明

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