CStdioFile m_readfile;
CString m_strTemp;
m_readfile.Open( "1.txt ",CFile::modeRead);
m_strTemp.Empty();
m_strText.Empty();
while(m_readfile.ReadString(m_strTemp))
{
m_strText+=m_strTemp+ "\n ";
}
IsText=TRUE;我把1.txt 打开后 背景是白色的,怎么变成透明的呢? 还有如果 1.txt中的 文字很多,怎么自动换行呢?
还有在哪设置显示文字的大小?
谢谢各位大哥了。。
CString m_strTemp;
m_readfile.Open( "1.txt ",CFile::modeRead);
m_strTemp.Empty();
m_strText.Empty();
while(m_readfile.ReadString(m_strTemp))
{
m_strText+=m_strTemp+ "\n ";
}
IsText=TRUE;我把1.txt 打开后 背景是白色的,怎么变成透明的呢? 还有如果 1.txt中的 文字很多,怎么自动换行呢?
还有在哪设置显示文字的大小?
谢谢各位大哥了。。
if(IsText)
{
pDC->SetBkMode(TRANSPARENT);
CRect clientRect;
GetClientRect(clientRect); // 获得客户区范围
pDC->DrawText(m_strText,clientRect, DT_EDITCONTROL | DT_WORDBREAK);
}