Compare commits

...

3 commits

Author SHA1 Message Date
Philippe Miossec
33f1b08e47
Merge 2996c309ce into 8fddf94121 2025-04-11 04:54:09 +02:00
Helium314
8fddf94121 fix unable to change one-handed mode scale 2025-04-08 16:10:04 +02:00
Philippe Miossec
2996c309ce Add french Ergo-L layout
"A Colemak-style layout for French-speaking users
which claims to be better than Bépo for French,
better than Dvorak for English
and better than Qwerty for programming"

See https://github.com/Nuclear-Squid/ErgoL?tab=readme-ov-file#English
More information in french from: https://ergol.org/

Compromise made to port Ergo-L to HeliBoard:
* the 3 bottom symbol keys have been removed (because for good UX, 3rd line is limited to 7 keys). So kept only letter ones...
* dead '*' replaced by a "symbols" key
* '[' and ']' coding characters shifted 1 key to the left
* decided to show the "coding" characters instead of the accentuated characters (which are easier to find and remember)
2024-07-22 14:20:03 +02:00
5 changed files with 48 additions and 4 deletions

View file

@ -0,0 +1,30 @@
q ^ â € 1
c < ç 2
o > œ 3
p $ ô 4
w % 5
j @ ^ 6
m & 7 µ
d * _ 8 §
' | , 9 ; ~ · • " « » “ ” `
y ` û 0
a { à
s ( é
e ) è
n } ê
f = ñ ≠
l \ ( /
r + )
t - î
i / ï ÷
u " ù « » “ ” ' `
z [ æ
x ] ß
v _
b #
h !
g : ; , . …
k ? ¿

View file

@ -78,7 +78,7 @@ class KeyboardWrapperView @JvmOverloads constructor(
val changePercent = 2 * sign * (x - motionEvent.rawX) / context.resources.displayMetrics.density
if (abs(changePercent) < 1) return@setOnTouchListener true
x = motionEvent.rawX
val oldScale = Settings.readOneHandedModeScale(context.prefs(), Settings.getValues().mDisplayOrientation == Configuration.ORIENTATION_PORTRAIT)
val oldScale = Settings.readOneHandedModeScale(context.prefs(), Settings.getValues().mDisplayOrientation == Configuration.ORIENTATION_LANDSCAPE)
val newScale = (oldScale + changePercent / 100f).coerceAtMost(2.5f).coerceAtLeast(0.5f)
if (newScale == oldScale) return@setOnTouchListener true
Settings.getInstance().writeOneHandedModeScale(newScale)

View file

@ -361,7 +361,7 @@ public final class Settings implements SharedPreferences.OnSharedPreferenceChang
public void writeOneHandedModeEnabled(final boolean enabled) {
mPrefs.edit().putBoolean(PREF_ONE_HANDED_MODE_PREFIX +
(mSettingsValues.mDisplayOrientation == Configuration.ORIENTATION_PORTRAIT), enabled).apply();
(mSettingsValues.mDisplayOrientation != Configuration.ORIENTATION_LANDSCAPE), enabled).apply();
}
public static float readOneHandedModeScale(final SharedPreferences prefs, final boolean isLandscape) {
@ -370,7 +370,7 @@ public final class Settings implements SharedPreferences.OnSharedPreferenceChang
public void writeOneHandedModeScale(final Float scale) {
mPrefs.edit().putFloat(PREF_ONE_HANDED_SCALE_PREFIX +
(mSettingsValues.mDisplayOrientation == Configuration.ORIENTATION_PORTRAIT), scale).apply();
(mSettingsValues.mDisplayOrientation != Configuration.ORIENTATION_LANDSCAPE), scale).apply();
}
public static int readOneHandedModeGravity(final SharedPreferences prefs, final boolean isLandscape) {
@ -379,7 +379,7 @@ public final class Settings implements SharedPreferences.OnSharedPreferenceChang
public void writeOneHandedModeGravity(final int gravity) {
mPrefs.edit().putInt(PREF_ONE_HANDED_GRAVITY_PREFIX +
(mSettingsValues.mDisplayOrientation == Configuration.ORIENTATION_PORTRAIT), gravity).apply();
(mSettingsValues.mDisplayOrientation != Configuration.ORIENTATION_LANDSCAPE), gravity).apply();
}
public void writeSplitKeyboardEnabled(final boolean enabled, final boolean isLandscape) {

View file

@ -48,6 +48,7 @@
<item>colemak_dh</item>
<item>workman</item>
<item>bepo</item>
<item>ergol</item>
<item>pcqwerty</item>
</string-array>
<!-- Predefined keyboard layout display names -->
@ -61,6 +62,7 @@
<item>Colemak Mod-DH</item>
<item>Workman</item>
<item>Bépo</item>
<item>Ergo-L</item>
<item>PC</item>
</string-array>
<!-- Description for generic subtype that has predefined layout.
@ -75,6 +77,7 @@
<string name="subtype_generic_colemak_dh" translatable="false" tools:keep="@string/subtype_generic_colemak_dh">%s (Colemak Mod-DH)</string>
<string name="subtype_generic_workman" translatable="false" tools:keep="@string/subtype_generic_workman">%s (Workman)</string>
<string name="subtype_generic_bepo" translatable="false" tools:keep="@string/subtype_generic_bepo">%s (Bépo)</string>
<string name="subtype_generic_ergol" translatable="false" tools:keep="@string/subtype_generic_ergol">%s (Ergo-L)</string>
<string name="subtype_generic_pcqwerty" translatable="false" tools:keep="@string/subtype_generic_pcqwerty">%s (PC)</string>
<!-- Description for Bulgarian (BDS) subtype. -->

View file

@ -512,6 +512,17 @@ are used to. This keyboard does not provide a dictionary, and it is not tied to
language among those that use the Latin alphabet. This keyboard is laid out in the Bépo
disposition rather than other common dispositions for Latin languages. -->
<string name="subtype_no_language_bepo" tools:keep="@string/subtype_no_language_bepo">Alphabet (Bépo)</string>
<!-- This string is displayed in the description for a keyboard type. It refers specifically to
the Latin alphabet, as opposed to Cyrillic, Arabic, Hebrew or other scripts.
When the device is configured to use a language using a script other than the Latin alphabet, the
user still needs a keyboard that can input Latin characters for passwords or login names for
example, and a way to switch to this Latin alphabet keyboard. This string is the description for
this keyboard, so users of other scripts should understand when they read this that it represents a
keyboard that is meant for them to be able to enter Latin characters as opposed to the script they
are used to. This keyboard does not provide a dictionary, and it is not tied to any specific
language among those that use the Latin alphabet. This keyboard is laid out in the Ergo-L
disposition rather than other common dispositions for Latin languages. [CHAR LIMIT=25] -->
<string name="subtype_no_language_ergol" tools:keep="@string/subtype_no_language_ergol">Alphabet (Ergo-L)</string>
<string name="subtype_no_language_pcqwerty" tools:keep="@string/subtype_no_language_pcqwerty">Alphabet (PC)</string>
<!-- Description for Emoji keyboard subtype -->
<string name="subtype_emoji">Emoji</string>