coloredit.cpp
来自「使用vc开发的个人信息管理系统」· C++ 代码 · 共 52 行
CPP
52 行
// ColorEdit.cpp : implementation file
//
#include "stdafx.h"
#include "dotNET界面.h"
#include "ColorEdit.h"
#ifdef _DEBUG
#define new DEBUG_NEW
#undef THIS_FILE
static char THIS_FILE[] = __FILE__;
#endif
#define RED RGB(127, 0, 0)
#define GREEN RGB( 0,127, 0)
#define BLUE RGB( 0, 0,127)
#define LIGHTRED RGB(255, 0, 0)
#define LIGHTGREEN RGB( 0,255, 0)
#define LIGHTBLUE RGB( 0, 0,255)
#define BLACK RGB( 0, 0, 0)
#define WHITE RGB(255,255,255)
#define GRAY RGB(192,192,192)
/////////////////////////////////////////////////////////////////////////////
// CColorEdit
CColorEdit::CColorEdit()
{
}
CColorEdit::~CColorEdit()
{
}
BEGIN_MESSAGE_MAP(CColorEdit, CEdit)
//{{AFX_MSG_MAP(CColorEdit)
ON_WM_CTLCOLOR_REFLECT()
//}}AFX_MSG_MAP
END_MESSAGE_MAP()
/////////////////////////////////////////////////////////////////////////////
// CColorEdit message handlers
HBRUSH CColorEdit::CtlColor(CDC* pDC, UINT nCtlColor)
{
// TODO: Change any attributes of the DC here
pDC->SetTextColor( WHITE );
pDC->SetBkColor( BLUE );
// TODO: Return a non-NULL brush if the parent's handler should not be called
return NULL;
}
⌨️ 快捷键说明
复制代码Ctrl + C
搜索代码Ctrl + F
全屏模式F11
增大字号Ctrl + =
减小字号Ctrl + -
显示快捷键?