Home > Software engineering >  CRichEditCtrl with Insert key problems
CRichEditCtrl with Insert key problems

Time:10-04

Inside the CRichEditCtrl input character, press the Insert button on the keyboard, you can switch input state.
One is covered, one kind is replaced.
How to judge the current in that state? In the program?

CodePudding user response:

HOOK according to the building, that is, whether the insert button has been pressed, and then to record the status

CodePudding user response:

# define VK_INSERT 0 x2d
If (pMsg - & gt; WParam==VK_INSERT)
{
.
}

CodePudding user response:


 bIsInsert=(GetKeyState (VK_INSERT) & amp; 0 x0001)? TRUE, FALSE; 

CodePudding user response:

If the low order bit is 1, the key is toggled. A key, to the as the caps lock key, is toggled the If it is turned on. The key is off and untoggled If the low order bit is 0. A toggle key 's indicator light (If any) on the the rid_device_info_keyboard will be on when the key is toggled, and off when the key is untoggled.
  • Related