ReactOS  0.4.15-dev-3723-g8d70159
kbdrost.c File Reference
#include <stdarg.h>
#include <windef.h>
#include <winuser.h>
#include <ndk/kbd.h>
#include "deadkeys/tilde"
#include "deadkeys/caron"
#include "deadkeys/circumflex"
#include "deadkeys/breve"
#include "deadkeys/ring_above"
#include "deadkeys/ogonek"
#include "deadkeys/grave_acc"
#include "deadkeys/dot_above"
#include "deadkeys/acute_acc"
#include "deadkeys/dbl_acute_acc"
#include "deadkeys/comma_below"
Include dependency graph for kbdrost.c:

Go to the source code of this file.

Macros

#define WIN32_NO_STATUS
 
#define ROSDATA   static __attribute__((section(".data")))
 
#define VK_EMPTY   0xff /* The non-existent VK */
 
#define KNUMS   KBDNUMPAD|KBDSPECIAL /* Special + number pad */
 
#define KMEXT   KBDEXT|KBDMULTIVK /* Multi + ext */
 
#define vk_master(n, x)   { (PVK_TO_WCHARS1)x, n, sizeof(x[0]) }
 
#define DEADTRANS(ch, accent, comp, flags)   MAKELONG(ch, accent), comp, flags
 

Functions

PKBDTABLES WINAPI KbdLayerDescriptor (VOID)
 

Variables

ROSDATA USHORT scancode_to_vk []
 
ROSDATA VSC_VK extcode0_to_vk []
 
ROSDATA VSC_VK extcode1_to_vk []
 
ROSDATA VK_TO_BIT modifier_keys []
 
ROSDATA MODIFIERS modifier_bits
 
ROSDATA VK_TO_WCHARS2 key_to_chars_2mod []
 
ROSDATA VK_TO_WCHARS3 key_to_chars_3mod []
 
ROSDATA VK_TO_WCHARS4 key_to_chars_4mod []
 
ROSDATA VK_TO_WCHARS5 key_to_chars_5mod []
 
ROSDATA VK_TO_WCHARS1 keypad_numbers []
 
ROSDATA VK_TO_WCHAR_TABLE vk_to_wchar_master_table []
 
ROSDATA VSC_LPWSTR key_names []
 
ROSDATA VSC_LPWSTR extended_key_names []
 
ROSDATA DEADKEY_LPWSTR dead_key_names []
 
ROSDATA DEADKEY dead_key []
 
ROSDATA KBDTABLES keyboard_layout_table
 

Macro Definition Documentation

◆ DEADTRANS

#define DEADTRANS (   ch,
  accent,
  comp,
  flags 
)    MAKELONG(ch, accent), comp, flags

Definition at line 422 of file kbdrost.c.

◆ KMEXT

#define KMEXT   KBDEXT|KBDMULTIVK /* Multi + ext */

Definition at line 51 of file kbdrost.c.

◆ KNUMS

#define KNUMS   KBDNUMPAD|KBDSPECIAL /* Special + number pad */

Definition at line 50 of file kbdrost.c.

◆ ROSDATA

#define ROSDATA   static __attribute__((section(".data")))

Definition at line 44 of file kbdrost.c.

◆ VK_EMPTY

#define VK_EMPTY   0xff /* The non-existent VK */

Definition at line 48 of file kbdrost.c.

◆ vk_master

#define vk_master (   n,
  x 
)    { (PVK_TO_WCHARS1)x, n, sizeof(x[0]) }

Definition at line 309 of file kbdrost.c.

◆ WIN32_NO_STATUS

#define WIN32_NO_STATUS

Definition at line 31 of file kbdrost.c.

Function Documentation

◆ KbdLayerDescriptor()

PKBDTABLES WINAPI KbdLayerDescriptor ( VOID  )

Definition at line 476 of file kbdrost.c.

477 {
478  return &keyboard_layout_table;
479 }
ROSDATA KBDTABLES keyboard_layout_table
Definition: kbdrost.c:446

Variable Documentation

◆ dead_key

ROSDATA DEADKEY dead_key[]

Definition at line 423 of file kbdrost.c.

