en:docs:fapi:kbdopen

Differences

This shows you the differences between two versions of the page.

Link to this comparison view

Next revision
Previous revision
en:docs:fapi:kbdopen [2021/10/06 11:57] – created prokusheven:docs:fapi:kbdopen [2021/11/04 13:27] (current) prokushev
Line 1: Line 1:
 +{{page>en:templates:fapiint}}
 +
 +====== KbdOpen ======
 + 
 This call creates a new logical keyboard. This call creates a new logical keyboard.
  
-==Syntax==+===== Syntax ===== 
 +<code c>
  KbdOpen (KbdHandle)  KbdOpen (KbdHandle)
 +</code>
  
-==Parameters== +===== Parameters =====
-;KbdHandle (PHKBD) - output : Address of the logical keyboard.+
  
-==Return Code== +  * KbdHandle (PHKBD) - output : Address of the logical keyboard. 
-;rc (USHORT) - return:Return code descriptions are: + 
-* 0  NO_ERROR +===== Return Code ===== 
-*440 ERROR_KBD_NO_MORE_HANDLE + 
-*441 ERROR_KBD_CANNOT_CREATE_KCB +rc (USHORT) - return:Return code descriptions are: 
-*464 ERROR_KBD_DETACHED + 
-*504 ERROR_KBD_EXTENDED_SG+  * 0  NO_ERROR 
 +  *440 ERROR_KBD_NO_MORE_HANDLE 
 +  *441 ERROR_KBD_CANNOT_CREATE_KCB 
 +  *464 ERROR_KBD_DETACHED 
 +  *504 ERROR_KBD_EXTENDED_SG 
 + 
 +===== Remarks =====
  
-==Remarks== 
 KbdOpen blocks while another thread has the keyboard focus (by way of [[KbdGetFocus]]) until the thread with the focus issues [[KbdFreeFocus]]. Therefore, to prevent KbdOpen from blocking, it is recommended that KbdOpen be issued only while the current thread has the focus. For example: KbdOpen blocks while another thread has the keyboard focus (by way of [[KbdGetFocus]]) until the thread with the focus issues [[KbdFreeFocus]]. Therefore, to prevent KbdOpen from blocking, it is recommended that KbdOpen be issued only while the current thread has the focus. For example:
  
-;KbdGetFocus : wait until focus available on handle 0 +  KbdGetFocus : wait until focus available on handle 0 
-;KbdOpen : get a logical keyboard handle +  KbdOpen : get a logical keyboard handle 
-;KbdOpen : get another logical keyboard handle +  KbdOpen : get another logical keyboard handle 
-;KbdOpen : get yet another logical keyboard handle +  KbdOpen : get yet another logical keyboard handle 
-;KbdFreeFocus : give up the focus on handle 0.+  KbdFreeFocus : give up the focus on handle 0. 
 + 
 +===== Bindings =====
  
-==Bindings== +==== ==== 
-=== C === +<code c>
-<PRE>+
 #define INCL_KBD #define INCL_KBD
  
Line 33: Line 44:
  
 USHORT  rc;            /* return code */ USHORT  rc;            /* return code */
-</PRE>+</code>
  
-===MASM=== +====MASM==== 
-<PRE>+<code asm>
 EXTRN  KbdOpen:FAR EXTRN  KbdOpen:FAR
 INCL_KBD            EQU 1 INCL_KBD            EQU 1
Line 44: Line 55:
  
 Returns WORD Returns WORD
-</PRE>+</code>
  
-[[Category:Kbd]]+{{page>en:templates:fapi}}