网站首页  词典首页

请输入您要查询的函数:

 

术语 getkeyboardlayout
释义 GetKeyboardLayout
语法:
HKL GetKeyboardLayout( DWORD idThread
);
GetKeyboardLayout功能
该GetKeyboardLayout函数检索积极投入区域设置标识符(前称的键盘布局指定线程)。如果idThread参数为零,为活动线程输入法区域设置标识符返回。
参数
idThread
[in]标识查询或线程为当前线程为零。
返回值
返回值是线程的输入法区域设置标识符。低字包含的输入语言的语言标识符和高位字包含一个设备句柄的键盘布局。
备注
输入法区域设置标识符是一个比键盘布局更广泛的概念,因为它也可以包括演讲到文本转换器,输入法编辑器(IME),或任何其他形式的投入。
由于键盘布局可以动态改变,应用程序缓存有关当前的键盘布局信息应处理WM_INPUTLANGCHANGE消息是在输入语言的变化情况。
要获得当前活动的 hkl KLID(键盘布局ID),调用GetKeyboardLayoutName。要找到某个特定KLID加载,请GetKeyboardLayoutList,加载与LoadKeyboardLayout键盘,然后检查,看看 hkl 是与已经加载的相同。如果不是,后卸载它。
功能信息
最低DLL版本 user32.dll
在Winuser.h中HeaderDeclared,头文件:winuser.h
import libraryUser32.lib
最低操作系统Windows 95,Windows NT 4.0
参见
键盘输入,ActivateKeyboardLayout,CreateThread,LoadKeyboardLayout,WM_INPUTLANGCHANGE
==英文原文==GetKeyboardLayout Function
The GetKeyboardLayout function retrieves the active input locale identifier (formerly called the keyboard layout) for the specified thread. If the idThread parameter is zero, the input locale identifier for the active thread is returned.
Syntax
HKL GetKeyboardLayout( DWORD idThread
);
Parameters
idThread
[in] Identifies the thread to query or is zero for the current thread.
Return Value
The return value is the input locale identifier for the thread. The low word contains a Language Identifier for the input language and the high word contains a device handle to the physical layout of the keyboard.
Remarks
The input locale identifier is a broader concept than a keyboard layout, since it can also encompass a speech-to-text converter, an Input Method Editor (IME), or any other form of input.
Since the keyboard layout can be dynamically changed, applications that cache information about the current keyboard layout should process the WM_INPUTLANGCHANGE message to be informed of changes in the input language.
To get the KLID (keyboard layout ID) of the currently active HKL, call the GetKeyboardLayoutName . To find out if a particular KLID is loaded, call GetKeyboardLayoutList , load the keyboard with LoadKeyboardLayout , and then check to see if the HKL is the same as the one already loaded. If not, unload it after.
Function Information
Minimum DLL Versionuser32.dll
HeaderDeclared in Winuser.h, include Windows.h
Import libraryUser32.lib
Minimum operating systemsWindows 95, Windows NT 4.0
See Also
Keyboard Input , ActivateKeyboardLayout , CreateThread , LoadKeyboardLayout , WM_INPUTLANGCHANGE
==原始网址==http://msdn.microsoft.com/en-us/library/ms646296(VS.85).aspx\n
随便看

 

windows api函数参考手册包含2258条windows api函数文档,详细介绍nodejs、java、rust调用windows api的方法技巧,是学习windows api编程的入门中文文档。

 

Copyright © 2004-2023 Winrtm.com All Rights Reserved
京ICP备2021023879号-40 更新时间:2024/10/6 11:26:21