1234567891011121314151617181920212223242526272829303132333435363738394041424344454647484950515253545556575859 |
- /************************************************************************/
- /* Copyright (C), 2016-2020, [IT], 保留所有权利;
- /* 模 块 名:;
- /* 描 述:;
- /*
- /* 版 本:[V];
- /* 作 者:[IT];
- /* 日 期:[8/19/2016];
- /*
- /*
- /* 注 意:;
- /*
- /* 修改记录:[IT];
- /* 修改日期:;
- /* 修改版本:;
- /* 修改内容:;
- /************************************************************************/
- #pragma once
- // CSkinEdit
- #include "EnBitmap.h"
- class CSkinEdit : public CEdit
- {
- DECLARE_DYNAMIC(CSkinEdit)
- public:
- CSkinEdit();
- virtual ~CSkinEdit();
- CEnBitmap m_bmpEdit;
- CString m_strText,m_strSearchTip;
- int m_nTextStart;
- COLORREF m_crText;
- void SetText(CString strText,int nStart,COLORREF cr);
- void SetExtendPoint(int nX,int nY){m_nX=nX;m_nY=nY;}
- BOOL DrawText(CDC *pDC,CRect rc ,CString strText);
- void LoadBitmap(LPCTSTR szImagePath);
- int Width(){return m_bmpEdit.GetWidth();}
- int Height(){return m_bmpEdit.GetHeight();}
- CRect GetRectInParent();
- protected:
- int m_nX,m_nY;
- DECLARE_MESSAGE_MAP()
- public:
- afx_msg void OnPaint();
- afx_msg void OnNcCalcSize(BOOL bCalcValidRects, NCCALCSIZE_PARAMS* lpncsp);
- afx_msg void OnNcLButtonDown(UINT nHitTest, CPoint point);
- afx_msg void OnMouseMove(UINT nFlags, CPoint point);
- afx_msg void OnSetFocus(CWnd* pOldWnd);
- afx_msg void OnKillFocus(CWnd* pNewWnd);
- afx_msg LRESULT OnNcHitTest(CPoint point);
- virtual BOOL PreTranslateMessage(MSG* pMsg);
- };
|