#include <imm.h>
#pragma comment(lib, "imm32.lib")
HIMC hImc = ::ImmGetContext( m_hWnd);
屏蔽输入法
::ImmAssociateContext(m_hWnd , NULL);
::ImmReleaseContext(m_hWnd , hImc );
恢复输入法的代码。
::ImmAssociateContext(m_hWnd , hImc );
procedure TForm1.Edit1MouseActivate(Sender: TObject; Button: TMouseButton;
Shift: TShiftState; X, Y, HitTest: Integer;
var MouseActivate: TMouseActivate);
begin
ImmAssociateContext(Edit1.Handle, 0);//uses IMM
end;
delphi 屏蔽中文输入法
原创
©著作权归作者所有:来自51CTO博客作者mb643d15e043b20的原创作品,请联系作者获取转载授权,否则将追究法律责任
提问和评论都可以,用心的回复会被更多人看到
评论
发布评论
相关文章