diff --git a/common/supplemental/attributeValueValidity.xml b/common/supplemental/attributeValueValidity.xml index 6ce3c371322..91a8b5296ed 100644 --- a/common/supplemental/attributeValueValidity.xml +++ b/common/supplemental/attributeValueValidity.xml @@ -450,8 +450,6 @@ pluralOrdinal pluralOrdinal - diff --git a/docs/ldml/tr35-keyboards.md b/docs/ldml/tr35-keyboards.md index a96b2ca0884..0008c5c2009 100644 --- a/docs/ldml/tr35-keyboards.md +++ b/docs/ldml/tr35-keyboards.md @@ -274,11 +274,10 @@ Currently, the following attribute values allow _UnicodeSet_ notation: The `\u{...}` notation, a subset of hex notation, is described in [UTS #18 section 1.1](https://www.unicode.org/reports/tr18/#Hex_notation). It can refer to one or multiple individual codepoints. Currently, the following attribute values allow the `\u{...}` notation: -* `to`, `longPress`, `multiTap`, and `longPressDefault` on the `` element -* `to` on the `` element +* `output` on the `` element * `from` or `to` on the `` element * `value` on the `` element -* `to` and `display` on the `` element +* `output` and `display` on the `` element * `baseCharacter` on the `` element * Some attributes on [Keyboard Test Data](#keyboard-test-data) subelements @@ -617,14 +616,14 @@ This element defines a mapping between an abstract key and its output. This elem ```xml @@ -641,7 +640,7 @@ This element defines a mapping between an abstract key and its output. This elem **Note**: The `id` attribute is required. -**Note**: _at least one of_ `switch`, `gap`, or `to` are required. +**Note**: _at least one of_ `layerId`, `gap`, or `output` are required. _Attribute:_ `id` @@ -649,9 +648,9 @@ _Attribute:_ `id` > > In the future, this attribute’s definition is expected to be updated to align with [UAX#31](https://www.unicode.org/reports/tr31/). Please see [CLDR-17043](https://unicode-org.atlassian.net/browse/CLDR-17043) for more details. -_Attribute:_ `flicks="{flick id}"` (optional) +_Attribute:_ `flickId="{flick id}"` (optional) -> The `flicks` attribute indicates that this key makes use of a [`flicks`](#Element_flicks) set with the specified id. +> The `flickId` attribute indicates that this key makes use of a [`flick`](#Element_flick) set with the specified id. _Attribute:_ `gap="true"` (optional) @@ -661,29 +660,60 @@ _Attribute:_ `gap="true"` (optional) ``` -_Attribute:_ `longPress="a b c"` (optional) +_Attribute:_ `longPressKeyIds="{list of key ids}"` (optional) -> The `longPress` attribute contains any characters that can be emitted by "long-pressing" a key, this feature is prominent in mobile devices. The possible sequences of characters that can be emitted are whitespace delimited. Control characters, combining marks and whitespace (which is intended to be a long-press option) in this attribute are escaped using the `\u{...}` notation. +> A space-separated ordered list of `key` element ids, which keys which can be emitted by "long-pressing" this key. This feature is prominent in mobile devices. > - -_Attribute:_ `longPressDefault` (optional) - -> Indicates which of the `longPress` target characters is the default long-press target, which could be different than the first element. Ignored if not in the `longPress` list. Characters in this attribute can be escaped using the `\u{...}` notation. -> For example, if the `longPressDefault` is a key whose [display](#Element_displays) value is `{`, an implementation might render the key as follows: +> In a list of keys specified by `longPressKeyIds`, the key matching `longPressDefaultKeyId` attribute (if present) specifies the default long-press target, which could be different than the first element. It is an error if the `longPressDefaultKeyId` key is not in the `longPressKeyIds` list. +> +> Implementations shall ignore any gestures (such as flick, multiTap, longPress) defined on keys in the `longPressKeyIds` list. +> +> For example, if the default key is a key whose [display](#Element_displays) value is `{`, an implementation might render the key as follows: > > ![keycap hint](images/keycapHint.png) +> +> _Example:_ +> - pressing the `o` key will produce `o` +> - holding down the key will produce a list `ó`, `{` (where `{` is the default and produces a marker) +> +> ```xml +> +> +> +> +> +> +> +> +> +> +> ``` -_Attribute:_ `multiTap` (optional) +_Attribute:_ `longPressDefaultKeyId="{key-id}"` (optional) -> A space-delimited list of strings, where each successive element of the list is produced by the corresponding number of quick taps. In the following example, three taps on the key will produce a “c” (first tap produces “a”, two taps produce “bb” etc.). ->> +> Specifies the default key, by id, in a list of long-press keys. See the discussion of `LongPressKeyIds`, above. + +_Attribute:_ `multiTapKeyIds` (optional) + +> A space-separated ordered list of `key` element ids, which keys, where each successive key in the list is produced by the corresponding number of quick taps. +> It is an error for a key to reference itself in the `multiTapKeyIds` list. +> +> Implementations shall ignore any gestures (such as flick, multiTap, longPress) defined on keys in the `multiTapKeyIds` list. +> > _Example:_ +> - first tap on the key will produce “a” +> - two taps will produce “bb” +> - three taps on the key will produce “c” +> - four taps on the key will produce “d” > > ```xml -> +> +> +> +> +> +> > ``` -> -> Control characters, combining marks and whitespace (which is intended to be a multiTap option) in this attribute are escaped using the `\u{...}` notation. **Note**: Behavior past the end of the multiTap list is implementation specific. @@ -692,11 +722,11 @@ _Attribute:_ `stretch="true"` (optional) > The `stretch` attribute indicates that a touch layout may stretch this key to fill available horizontal space on the row. > This is used, for example, on the spacebar. Note that `stretch=` is ignored for hardware layouts. -_Attribute:_ `switch="shift"` (optional) +_Attribute:_ `layerId="shift"` (optional) -> The `switch` attribute indicates that this key switches to another `layer` with the specified id (such as `` in this example). -> Note that a key may have both a `switch=` and a `to=` attribute, indicating that the key outputs prior to switching layers. -> Also note that `switch=` is ignored for hardware layouts: their shifting is controlled via +> The `layerId` attribute indicates that this key switches to another `layer` with the specified id (such as `` in this example). +> Note that a key may have both a `layerId=` and a `output=` attribute, indicating that the key outputs _prior_ to switching layers. +> Also note that `layerId=` is ignored for hardware layouts: their shifting is controlled via > the modifier keys. > > This attribute is an NMTOKEN. @@ -704,11 +734,11 @@ _Attribute:_ `switch="shift"` (optional) > In the future, this attribute’s definition is expected to be updated to align with [UAX#31](https://www.unicode.org/reports/tr31/). Please see [CLDR-17043](https://unicode-org.atlassian.net/browse/CLDR-17043) for more details. -_Attribute:_ `to` +_Attribute:_ `output` -> The `to` attribute contains the output sequence of characters that is emitted when pressing this particular key. Control characters, whitespace (other than the regular space character) and combining marks in this attribute are escaped using the `\u{...}` notation. More than one key may output the same output. +> The `output` attribute contains the sequence of characters that is emitted when pressing this particular key. Control characters, whitespace (other than the regular space character) and combining marks in this attribute are escaped using the `\u{...}` notation. More than one key may output the same output. > -> The `to` attribute may also contain the `\m{…}` syntax to insert a marker. See the definition of [markers](#markers). +> The `output` attribute may also contain the `\m{…}` syntax to insert a marker. See the definition of [markers](#markers). _Attribute:_ `transform="no"` (optional) @@ -722,8 +752,8 @@ _Attribute:_ `transform="no"` (optional) ```xml - - + + @@ -745,13 +775,13 @@ _Attribute:_ `transform="no"` (optional) ```xml - - + + - + ``` @@ -759,13 +789,13 @@ Even better is to use a marker to indicate where transforms are desired: ```xml - - + + - + ``` @@ -774,7 +804,7 @@ _Attribute:_ `width="1.2"` (optional, default "1.0") > The `width` attribute indicates that this key has a different width than other keys, by the specified number of key widths. ```xml - + ``` @@ -784,23 +814,23 @@ Not all keys need to be listed explicitly. The following two can be assumed to ```xml - + ``` In addition, these 62 keys, comprising 10 digit keys, 26 Latin lower-case keys, and 26 Latin upper-case keys, where the `id` is the same as the `to`, are assumed to exist: ```xml - - - + + + … - - - + + + … - - - + + + … ``` @@ -844,7 +874,7 @@ The `flick` element is used to generate results from a "flick" of the finger on ```xml - + @@ -879,7 +909,7 @@ _Attribute:_ `id` (required) **Syntax** ```xml - + ``` > @@ -896,17 +926,27 @@ _Attribute:_ `directions` (required) > The `directions` attribute value is a space-delimited list of keywords, that describe a path, currently restricted to the cardinal and intercardinal directions `{n e s w ne nw se sw}`. -_Attribute:_ `to` (required) +_Attribute:_ `keyId` (required) + +> The `keyId` attribute value is the result of (one or more) flicks. +> +> Implementations shall ignore any gestures (such as flick, multiTap, longPress) defined on the key specified by `keyId`. -> The to attribute value is the result of (one or more) flicks. **Example** -where a flick to the Northeast then South produces two code points. +where a flick to the Northeast then South produces `Å`. ```xml - - - + + + + + + + + + + ``` * * * @@ -1015,7 +1055,7 @@ For combining characters, U+25CC `◌` is used as a base. It is an error to use For example, a key which outputs a combining tilde (U+0303) can be represented as follows: ```xml - + ``` This way, a key which outputs a combining tilde (U+0303) will be represented as `◌̃` (a tilde on a dotted circle). @@ -1052,7 +1092,7 @@ The `display` element describes how a character, that has come from a `keys/key` **Syntax** ```xml - + ``` > @@ -1065,23 +1105,26 @@ The `display` element describes how a character, that has come from a `keys/key` > > -One of the `to` or `id` attributes is required. +One of the `output` or `id` attributes is required. -_Attribute:_ `to` (optional) +_Attribute:_ `output` (optional) > Specifies the character or character sequence from the `keys/key` element that is to have a special display. > This attribute may be escaped with `\u` notation, see [Escaping](#Escaping). -> The `to` attribute may also contain the `\m{…}` syntax to reference a marker. See [Markers](#markers). Implementations may highlight a displayed marker, such as with a lighter text color, or a yellow highlight. +> The `output` attribute may also contain the `\m{…}` syntax to reference a marker. See [Markers](#markers). Implementations may highlight a displayed marker, such as with a lighter text color, or a yellow highlight. +> String variables may be substituted. See [String variables](#element-string) _Attribute:_ `id` (optional) -> Specifies the `key` id. This is useful for keys which do not produce any output (no `to=` value), such as a shift key. +> Specifies the `key` id. This is useful for keys which do not produce any output (no `output=` value), such as a shift key. > > This attribute must match `[A-Za-z0-9][A-Za-z0-9-]*` _Attribute:_ `display` (required) -> Required and specifies the character sequence that should be displayed on the keytop for any key that generates the `@to` sequence or has the `@id`. (It is an error if the value of the `display` attribute is the same as the value of the `to` attribute, this would be an extraneous entry.) +> Required and specifies the character sequence that should be displayed on the keytop for any key that generates the `@output` sequence or has the `@id`. (It is an error if the value of the `display` attribute is the same as the value of the `output` attribute, this would be an extraneous entry.) + +> String variables may be substituted. See [String variables](#element-string) This attribute may be escaped with `\u` notation, see [Escaping](#Escaping). @@ -1090,19 +1133,19 @@ This attribute may be escaped with `\u` notation, see [Escaping](#Escaping). ```xml - - + + + - - - - + + + ``` -To allow `displays` elements to be shared across keyboards, there is no requirement that `@to` in a `display` element matches any `@to`/`@id` in any `keys/key` element in the keyboard description. +To allow `displays` elements to be shared across keyboards, there is no requirement that `@output` in a `display` element matches any `@output`/`@id` in any `keys/key` element in the keyboard description. * * * @@ -1470,6 +1513,7 @@ _Attribute:_ `value` (required) + @@ -1483,11 +1527,11 @@ These may be then used in multiple contexts: - - + + - + ``` * * * @@ -1643,10 +1687,10 @@ The marker ID is any valid `NMTOKEN` (But see [CLDR-17043](https://unicode-org.a Consider the following abbreviated example: ```xml - + … - - + + ``` diff --git a/keyboards/3.0/fr-t-k0-azerty.xml b/keyboards/3.0/fr-t-k0-azerty.xml index 942ffe83f58..76d04f5528b 100644 --- a/keyboards/3.0/fr-t-k0-azerty.xml +++ b/keyboards/3.0/fr-t-k0-azerty.xml @@ -22,13 +22,17 @@ - + + + + + @@ -37,10 +41,10 @@ - - - - + + + + - - - - - - + + + + + + + + + + + + + + + + + + + + - - - - - - - - - + + + + + + + + + - - - - - - - - + + + + + + + + + - + - + diff --git a/keyboards/3.0/ja-Latn.xml b/keyboards/3.0/ja-Latn.xml index 0e7be47e8d6..8c79ee4f373 100644 --- a/keyboards/3.0/ja-Latn.xml +++ b/keyboards/3.0/ja-Latn.xml @@ -12,7 +12,7 @@ - + diff --git a/keyboards/3.0/mt-t-k0-47key.xml b/keyboards/3.0/mt-t-k0-47key.xml index 56361ae242c..3adc34aa684 100644 --- a/keyboards/3.0/mt-t-k0-47key.xml +++ b/keyboards/3.0/mt-t-k0-47key.xml @@ -14,36 +14,36 @@ - - - - - - - - - - + + + + + + + + + + - - - - - - - - + + + + + + + + - + - + diff --git a/keyboards/3.0/mt.xml b/keyboards/3.0/mt.xml index 84985d1c0ad..f63e0845476 100644 --- a/keyboards/3.0/mt.xml +++ b/keyboards/3.0/mt.xml @@ -20,33 +20,33 @@ - - - - - - - - - - + + + + + + + + + + - - - - - - - - + + + + + + + + - + - + diff --git a/keyboards/3.0/pcm.xml b/keyboards/3.0/pcm.xml index 4bc34be49ac..50a308b81c1 100644 --- a/keyboards/3.0/pcm.xml +++ b/keyboards/3.0/pcm.xml @@ -6,21 +6,21 @@ - - - + + + - - - - + + + + - + - + diff --git a/keyboards/3.0/pt-t-k0-abnt2.xml b/keyboards/3.0/pt-t-k0-abnt2.xml index 8d056de3a1c..41060ea6403 100644 --- a/keyboards/3.0/pt-t-k0-abnt2.xml +++ b/keyboards/3.0/pt-t-k0-abnt2.xml @@ -7,11 +7,11 @@ - - - - - + + + + + @@ -19,22 +19,22 @@ - - - - - + + + + + - - + + - - - - - + + + + + - + diff --git a/keyboards/dtd/ldmlKeyboard3.dtd b/keyboards/dtd/ldmlKeyboard3.dtd index a667f0f12d2..8a1f66ffd8e 100644 --- a/keyboards/dtd/ldmlKeyboard3.dtd +++ b/keyboards/dtd/ldmlKeyboard3.dtd @@ -69,9 +69,9 @@ Please view the subcommittee page for the most recent information. - + - + @@ -96,28 +96,26 @@ Please view the subcommittee page for the most recent information. - + - + - + - - + - - + + - - + @@ -137,10 +135,9 @@ Please view the subcommittee page for the most recent information. - + - @@ -158,7 +155,7 @@ Please view the subcommittee page for the most recent information. - + diff --git a/keyboards/dtd/ldmlKeyboard3.xsd b/keyboards/dtd/ldmlKeyboard3.xsd index f780408bf53..f2378db64e0 100644 --- a/keyboards/dtd/ldmlKeyboard3.xsd +++ b/keyboards/dtd/ldmlKeyboard3.xsd @@ -139,8 +139,8 @@ Note: DTD @-annotations are not currently converted to .xsd. For full CLDR file - - + + @@ -175,7 +175,7 @@ Note: DTD @-annotations are not currently converted to .xsd. For full CLDR file - + @@ -183,10 +183,10 @@ Note: DTD @-annotations are not currently converted to .xsd. For full CLDR file - - - - + + + + @@ -194,7 +194,7 @@ Note: DTD @-annotations are not currently converted to .xsd. For full CLDR file - + @@ -223,8 +223,6 @@ Note: DTD @-annotations are not currently converted to .xsd. For full CLDR file - - @@ -249,14 +247,13 @@ Note: DTD @-annotations are not currently converted to .xsd. For full CLDR file - + - @@ -293,7 +290,7 @@ Note: DTD @-annotations are not currently converted to .xsd. For full CLDR file - + diff --git a/keyboards/import/keys-Latn-implied.xml b/keyboards/import/keys-Latn-implied.xml index eed84d38f82..537860aeb93 100644 --- a/keyboards/import/keys-Latn-implied.xml +++ b/keyboards/import/keys-Latn-implied.xml @@ -13,68 +13,68 @@ CLDR data files are interpreted according to the LDML specification (http://unic - + - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + diff --git a/keyboards/import/keys-Zyyy-currency.xml b/keyboards/import/keys-Zyyy-currency.xml index 778cad451ad..dd88113501b 100644 --- a/keyboards/import/keys-Zyyy-currency.xml +++ b/keyboards/import/keys-Zyyy-currency.xml @@ -13,10 +13,10 @@ CLDR data files are interpreted according to the LDML specification (http://unic --> - - - - - - + + + + + + diff --git a/keyboards/import/keys-Zyyy-punctuation.xml b/keyboards/import/keys-Zyyy-punctuation.xml index 1e540cf024e..59c6280826d 100644 --- a/keyboards/import/keys-Zyyy-punctuation.xml +++ b/keyboards/import/keys-Zyyy-punctuation.xml @@ -8,39 +8,39 @@ - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + diff --git a/tools/cldr-code/src/test/java/org/unicode/cldr/unittest/TestDtdData.java b/tools/cldr-code/src/test/java/org/unicode/cldr/unittest/TestDtdData.java index 7cf5608c617..4fde8212c63 100644 --- a/tools/cldr-code/src/test/java/org/unicode/cldr/unittest/TestDtdData.java +++ b/tools/cldr-code/src/test/java/org/unicode/cldr/unittest/TestDtdData.java @@ -758,14 +758,13 @@ public boolean isDistinguishingOld(DtdType dtdType, String elementName, String a case keyboard3: if (elementName.equals("keyboard3") && attribute.equals("locale") - || elementName.equals("vkeys") && attribute.equals("from") - || elementName.equals("layers") && attribute.equals("form") + || elementName.equals("layers") && attribute.equals("formId") || elementName.equals("layers") && attribute.equals("minDeviceWidth") - || elementName.equals("vkey") && attribute.equals("from") || elementName.equals("layer") && attribute.equals("modifier") || elementName.equals("form") && attribute.equals("id") - || elementName.equals("map") && attribute.equals("id") || elementName.equals("key") && attribute.equals("id") + || elementName.equals("keyList") && attribute.equals("id") + || elementName.equals("flick") && attribute.equals("id") || elementName.equals("import") && attribute.equals("path") || elementName.equals("import") && attribute.equals("base") || elementName.equals("layer") && attribute.equals("id") @@ -778,20 +777,12 @@ public boolean isDistinguishingOld(DtdType dtdType, String elementName, String a return attribute.equals("_q") || elementName.equals("keyboard3") && attribute.equals("locale") || elementName.equals("keyMap") && attribute.equals("modifiers") - || elementName.equals("key") && attribute.equals("flicks") + || elementName.equals("key") && attribute.equals("flickId") || elementName.equals("transforms") && attribute.equals("type") - || elementName.equals("layerMap") && attribute.equals("modifier") - || elementName.equals("transform") && attribute.equals("before") || elementName.equals("transform") && attribute.equals("after") - || elementName.equals("backspace") && attribute.equals("before") - || elementName.equals("backspace") && attribute.equals("from") - || elementName.equals("backspace") && attribute.equals("after") - || elementName.equals("vkeys") && attribute.equals("type") || elementName.equals("flickSegment") && attribute.equals("directions") - // || elementName.equals("row") && attribute.equals("keys") - || elementName.equals("vkey") && attribute.equals("iso") - || elementName.equals("display") && attribute.equals("to") - || elementName.equals("display") && attribute.equals("id") + || elementName.equals("display") && attribute.equals("output") + || elementName.equals("display") && attribute.equals("keyId") || elementName.equals("flick") && attribute.equals("id"); case keyboardTest3: return elementName.equals("tests") && attribute.equals("name") diff --git a/tools/cldr-code/src/test/resources/org/unicode/cldr/tool/KeyboardFlatten/broken-import-missing.xml b/tools/cldr-code/src/test/resources/org/unicode/cldr/tool/KeyboardFlatten/broken-import-missing.xml index 73088028861..dad045e1e46 100644 --- a/tools/cldr-code/src/test/resources/org/unicode/cldr/tool/KeyboardFlatten/broken-import-missing.xml +++ b/tools/cldr-code/src/test/resources/org/unicode/cldr/tool/KeyboardFlatten/broken-import-missing.xml @@ -16,35 +16,35 @@ - - - - - - - - - - + + + + + + + + + + - - - - - - - - + + + + + + + + - + - + diff --git a/tools/cldr-code/src/test/resources/org/unicode/cldr/tool/KeyboardFlatten/broken-import-unknownbase.xml b/tools/cldr-code/src/test/resources/org/unicode/cldr/tool/KeyboardFlatten/broken-import-unknownbase.xml index a1e902f480e..a7fe30b2763 100644 --- a/tools/cldr-code/src/test/resources/org/unicode/cldr/tool/KeyboardFlatten/broken-import-unknownbase.xml +++ b/tools/cldr-code/src/test/resources/org/unicode/cldr/tool/KeyboardFlatten/broken-import-unknownbase.xml @@ -16,35 +16,35 @@ - - - - - - - - - - + + + + + + + + + + - - - - - - - - + + + + + + + + - + - + diff --git a/tools/cldr-code/src/test/resources/org/unicode/cldr/tool/KeyboardFlatten/broken-import-unknownver.xml b/tools/cldr-code/src/test/resources/org/unicode/cldr/tool/KeyboardFlatten/broken-import-unknownver.xml index 1ff9b4fa415..f1443c3eb02 100644 --- a/tools/cldr-code/src/test/resources/org/unicode/cldr/tool/KeyboardFlatten/broken-import-unknownver.xml +++ b/tools/cldr-code/src/test/resources/org/unicode/cldr/tool/KeyboardFlatten/broken-import-unknownver.xml @@ -8,7 +8,7 @@ - + @@ -18,35 +18,35 @@ - - - - - - - - - - + + + + + + + + + + - - - - - - - - + + + + + + + + - + - + diff --git a/tools/cldr-code/src/test/resources/org/unicode/cldr/tool/KeyboardFlatten/broken-import-wrongparent.xml b/tools/cldr-code/src/test/resources/org/unicode/cldr/tool/KeyboardFlatten/broken-import-wrongparent.xml index 5ee1baa544d..de14815c45a 100644 --- a/tools/cldr-code/src/test/resources/org/unicode/cldr/tool/KeyboardFlatten/broken-import-wrongparent.xml +++ b/tools/cldr-code/src/test/resources/org/unicode/cldr/tool/KeyboardFlatten/broken-import-wrongparent.xml @@ -16,35 +16,35 @@ - - - - - - - - - - + + + + + + + + + + - - - - - - - - + + + + + + + + - + - +