9#include "keyboard_virtual_key_intf.hpp"
10#include "keyboard_modifiers.hpp"
11#include "../macros.hpp"
13hi_export_module(hikogui.GUI : keyboard_virtual_key_impl);
15hi_export
namespace hi::inline
v1 {
17[[nodiscard]]
constexpr keyboard_virtual_key to_keyboard_virtual_key(
int key_code,
bool extended, keyboard_modifiers modifiers)
noexcept
21 return keyboard_virtual_key::menu;
23 return keyboard_virtual_key::backspace;
25 return keyboard_virtual_key::tab;
27 return keyboard_virtual_key::clear;
29 return keyboard_virtual_key::enter;
31 return keyboard_virtual_key::pause_break;
33 return keyboard_virtual_key::escape;
35 return keyboard_virtual_key::space;
37 return keyboard_virtual_key::page_up;
39 return keyboard_virtual_key::page_down;
41 return keyboard_virtual_key::end;
43 return keyboard_virtual_key::home;
45 return keyboard_virtual_key::left;
47 return keyboard_virtual_key::up;
49 return keyboard_virtual_key::right;
51 return keyboard_virtual_key::down;
53 return keyboard_virtual_key::print_screen;
55 return keyboard_virtual_key::print_screen;
57 return keyboard_virtual_key::insert;
59 return keyboard_virtual_key::_delete;
61 return keyboard_virtual_key::_0;
63 return keyboard_virtual_key::_1;
65 return keyboard_virtual_key::_2;
67 return keyboard_virtual_key::_3;
69 return keyboard_virtual_key::_4;
71 return keyboard_virtual_key::_5;
73 return keyboard_virtual_key::_6;
75 return keyboard_virtual_key::_7;
77 return keyboard_virtual_key::_8;
79 return keyboard_virtual_key::_9;
81 return keyboard_virtual_key::A;
83 return keyboard_virtual_key::B;
85 return keyboard_virtual_key::C;
87 return keyboard_virtual_key::D;
89 return keyboard_virtual_key::E;
91 return keyboard_virtual_key::F;
93 return keyboard_virtual_key::G;
95 return keyboard_virtual_key::H;
97 return keyboard_virtual_key::I;
99 return keyboard_virtual_key::J;
101 return keyboard_virtual_key::K;
103 return keyboard_virtual_key::L;
105 return keyboard_virtual_key::M;
107 return keyboard_virtual_key::N;
109 return keyboard_virtual_key::O;
111 return keyboard_virtual_key::P;
113 return keyboard_virtual_key::Q;
115 return keyboard_virtual_key::R;
117 return keyboard_virtual_key::S;
119 return keyboard_virtual_key::T;
121 return keyboard_virtual_key::U;
123 return keyboard_virtual_key::V;
125 return keyboard_virtual_key::W;
127 return keyboard_virtual_key::X;
129 return keyboard_virtual_key::Y;
131 return keyboard_virtual_key::Z;
133 return keyboard_virtual_key::_0;
135 return keyboard_virtual_key::_1;
137 return keyboard_virtual_key::_2;
139 return keyboard_virtual_key::_3;
141 return keyboard_virtual_key::_4;
143 return keyboard_virtual_key::_5;
145 return keyboard_virtual_key::_6;
147 return keyboard_virtual_key::_7;
149 return keyboard_virtual_key::_8;
151 return keyboard_virtual_key::_9;
153 return keyboard_virtual_key::star;
155 return keyboard_virtual_key::plus;
157 return keyboard_virtual_key::minus;
159 return keyboard_virtual_key::period;
161 return keyboard_virtual_key::slash;
163 return keyboard_virtual_key::F1;
165 return keyboard_virtual_key::F2;
167 return keyboard_virtual_key::F3;
169 return keyboard_virtual_key::F4;
171 return keyboard_virtual_key::F5;
173 return keyboard_virtual_key::F6;
175 return keyboard_virtual_key::F7;
177 return keyboard_virtual_key::F8;
179 return keyboard_virtual_key::F9;
181 return keyboard_virtual_key::F10;
183 return keyboard_virtual_key::F11;
185 return keyboard_virtual_key::F12;
187 return keyboard_virtual_key::F13;
189 return keyboard_virtual_key::F14;
191 return keyboard_virtual_key::F15;
193 return keyboard_virtual_key::F16;
195 return keyboard_virtual_key::F17;
197 return keyboard_virtual_key::F18;
199 return keyboard_virtual_key::F19;
201 return keyboard_virtual_key::F20;
203 return keyboard_virtual_key::F21;
205 return keyboard_virtual_key::F22;
207 return keyboard_virtual_key::F23;
209 return keyboard_virtual_key::F24;
210 case VK_BROWSER_BACK:
211 return keyboard_virtual_key::browser_back;
212 case VK_BROWSER_FORWARD:
213 return keyboard_virtual_key::browser_forward;
214 case VK_BROWSER_REFRESH:
215 return keyboard_virtual_key::browser_refresh;
216 case VK_BROWSER_STOP:
217 return keyboard_virtual_key::browser_stop;
218 case VK_BROWSER_SEARCH:
219 return keyboard_virtual_key::browser_search;
220 case VK_BROWSER_FAVORITES:
221 return keyboard_virtual_key::browser_favorites;
222 case VK_BROWSER_HOME:
223 return keyboard_virtual_key::browser_home;
225 return keyboard_virtual_key::volume_mute;
227 return keyboard_virtual_key::volume_down;
229 return keyboard_virtual_key::volume_up;
230 case VK_MEDIA_NEXT_TRACK:
231 return keyboard_virtual_key::media_next_track;
232 case VK_MEDIA_PREV_TRACK:
233 return keyboard_virtual_key::media_prev_track;
235 return keyboard_virtual_key::media_stop;
236 case VK_MEDIA_PLAY_PAUSE:
237 return keyboard_virtual_key::media_play_pause;
239 return to_bool(modifiers & keyboard_modifiers::shift) ? keyboard_virtual_key::colon : keyboard_virtual_key::semi_colon;
241 return keyboard_virtual_key::plus;
243 return keyboard_virtual_key::comma;
245 return keyboard_virtual_key::minus;
247 return keyboard_virtual_key::period;
249 return to_bool(modifiers & keyboard_modifiers::shift) ? keyboard_virtual_key::question : keyboard_virtual_key::slash;
251 return to_bool(modifiers & keyboard_modifiers::shift) ? keyboard_virtual_key::tilde : keyboard_virtual_key::backtick;
253 return to_bool(modifiers & keyboard_modifiers::shift) ? keyboard_virtual_key::open_brace :
254 keyboard_virtual_key::open_bracket;
256 return to_bool(modifiers & keyboard_modifiers::shift) ? keyboard_virtual_key::pipe : keyboard_virtual_key::backslash;
258 return to_bool(modifiers & keyboard_modifiers::shift) ? keyboard_virtual_key::close_brace :
259 keyboard_virtual_key::close_bracket;
261 return to_bool(modifiers & keyboard_modifiers::shift) ? keyboard_virtual_key::double_quote : keyboard_virtual_key::quote;
263 return keyboard_virtual_key::media_play_pause;
265 return keyboard_virtual_key::clear;
267 return keyboard_virtual_key::nul;
Rules for working with win32 headers.
DOXYGEN BUG.
Definition algorithm_misc.hpp:20