?? contourdrawer.h
字號:
// ContourDrawer.h: interface for the CContourDrawer class.
//
//////////////////////////////////////////////////////////////////////
#if !defined(AFX_CONTOURDRAWER_H__0BD72FC9_023F_4CDA_85EF_CB9EAED3883A__INCLUDED_)
#define AFX_CONTOURDRAWER_H__0BD72FC9_023F_4CDA_85EF_CB9EAED3883A__INCLUDED_
#if _MSC_VER > 1000
#pragma once
#endif // _MSC_VER > 1000
/*===================等值線繪制器===========================*/
//
// 其負責等值線的繪制以及繪制屬性的管理
// jeny_man@163.com
/*==============================================================*/
#include "ContourObj.h"
typedef CTypedPtrArray<CPtrArray,CContourObj*> CContourObjArray;
class CContour;
class CContourDrawer
{
public:
CContourDrawer(CContour* pContour);
virtual ~CContourDrawer();
void CreateContourObjs();
void DoDraw(CDC* pDC, const CRect& drawRect);
void ModifyColorTable();
//---------管理繪制屬性--------------------
// SetColorTable();.....
// SetDrawStyle();......
private:
//-----繪制相關---------------
void CalcScaleRatioAndTranslateXY(CDC* pDC,const CRect& drawRect);
void DrawGridBorder(CDC* pDC);
void DrawContours(CDC* pDC);
//-----繪制對象-------------
void RemoveAllContourObjs(); //清除所有的ContourObj對象
private:
CContour* m_pContourOwner; //所要繪制的等值線
CContourObjArray m_ContourObjSets; //繪制對象集合
CColorLookUpTable m_ColorTable;
//------繪制屬性--------------
//
// CDrawStyle......
//------實現縮放和平移--------------
float m_ScaleRatio; //縮放比例
float m_TranslateX; //X方向平移量
float m_TranslateY; //Y方向平移量
};
#endif // !defined(AFX_CONTOURDRAWER_H__0BD72FC9_023F_4CDA_85EF_CB9EAED3883A__INCLUDED_)
?? 快捷鍵說明
復制代碼
Ctrl + C
搜索代碼
Ctrl + F
全屏模式
F11
切換主題
Ctrl + Shift + D
顯示快捷鍵
?
增大字號
Ctrl + =
減小字號
Ctrl + -