◆ dead_key_names

ROSDATA DEADKEY_LPWSTR dead_key_names[]
Initial value:
=
{
L"\x0300" L"Accent grav",
L"\x0301" L"Accent acut",
L"\x0302" L"Circumflex",
L"\x0303" L"Tild\u0103",
L"\x0306" L"Breve",
L"\x0307" L"Suprapunct",
L"\x0308" L"Trem\u0103",
L"\x030A" L"Supracerc",
L"\x030B" L"Accent acut dublu",
L"\x030C" L"Caron",
L"\x0326" L"Virgul\u0103",
L"\x0327" L"Sedil\u0103",
L"\x0328" L"Ogonek",
}
#define L(x)
Definition: ntvdm.h:50
#define NULL
Definition: types.h:112

Definition at line 404 of file kbdrost.c.

◆ extcode0_to_vk

ROSDATA VSC_VK extcode0_to_vk[]

Definition at line 143 of file kbdrost.c.

◆ extcode1_to_vk

ROSDATA VSC_VK extcode1_to_vk[]
Initial value:
=
{
{ 0x1d, VK_PAUSE },
{ 0, 0 }
}
#define VK_PAUSE
Definition: winuser.h:2185

Definition at line 186 of file kbdrost.c.

◆ extended_key_names

ROSDATA VSC_LPWSTR extended_key_names[]
Initial value:
=
{
{ 0x1c, L"Intr. numerice" },
{ 0x1d, L"Control dreapta" },
{ 0x37, L"Imprimare" },
{ 0x38, L"Alt dreapta" },
{ 0x45, L"Fix. numerice" },
{ 0x46, L"\u00CEntrerupere" },
{ 0x47, L"Acas\u0103" },
{ 0x48, L"Sus" },
{ 0x49, L"Pag. sus" },
{ 0x4b, L"St\u00E2nga" },
{ 0x4c, L"Centru" },
{ 0x4d, L"Dreapta" },
{ 0x4f, L"Sf\u00E2r\u0219it" },
{ 0x50, L"Jos" },
{ 0x51, L"Pag. jos" },
{ 0x52, L"Inser\u021Bie" },
{ 0x53, L"\u0218tergere" },
{ 0x54, L"Meniu" },
{ 0x56, L"Ajutor" },
{ 0x5b, L"Meniu st\u00E2nga" },
{ 0x5c, L"Meniu dreapta" },
{ 0, NULL }
}
#define L(x)
Definition: ntvdm.h:50
#define NULL
Definition: types.h:112

Definition at line 378 of file kbdrost.c.

◆ key_names

ROSDATA VSC_LPWSTR key_names[]

Definition at line 320 of file kbdrost.c.

◆ key_to_chars_2mod

ROSDATA VK_TO_WCHARS2 key_to_chars_2mod[]

Definition at line 208 of file kbdrost.c.

◆ key_to_chars_3mod

ROSDATA VK_TO_WCHARS3 key_to_chars_3mod[]
Initial value:
=
{
{ VK_OEM_102, 0, {'\\','|', 0x1c } },
{ VK_BACK, 0, {0x8, 0x8, 0x7F } },
{ VK_ESCAPE, 0, {0x1b,0x1b,0x1b } },
{ VK_RETURN, 0, {'\r','\r','\n'} },
{ VK_SPACE, 0, {' ', ' ', ' '} },
{ VK_CANCEL, 0, {0x3, 0x3, 0x3} },
{ 0, 0 }
}
#define VK_ESCAPE
Definition: winuser.h:2194
#define VK_RETURN
Definition: winuser.h:2181
#define VK_CANCEL
Definition: winuser.h:2172
#define VK_BACK
Definition: winuser.h:2178
#define VK_SPACE
Definition: winuser.h:2199

Definition at line 245 of file kbdrost.c.

◆ key_to_chars_4mod

