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

📄 globaldisp.h

📁 51单片机学习的源代码
💻 H
字号:
#if !defined(AFX_GLOBALDISP_H__93C0C50B_B8BA_461B_B89C_B7028E9631C0__INCLUDED_)
#define AFX_GLOBALDISP_H__93C0C50B_B8BA_461B_B89C_B7028E9631C0__INCLUDED_

#if _MSC_VER > 1000
#pragma once
#endif // _MSC_VER > 1000
// GlobalDisp.h : header file
//
#include "mcdsDoc.h"
/////////////////////////////////////////////////////////////////////////////
// CGlobalDisp view

class CGlobalDisp : public CView
{
protected:
	CGlobalDisp();           // protected constructor used by dynamic creation
	DECLARE_DYNCREATE(CGlobalDisp)

// Attributes
public:
	CMcdsDoc* GetDocument();
// Operations
public:
	

// Overrides
	// ClassWizard generated virtual function overrides
	//{{AFX_VIRTUAL(CGlobalDisp)
	public:
	virtual void OnInitialUpdate();
	protected:
	virtual void OnDraw(CDC* pDC);      // overridden to draw this view
	virtual void OnUpdate(CView* pSender, LPARAM lHint, CObject* pHint);
	//}}AFX_VIRTUAL

// Implementation
protected:
	virtual ~CGlobalDisp();
#ifdef _DEBUG
	virtual void AssertValid() const;
	virtual void Dump(CDumpContext& dc) const;
#endif

protected:
	CPoint leftPoint;
	CPoint rightPoint;

	double scalex(CRect rect);//每道多少像素,中间函数
	double scaley(CRect rect);//每计数多少像素,中间函数

	CString Point2Channel(CRect rect,CPoint point);//将点的坐标转换为道数
	CPoint Channel2Point(CRect rect,CString channel);//将道数转换为最上面的点
	CPoint Data2Point(CRect rect,int i);//将全局变量中的数据转换为点的坐标

	int PickMaxChannel();
	CString AutoSetRange();

	// Generated message map functions
protected:	
	//{{AFX_MSG(CGlobalDisp)
	afx_msg void OnPaint();
	afx_msg void OnTimer(UINT nIDEvent);
	afx_msg void OnLButtonDown(UINT nFlags, CPoint point);
	afx_msg void OnMouseMove(UINT nFlags, CPoint point);
	//}}AFX_MSG
	DECLARE_MESSAGE_MAP()
};

/////////////////////////////////////////////////////////////////////////////

#ifndef _DEBUG  // debug version in mcdsView.cpp
inline CMcdsDoc* CGlobalDisp::GetDocument()
{ return (CMcdsDoc*)m_pDocument; }
#endif
//{{AFX_INSERT_LOCATION}}
// Microsoft Visual C++ will insert additional declarations immediately before the previous line.

#endif // !defined(AFX_GLOBALDISP_H__93C0C50B_B8BA_461B_B89C_B7028E9631C0__INCLUDED_)

⌨️ 快捷键说明

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