Skip to content

Commit

Permalink
CLDR-12026 kbd: update Français normalisé (AZERTY)
Browse files Browse the repository at this point in the history
- hit all cases, simplified some
- renamed to just fr.xml
  • Loading branch information
srl295 committed Apr 11, 2024
1 parent c6b9488 commit 40396b1
Showing 1 changed file with 82 additions and 66 deletions.
148 changes: 82 additions & 66 deletions keyboards/3.0/fr-t-k0-optimise.xml → keyboards/3.0/fr.xml
Original file line number Diff line number Diff line change
@@ -1,10 +1,8 @@
<?xml version="1.0" encoding="UTF-8"?>
<keyboard3 xmlns="https://schemas.unicode.org/cldr/45/keyboard3" locale="fr-t-k0-optimise"
conformsTo="45">
<!--
New French
-->
<keyboard3 xmlns="https://schemas.unicode.org/cldr/45/keyboard3" conformsTo="45"
locale="fr">
<version number="1.0.0" />

<info author="Team Keyboard" name="Français normalisé (AZERTY)" layout="AZERTY" indicator="FR" />

<displays>
Expand All @@ -15,7 +13,7 @@
<display output="\m{umlaut}" display="¨" />
<display output="\m{caret}" display="^" />
<display output="\m{tilde}" display="~" />
<display output="\m{invbreve}" display="\u{20}\u{0311}" />
<display output="\m{invbreve}" display="\u{20}\u{0311}" />

<!-- display for 'mode' keys -->
<display keyId="mark-currency" display="\u{00A4}" />
Expand Down Expand Up @@ -52,9 +50,9 @@
<key id="mark-tilde" output="\m{tilde}" />
<key id="mark-umlaut" output="\m{umlaut}" />

<!-- spaces -->
<key id="nbsp" output="\u{A0}" />
<key id="nnbsp" output="\u{202F}" />
<!-- spaces -->
<key id="nbsp" output="\u{A0}" />
<key id="nnbsp" output="\u{202F}" />

<!-- extra keys -->
<key id="e-grave" output="è" />
Expand Down Expand Up @@ -107,11 +105,8 @@
<key id="radix" output="" />
<key id="C-cedilla" output="Ç" />
<key id="not-equal" output="" />
<key id="open-angle-quote" output="" />
<key id="close-angle-quote" output="" />



<key id="open-angle-quote" output="" />
<key id="close-angle-quote" output="" />

<key id="E-grave" output="È" />
<key id="U-grave" output="Ù" />
Expand Down Expand Up @@ -145,7 +140,7 @@
<row keys="close-angle W X C V B N question bang ellipsis equal" />
<row keys="space" />
</layer>
<!-- layer is for AltGr - for now we use ctrl alt -->
<!-- layer is for AltGr - for now we use ctrl alt -->
<layer modifiers="ctrl alt">
<row
keys="mark-breve section mark-acute mark-grave amp open-square close-square mark-macron underscore open-double close-double degree mark-caron" />
Expand Down Expand Up @@ -179,65 +174,86 @@
<!-- sets representing vowels and accented vowels. -->
<!-- There's an extra space between the lower and upper case for visual separation -->
<!-- but, there are only 10 vowels in the following four sets -->
<!-- plus space at end for the visible version -->
<set id="vowel" value="a e i o u A E I O U" />
<!-- plus space at end for the visible version -->
<set id="vowel" value="a e i o u A E I O U" />

<!-- everything that should take an accented combining char -->
<set id="upaccentable" value="A B C D E F G H I J K L M N O P Q R S T U V W X Y Z Ʒ Æ Œ" />
<set id="lwaccentable" value="a b c d e f g h i j k l m n o p q r s t u v w x y z ʒ æ œ" />
<set id="accentable" value="$[upaccentable] $[lwaccentable]" />

<!-- currency key from/to -->
<!-- currency key from/to -->
<set id="currfrom" value="e r t y p s d f g h k l m w c b n A R T P S D F L M C B"/>
<set id="currto" value="₠ ₽ ₸ ¥ ₱ ₪ ₫ ƒ ₲ ₴ ₭ ₺ ₥ ₩ ¢ ₿ ₦ ₳ ₹ ₮ ₧ ₷ ₯ ₣ ₤ ℳ ₡ ﺀ"/>
<!-- currency key from/to -->
<set id="currfrom" value="e r t y p s d f g h k l m w c b n A R T P S D F L M C B" />
<set id="currto" value="₠ ₽ ₸ ¥ ₱ ₪ ₫ ƒ ₲ ₴ ₭ ₺ ₥ ₩ ¢ ₿ ₦ ₳ ₹ ₮ ₧ ₷ ₯ ₣ ₤ ℳ ₡ ﺀ" />

