From 33a465d81dbe7d8f0f9bbee4a5aa03f0ba0b3e87 Mon Sep 17 00:00:00 2001 From: Siarhei Vishniakou Date: Thu, 15 Mar 2018 11:27:18 -0700 Subject: [PATCH] Add Polish keycharactermap Add Polish .kcm layout file. This will be used for connecting a physical keyboard for Android and typing in Polish. Bug: 13938356 Test: connect a keyboard to Pixel phone via OTG connector. Open Google search and select "Polish" keyboard layout, type with keyboard. Change-Id: I74bfc2bba7ca8b82b0de0202dbfc05d935b27c38 Signed-off-by: Siarhei Vishniakou --- .../res/raw/keyboard_layout_polish.kcm | 327 +++++++++++++++++++++ packages/InputDevices/res/values/strings.xml | 3 + packages/InputDevices/res/xml/keyboard_layouts.xml | 4 + 3 files changed, 334 insertions(+) create mode 100644 packages/InputDevices/res/raw/keyboard_layout_polish.kcm diff --git a/packages/InputDevices/res/raw/keyboard_layout_polish.kcm b/packages/InputDevices/res/raw/keyboard_layout_polish.kcm new file mode 100644 index 000000000000..559ec07705b2 --- /dev/null +++ b/packages/InputDevices/res/raw/keyboard_layout_polish.kcm @@ -0,0 +1,327 @@ +# Copyright (C) 2018 The Android Open Source Project +# +# Licensed under the Apache License, Version 2.0 (the "License"); +# you may not use this file except in compliance with the License. +# You may obtain a copy of the License at +# +# http://www.apache.org/licenses/LICENSE-2.0 +# +# Unless required by applicable law or agreed to in writing, software +# distributed under the License is distributed on an "AS IS" BASIS, +# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +# See the License for the specific language governing permissions and +# limitations under the License. + +# +# Polish (qwerty) keyboard layout. +# + +type OVERLAY + +### ROW 1 + +key GRAVE { + label: '`' + base: '`' + shift: '~' +} + +key 1 { + label: '1' + base: '1' + shift: '!' +} + +key 2 { + label: '2' + base: '2' + shift: '@' +} + +key 3 { + label: '3' + base: '3' + shift: '#' +} + +key 4 { + label: '4' + base: '4' + shift: '$' +} + +key 5 { + label: '5' + base: '5' + shift: '%' +} + +key 6 { + label: '6' + base: '6' + shift: '^' +} + +key 7 { + label: '7' + base: '7' + shift: '&' +} + +key 8 { + label: '8' + base: '8' + shift: '*' +} + +key 9 { + label: '9' + base: '9' + shift: '(' +} + +key 0 { + label: '0' + base: '0' + shift: ')' +} + +key MINUS { + label: '-' + base: '-' + shift: '_' +} + +key EQUALS { + label: '=' + base: '=' + shift: '+' +} + +### ROW 2 + +key Q { + label: 'Q' + base: 'q' + shift, capslock: 'Q' +} + +key W { + label: 'W' + base: 'w' + shift, capslock: 'W' +} + +key E { + label: 'E' + base: 'e' + shift, capslock: 'E' + ralt: '\u0119' + ralt+shift, ralt+capslock: '\u0118' +} + +key R { + label: 'R' + base: 'r' + shift, capslock: 'R' +} + +key T { + label: 'T' + base: 't' + shift, capslock: 'T' +} + +key Y { + label: 'Y' + base: 'y' + shift, capslock: 'Y' +} + +key U { + label: 'U' + base: 'u' + shift, capslock: 'U' +} + +key I { + label: 'I' + base: 'i' + shift, capslock: 'I' +} + +key O { + label: 'O' + base: 'o' + shift, capslock: 'O' + ralt: '\u00F3' + ralt+shift, ralt+capslock: '\u00D3' +} + +key P { + label: 'P' + base: 'p' + shift, capslock: 'P' +} + +key LEFT_BRACKET { + label: '[' + base: '[' + shift: '{' +} + +key RIGHT_BRACKET { + label: ']' + base: ']' + shift: '}' +} + +key BACKSLASH { + label: '\\' + base: '\\' + shift: '|' +} + +### ROW 3 + +key A { + label: 'A' + base: 'a' + shift, capslock: 'A' + ralt: '\u0105' + ralt+shift, ralt+capslock: '\u0104' +} + +key S { + label: 'S' + base: 's' + shift, capslock: 'S' + ralt: '\u015b' + ralt+shift, ralt+capslock: '\u015a' +} + +key D { + label: 'D' + base: 'd' + shift, capslock: 'D' +} + +key F { + label: 'F' + base: 'f' + shift, capslock: 'F' +} + +key G { + label: 'G' + base: 'g' + shift, capslock: 'G' +} + +key H { + label: 'H' + base: 'h' + shift, capslock: 'H' +} + +key J { + label: 'J' + base: 'j' + shift, capslock: 'J' +} + +key K { + label: 'K' + base: 'k' + shift, capslock: 'K' +} + +key L { + label: 'L' + base: 'l' + shift, capslock: 'L' + ralt: '\u0142' + ralt+shift, ralt+capslock: '\u0141' +} + +key SEMICOLON { + label: ';' + base: ';' + shift: ':' +} + +key APOSTROPHE { + label: '\'' + base: '\'' + shift: '"' +} + +### ROW 4 + +key Z { + label: 'Z' + base: 'z' + shift, capslock: 'Z' + ralt: '\u017c' + ralt+shift, ralt+capslock: '\u017b' +} + +key X { + label: 'X' + base: 'x' + shift, capslock: 'X' + ralt: '\u017a' + ralt+shift, ralt+capslock: '\u0179' +} + +key C { + label: 'C' + base: 'c' + shift, capslock: 'C' + ralt: '\u0107' + ralt+shift, ralt+capslock: '\u0106' +} + +key V { + label: 'V' + base: 'v' + shift, capslock: 'V' +} + +key B { + label: 'B' + base: 'b' + shift, capslock: 'B' +} + +key N { + label: 'N' + base: 'n' + shift, capslock: 'N' + ralt: '\u0144' + ralt+shift, ralt+capslock: '\u0143' +} + +key M { + label: 'M' + base: 'm' + shift, capslock: 'M' +} + +key COMMA { + label: ',' + base: ',' + shift: '<' +} + +key PERIOD { + label: '.' + base: '.' + shift: '>' +} + +key SLASH { + label: '/' + base: '/' + shift: '?' +} diff --git a/packages/InputDevices/res/values/strings.xml b/packages/InputDevices/res/values/strings.xml index 61d3234a1f44..5fdc4a6a4505 100644 --- a/packages/InputDevices/res/values/strings.xml +++ b/packages/InputDevices/res/values/strings.xml @@ -125,4 +125,7 @@ Azerbaijani + + + Polish diff --git a/packages/InputDevices/res/xml/keyboard_layouts.xml b/packages/InputDevices/res/xml/keyboard_layouts.xml index c6bfc1f65be2..1807aeae0da3 100644 --- a/packages/InputDevices/res/xml/keyboard_layouts.xml +++ b/packages/InputDevices/res/xml/keyboard_layouts.xml @@ -159,4 +159,8 @@ + + -- 2.11.0