Compare commits
| Author | SHA1 | Date | |
|---|---|---|---|
|
|
0739c6bd2c | ||
|
|
a1de69bcc4 | ||
|
|
5e5937b0f4 | ||
|
|
ce38a4f151 | ||
|
|
0e0c761a92 | ||
|
|
940cf0deb8 | ||
|
|
c2d5b14261 | ||
|
|
ebda7b2c3e | ||
|
|
39f6d294fb | ||
|
|
8b5d971fb5 | ||
|
|
8c7559d8f6 | ||
|
|
d7e5040873 | ||
|
|
b29a344cd0 | ||
|
|
b8e673b614 | ||
|
|
bae82d6ed8 | ||
|
|
f913051dca | ||
|
|
dac702ad0b | ||
|
|
f2f6ef0627 | ||
|
|
6389d58553 | ||
|
|
e40558677e | ||
|
|
ae270b36f4 | ||
|
|
146d520325 | ||
|
|
065d9520e5 | ||
|
|
bb60ed9b13 | ||
|
|
d56e4d129e | ||
|
|
e9f734b6cc | ||
|
|
63e7ac2e94 | ||
|
|
8c29073260 | ||
|
|
38deb810f9 | ||
|
|
d8beda411d | ||
|
|
d96577963e | ||
|
|
f369b5d90b | ||
|
|
f4d88cc087 | ||
|
|
d5676d683f | ||
|
|
332413ed3c | ||
|
|
93d8af4505 | ||
|
|
f74e5a9f73 | ||
|
|
6513c21144 | ||
|
|
79aec5b9bc | ||
|
|
be053b082c | ||
|
|
5ce89d1b4b | ||
|
|
82a9774f5a | ||
|
|
5d1a503210 | ||
|
|
d1aa59768d | ||
|
|
2c52e94e0b | ||
|
|
3adf95a4c9 | ||
|
|
44f39059e4 | ||
|
|
bbc6226839 | ||
|
|
c5f2c0b727 | ||
|
|
fb27f8d36f | ||
|
|
5beacf32b7 | ||
|
|
ad7314a016 | ||
|
|
bef29da3de | ||
|
|
a55506e607 | ||
|
|
b3dcd61c28 | ||
|
|
9257bf7392 | ||
|
|
95bd9312a7 | ||
|
|
0a86f9ab01 | ||
|
|
70d777253c | ||
|
|
d7fa5ffa9a | ||
|
|
b114c78bf1 | ||
|
|
eddf9c6c11 | ||
|
|
148f3dfc05 | ||
|
|
6725d3057b | ||
|
|
cf9fd3a0db | ||
|
|
329a35e7d3 | ||
|
|
b319356a08 | ||
|
|
73267d68fb | ||
|
|
3f2f3177da | ||
|
|
e26e1d112c | ||
|
|
0005eb2dd5 |
@@ -0,0 +1 @@
|
||||
srcs/juloo.keyboard2/ComposeKeyData.java -diff
|
||||
@@ -1,19 +1,26 @@
|
||||
name: Check layouts
|
||||
|
||||
# Runs 'gen_layouts.py' and checks that the generated file were uptodate.
|
||||
# This doesn't run 'check_layout.py'.
|
||||
|
||||
on:
|
||||
workflow_dispatch:
|
||||
push:
|
||||
pull_request:
|
||||
|
||||
jobs:
|
||||
check-layouts:
|
||||
gen-layouts:
|
||||
name: Generated files
|
||||
runs-on: ubuntu-latest
|
||||
steps:
|
||||
- name: Checkout repo
|
||||
uses: actions/checkout@v3
|
||||
uses: actions/checkout@v4
|
||||
- run: python3 gen_layouts.py
|
||||
- name: Check that the generated layouts.xml is uptodate, run python3 gen_layouts.py otherwise
|
||||
- name: "Check that the generated 'layouts.xml' is uptodate, otherwise run 'python3 gen_layouts.py'"
|
||||
run: git diff --exit-code
|
||||
check-layouts:
|
||||
name: check_layout.output
|
||||
runs-on: ubuntu-latest
|
||||
steps:
|
||||
- name: Checkout repo
|
||||
uses: actions/checkout@v4
|
||||
- run: python3 check_layout.py
|
||||
- name: "Check that the generated 'check_layout.output' is uptodate, otherwise run 'python3 check_layout.py'"
|
||||
run: git diff --exit-code
|
||||
|
||||
@@ -10,7 +10,7 @@ jobs:
|
||||
runs-on: ubuntu-latest
|
||||
steps:
|
||||
- name: Checkout repo
|
||||
uses: actions/checkout@v3
|
||||
uses: actions/checkout@v4
|
||||
- run: python3 sync_translations.py
|
||||
- name: Check that strings files are uptodate, run python3 sync_translations.py otherwise
|
||||
run: git diff --exit-code
|
||||
- name: "Check that strings files are uptodate, otherwise run 'python3 sync_translations.py'"
|
||||
run: git add -N . && git diff --exit-code
|
||||
|
||||
@@ -9,17 +9,18 @@ jobs:
|
||||
Build-Apk:
|
||||
runs-on: ubuntu-latest
|
||||
steps:
|
||||
- uses: actions/setup-java@v3
|
||||
- uses: actions/setup-java@v4
|
||||
with:
|
||||
distribution: 'zulu' # See 'Supported distributions' for available options
|
||||
java-version: '17'
|
||||
- name: Checkout repo
|
||||
uses: actions/checkout@v3
|
||||
uses: actions/checkout@v4
|
||||
- name: Restore debug keystore from GitHub Secrets
|
||||
run: |
|
||||
# Check if exist and use the secret named DEBUG_KEYSTORE
|
||||
# The contents of the secret can be obtained -
|
||||
# from the debug.keystore.asc from you local folder (refer to CONTRIBUTING.md#Using the local debug.keystore on the Github CI actions)
|
||||
# from the debug.keystore.asc from you local folder
|
||||
# (refer to CONTRIBUTING.md Using the local debug.keystore on the Github CI actions)
|
||||
if [[ ! "${{ secrets.DEBUG_KEYSTORE }}" = "" ]]; then
|
||||
echo "${{ secrets.DEBUG_KEYSTORE }}" > "debug.keystore.asc"
|
||||
if [[ -s "debug.keystore.asc" ]]; then
|
||||
@@ -28,7 +29,7 @@ jobs:
|
||||
fi
|
||||
fi
|
||||
- name: Build debug APK
|
||||
uses: gradle/gradle-build-action@v2
|
||||
uses: gradle/gradle-build-action@v3
|
||||
env:
|
||||
DEBUG_KEYSTORE: "debug.keystore"
|
||||
DEBUG_KEYSTORE_PASSWORD: debug0
|
||||
@@ -42,7 +43,7 @@ jobs:
|
||||
artifact="${artifact//\//-}" # replace slashes
|
||||
echo "artifact=${artifact}" >> $GITHUB_ENV
|
||||
- name: Upload debug APK
|
||||
uses: actions/upload-artifact@v3
|
||||
uses: actions/upload-artifact@v4
|
||||
with:
|
||||
name: "${{env.artifact}} debug_apk"
|
||||
path: build/outputs/apk/debug/*.apk
|
||||
|
||||
@@ -1,5 +1,8 @@
|
||||
<?xml version="1.0" encoding="utf-8"?>
|
||||
<manifest xmlns:android="http://schemas.android.com/apk/res/android" android:hardwareAccelerated="false">
|
||||
<uses-permission android:name="android.permission.VIBRATE"/>
|
||||
<uses-permission android:name="android.permission.RECEIVE_BOOT_COMPLETED"/>
|
||||
|
||||
<application android:label="@string/app_name" android:allowBackup="true" android:icon="@mipmap/ic_launcher" android:hardwareAccelerated="false">
|
||||
<service android:name="juloo.keyboard2.Keyboard2" android:label="@string/app_name" android:permission="android.permission.BIND_INPUT_METHOD" android:exported="true" android:directBootAware="true">
|
||||
<intent-filter>
|
||||
@@ -7,18 +10,23 @@
|
||||
</intent-filter>
|
||||
<meta-data android:name="android.view.im" android:resource="@xml/method"/>
|
||||
</service>
|
||||
<activity android:name="juloo.keyboard2.SettingsActivity" android:icon="@mipmap/ic_launcher" android:label="@string/settings_activity_label" android:theme="@style/android:Theme.DeviceDefault" android:exported="true" android:directBootAware="true">
|
||||
<activity android:name="juloo.keyboard2.SettingsActivity" android:icon="@mipmap/ic_launcher" android:label="@string/settings_activity_label" android:theme="@style/appTheme" android:exported="true" android:directBootAware="true">
|
||||
<intent-filter>
|
||||
<action android:name="android.intent.action.MAIN"/>
|
||||
</intent-filter>
|
||||
</activity>
|
||||
<activity android:name="juloo.keyboard2.LauncherActivity" android:icon="@mipmap/ic_launcher" android:label="@string/app_name" android:theme="@style/android:Theme.DeviceDefault" android:exported="true" android:directBootAware="true">
|
||||
<activity android:name="juloo.keyboard2.LauncherActivity" android:icon="@mipmap/ic_launcher" android:theme="@style/appTheme" android:exported="true" android:directBootAware="true">
|
||||
<intent-filter>
|
||||
<action android:name="android.intent.action.MAIN"/>
|
||||
<category android:name="android.intent.category.LAUNCHER"/>
|
||||
</intent-filter>
|
||||
</activity>
|
||||
</application>
|
||||
<uses-permission android:name="android.permission.VIBRATE"/>
|
||||
<uses-permission android:name="android.permission.RECEIVE_BOOT_COMPLETED"/>
|
||||
|
||||
<!-- To query enabled input methods for voice IME detection -->
|
||||
<queries>
|
||||
<intent>
|
||||
<action android:name="android.view.InputMethod" />
|
||||
</intent>
|
||||
</queries>
|
||||
</manifest>
|
||||
|
||||
@@ -88,14 +88,15 @@ Github secret named `DEBUG_KEYSTORE`.
|
||||
|
||||
### Adding a layout
|
||||
|
||||
Layouts are defined in XML, see `res/xml/latn_qwerty_us.xml`.
|
||||
Layouts are defined in XML, see `srcs/layouts/latn_qwerty_us.xml`.
|
||||
An online tool for editing layout files written by @Lixquid is available
|
||||
[here](https://unexpected-keyboard-layout-editor.lixquid.com/).
|
||||
|
||||
Makes sure to specify the `name` attribute like in `latn_qwerty_us.xml`,
|
||||
otherwise the layout won't be added to the app.
|
||||
|
||||
The layout file must be placed in the `res/xml/` directory and named according to:
|
||||
The layout file must be placed in the `srcs/layouts` directory and named
|
||||
according to:
|
||||
- script (`latn` for latin, etc..)
|
||||
- layout name (eg. the name of a standard)
|
||||
- country code (or language code if more adequate)
|
||||
@@ -109,6 +110,10 @@ Run `./gradlew checkKeyboardLayouts` to check some properties about your
|
||||
layout. This will change the file `check_layout.output`, which you should
|
||||
commit.
|
||||
|
||||
Layouts are CC0 licensed by default. If you do not want your layout to be
|
||||
released into the public domain, add a copyright notice at the top of the file
|
||||
and a mention in `srcs/layouts/LICENSE`.
|
||||
|
||||
#### Adding a programming layout
|
||||
|
||||
A programming layout must contain all ASCII characters.
|
||||
@@ -173,15 +178,13 @@ default translation in `res/values/strings.xml`, which contain the structure of
|
||||
the file and the English strings.
|
||||
|
||||
To check that `strings.xml` is formatted correctly, run
|
||||
`./gradlew syncTranslations`. This will modify your files.
|
||||
`python sync_translations.py`. This will modify your files.
|
||||
|
||||
The store description is found in `metadata/android/<locale>/`,
|
||||
`short_description.txt` and `full_description.txt`.
|
||||
The short description must not exceed 80 characters.
|
||||
Store descriptions in `metadata/` are updated automatically.
|
||||
Translating changelogs is not useful.
|
||||
|
||||
The app name might be partially translated, the "Unexpected" word should remain
|
||||
untranslated.
|
||||
untranslated if possible.
|
||||
|
||||
As translations need to be updated regularly, you can subscribe to this issue
|
||||
to receive a notification when an update is needed:
|
||||
|
||||
@@ -0,0 +1,3 @@
|
||||
github: [ Julow ]
|
||||
liberapay: Julow
|
||||
custom: [ "https://paypal.me/JulesAguillon" ]
|
||||
@@ -18,6 +18,8 @@ Now perfect for everyday use.
|
||||
|
||||
This application contains no ads, doesn't make any network requests and is Open Source.
|
||||
|
||||
Usage: to apply the symbols located in the corners of each key, slide your finger in the direction of the symbols. For example, the Settings are opened by sliding in the left down corner.
|
||||
|
||||
| <img src="/metadata/android/en-US/images/phoneScreenshots/1.png" alt="Screenshot-1" /> | <img src="/metadata/android/en-US/images/phoneScreenshots/2.png" alt="Screenshot-2"/> | <img src="/metadata/android/en-US/images/phoneScreenshots/3.png" alt="Screenshot-3"/> |
|
||||
| --- | --- | --- |
|
||||
| <img src="/metadata/android/en-US/images/phoneScreenshots/4.png" alt="Screenshot-4" /> | <img src="/metadata/android/en-US/images/phoneScreenshots/5.png" alt="Screenshot-5" /> | <img src="/metadata/android/en-US/images/phoneScreenshots/6.png" alt="Screenshot-6" /> |
|
||||
|
||||
@@ -8,10 +8,10 @@ android {
|
||||
|
||||
defaultConfig {
|
||||
applicationId "juloo.keyboard2"
|
||||
minSdk 4
|
||||
minSdk 11
|
||||
targetSdkVersion 33
|
||||
versionCode 37
|
||||
versionName "1.25.0"
|
||||
versionCode 39
|
||||
versionName "1.27.0"
|
||||
}
|
||||
|
||||
sourceSets {
|
||||
@@ -34,8 +34,7 @@ android {
|
||||
keyAlias(System.env.DEBUG_KEY_ALIAS ? "$System.env.DEBUG_KEY_ALIAS" : "debug")
|
||||
keyPassword(System.env.DEBUG_KEY_PASSWORD ? "$System.env.DEBUG_KEY_PASSWORD" : "debug0")
|
||||
}
|
||||
// Release builds will only be signed with a dedicated key if specified. This key has to be
|
||||
// created manually.
|
||||
|
||||
release {
|
||||
if (System.env.RELEASE_KEYSTORE) {
|
||||
storeFile file(System.env.RELEASE_KEYSTORE)
|
||||
@@ -53,10 +52,9 @@ android {
|
||||
debuggable false
|
||||
proguardFiles getDefaultProguardFile('proguard-android-optimize.txt')
|
||||
resValue "string", "app_name", "@string/app_name_release"
|
||||
if (System.env.RELEASE_KEYSTORE) {
|
||||
signingConfig signingConfigs.release
|
||||
}
|
||||
signingConfig signingConfigs.release
|
||||
}
|
||||
|
||||
debug {
|
||||
minifyEnabled false
|
||||
shrinkResources false
|
||||
@@ -68,14 +66,25 @@ android {
|
||||
}
|
||||
}
|
||||
|
||||
// Name outputs after the application ID.
|
||||
android.applicationVariants.all { variant ->
|
||||
variant.outputs.all {
|
||||
outputFileName = "${applicationId}.apk"
|
||||
}
|
||||
}
|
||||
|
||||
compileOptions {
|
||||
sourceCompatibility JavaVersion.VERSION_1_7
|
||||
targetCompatibility JavaVersion.VERSION_1_7
|
||||
}
|
||||
|
||||
lintOptions {
|
||||
// Translation are already checked by 'syncTranslations'
|
||||
disable 'MissingTranslation'
|
||||
}
|
||||
}
|
||||
|
||||
dependencies {
|
||||
|
||||
}
|
||||
|
||||
tasks.register('buildKeyboardFont') {
|
||||
@@ -98,6 +107,7 @@ tasks.withType(Test).configureEach {
|
||||
dependsOn 'genLayoutsList'
|
||||
dependsOn 'checkKeyboardLayouts'
|
||||
dependsOn 'syncTranslations'
|
||||
dependsOn 'compileComposeSequences'
|
||||
}
|
||||
|
||||
tasks.register('genLayoutsList') {
|
||||
@@ -110,17 +120,13 @@ tasks.register('genLayoutsList') {
|
||||
|
||||
tasks.register('checkKeyboardLayouts') {
|
||||
println "\nChecking layouts"
|
||||
new ByteArrayOutputStream().withStream { bos ->
|
||||
exec {
|
||||
def layouts = new File(projectDir, "res/xml").listFiles().findAll {
|
||||
it.isFile() && it.name.endsWith(".xml")
|
||||
}
|
||||
workingDir = projectDir
|
||||
commandLine("python", "check_layout.py", *layouts)
|
||||
standardOutput = bos
|
||||
exec {
|
||||
def layouts = new File(projectDir, "srcs/layouts").listFiles().findAll {
|
||||
it.name.endsWith(".xml")
|
||||
}
|
||||
|
||||
new File(projectDir, "check_layout.output").write(bos.toString())
|
||||
workingDir = projectDir
|
||||
commandLine("python", "check_layout.py", *layouts)
|
||||
standardOutput = new FileOutputStream("${projectDir}/check_layout.output")
|
||||
}
|
||||
}
|
||||
|
||||
@@ -132,9 +138,23 @@ tasks.register('syncTranslations') {
|
||||
}
|
||||
}
|
||||
|
||||
tasks.register('compileComposeSequences') {
|
||||
def out = "srcs/juloo.keyboard2/ComposeKeyData.java"
|
||||
println "\nGenerating ${out}"
|
||||
exec {
|
||||
def sequences = new File(projectDir, "srcs/compose").listFiles().findAll {
|
||||
it.name.endsWith(".pre") || it.name.endsWith(".json")
|
||||
}
|
||||
workingDir = projectDir
|
||||
commandLine("python", "srcs/compose/compile.py", *sequences)
|
||||
standardOutput = new FileOutputStream("${projectDir}/${out}")
|
||||
}
|
||||
}
|
||||
|
||||
tasks.named("preBuild") {
|
||||
dependsOn += "initDebugKeystore"
|
||||
dependsOn += "copyRawQwertyUS"
|
||||
dependsOn += "copyLayoutDefinitions"
|
||||
}
|
||||
|
||||
tasks.register('initDebugKeystore') {
|
||||
@@ -151,7 +171,16 @@ tasks.register('initDebugKeystore') {
|
||||
tasks.register('copyRawQwertyUS')
|
||||
{
|
||||
copy {
|
||||
from "res/xml/latn_qwerty_us.xml"
|
||||
from "srcs/layouts/latn_qwerty_us.xml"
|
||||
into "build/generated-resources/raw"
|
||||
}
|
||||
}
|
||||
|
||||
tasks.register('copyLayoutDefinitions')
|
||||
{
|
||||
copy {
|
||||
from "srcs/layouts"
|
||||
include "*.xml"
|
||||
into "build/generated-resources/xml"
|
||||
}
|
||||
}
|
||||
|
||||
@@ -2,6 +2,10 @@
|
||||
Layout includes some ASCII punctuation but not all, missing: !, ", ', +, -, /, :, ;, <, =, >, ?, [, \, ], _, |, ~
|
||||
Layout doesn't define some important keys, missing: f11_placeholder, f12_placeholder
|
||||
2 warnings
|
||||
# arab_hamvaj_tly
|
||||
Layout includes some ASCII punctuation but not all, missing: ", %, ', ,, /, ;, <, =, >, ?, [, \, ], _, `, {, |, }
|
||||
Layout doesn't define some important keys, missing: esc, f11_placeholder, f12_placeholder
|
||||
2 warnings
|
||||
# arab_pc
|
||||
Layout includes some ASCII punctuation but not all, missing: !, ', +, ;, ?, \, |
|
||||
1 warnings
|
||||
@@ -39,13 +43,17 @@ Layout includes some ASCII punctuation but not all, missing: #, $, %, &, ', (, )
|
||||
Layout doesn't define some important keys, missing: esc, f11_placeholder, f12_placeholder, tab
|
||||
2 warnings
|
||||
# deva_inscript
|
||||
Duplicate keys: , ।
|
||||
Duplicate keys: ।
|
||||
Layout includes some ASCII punctuation but not all, missing: ", $, ', ^, _, `, |
|
||||
Layout doesn't define some important keys, missing: f11_placeholder, f12_placeholder
|
||||
3 warnings
|
||||
# grek_qwerty
|
||||
Duplicate keys: ;
|
||||
1 warnings
|
||||
# guj_phonetic_in
|
||||
Duplicate keys: ટ, ડ
|
||||
Layout doesn't define some important keys, missing: f11_placeholder, f12_placeholder
|
||||
2 warnings
|
||||
# hang_dubeolsik_kr
|
||||
0 warnings
|
||||
# hebr_1_il
|
||||
@@ -61,10 +69,11 @@ Layout doesn't define some important keys, missing: f11_placeholder, f12_placeho
|
||||
1 warnings
|
||||
# latn_bone
|
||||
Layout includes some ASCII punctuation but not all, missing: $
|
||||
Layout redefines the bottom row but some important keys are missing, missing: switch_backward
|
||||
Layout redefines the bottom row but some important keys are missing, missing: cursor_left, cursor_right, loc compose, loc end, loc home, loc page_down, loc page_up, loc switch_greekmath, loc voice_typing, switch_backward
|
||||
2 warnings
|
||||
# latn_colemak
|
||||
0 warnings
|
||||
Some keys contain whitespaces, unexpected: ́
|
||||
1 warnings
|
||||
# latn_dvorak
|
||||
0 warnings
|
||||
# latn_neo2
|
||||
@@ -76,6 +85,8 @@ Layout doesn't define some important keys, missing: f11_placeholder, f12_placeho
|
||||
1 warnings
|
||||
# latn_qwerty_es
|
||||
0 warnings
|
||||
# latn_qwerty_gb
|
||||
0 warnings
|
||||
# latn_qwerty_hu
|
||||
0 warnings
|
||||
# latn_qwerty_lv
|
||||
@@ -89,14 +100,20 @@ Layout doesn't define some important keys, missing: f11_placeholder, f12_placeho
|
||||
# latn_qwerty_se
|
||||
Duplicate keys: !, ', ,, -, ., ?
|
||||
1 warnings
|
||||
# latn_qwerty_sk
|
||||
Layout doesn't define some important keys, missing: f11_placeholder, f12_placeholder
|
||||
1 warnings
|
||||
# latn_qwerty_tly
|
||||
Duplicate keys: a, c, j, q
|
||||
Layout doesn't define some important keys, missing: esc, f11_placeholder, f12_placeholder, tab
|
||||
2 warnings
|
||||
# latn_qwerty_tr
|
||||
Layout doesn't define some important keys, missing: f11_placeholder, f12_placeholder
|
||||
1 warnings
|
||||
# latn_qwerty_us
|
||||
0 warnings
|
||||
# latn_qwerty_vi
|
||||
Layout includes some ASCII punctuation but not all, missing: \
|
||||
1 warnings
|
||||
0 warnings
|
||||
# latn_qwertz
|
||||
0 warnings
|
||||
# latn_qwertz_cz
|
||||
@@ -113,11 +130,12 @@ Layout doesn't define some important keys, missing: f11_placeholder, f12_placeho
|
||||
# latn_qwertz_hu
|
||||
0 warnings
|
||||
# latn_qwertz_sk
|
||||
Layout includes some ASCII punctuation but not all, missing: \, `
|
||||
Layout includes some ASCII punctuation but not all, missing: `
|
||||
Layout doesn't define some important keys, missing: f11_placeholder, f12_placeholder
|
||||
2 warnings
|
||||
# urdu_phonetic_ur
|
||||
Duplicate keys:
|
||||
Layout includes some ASCII punctuation but not all, missing: <, >, ?, `, |, ~
|
||||
Layout doesn't define some important keys, missing: f11_placeholder, f12_placeholder
|
||||
3 warnings
|
||||
Some keys contain whitespaces, unexpected:
|
||||
4 warnings
|
||||
|
||||
@@ -34,6 +34,15 @@ def unexpected_keys(keys, symbols, msg):
|
||||
if len(unexpected) > 0:
|
||||
warn("%s, unexpected: %s" % (msg, key_list_str(unexpected)))
|
||||
|
||||
# Write to [keys] and [dup].
|
||||
def parse_row_from_et(row, keys, dup):
|
||||
for key in row:
|
||||
for attr in key.keys():
|
||||
if attr.startswith("key"):
|
||||
k = key.get(attr).removeprefix("\\")
|
||||
if k in keys: dup.add(k)
|
||||
keys.add(k)
|
||||
|
||||
def parse_layout(fname):
|
||||
keys = set()
|
||||
dup = set()
|
||||
@@ -41,12 +50,16 @@ def parse_layout(fname):
|
||||
if root.tag != "keyboard":
|
||||
return None
|
||||
for row in root:
|
||||
for key in row:
|
||||
for attr in key.keys():
|
||||
if attr.startswith("key"):
|
||||
k = key.get(attr).removeprefix("\\")
|
||||
if k in keys: dup.add(k)
|
||||
keys.add(k)
|
||||
parse_row_from_et(row, keys, dup)
|
||||
return root, keys, dup
|
||||
|
||||
def parse_row(fname):
|
||||
keys = set()
|
||||
dup = set()
|
||||
root = ET.parse(fname).getroot()
|
||||
if root.tag != "row":
|
||||
return None
|
||||
parse_row_from_et(root, keys, dup)
|
||||
return root, keys, dup
|
||||
|
||||
def check_layout(layout):
|
||||
@@ -66,12 +79,11 @@ def check_layout(layout):
|
||||
[ "f1", "f2", "f3", "f4", "f5", "f6", "f7", "f8", "f9",
|
||||
"f10", "f11", "f12" ],
|
||||
"Layout contains function keys")
|
||||
unexpected_keys(keys, [""], "Layout contains empty strings")
|
||||
unexpected_keys(keys, ["loc"], "Special keyword cannot be a symbol")
|
||||
unexpected_keys(keys, filter(lambda k: k.strip()!=k, keys), "Some keys contain whitespaces")
|
||||
|
||||
bottom_row_keys = [
|
||||
"ctrl", "fn", "switch_numeric", "change_method", "switch_emoji",
|
||||
"config", "switch_forward", "switch_backward", "enter", "action",
|
||||
"left", "up", "right", "down", "space"
|
||||
]
|
||||
_, bottom_row_keys, _ = parse_row("res/xml/bottom_row.xml")
|
||||
|
||||
if root.get("bottom_row") == "false":
|
||||
missing_required(keys, bottom_row_keys,
|
||||
|
||||
@@ -1,7 +1,7 @@
|
||||
#!/usr/bin/env python
|
||||
|
||||
# Generates the list of layouts in res/values/layouts.xml from the layout files
|
||||
# in res/xml. Every layouts must have a 'name' attribute to be listed.
|
||||
# in srcs/layouts. Every layouts must have a 'name' attribute to be listed.
|
||||
|
||||
import itertools as it
|
||||
import sys, os, glob
|
||||
@@ -11,11 +11,6 @@ import xml.etree.ElementTree as XML
|
||||
# are sorted alphabetically.
|
||||
FIRST_LAYOUTS = [ "latn_qwerty_us", "latn_colemak", "latn_dvorak" ]
|
||||
|
||||
# File names that are known not to be layouts. Avoid warning about them.
|
||||
KNOWN_NOT_LAYOUT = set([
|
||||
"number_row", "numpad", "pin", "bottom_row", "settings", "method",
|
||||
"greekmath", "numeric" ])
|
||||
|
||||
# Read a layout from a file. Returns [None] if [fname] is not a layout.
|
||||
def read_layout(fname):
|
||||
root = XML.parse(fname).getroot()
|
||||
@@ -28,9 +23,7 @@ def read_layouts(files):
|
||||
for layout_file in files:
|
||||
layout_id, _ = os.path.splitext(os.path.basename(layout_file))
|
||||
layout = read_layout(layout_file)
|
||||
if layout_id in KNOWN_NOT_LAYOUT:
|
||||
continue
|
||||
elif layout == None:
|
||||
if layout == None:
|
||||
print("Not a layout file: %s" % layout_file)
|
||||
elif layout["name"] == None:
|
||||
print("Layout doesn't have a name: %s" % layout_id)
|
||||
@@ -66,6 +59,6 @@ def generate_arrays(out, layouts):
|
||||
XML.indent(root)
|
||||
XML.ElementTree(element=root).write(out, encoding="unicode", xml_declaration=True)
|
||||
|
||||
layouts = sort_layouts(read_layouts(glob.glob("res/xml/*.xml")))
|
||||
layouts = sort_layouts(read_layouts(glob.glob("srcs/layouts/*.xml")))
|
||||
with open("res/values/layouts.xml", "w") as out:
|
||||
generate_arrays(out, layouts)
|
||||
|
||||
@@ -0,0 +1,7 @@
|
||||
The custom vibration setting is back.
|
||||
Allow to hide the keyboard switching key.
|
||||
Fixed modifier keys in some development apps.
|
||||
Updated translations.
|
||||
Bug fixes and general improvements.
|
||||
|
||||
Many thanks to the contributors: @abb128, @marciozomb13, @RetrogisusDEV, @Sestowner, @vedamanavi, @krtsgnr7230
|
||||
@@ -0,0 +1,6 @@
|
||||
New layouts: QWERTY (Slovak), Gujarati phonetic
|
||||
Add Linux Compose key to type a variety of characters using known combinations.
|
||||
Fixed localized numpad and number row.
|
||||
Many improvements and bug fixes.
|
||||
|
||||
Huge thanks to the contributors: @Yogesh-B, @ChasmSolacer, @matthiakl, @Sestowner, @RyanGibb, @BogdanLata, @RetrogisusDEV, @V6lhost, @ErrrorMaxx, @sdrapha, @vedamanavi
|
||||
|
Before Width: | Height: | Size: 22 KiB After Width: | Height: | Size: 22 KiB |
|
Before Width: | Height: | Size: 22 KiB After Width: | Height: | Size: 22 KiB |
|
Before Width: | Height: | Size: 26 KiB After Width: | Height: | Size: 26 KiB |
|
Before Width: | Height: | Size: 26 KiB After Width: | Height: | Size: 26 KiB |
|
Before Width: | Height: | Size: 24 KiB After Width: | Height: | Size: 24 KiB |
|
Before Width: | Height: | Size: 62 KiB After Width: | Height: | Size: 62 KiB |
|
Before Width: | Height: | Size: 62 KiB After Width: | Height: | Size: 62 KiB |
|
Before Width: | Height: | Size: 20 KiB After Width: | Height: | Size: 20 KiB |
@@ -3,4 +3,4 @@ La característica principal es que hay acceso a más caractéres deslizando hac
|
||||
Esta aplicación fue originalmente diseñada para programadores que usaran Termux.
|
||||
Ahora es perfecta para uso cotidiano.
|
||||
|
||||
La misma no contiene ningún anuncio/publicidad, no realiza peticiones de red y es de Fuente Abierta.
|
||||
La misma no contiene ningún anuncio/publicidad, no realiza peticiones de red y es de Fuente Abierta.
|
||||
@@ -0,0 +1 @@
|
||||
صفحه کلید غیرمنتظره
|
||||
@@ -15,4 +15,4 @@
|
||||
- 다중 레이아웃: QWERTY, QWERTZ, AZERTY. 다양한 테마: White, Dark, OLED Black. 또한 다른 많은 옵션들.
|
||||
|
||||
다른 가상 키보드와 마찬가지로 시스템 설정에서 활성화해야 합니다. 시스템 설정을 열고 다음으로 이동합니다.
|
||||
시스템 > 언어 및 입력 > 키보드 > 키보드 관리.
|
||||
시스템 > 언어 및 입력 > 키보드 > 키보드 관리.
|
||||
@@ -0,0 +1 @@
|
||||
Unexpected Keyboard
|
||||
@@ -0,0 +1 @@
|
||||
Unexpected Keyboard
|
||||
@@ -0,0 +1 @@
|
||||
Unexpected Keyboard
|
||||
@@ -0,0 +1,6 @@
|
||||
Головна особливість полягає в тому, що ви можете вводити більше символів, проводячи клавіші до кутів.
|
||||
|
||||
Ця програма спочатку була розроблена для програмістів, які використовують Termux.
|
||||
Тепер ідеально підходить для щоденного використання.
|
||||
|
||||
Ця програма не містить реклами, не надсилає жодних мережевих запитів і має відкритий код.
|
||||
@@ -0,0 +1 @@
|
||||
Легка та конфіденційна віртуальна клавіатура для Android.
|
||||
@@ -0,0 +1 @@
|
||||
Unexpected Keyboard
|
||||
@@ -0,0 +1 @@
|
||||
Unexpected Keyboard
|
||||
@@ -0,0 +1 @@
|
||||
Unexpected Keyboard
|
||||
@@ -1,4 +1,4 @@
|
||||
<?xml version="1.0" encoding="utf-8"?>
|
||||
<LinearLayout xmlns:android="http://schemas.android.com/apk/res/android" android:layout_width="fill_parent" android:layout_height="wrap_content">
|
||||
<EditText android:id="@+id/text" android:layout_width="fill_parent" android:layout_height="wrap_content" android:layout_margin="10dp"/>
|
||||
<EditText android:id="@+id/text" android:inputType="text" android:importantForAutofill="no" android:layout_width="fill_parent" android:layout_height="wrap_content" android:layout_margin="10dp"/>
|
||||
</LinearLayout>
|
||||
|
||||
@@ -3,6 +3,6 @@
|
||||
<juloo.keyboard2.EmojiGroupButtonsBar android:orientation="horizontal" android:layout_width="fill_parent" android:layout_height="wrap_content"/>
|
||||
<juloo.keyboard2.EmojiGridView android:id="@+id/emoji_grid" android:layout_width="fill_parent" android:layout_height="@dimen/emoji_grid_height" android:orientation="vertical" android:numColumns="auto_fit" android:columnWidth="45sp" android:background="?attr/colorKeyboard"/>
|
||||
<LinearLayout android:orientation="horizontal" android:layout_width="fill_parent" android:layout_height="wrap_content">
|
||||
<juloo.keyboard2.EmojiBottomRow android:layout_width="fill_parent" android:layout_height="wrap_content" android:background="?attr/emoji_key_bg"/>
|
||||
<juloo.keyboard2.Keyboard2View layout="@xml/emoji_bottom_row" android:layout_width="fill_parent" android:layout_height="wrap_content" android:background="?attr/emoji_key_bg"/>
|
||||
</LinearLayout>
|
||||
</LinearLayout>
|
||||
|
||||
@@ -1,12 +1,12 @@
|
||||
<?xml version="1.0" encoding="utf-8"?>
|
||||
<ScrollView xmlns:android="http://schemas.android.com/apk/res/android" android:layout_width="match_parent" android:layout_height="match_parent" android:fillViewport="true">
|
||||
<LinearLayout android:layout_width="fill_parent" android:layout_height="fill_parent" android:orientation="vertical">
|
||||
<LinearLayout android:layout_width="fill_parent" android:layout_height="wrap_content" android:orientation="vertical">
|
||||
<TextView style="@style/paragraph" android:text="@string/launcher_description"/>
|
||||
<Button style="@style/paragraph" android:text="@string/launcher_button_imesettings" android:onClick="launch_imesettings" android:layout_width="wrap_content"/>
|
||||
<Button style="@style/paragraph" android:text="@string/launcher_button_imepicker" android:onClick="launch_imepicker" android:layout_width="wrap_content"/>
|
||||
<VideoView android:id="@+id/launcher_intro_video" android:layout_width="240dp" android:layout_height="wrap_content" android:layout_gravity="center"/>
|
||||
<TextView android:id="@+id/launcher_tryhere_text" style="@style/paragraph" android:text="@string/launcher_tryhere"/>
|
||||
<EditText android:id="@+id/launcher_tryhere_area" style="@style/paragraph" android:inputType="text"/>
|
||||
<EditText android:id="@+id/launcher_tryhere_area" style="@style/paragraph" android:inputType="text" android:hint="@string/launcher_tryhere_hint" android:importantForAutofill="no"/>
|
||||
<TextView style="@style/paragraph" android:text="@string/launcher_sourcecode"/>
|
||||
<TextView style="@style/paragraph" android:text="https://github.com/Julow/Unexpected-Keyboard" android:autoLink="web" android:linksClickable="true"/>
|
||||
</LinearLayout>
|
||||
|
||||