DOSBox-X
 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator
include/keyboard.h
00001 /*
00002  *  Copyright (C) 2002-2013  The DOSBox Team
00003  *
00004  *  This program is free software; you can redistribute it and/or modify
00005  *  it under the terms of the GNU General Public License as published by
00006  *  the Free Software Foundation; either version 2 of the License, or
00007  *  (at your option) any later version.
00008  *
00009  *  This program is distributed in the hope that it will be useful,
00010  *  but WITHOUT ANY WARRANTY; without even the implied warranty of
00011  *  MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
00012  *  GNU General Public License for more details.
00013  *
00014  *  You should have received a copy of the GNU General Public License
00015  *  along with this program; if not, write to the Free Software
00016  *  Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA.
00017  */
00018 
00019 #ifndef DOSBOX_KEYBOARD_H
00020 #define DOSBOX_KEYBOARD_H
00021 
00022 enum KBD_KEYS {
00023         KBD_NONE,
00024         KBD_1,  KBD_2,  KBD_3,  KBD_4,  KBD_5,  KBD_6,  KBD_7,  KBD_8,  KBD_9,  KBD_0,          
00025         KBD_q,  KBD_w,  KBD_e,  KBD_r,  KBD_t,  KBD_y,  KBD_u,  KBD_i,  KBD_o,  KBD_p,  
00026         KBD_a,  KBD_s,  KBD_d,  KBD_f,  KBD_g,  KBD_h,  KBD_j,  KBD_k,  KBD_l,  KBD_z,
00027         KBD_x,  KBD_c,  KBD_v,  KBD_b,  KBD_n,  KBD_m,  
00028         KBD_f1, KBD_f2, KBD_f3, KBD_f4, KBD_f5, KBD_f6, KBD_f7, KBD_f8, KBD_f9, KBD_f10,KBD_f11,KBD_f12,
00029         
00030         /*Now the weirder keys */
00031 
00032         KBD_esc,KBD_tab,KBD_backspace,KBD_enter,KBD_space,
00033         KBD_leftalt,KBD_rightalt,KBD_leftctrl,KBD_rightctrl,KBD_leftshift,KBD_rightshift,
00034         KBD_capslock,KBD_scrolllock,KBD_numlock,
00035         
00036         KBD_grave,KBD_minus,KBD_equals,KBD_backslash,KBD_leftbracket,KBD_rightbracket,
00037         KBD_semicolon,KBD_quote,KBD_period,KBD_comma,KBD_slash,KBD_extra_lt_gt,
00038 
00039         KBD_printscreen,KBD_pause,
00040         KBD_insert,KBD_home,KBD_pageup,KBD_delete,KBD_end,KBD_pagedown,
00041         KBD_left,KBD_up,KBD_down,KBD_right,
00042 
00043         KBD_kp1,KBD_kp2,KBD_kp3,KBD_kp4,KBD_kp5,KBD_kp6,KBD_kp7,KBD_kp8,KBD_kp9,KBD_kp0,
00044         KBD_kpdivide,KBD_kpmultiply,KBD_kpminus,KBD_kpplus,KBD_kpenter,KBD_kpperiod,
00045 
00046         /* Windows 95 keys */
00047         KBD_lwindows,KBD_rwindows,KBD_rwinmenu,
00048 
00049         /* other bindings */
00050         KBD_kpequals,
00051 
00052         /* F13-F24 */
00053         KBD_f13,KBD_f14,KBD_f15,KBD_f16,
00054         KBD_f17,KBD_f18,KBD_f19,KBD_f20,
00055         KBD_f21,KBD_f22,KBD_f23,KBD_f24,
00056 
00057         /* Japanese [see http://www.stanford.edu/class/cs140/projects/pintos/specs/kbd/scancodes-7.html] */
00058         KBD_jp_hankaku,         /* Hankaku/zenkaku (half-width/full-width) */
00059         KBD_jp_muhenkan,        /* Muhenkan (No conversion from kana to kanji) */
00060         KBD_jp_henkan,          /* Henkan/zenkouho (Conversion from kana to kanji, shifted: previous candidate, alt: all candidates) */
00061         KBD_jp_hiragana,        /* Hiragana/Katakana (Hiragana, shifted: Katakana, alt: romaji) */
00062 
00063         /* Korean */
00064         KBD_kor_hancha,         /* Hancha */
00065         KBD_kor_hanyong,        /* Han/yong */
00066 
00067         /* for Japanese A01 (106) key [http://www.mediafire.com/download/t968ydz6ky92myl/dosbox74.zip] */
00068         /* see reference image [https://upload.wikimedia.org/wikipedia/commons/thumb/b/bc/KB_Japanese.svg/1280px-KB_Japanese.svg.png] */
00069         KBD_jp_yen, KBD_jp_backslash, KBD_colon, KBD_caret, KBD_atsign, KBD_jp_ro, KBD_help, KBD_kpcomma,
00070     KBD_stop, KBD_copy, KBD_vf1, KBD_vf2, KBD_vf3, KBD_vf4, KBD_vf5, KBD_kana,
00071     KBD_nfer, KBD_xfer,
00072 
00073         KBD_LAST
00074 };
00075 
00076 void KEYBOARD_ClrBuffer(void);
00077 void KEYBOARD_AddKey(KBD_KEYS keytype,bool pressed);
00078 size_t KEYBOARD_BufferSpaceAvail();  // emendelson from dbDOS
00079 
00080 #endif