ROSDATA VK_TO_WCHARS4 key_to_chars_4mod[]
Initial value:
=
{
{ '1', 0, {'1', '!', WCH_NONE, 0x0303 } },
{ '2', 0, {'2', '@', WCH_NONE, 0x030C } },
{ '3', 0, {'3', '#', WCH_NONE, 0x0302 } },
{ '4', 0, {'4', '$', WCH_NONE, 0x0306 } },
{ '5', 0, {'5', '%', WCH_NONE, 0x030A } },
{ '6', 0, {'6', '^', WCH_NONE, 0x0328 } },
{ '7', 0, {'7', '&', WCH_NONE, 0x0300 } },
{ '8', 0, {'8', '*', WCH_NONE, 0x0307 } },
{ '9', 0, {'9', '(', WCH_NONE, 0x0301 } },
{ '0', 0, {'0', ')', WCH_NONE, 0x030B } },
{ 'Q', CAPLOK, {'q', 'Q', WCH_NONE, 0x0326 } },
{ 'E', CAPLOK, {'e', 'E', WCH_NONE, 0x20AC } },
{ 'P', CAPLOK, {'p', 'P', WCH_NONE, 0x00A7 } },
{ 'S', CAPLOK, {'s', 'S', WCH_NONE, 0x00DF } },
{ 0, 0 }
}
#define CAPLOK
Definition: kbd.h:118
#define WCH_NONE
Definition: kbd.h:113

Definition at line 257 of file kbdrost.c.

◆ key_to_chars_5mod

ROSDATA VK_TO_WCHARS5 key_to_chars_5mod[]
Initial value:
=
{
{ VK_OEM_3, 0, {0x201E , 0x201D , WCH_NONE, '`', '~' } },
{ VK_OEM_MINUS, 0, {'-', '_', WCH_NONE, 0x0308 , 0x2013 } },
{ VK_OEM_PLUS, 0, {'=', '+', WCH_NONE, 0x0327 , 0x00B1 } },
{ VK_OEM_4, CAPLOK, {0x0103 , 0x0102 , 0x1b , '[', '{' } },
{ VK_OEM_6, CAPLOK, {0x00ee , 0x00ce , 0x1d , ']', '}' } },
{ 'D', CAPLOK, {'d', 'D', WCH_NONE, 0x0111 , 0x0110 } },
{ 'L', CAPLOK, {'l', 'L', WCH_NONE, 0x0142 , 0x0141 } },
{ VK_OEM_1, CAPLOK, {0x0219 , 0x0218 , WCH_NONE, ';', ':' } },
{ VK_OEM_7, CAPLOK, {0x021B , 0x021A , WCH_NONE, '\'', '"' } },
{ VK_OEM_5, CAPLOK, {0x00e2 , 0x00c2 , 0x1c , '\\', '|' } },
{ VK_OEM_COMMA, 0, {',', ';', WCH_NONE, '<', 0x00AB } },
{ VK_OEM_PERIOD, 0, {'.', ':', WCH_NONE, '>', 0x00BB } },
{ 0, 0 }
}
#define VK_OEM_5
Definition: winuser.h:2298
#define CAPLOK
Definition: kbd.h:118
#define WCH_NONE
Definition: kbd.h:113
#define VK_OEM_4
Definition: winuser.h:2297
#define VK_OEM_6
Definition: winuser.h:2299
#define VK_OEM_7
Definition: winuser.h:2300
#define VK_OEM_3
Definition: winuser.h:2296
#define VK_OEM_1
Definition: winuser.h:2288

Definition at line 276 of file kbdrost.c.

◆ keyboard_layout_table

ROSDATA KBDTABLES keyboard_layout_table
Initial value:
=
{
sizeof(scancode_to_vk) / sizeof(scancode_to_vk[0]),
0,
0,
}
ROSDATA DEADKEY_LPWSTR dead_key_names[]
Definition: kbdrost.c:404
ROSDATA MODIFIERS modifier_bits
Definition: kbdrost.c:200
ROSDATA VK_TO_WCHAR_TABLE vk_to_wchar_master_table[]
Definition: kbdrost.c:310
#define KLLF_ALTGR
Definition: kbd.h:91
#define MAKELONG(a, b)
Definition: typedefs.h:249
ROSDATA DEADKEY dead_key[]
Definition: kbdrost.c:423
ROSDATA VSC_LPWSTR key_names[]
Definition: kbdrost.c:320
ROSDATA VSC_VK extcode0_to_vk[]
Definition: kbdrost.c:143
ROSDATA VSC_VK extcode1_to_vk[]
Definition: kbdrost.c:186
ROSDATA VSC_LPWSTR extended_key_names[]
Definition: kbdrost.c:378
#define NULL
Definition: types.h:112
ROSDATA USHORT scancode_to_vk[]
Definition: kbdrost.c:53

