rrecruler.h

来自「管理项目进度工具的原代码」· C头文件 代码 · 共 40 行

H
40
字号
#ifndef _RRECRULER_H_
#define _RRECRULER_H_

class CRRECRuler : public CWnd 
{

public:
// Construction/creation/destruction
	CRRECRuler();
	virtual ~CRRECRuler();
	virtual BOOL Create( const CRect& rect, CWnd* parent, UINT id );

// Implementation
	void	SetMode( int mode );
	int		GetMode() const;
	void	SetMargin( int margin );
	void	SetTabStops( const CDWordArray& arr );

protected:
// Message handlers
	afx_msg void OnLButtonDown(UINT nFlags, CPoint point);
	afx_msg void OnLButtonUp(UINT nFlags, CPoint point);
	afx_msg void OnMouseMove(UINT nFlags, CPoint point);
	afx_msg BOOL OnEraseBkgnd(CDC* pDC);
	afx_msg void OnPaint();
	afx_msg void OnEnable(BOOL bEnable);
	DECLARE_MESSAGE_MAP()

private:
// Internal data
	int m_margin;		// Left margin of ruler in pixels
	int m_mode;			// MODE_INCH/MODE_METRIC, what units 
						// to use for the ruler measure.
	int m_physicalInch;	// The number of device pixels for a 
						// physical inch of the window CDC

	CDWordArray	m_tabs;	// Tabulator settings in device pixels
};

#endif // _RRECRULER_H_

⌨️ 快捷键说明

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