From 6b1551d1039542a73c979da56468c46c3194ce42 Mon Sep 17 00:00:00 2001 From: Jules Aguillon Date: Sun, 24 Nov 2024 10:56:19 +0100 Subject: layouts format: Add 'c' as a synonym for 'key0' The attribute 'c' specifies the symbol in the center of a key, just like 'key0'. This adds consistency with the cardinal direction attributes and is intended to make layouts more readable. --- srcs/juloo.keyboard2/KeyboardData.java | 2 +- srcs/layouts/latn_qwerty_us.xml | 58 +++++++++++++++++----------------- 2 files changed, 30 insertions(+), 30 deletions(-) (limited to 'srcs') diff --git a/srcs/juloo.keyboard2/KeyboardData.java b/srcs/juloo.keyboard2/KeyboardData.java index 3432fe1..aca8ba3 100644 --- a/srcs/juloo.keyboard2/KeyboardData.java +++ b/srcs/juloo.keyboard2/KeyboardData.java @@ -473,7 +473,7 @@ public final class KeyboardData { KeyValue[] ks = new KeyValue[9]; int keysflags = 0; - keysflags |= parse_key_attr(parser, parser.getAttributeValue(null, "key0"), ks, 0); + keysflags |= parse_key_attr(parser, get_key_attr(parser, "key0", "c"), ks, 0); /* Swipe gestures (key1-key8 diagram above), with compass-point synonyms. */ keysflags |= parse_key_attr(parser, get_key_attr(parser, "key1", "nw"), ks, 1); keysflags |= parse_key_attr(parser, get_key_attr(parser, "key2", "ne"), ks, 2); diff --git a/srcs/layouts/latn_qwerty_us.xml b/srcs/layouts/latn_qwerty_us.xml index 08c4961..a97525e 100644 --- a/srcs/layouts/latn_qwerty_us.xml +++ b/srcs/layouts/latn_qwerty_us.xml @@ -8,7 +8,7 @@ symbols to the corners of a key, they are arranged following the cardinal directions: nw n ne - w key0 e + w c e sw s se Symbols prefixed with 'loc ' are not visible on the keyboard. They are used to @@ -23,37 +23,37 @@ doc/Possible-key-values.md for the keys that have a special meaning. --> - - - - - - - - - - + + + + + + + + + + - - - - - - - - - + + + + + + + + + - - - - - - - - - + + + + + + + + + -- cgit v1.2.3