keymap_jis2us.h 2.2 KB

12345678910111213141516171819202122232425262728293031323334353637383940414243444546474849
  1. /* Copyright 2020 shela
  2. *
  3. * This program is free software: you can redistribute it and/or modify
  4. * it under the terms of the GNU General Public License as published by
  5. * the Free Software Foundation, either version 2 of the License, or
  6. * (at your option) any later version.
  7. *
  8. * This program is distributed in the hope that it will be useful,
  9. * but WITHOUT ANY WARRANTY; without even the implied warranty of
  10. * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
  11. * GNU General Public License for more details.
  12. *
  13. * You should have received a copy of the GNU General Public License
  14. * along with this program. If not, see <http://www.gnu.org/licenses/>.
  15. */
  16. #pragma once
  17. #include "keymap_jp.h"
  18. // clang-format off
  19. /* Keymap for converting JIS to US */
  20. const uint16_t PROGMEM keymap_jis2us[][2] = {
  21. [KC_A ... KC_CAPS] = { 0x00, 0x00 }, /* default value */
  22. [KC_1] = { KC_1, JP_EXLM }, /* 1 and ! -> 1 and ! */
  23. [KC_2] = { KC_2, JP_AT }, /* 2 and " -> 2 and @ */
  24. [KC_3] = { KC_3, JP_HASH }, /* 3 and # -> 3 and # */
  25. [KC_4] = { KC_4, JP_DLR }, /* 4 and $ -> 4 and $ */
  26. [KC_5] = { KC_5, JP_PERC }, /* 5 and % -> 5 and % */
  27. [KC_6] = { KC_6, JP_CIRC }, /* 6 and & -> 6 and ^ */
  28. [KC_7] = { KC_7, JP_AMPR }, /* 7 and ' -> 7 and & */
  29. [KC_8] = { KC_8, JP_ASTR }, /* 8 and ( -> 8 and * */
  30. [KC_9] = { KC_9, JP_LPRN }, /* 9 and ) -> 9 and ( */
  31. [KC_0] = { KC_0, JP_RPRN }, /* 0 -> 0 and ) */
  32. [KC_MINS] = { JP_MINS, JP_UNDS }, /* - and = -> - and _ */
  33. [KC_EQL] = { JP_EQL, JP_PLUS }, /* ^ and ~ -> = and + */
  34. [KC_LBRC] = { JP_LBRC, JP_LCBR }, /* @ and ` -> [ and { */
  35. [KC_RBRC] = { JP_RBRC, JP_RCBR }, /* [ and { -> ] and } */
  36. [KC_BSLS] = { JP_YEN, JP_PIPE }, /* ] and } -> \ and | */
  37. [KC_NUHS] = { JP_YEN, JP_PIPE }, /* ] and } -> \ and | */
  38. [KC_SCLN] = { JP_SCLN, JP_COLN }, /* ; and + -> ; and : */
  39. [KC_QUOT] = { JP_QUOT, JP_DQUO }, /* : and * -> ' and " */
  40. [KC_GRV] = { JP_GRV, JP_TILD }, /* Han/Zen -> ` and ~ */
  41. [KC_COMM] = { JP_COMM, JP_LABK }, /* , and < -> , and < */
  42. [KC_DOT] = { JP_DOT, JP_RABK }, /* . and > -> . and > */
  43. [KC_SLSH] = { JP_SLSH, JP_QUES }, /* / and ? -> / and ? */
  44. };
  45. // clang-format on