<!-- greek from/to: deviating from spec, uppercase final sigma (X) is encoded as another Σ -->
<set id="greekfrom" value="a z e r u i o p s d g h j k l m x b n A Z E R U I O P S D G H J K L M X B N" />
<set id="greekto" value="α ζ ε ρ θ ι ο π σ δ γ η ξ κ λ μ ς β ν Α Ζ Ε Ρ Θ Ι Ο Π Σ Δ Γ Η Ξ Κ Λ Μ Σ Β Ν" />
<!-- greek from/to: deviating from spec, uppercase final sigma (X) is encoded as another Σ -->
<set id="greekfrom"
value="a z e r u i o p s d g h j k l m x b n A Z E R U I O P S D G H J K L M X B N" />
<set id="greekto"
value="α ζ ε ρ θ ι ο π σ δ γ η ξ κ λ μ ς β ν Α Ζ Ε Ρ Θ Ι Ο Π Σ Δ Γ Η Ξ Κ Λ Μ Σ Β Ν" />

<!-- euro key from/to -->
<set id="eurofrom" value="a e t i o s d g j ‘ ’ « » ' E T I D G J 7 8 9 0"/>
<set id="euroto" value="ª ə þ ı º ſ ð ŋ ij ‚ ‘ „ ‟ ’ Ə Þ İ Đ Ŋ IJ › ‹ » «"/>
<!-- euro key from/to -->
<set id="eurofrom" value="a e t i o s d g j ‘ ’ « » ' E T I D G J 7 8 9 0" />
<set id="euroto" value="ª ə þ ı º ſ ð ŋ ij ‚ ‘ „ ‟ ’ Ə Þ İ Đ Ŋ IJ › ‹ » «" />

<set id="digits" value="0 1 2 3 4 5 6 7 8 9"/>
<set id="superdigits" value="⁰ ¹ ² ³ ⁴ ⁵ ⁶ ⁷ ⁸ ⁹"/>
<set id="subdigits" value="₀ ₁ ₂ ₃ ₄ ₅ ₆ ₇ ₈ ₉"/>
<!-- numbers -->
<set id="digits" value="0 1 2 3 4 5 6 7 8 9" />
<set id="superdigits" value="⁰ ¹ ² ³ ⁴ ⁵ ⁶ ⁷ ⁸ ⁹" />
<set id="subdigits" value="₀ ₁ ₂ ₃ ₄ ₅ ₆ ₇ ₈ ₉" />
</variables>

<transforms type="simple">
<transformGroup>
<!-- use sets for those that fit neatly into sets -->
<transform from="\m{breve}($[vowel])" to="$1\u{0306}" />
<transform from="\m{umlaut}($[vowel])" to="$1\u{0308}" />
<transform from="\m{invbreve}($[vowel])" to="$1\u{0311}" />

<!-- curr/greek/euro layer for hardware -->
<transform from="\m{currency}($[currfrom])" to="$[1:currto]" />
<transform from="\m{greek}\m{greek}" to="\u{B5}" />
<transform from="\m{greek}($[greekfrom])" to="$[1:greekto]" />
<transform from="\m{euro}($[eurofrom])" to="$[1:euroto]" />

<!-- these are harder to see because they are from AltGr and AltGr+Shift layers -->
<transform from="\m{currency}®" to=""/> <!-- AltGr-R -->
<transform from="\m{currency}%" to=""/> <!-- AltGr-P -->
<transform from="\m{currency}\|" to=""/> <!-- AltGr-L - note pipe is escaped -->
<transform from="\m{currency}∞" to=""/> <!-- AltGr-M -->
<transform from="\m{currency}ç" to=""/> <!-- AltGr-C -->
<transform from="\m{currency}\m{currency}" to="¤"/> <!-- AltGr-Shift-E -->
<transform from="\m{currency}Ç" to=""/> <!-- AltGr-Shift-C (Cedi sign) -->

