⭐ 欢迎来到虫虫下载站! | 📦 资源下载 📁 资源专辑 ℹ️ 关于我们
⭐ 虫虫下载站

📄 textproperties.cpp

📁 此源程序是一个简单的绘图程序,你通过他可以画一些简单的图形,是一款简单的画图程序,你通过他可是学到VC的图形编程.
💻 CPP
字号:
// TextProperties.cpp : implementation file
//

#include "stdafx.h"
#include "MyDraw.h"
#include "TextProperties.h"

#ifdef _DEBUG
#define new DEBUG_NEW
#undef THIS_FILE
static char THIS_FILE[] = __FILE__;
#endif

/////////////////////////////////////////////////////////////////////////////
// CTextProperties dialog


CTextProperties::CTextProperties(CWnd* pParent /*=NULL*/)
	: CDialog(CTextProperties::IDD, pParent)
{
	//{{AFX_DATA_INIT(CTextProperties)
	m_Text = _T("");
	m_BkMode = FALSE;
	//}}AFX_DATA_INIT
}


void CTextProperties::DoDataExchange(CDataExchange* pDX)
{
	CDialog::DoDataExchange(pDX);
	//{{AFX_DATA_MAP(CTextProperties)
	DDX_Text(pDX, IDC_EDIT_TEXT, m_Text);
	DDX_Check(pDX, IDC_CHECK_BKMODE, m_BkMode);
	//}}AFX_DATA_MAP
}


BEGIN_MESSAGE_MAP(CTextProperties, CDialog)
	//{{AFX_MSG_MAP(CTextProperties)
	ON_BN_CLICKED(IDC_BUTTON_FONT, OnButtonFont)
	//}}AFX_MSG_MAP
END_MESSAGE_MAP()

/////////////////////////////////////////////////////////////////////////////
// CTextProperties message handlers

void CTextProperties::OnButtonFont() 
{
	// TODO: Add your control notification handler code here
	CFontDialog dlg(&m_Font);
	if(dlg.DoModal()==IDOK)
	{
		dlg.GetCurrentFont(&m_Font);
		m_TextColor=dlg.m_cf.rgbColors;
	}
}

⌨️ 快捷键说明

复制代码 Ctrl + C
搜索代码 Ctrl + F
全屏模式 F11
切换主题 Ctrl + Shift + D
显示快捷键 ?
增大字号 Ctrl + =
减小字号 Ctrl + -