怎么设置richedit可编辑区域?
比如richedit的宽度是600,但只有0-300是可以输入内容的,到300后换行.
[解决办法]
void __fastcall TForm1::Button1Click(TObject *Sender){ RECT rect; SendMessage(RichEdit1->Handle, EM_GETRECT, 0, LPARAM(&rect)); rect.top = 4; rect.left = 4; rect.right = 300; rect.bottom = RichEdit1->Height; SendMessage(RichEdit1->Handle, EM_SETRECT, 0, LPARAM(&rect)); RichEdit1->Refresh();