<!-- tilde is on a subset, not all vowels, + n -->
<transform from="\m{tilde}a" to="ã" />
<transform from="\m{tilde}A" to="Ã" />
<transform from="\m{tilde}n" to="ñ" />
<transform from="\m{tilde}N" to="Ñ" />
<transform from="\m{tilde}o" to="õ" />
<transform from="\m{tilde}O" to="Õ" />

<transform from="\m{breve}($[digits])" to="$[1:superdigits]" />
<transform from="\m{invbreve}($[digits])" to="$[1:subdigits]" />
<!-- super/sub digits -->
<transform from="\m{breve}($[digits])" to="$[1:superdigits]" />
<transform from="\m{invbreve}($[digits])" to="$[1:subdigits]" />

<!-- special cases - any more of these? -->
<transform from="\m{dotabove}i" to="ı" />

<!-- match accentables with combining marks -->
<transform from="\m{breve}($[accentable])" to="$1\u{0306}" />
<transform from="\m{umlaut}($[accentable])" to="$1\u{0308}" />
<transform from="\m{invbreve}($[accentable])" to="$1\u{0311}" />
<transform from="\m{acute}($[accentable])" to="$1\u{0301}" />
<transform from="\m{caret}($[accentable])" to="$1\u{0302}" />
<transform from="\m{caron}($[accentable])" to="$1\u{030c}" />
<transform from="\m{cedilla}($[accentable])" to="$1\u{0327}" />
<transform from="\m{comma}($[accentable])" to="$1\u{0326}" />
<transform from="\m{dotabove}($[accentable])" to="$1\u{0307}" />
<transform from="\m{dotbelow}($[accentable])" to="$1\u{0323}" />
<transform from="\m{doubleacute}($[accentable])" to="$1\u{030b}" />
<transform from="\m{doublegrave}($[accentable])" to="$1\u{030f}" />
<transform from="\m{grave}($[accentable])" to="$1\u{0300}" />
<transform from="\m{macron}($[accentable])" to="$1\u{0304}" />
<transform from="\m{ogonek}($[accentable])" to="$1\u{0328}" />
<transform from="\m{ring}($[accentable])" to="$1\u{030a}" />
<transform from="\m{solidus}($[accentable])" to="$1\u{338}" />
<transform from="\m{stroke}($[accentable])" to="$1\u{0335}" />
<transform from="\m{submacron}($[accentable])" to="$1\u{0331}" />
<transform from="\m{tilde}($[accentable])" to="$1\u{0303}" />

<!-- curr/greek/euro layer for hardware -->
<transform from="\m{currency}($[currfrom])" to="$[1:currto]" />
<transform from="\m{greek}\m{greek}" to="\u{B5}" />
<transform from="\m{greek}($[greekfrom])" to="$[1:greekto]" />
<transform from="\m{euro}($[eurofrom])" to="$[1:euroto]" />

<!-- these are harder to see because they are from AltGr and AltGr+Shift layers -->
<transform from="\m{currency}®" to="" /> <!-- AltGr-R -->
<transform from="\m{currency}%" to="" /> <!-- AltGr-P -->
<transform from="\m{currency}\|" to="" /> <!-- AltGr-L - note pipe is escaped -->
<transform from="\m{currency}∞" to="" /> <!-- AltGr-M -->
<transform from="\m{currency}ç" to="" /> <!-- AltGr-C -->
<transform from="\m{currency}\m{currency}" to="¤" /> <!-- AltGr-Shift-E -->
<transform from="\m{currency}Ç" to="" /> <!-- AltGr-Shift-C (Cedi sign) -->
</transformGroup>
<!-- now, cleanup -->
<transformGroup>
<!-- catch-all: drop any marker that didn't otherwise match before a char -->
<transform from="\m{.}(.)" to="$1" />
<!-- not defined, so drop double euro -->
<transform from="\m{euro}\m{euro}" />
</transformGroup>
<transformGroup>
<!-- catch-all: drop any marker that didn't otherwise match before a char -->
<transform from="\m{.}(.)" to="$1" />
<!-- also drop any doubled marker -->
<!-- (not currently working) <transform from="\m{.}(\m{.})" to="$1" /> -->
</transformGroup>
</transforms>
</keyboard3>

0 comments on commit 40396b1

Please sign in to comment.