slight adjustments to kannada layout for #444

This commit is contained in:
Helium314 2024-02-10 19:44:20 +01:00
parent b872975189
commit 84713fb0f9
3 changed files with 16 additions and 12 deletions

View file

@ -1,14 +1,14 @@
[popup_keys]
ೌ ಔ %
ೈ ಐ %
ಾ ಆ %
ೀ ಈ %
ೂ ಊ %
ಬ ಭ %
ಹ ಙ %
ಗ ಘ %
ದ ಧ %
ಜ ಝ %
ೌ ಔ %
ೈ ಐ %
ಾ ಆ %
ೀ ಈ %
ೂ ಊ %
ಬ ಭ %
ಹ ಙ %
ಗ ಘ %
ದ ಧ %
ಜ ಝ %
ಡ ಢ
ೋ ಓ
ೇ ಏ
@ -32,3 +32,6 @@
[labels]
alphabet: ಅಆಇ
[number_row]
೧ ೨ ೩ ೪ ೫ ೬ ೭ ೮ ೯

View file

@ -824,7 +824,8 @@ abstract class KeyboardParser(private val params: KeyboardParams, private val co
else R.array.touch_position_correction_data_holo
val hasZwnjKey = params.mId.locale.language in listOf("fa", "ne", "kn", "te") // determine from language, user might have custom layout
// custom non-json layout for non-uppercase language should not have shift key
val hasShiftKey = !params.mId.isAlphabetKeyboard || layout !in listOf("hindi_compact", "bengali", "arabic", "arabic_pc", "hebrew", "kannada", "malayalam", "marathi", "farsi", "tamil", "telugu")
val hasShiftKey = !params.mId.isAlphabetKeyboard
|| layout !in listOf("hindi_compact", "bengali", "arabic", "arabic_pc", "hebrew", "kannada", "kannada_extended","malayalam", "marathi", "farsi", "tamil", "telugu")
val numbersOnTopRow = layout !in listOf("pcqwerty", "lao", "thai", "korean_sebeolsik_390", "korean_sebeolsik_final")
return LayoutInfos(labelFlags, enableProximityCharsCorrection, allowRedundantPopupKeys, touchPositionCorrectionData, hasZwnjKey, hasShiftKey, numbersOnTopRow)
}

View file

@ -103,7 +103,7 @@ public final class PreferencesSettingsFragment extends SubScreenFragment {
final Preference pref = findPreference(Settings.PREF_LOCALIZED_NUMBER_ROW);
if (pref == null) return;
// locales that have a number row defined (not good to have it hardcoded, but reading a bunch of files may be noticeably slow)
final String[] numberRowLocales = new String[] { "ar", "bn", "fa", "gu", "hi", "mr", "ne", "ur" };
final String[] numberRowLocales = new String[] { "ar", "bn", "fa", "gu", "hi", "kn", "mr", "ne", "ur" };
for (final InputMethodSubtype subtype : SubtypeSettingsKt.getEnabledSubtypes(getSharedPreferences(), true)) {
if (ArraysKt.any(numberRowLocales, (l) -> l.equals(SubtypeUtilsKt.locale(subtype).getLanguage()))) {
pref.setVisible(true);