diff --git a/data/keyboards/br.yaml b/data/keyboards/br.yaml index eb06ec5f..42cf66a6 100644 --- a/data/keyboards/br.yaml +++ b/data/keyboards/br.yaml @@ -1,34 +1,39 @@ --- outlines: - default: { width: 35.33, height: 52 } - altline: { width: 52.67, height: 52 } - wide: { width: 62, height: 52 } - change-view: { width: 52.67, height: 52 } - change-view-2: { width: 62, height: 52 } - spaceline: { width: 142, height: 52 } - special: { width: 44, height: 52 } + default: { width: 35.67, height: 52 } + altline: { width: 53, height: 52 } + wide: { width: 53, height: 52 } + change-view: { width: 53, height: 52 } + spaceline: { width: 90, height: 52 } + special: { width: 35.67, height: 52 } + large: { width: 71.34, height: 52 } views: base: - "q w e r t y u i o p" - "a s d f g h j k l ç" - "Shift_L z x c v b n m BackSpace" - - "show_numbers preferences space , Return" + - "show_numbers show_eschars preferences space .-large Return" upper: - "Q W E R T Y U I O P" - "A S D F G H J K L Ç" - "Shift_L Z X C V B N M BackSpace" - - "show_numbers preferences space . Return" + - "show_numbers show_eschars preferences space ,-large Return" numbers: - "1 2 3 4 5 6 7 8 9 0" - - "à À á Á ã Ã â Â é É" - - "show_symbols ê Ê í Í ó Ó ô Ô" - - "show_letters õ Õ ú Ú ü Ü . BackSpace" + - "@ # $ % & - _ + ( )" + - "show_symbols , \" ' : ; ! ? BackSpace" + - "show_letters show_eschars preferences space º . Return" symbols: - - "@ # $ % - + ÷ × = ≠" - - "( ) § & < > / * { }" - - "show_numbers_from_symbols º \" ' : ; ! ? BackSpace" - - "show_letters preferences space . Return" + - "~ ` | · √ π τ ÷ × ¶" + - "© ® £ € ¥ ^ ° * { }" + - "show_numbers \\ / < > = [ ] BackSpace" + - "show_letters show_eschars preferences space ≠ § Return" + eschars: + - "À Á Ã Â É Ê Í Ó Ô Õ" + - "à á ã â é ê í ó ô õ " + - "show_numbers Ú Ü ú ü ! ? . BackSpace" + - "show_letters show_eschars preferences space « » Return" buttons: Shift_L: @@ -47,27 +52,33 @@ buttons: outline: "special" icon: "keyboard-mode-symbolic" show_numbers: - action: - set_view: "numbers" - outline: "change-view-2" - label: "1ã" - show_numbers_from_symbols: action: set_view: "numbers" outline: "change-view" - label: "1ã" + label: "123" show_letters: action: set_view: "base" - outline: "change-view-2" + outline: "change-view" label: "ABC" show_symbols: action: set_view: "symbols" outline: "change-view" label: "*/=" - .: - outline: "special" + show_eschars: + action: + locking: + lock_view: "eschars" + unlock_view: "base" + outline: "change-view" + label: "Ãã" + .-large: + outline: "large" + text: "." + ",-large": + outline: "large" + text: "," space: outline: "spaceline" text: " " diff --git a/data/keyboards/br_wide.yaml b/data/keyboards/br_wide.yaml index 68ab967b..f2a6cb5c 100644 --- a/data/keyboards/br_wide.yaml +++ b/data/keyboards/br_wide.yaml @@ -1,34 +1,40 @@ --- outlines: - default: { width: 52, height: 42 } - altline: { width: 77.52, height: 42 } - wide: { width: 91.25, height: 42 } - change-view: { width: 77.52, height: 42 } - change-view-2: { width: 91.25, height: 42 } - spaceline: { width: 209, height: 42 } - special: { width: 64.76, height: 42 } + default: { width: 53.75, height: 42 } + thin: { width: 40.5, height: 42 } + altline: { width: 81, height: 42 } + wide: { width: 92, height: 42 } + change-view: { width: 81, height: 42 } + spaceline: { width: 149.5, height: 42 } + special: { width: 53.75, height: 42 } + large: { width: 81, height: 42 } views: base: - "q w e r t y u i o p" - "a s d f g h j k l ç" - "Shift_L z x c v b n m BackSpace" - - "show_numbers preferences space , Return" + - "show_numbers show_eschars preferences space .-large Return" upper: - "Q W E R T Y U I O P" - "A S D F G H J K L Ç" - "Shift_L Z X C V B N M BackSpace" - - "show_numbers preferences space . Return" + - "show_numbers show_eschars preferences space ,-large Return" numbers: - "1 2 3 4 5 6 7 8 9 0" - - "à À á Á ã Ã â Â é É" - - "show_symbols ê Ê í Í ó Ó ô Ô" - - "show_letters õ Õ ú Ú ü Ü . BackSpace" + - "@ # $ % & - _ + ( )" + - "show_symbols , \" ' : ; ! ? BackSpace" + - "show_letters show_eschars preferences space º .-thin Return" symbols: - - "@ # $ % - + ÷ × = ≠" - - "( ) § & < > / * { }" - - "show_numbers_from_symbols º \" ' : ; ! ? BackSpace" - - "show_letters preferences space . Return" + - "~ ` | · √ π τ ÷ × ¶" + - "© ® £ € ¥ ^ ° * { }" + - "show_numbers \\ / < > = [ ] BackSpace" + - "show_letters show_eschars preferences space ≠ § Return" + eschars: + - "À Á Ã Â É Ê Í Ó Ô Õ" + - "à á ã â é ê í ó ô õ " + - "show_numbers Ú Ü ú ü ! ? . BackSpace" + - "show_letters show_eschars preferences space « » Return" buttons: Shift_L: @@ -47,27 +53,33 @@ buttons: outline: "special" icon: "keyboard-mode-symbolic" show_numbers: - action: - set_view: "numbers" - outline: "change-view-2" - label: "1ã" - show_numbers_from_symbols: action: set_view: "numbers" outline: "change-view" - label: "1ã" + label: "123" show_letters: action: set_view: "base" - outline: "change-view-2" + outline: "change-view" label: "ABC" show_symbols: action: set_view: "symbols" outline: "change-view" label: "*/=" - .: - outline: "special" + show_eschars: + action: + locking: + lock_view: "eschars" + unlock_view: "base" + outline: "change-view" + label: "Ãã" + .-large: + outline: "large" + text: "." + ",-large": + outline: "large" + text: "," space: outline: "spaceline" text: " " @@ -75,3 +87,16 @@ buttons: outline: "wide" icon: "key-enter" keysym: "Return" + «: + outline: "thin" + »: + outline: "thin" + º: + outline: "thin" + .-thin: + outline: "thin" + text: "." + ≠: + outline: "thin" + §: + outline: "thin" diff --git a/data/keyboards/pt.yaml b/data/keyboards/pt.yaml new file mode 100644 index 00000000..1365e33d --- /dev/null +++ b/data/keyboards/pt.yaml @@ -0,0 +1,89 @@ +# This layout-file is a copy of "br.yaml" +--- +outlines: + default: { width: 35.67, height: 52 } + altline: { width: 53, height: 52 } + wide: { width: 53, height: 52 } + change-view: { width: 53, height: 52 } + spaceline: { width: 90, height: 52 } + special: { width: 35.67, height: 52 } + large: { width: 71.34, height: 52 } + +views: + base: + - "q w e r t y u i o p" + - "a s d f g h j k l ç" + - "Shift_L z x c v b n m BackSpace" + - "show_numbers show_eschars preferences space .-large Return" + upper: + - "Q W E R T Y U I O P" + - "A S D F G H J K L Ç" + - "Shift_L Z X C V B N M BackSpace" + - "show_numbers show_eschars preferences space ,-large Return" + numbers: + - "1 2 3 4 5 6 7 8 9 0" + - "@ # $ % & - _ + ( )" + - "show_symbols , \" ' : ; ! ? BackSpace" + - "show_letters show_eschars preferences space º . Return" + symbols: + - "~ ` | · √ π τ ÷ × ¶" + - "© ® £ € ¥ ^ ° * { }" + - "show_numbers \\ / < > = [ ] BackSpace" + - "show_letters show_eschars preferences space ≠ § Return" + eschars: + - "À Á Ã Â É Ê Í Ó Ô Õ" + - "à á ã â é ê í ó ô õ " + - "show_numbers Ú Ü ú ü ! ? . BackSpace" + - "show_letters show_eschars preferences space « » Return" + +buttons: + Shift_L: + action: + locking: + lock_view: "upper" + unlock_view: "base" + outline: "change-view" + icon: "key-shift" + BackSpace: + outline: "altline" + icon: "edit-clear-symbolic" + action: "erase" + preferences: + action: "show_prefs" + outline: "special" + icon: "keyboard-mode-symbolic" + show_numbers: + action: + set_view: "numbers" + outline: "change-view" + label: "123" + show_letters: + action: + set_view: "base" + outline: "change-view" + label: "ABC" + show_symbols: + action: + set_view: "symbols" + outline: "change-view" + label: "*/=" + show_eschars: + action: + locking: + lock_view: "eschars" + unlock_view: "base" + outline: "change-view" + label: "Ãã" + .-large: + outline: "large" + text: "." + ",-large": + outline: "large" + text: "," + space: + outline: "spaceline" + text: " " + Return: + outline: "wide" + icon: "key-enter" + keysym: "Return" diff --git a/data/keyboards/pt_wide.yaml b/data/keyboards/pt_wide.yaml new file mode 100644 index 00000000..970ed376 --- /dev/null +++ b/data/keyboards/pt_wide.yaml @@ -0,0 +1,103 @@ +# This layout-file is a copy of "br_wide.yaml" +--- +outlines: + default: { width: 53.75, height: 42 } + thin: { width: 40.5, height: 42 } + altline: { width: 81, height: 42 } + wide: { width: 92, height: 42 } + change-view: { width: 81, height: 42 } + spaceline: { width: 149.5, height: 42 } + special: { width: 53.75, height: 42 } + large: { width: 81, height: 42 } + +views: + base: + - "q w e r t y u i o p" + - "a s d f g h j k l ç" + - "Shift_L z x c v b n m BackSpace" + - "show_numbers show_eschars preferences space .-large Return" + upper: + - "Q W E R T Y U I O P" + - "A S D F G H J K L Ç" + - "Shift_L Z X C V B N M BackSpace" + - "show_numbers show_eschars preferences space ,-large Return" + numbers: + - "1 2 3 4 5 6 7 8 9 0" + - "@ # $ % & - _ + ( )" + - "show_symbols , \" ' : ; ! ? BackSpace" + - "show_letters show_eschars preferences space º .-thin Return" + symbols: + - "~ ` | · √ π τ ÷ × ¶" + - "© ® £ € ¥ ^ ° * { }" + - "show_numbers \\ / < > = [ ] BackSpace" + - "show_letters show_eschars preferences space ≠ § Return" + eschars: + - "À Á Ã Â É Ê Í Ó Ô Õ" + - "à á ã â é ê í ó ô õ " + - "show_numbers Ú Ü ú ü ! ? . BackSpace" + - "show_letters show_eschars preferences space « » Return" + +buttons: + Shift_L: + action: + locking: + lock_view: "upper" + unlock_view: "base" + outline: "change-view" + icon: "key-shift" + BackSpace: + outline: "altline" + icon: "edit-clear-symbolic" + action: "erase" + preferences: + action: "show_prefs" + outline: "special" + icon: "keyboard-mode-symbolic" + show_numbers: + action: + set_view: "numbers" + outline: "change-view" + label: "123" + show_letters: + action: + set_view: "base" + outline: "change-view" + label: "ABC" + show_symbols: + action: + set_view: "symbols" + outline: "change-view" + label: "*/=" + show_eschars: + action: + locking: + lock_view: "eschars" + unlock_view: "base" + outline: "change-view" + label: "Ãã" + .-large: + outline: "large" + text: "." + ",-large": + outline: "large" + text: "," + space: + outline: "spaceline" + text: " " + Return: + outline: "wide" + icon: "key-enter" + keysym: "Return" + «: + outline: "thin" + »: + outline: "thin" + º: + outline: "thin" + .-thin: + outline: "thin" + text: "." + ≠: + outline: "thin" + §: + outline: "thin" diff --git a/src/resources.rs b/src/resources.rs index 7aa76cef..d9a183f5 100644 --- a/src/resources.rs +++ b/src/resources.rs @@ -101,6 +101,9 @@ static KEYBOARDS: &[(&'static str, &'static str)] = &[ ("pl", include_str!("../data/keyboards/pl.yaml")), ("pl_wide", include_str!("../data/keyboards/pl_wide.yaml")), + ("pt", include_str!("../data/keyboards/pt.yaml")), + ("pt_wide", include_str!("../data/keyboards/pt_wide.yaml")), + ("ro", include_str!("../data/keyboards/ro.yaml")), ("ro_wide", include_str!("../data/keyboards/ro_wide.yaml")), diff --git a/tests/meson.build b/tests/meson.build index 8b314e1d..d965f561 100644 --- a/tests/meson.build +++ b/tests/meson.build @@ -89,6 +89,7 @@ foreach layout : [ 'it+fur', 'it+fur_wide', 'jp+kana','jp+kana_wide', 'no', 'no_wide', + 'pt', 'pt_wide', 'pl', 'pl_wide', 'ro', 'ro_wide', 'ru', 'ru_wide', @@ -99,16 +100,11 @@ foreach layout : [ 'us+dvorak', 'us+dvorak_wide', # Terminal keyboards - 'terminal/de', - 'terminal/de_wide', - 'terminal/es', - 'terminal/es_wide', - 'terminal/fr', - 'terminal/fr_wide', - 'terminal/us', - 'terminal/us_wide', - 'terminal/us+dvorak', - 'terminal/us+dvorak_wide', + 'terminal/de', 'terminal/de_wide', + 'terminal/es', 'terminal/es_wide', + 'terminal/fr', 'terminal/fr_wide', + 'terminal/us', 'terminal/us_wide', + 'terminal/us+dvorak', 'terminal/us+dvorak_wide', # Block: Not languages. 'emoji/us', 'emoji/us_wide',