用MFC RichEdit做一個類似secureCRT的工具,如何實作插入符游標一直在行末閃爍同時可以通過滑鼠選擇文本?現在通過滑鼠點擊選擇文本的時候命令列的游標就不見了。
象secureCRT的視窗中就可以讓游標一直在命令輸入處閃爍,同時可以操作滑鼠選擇前面已經輸出的文本內容。
uj5u.com熱心網友回復:
int ShowCursor(TRUE); 不起作用 ?uj5u.com熱心網友回復:
int ShowCursor(TRUE); 不起作用 ?uj5u.com熱心網友回復:
通過滑鼠右鍵彈出的,右鍵選單也可以。。uj5u.com熱心網友回復:
ShowCursor()這個不是控制滑鼠游標的嗎?我說的游標是文本插入符游標。uj5u.com熱心網友回復:
CWnd::ShowCaretvoid ShowCaret( );
Remarks
Shows the caret on the screen at the caret’s current position. Once shown, the caret begins flashing automatically.
The ShowCaret member function shows the caret only if it has a current shape and has not been hidden two or more times consecutively. If the caret is not owned by this window, the caret is not shown.
Hiding the caret is cumulative. If the HideCaret member function has been called five times consecutively, ShowCaret must be called five times to show the caret.
The caret is a shared resource. The window should show the caret only when it has the input focus or is active.
uj5u.com熱心網友回復:
可能前面說的不清楚,我要的效果是滑鼠選擇文本字串到復制完文本,插入符游標都要在命令列位置閃爍。現狀是滑鼠選擇文本時命令列的插入符游標就會跑到滑鼠點擊的位置去了。下圖上面是crt中選擇的文本,下面小方塊是插入符游標。
uj5u.com熱心網友回復:
"下面小方塊是插入符游標" 是 單獨 一行 ?uj5u.com熱心網友回復:
小方塊游標和命令列提示符是在一行的。uj5u.com熱心網友回復:
我的意思是 輸入 用 另一個 edit轉載請註明出處,本文鏈接:https://www.uj5u.com/gongcheng/62522.html
標籤:界面