Definition at line 446 of file kbdrost.c.

Referenced by KbdLayerDescriptor().

◆ keypad_numbers

ROSDATA VK_TO_WCHARS1 keypad_numbers[]
Initial value:
=
{
{ VK_NUMPAD0, 0, {'0'} },
{ VK_NUMPAD1, 0, {'1'} },
{ VK_NUMPAD2, 0, {'2'} },
{ VK_NUMPAD3, 0, {'3'} },
{ VK_NUMPAD4, 0, {'4'} },
{ VK_NUMPAD5, 0, {'5'} },
{ VK_NUMPAD6, 0, {'6'} },
{ VK_NUMPAD7, 0, {'7'} },
{ VK_NUMPAD8, 0, {'8'} },
{ VK_NUMPAD9, 0, {'9'} },
{ VK_DECIMAL, 0, {','} },
{ 0, 0 }
}
#define VK_NUMPAD8
Definition: winuser.h:2227
#define VK_NUMPAD0
Definition: winuser.h:2219
#define VK_NUMPAD6
Definition: winuser.h:2225
#define VK_NUMPAD5
Definition: winuser.h:2224
#define VK_DECIMAL
Definition: winuser.h:2233
#define VK_NUMPAD9
Definition: winuser.h:2228
#define VK_NUMPAD3
Definition: winuser.h:2222
#define VK_NUMPAD4
Definition: winuser.h:2223
#define VK_NUMPAD7
Definition: winuser.h:2226
#define VK_NUMPAD2
Definition: winuser.h:2221
#define VK_NUMPAD1
Definition: winuser.h:2220

Definition at line 293 of file kbdrost.c.

◆ modifier_bits

ROSDATA MODIFIERS modifier_bits
Initial value:
=
{
7,
{ 0, 1, 2, SHFT_INVALID, SHFT_INVALID, SHFT_INVALID, 3, 4 }
}
#define SHFT_INVALID
Definition: kbd.h:19
ROSDATA VK_TO_BIT modifier_keys[]
Definition: kbdrost.c:192

Definition at line 200 of file kbdrost.c.

◆ modifier_keys

ROSDATA VK_TO_BIT modifier_keys[]
Initial value:
=
{
{ 0, 0 }
}
#define KBDCTRL
Definition: kbd.h:15
#define KBDSHIFT
Definition: kbd.h:14
#define VK_MENU
Definition: winuser.h:2184
#define VK_SHIFT
Definition: winuser.h:2182
#define KBDALT
Definition: kbd.h:16
#define VK_CONTROL
Definition: winuser.h:2183

Definition at line 192 of file kbdrost.c.

◆ scancode_to_vk

ROSDATA USHORT scancode_to_vk[]

Definition at line 53 of file kbdrost.c.

◆ vk_to_wchar_master_table

ROSDATA VK_TO_WCHAR_TABLE vk_to_wchar_master_table[]
Initial value:
=
{
{ 0, 0, 0 }
}
ROSDATA VK_TO_WCHARS1 keypad_numbers[]
Definition: kbdrost.c:293
ROSDATA VK_TO_WCHARS3 key_to_chars_3mod[]
Definition: kbdrost.c:245
ROSDATA VK_TO_WCHARS5 key_to_chars_5mod[]
Definition: kbdrost.c:276
ROSDATA VK_TO_WCHARS4 key_to_chars_4mod[]
Definition: kbdrost.c:257
#define vk_master(n, x)
Definition: kbdrost.c:309
ROSDATA VK_TO_WCHARS2 key_to_chars_2mod[]
Definition: kbdrost.c:208

Definition at line 310 of file kbdrost.c.