?? cestripchartctl.h
字號:
#if !defined(AFX_CESTRIPCHARTCTL_H__D363D2BB_5DE6_44FB_843F_CCC59D628071__INCLUDED_)
#define AFX_CESTRIPCHARTCTL_H__D363D2BB_5DE6_44FB_843F_CCC59D628071__INCLUDED_
#if _MSC_VER >= 1000
#pragma once
#endif // _MSC_VER >= 1000
// CEStripChartCtl.h : Declaration of the CCEStripChartCtrl ActiveX Control class.
/////////////////////////////////////////////////////////////////////////////
// CCEStripChartCtrl : See CEStripChartCtl.cpp for implementation.
class CCEStripChartCtrl : public COleControl
{
DECLARE_DYNCREATE(CCEStripChartCtrl)
private:
long m_LinearGaugeNum;
COleDateTime m_dt;
long m_index;
// Constructor
public:
CCEStripChartCtrl();
CDrawStripChart m_StripChart;
CDrawLinearGauge m_linearGauge;
//long m_XSpan;
// Overrides
// ClassWizard generated virtual function overrides
//{{AFX_VIRTUAL(CCEStripChartCtrl)
public:
virtual void OnDraw(CDC* pdc, const CRect& rcBounds, const CRect& rcInvalid);
virtual void DoPropExchange(CPropExchange* pPX);
virtual void OnResetState();
virtual BOOL PreTranslateMessage(MSG* pMsg);
protected:
virtual LRESULT WindowProc(UINT message, WPARAM wParam, LPARAM lParam);
//}}AFX_VIRTUAL
// Implementation
protected:
~CCEStripChartCtrl();
DECLARE_OLECREATE_EX(CCEStripChartCtrl) // Class factory and guid
DECLARE_OLETYPELIB(CCEStripChartCtrl) // GetTypeInfo
DECLARE_PROPPAGEIDS(CCEStripChartCtrl) // Property page IDs
DECLARE_OLECTLTYPE(CCEStripChartCtrl) // Type name and misc status
// Message maps
//{{AFX_MSG(CCEStripChartCtrl)
afx_msg int OnCreate(LPCREATESTRUCT lpCreateStruct);
afx_msg void OnTimer(UINT nIDEvent);
afx_msg void OnRButtonDown(UINT nFlags, CPoint point);
afx_msg void OnMouseMove(UINT nFlags, CPoint point);
afx_msg void OnLButtonDown(UINT nFlags, CPoint point);
afx_msg void OnLButtonUp(UINT nFlags, CPoint point);
//}}AFX_MSG
DECLARE_MESSAGE_MAP()
// Dispatch maps
//{{AFX_DISPATCH(CCEStripChartCtrl)
afx_msg long GetLinearGaugeNum();
afx_msg void SetLinearGaugeNum(long nNewValue);
afx_msg long GetOrientation();
afx_msg void SetOrientation(long nNewValue);
afx_msg long GetValueCount();
afx_msg void SetValueCount(long nNewValue);
afx_msg long GetCurveCount();
afx_msg void SetCurveCount(long nNewValue);
afx_msg long GetCursor();
afx_msg void SetCursor(long nNewValue);
afx_msg OLE_COLOR GetBackColor();
afx_msg void SetBackColor(OLE_COLOR nNewValue);
afx_msg OLE_COLOR GetGridBkColor();
afx_msg void SetGridBkColor(OLE_COLOR nNewValue);
afx_msg void SetLinearGaugeValueCount(long Index, long ValueCount);
afx_msg void SetLinearGaugeParm(long Index, long Max, long Min, long Majortics, long Minortics);
afx_msg long SetY(long Ymajortics, long Yminortics, OLE_COLOR YmajorticsColor, OLE_COLOR YminorticsColor);
afx_msg long SetX(long Xmajortics, long Xminortics, OLE_COLOR XmajorticsColor, OLE_COLOR XminorticsColor, long XSpan);
afx_msg long SetValueParm(long index, long valueIndex, OLE_COLOR valueColor, float value);
afx_msg long AddCurveValue(long index, long YMax, long YMin, long Timelevel, OLE_COLOR color, long Visibled, long lineWidth, long lineType, long excursion, DATE DateTime, float value);
afx_msg long SetXYPrt(long index, long iYMax, long iYMin, long Timelevel, OLE_COLOR color, long Visibled, long LineWidth, long LineType, long Excursion);
afx_msg long AddXYValue(long index, DATE DateTime, float value);
afx_msg long SetLGParm(long index, long valueIndex, OLE_COLOR valueColor);
afx_msg long SetLGValue(long index, long valueIndex, float value);
afx_msg DATE GetLastDateTime();
afx_msg long SetRect(long left, long top, long right, long bottom);
afx_msg long GetXYValue(long index, DATE FAR* datatime, float FAR* value);
afx_msg long GetLinearGaugeVisibled(long index);
afx_msg void SetLinearGaugeVisibled(long index, long nNewValue);
afx_msg void refresh();
//}}AFX_DISPATCH
DECLARE_DISPATCH_MAP()
afx_msg void AboutBox();
// Event maps
//{{AFX_EVENT(CCEStripChartCtrl)
void MouseMove(short Button, short Shift, OLE_XPOS_PIXELS x, OLE_YPOS_PIXELS y)
{FireEvent(DISPID_MOUSEMOVE,EVENT_PARAM(VTS_I2 VTS_I2 VTS_XPOS_PIXELS VTS_YPOS_PIXELS), Button, Shift, x, y);}
void Click()
{FireEvent(DISPID_CLICK,EVENT_PARAM(VTS_NONE));}
//}}AFX_EVENT
DECLARE_EVENT_MAP()
// Dispatch and event IDs
public:
enum {
//{{AFX_DISP_ID(CCEStripChartCtrl)
dispidLinearGaugeNum = 1L,
dispidOrientation = 2L,
dispidValueCount = 3L,
dispidCurveCount = 4L,
dispidCursor = 5L,
dispidBackColor = 6L,
dispidGridBkColor = 7L,
dispidSetLinearGaugeValueCount = 8L,
dispidSetLinearGaugeParm = 9L,
dispidSetY = 10L,
dispidSetX = 11L,
dispidLinearGaugeVisibled = 21L,
dispidSetValueParm = 12L,
dispidAddCurveValue = 13L,
dispidSetXYPrt = 14L,
dispidAddXYValue = 15L,
dispidSetLGParm = 16L,
dispidSetLGValue = 17L,
dispidGetLastDateTime = 18L,
dispidSetRect = 19L,
dispidGetXYValue = 20L,
//}}AFX_DISP_ID
};
};
//{{AFX_INSERT_LOCATION}}
// Microsoft eMbedded Visual C++ will insert additional declarations immediately before the previous line.
#endif // !defined(AFX_CESTRIPCHARTCTL_H__D363D2BB_5DE6_44FB_843F_CCC59D628071__INCLUDED)
?? 快捷鍵說明
復制代碼
Ctrl + C
搜索代碼
Ctrl + F
全屏模式
F11
切換主題
Ctrl + Shift + D
顯示快捷鍵
?
增大字號
Ctrl + =
減小字號
Ctrl + -