📄 edittoolbar.cpp
字号:
// EditToolBar.cpp : implementation file
//
#include "stdafx.h"
#include "ED256.h"
#include "EditToolBar.h"
#include <stdlib.h>
#ifdef _DEBUG
#define new DEBUG_NEW
#undef THIS_FILE
static char THIS_FILE[] = __FILE__;
#endif
/////////////////////////////////////////////////////////////////////////////
// CEditToolBar
CEditToolBar::CEditToolBar()
{
}
CEditToolBar::~CEditToolBar()
{
}
BEGIN_MESSAGE_MAP(CEditToolBar, CToolBar)
//{{AFX_MSG_MAP(CEditToolBar)
ON_EN_CHANGE(ID_THRESHEDIT, ChangeThresh)
//}}AFX_MSG_MAP
END_MESSAGE_MAP()
/////////////////////////////////////////////////////////////////////////////
// CEditToolBar message handlers
void CEditToolBar::ChangeThresh() {
CString str;
m_cEdit.GetWindowText(str);
int thresh = atoi(str);
if (thresh > 255) thresh = 255;
if (thresh < 0) thresh = 0;
// This function will get called before main window
// is created, so check for that before sending msg.
CWnd *mainwnd = AfxGetMainWnd();
if (mainwnd) mainwnd->SendMessage(WM_USER+0x0001, (WPARAM)(thresh), NULL);
}
⌨️ 快捷键说明
复制代码
Ctrl + C
搜索代码
Ctrl + F
全屏模式
F11
切换主题
Ctrl + Shift + D
显示快捷键
?
增大字号
Ctrl + =
减小字号
Ctrl + -