Compare commits

...
37 Commits
Author SHA1 Message Date
Jules Aguillon fdebae929b Release 1.19.0
Make Apk CI / Build-Apk (push) Has been cancelled
2022-11-06 21:20:15 +01:00
Jules Aguillon 25cefc5890 Allow to type password on boot
The "android.permission.RECEIVE_BOOT_COMPLETED" permission doesn't seem
useful on Android 12 but is added just in case.
2022-11-06 21:06:04 +01:00
Jules Aguillon 30198acddd Enable pin layout for decimal and signed inputs
Decimal and signed inputs are more common than expected. Adding a few
keys is enough to support these.
2022-11-06 19:54:55 +01:00
Jules Aguillon 96db0397f0 Fix adding two pointers for the same key 2022-11-06 19:49:30 +01:00
Jules Aguillon d2128e777e Remove option "Lockable modifiers" 2022-11-06 19:34:57 +01:00
Jules Aguillon 6a7fbf5e50 Add combinations to 'accent_slash' and show in settings
The 'accent_slash' was missing in the extra keys setting.

Allow to type more latin letters "with oblique stroke" or "with stroke"
that visually have an oblique bar, that were not added to 'accent_bar'.
2022-11-05 19:33:46 +01:00
Jules Aguillon 1e067c9863 Add the bar diacritic dead key
Allows to type many of the "with stroke" or "with bar" latin letters.
2022-11-05 19:26:49 +01:00
Jules Aguillon ebe66eb740 Apply Fn first
It's otherwise impossible to type Ctrl+F keys.
2022-11-05 10:29:36 +01:00
Jules Aguillon d2328d4b9a Automatic day night theme in settings activity
There seems to be no "DayNight" theme compatible with older version of
android outside of the androidx library.

Using 'Theme.DeviceDefault' which is a dark theme, even if it doesn't
sounds like. Detect if a light theme should be used at activity
creation.
2022-11-05 10:13:35 +01:00
Jules Aguillon 7edfd81db1 Use '₹' instead of '₨' in Hindi
₨ is Shift+₹.
2022-11-01 21:44:49 +01:00
Jules Aguillon 67e46e2da3 Add 'qwertz_cs' to the settings
The layout was added in 5169472d but was not present in the settings.
2022-11-01 21:32:58 +01:00
Jules Aguillon 4f3fcfe64b Add the 'qwertz_de' layout
Similar to 'qwertz' but is wider to show äöü on dedicated keys. Some
punctuations are rebalanced to use the space better.
The default layout for de_DE is changed.
2022-11-01 21:29:18 +01:00
Jules Aguillon 2e598a4d47 Draw letter indication on the pin layout
There is no way to type letters on the pin layout, the indication are
decoration only.
Use the E.161 standard.
2022-10-24 00:27:49 +02:00
Jules Aguillon e01a2733b1 Add the pin entry layout
The layout is used for phone number and datetime input boxes as well as
some numbers.
It is easier to use when the full numeric layout is not needed.
2022-10-24 00:17:55 +02:00
Jules Aguillon e1145d3851 Disable Alt and Meta by default
The Meta key is not useful.
The Alt key can be used in a terminal but is not useful to a part of
terminal users.
2022-10-23 23:09:58 +02:00
Gero Streng baec5a76ee Add optional NumPad
Shows a NumPad depending on preference:
   Never/Landscape/Always
2022-10-23 22:51:36 +02:00
Jules Aguillon ea0b873dd8 Make the shift symbol bigger 2022-10-23 22:02:41 +02:00
Jules Aguillon 6aa4740702 Clarify the double tap option text
Also update a bit the README.
2022-10-23 22:01:43 +02:00
Jules Aguillon ff0c0354d6 Show keys description in settings
The symbols alone might be hard to understand when scrolling through the
"extra keys" option.
2022-10-23 21:51:43 +02:00
Jules Aguillon 344df4c5c1 Refactor: Remove boilerplate for symbol keys 2022-10-23 21:42:03 +02:00
Jules Aguillon 36e10a792f Add the capslock key
The key enable caps lock immediately. It does nothing if caps lock is
already enabled.

It is not present on the keyboard by default but a place is defined on
every layout, top-right of the shift key. It can be enabled in the
settings.

The icon is from materialdesignicons.com.
2022-10-23 21:37:04 +02:00
Jules Aguillon 55cece7965 Remove cruft
This old script will not help to upgrade to the newer unicode standards.
2022-10-16 22:55:01 +02:00
Jules Aguillon 167c63ee25 Release 1.18.0
Make Apk CI / Build-Apk (push) Has been cancelled
2022-10-16 22:42:14 +02:00
Jules Aguillon f56b926857 Autocapitalisation: Avoid trigerring when Ctrl+Del
Autocapitalisation could trigger while repeatedly typing Ctrl+Del to
remove several words.
2022-10-16 22:34:21 +02:00
Jules Aguillon 75df3afda6 Allow to disable Alt and Meta keys
The keys are marked "loc" in the layouts and are handled like the other
extra keys.
The only difference is that they are enabled by default (for now).
2022-10-16 01:07:24 +02:00
Rapha 7fb5c992b6 Rename resulting CI artifact (#180)
* Rename resulting CI artifact
Add details to the name of the artifact, to distiguish downloads of it between multiple branches while testing

* Update CI to nodejs16 and improve artifact naming
2022-10-16 00:53:04 +02:00
Jules Aguillon 158a3577be Disable fullscreen mode
This mode is annoying to some users and is disabled in most text views.

The keyboard has a fixed sized relative to the height of the screen in
landscape mode. The keyboard can't take more space than expected,
currently.

This might cause problems in the future and might be hidden behind an
option if one is found. Every text views so far seemed to behave fine.
2022-10-16 00:42:28 +02:00
Jules Aguillon 138e59f13a Fix literal tab key
Broken since 31d6a70d.
2022-10-16 00:04:06 +02:00
Jules Aguillon db347c665c Add the breve diacritic 2022-10-15 23:28:36 +02:00
lpv 8be80eecd4 Basic greek layout. (#207)
* Basic greek layout.
2022-10-15 23:22:19 +02:00
Jules Aguillon d9a8688237 Fix crash due to auto capitalisation
It is unclear how _autocap.started is not called first but nothing is
preventing to initialize things earlier.
2022-10-15 16:19:27 +02:00
Jules Aguillon 7f51cf001a Mention long press in lockable modifiers option
More documentation about this feature would be appropriate.
2022-10-15 15:55:48 +02:00
Raj9039852537 1909f2fcb4 Added Hindi language layout (#211)
* Hindi Keyboard Layout

Hindi keyboard layout added
Basic symbols like brackets, colons etc are useful. This includes ( ) { } [ ] \ / ÷ - + = ! % : ; . , ?
2022-10-11 22:13:40 +02:00
Jules Aguillon fc8bb3a539 Allow to type İ on the Turkish layout
In Turkish, upper case of 'iı' is 'İI' but Java's toUpperCase will
return 'II'.
To make 'İ' accessible, make it the shift of 'ı'. This has the
inconvenient of swapping i and ı on the keyboard.
2022-10-04 10:12:22 +02:00
Jules Aguillon dda8f0314d Contributing: clarify layouts 2022-10-04 10:12:22 +02:00
polyctenaandBenjamin 5873b7315d German translation (#208)
Co-authored-by: Benjamin <f.weiss@stud.uni-goettingen.de>
2022-10-04 09:56:15 +02:00
Jules Aguillon 64e263a1af Fix an unexplained crash encountered in the wild
For some reason, 'subtype' can be null. Perhaps because the keyboard is
started before the IMM is ready.
2022-09-24 23:34:50 +02:00
62 changed files with 701 additions and 1114 deletions
+10 -5
View File
@@ -9,14 +9,14 @@ jobs:
Build-Apk:
runs-on: ubuntu-latest
steps:
- uses: actions/setup-java@v2
- uses: actions/setup-java@v3
with:
distribution: 'zulu' # See 'Supported distributions' for available options
java-version: '11'
- name: Checkout repo
uses: actions/checkout@v2
uses: actions/checkout@v3
- name: Cache debug certificate
uses: actions/cache@v2
uses: actions/cache@v3
with:
path: _build/debug.keystore
key: debug-keystore
@@ -35,8 +35,13 @@ jobs:
fi
- name: Build
run: make
- name: Artifact naming
run: |
artifact="${{github.repository_owner}} ${{github.ref_name}}"
artifact="${artifact//\//-}" # replace slashes
echo "artifact=${artifact}" >> $GITHUB_ENV
- name: Save debug apk
uses: actions/upload-artifact@v2
uses: actions/upload-artifact@v3
with:
name: debug apk
name: "${{env.artifact}} debug_apk"
path: _build/*.apk
+4 -3
View File
@@ -1,18 +1,19 @@
<?xml version="1.0" encoding="utf-8"?>
<manifest xmlns:android="http://schemas.android.com/apk/res/android" package="juloo.keyboard2" android:versionCode="25" android:versionName="1.17.0" android:hardwareAccelerated="false">
<manifest xmlns:android="http://schemas.android.com/apk/res/android" package="juloo.keyboard2" android:versionCode="27" android:versionName="1.19.0" android:hardwareAccelerated="false">
<uses-sdk android:minSdkVersion="4" android:targetSdkVersion="30"/>
<application android:label="@string/app_name" android:allowBackup="true" android:icon="@drawable/ic_launcher" android:hardwareAccelerated="false">
<service android:name="juloo.keyboard2.Keyboard2" android:label="@string/app_name" android:permission="android.permission.BIND_INPUT_METHOD">
<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>
<action android:name="android.view.InputMethod"/>
</intent-filter>
<meta-data android:name="android.view.im" android:resource="@xml/method"/>
</service>
<activity android:name="juloo.keyboard2.SettingsActivity" android:icon="@drawable/ic_launcher" android:label="@string/settings_activity_label" android:theme="@style/android:Theme.Material">
<activity android:name="juloo.keyboard2.SettingsActivity" android:icon="@drawable/ic_launcher" android:label="@string/settings_activity_label" android:theme="@style/android:Theme.DeviceDefault">
<intent-filter>
<action android:name="android.intent.action.MAIN"/>
</intent-filter>
</activity>
</application>
<uses-permission android:name="android.permission.VIBRATE"/>
<uses-permission android:name="android.permission.RECEIVE_BOOT_COMPLETED"/>
</manifest>
+12 -7
View File
@@ -78,17 +78,22 @@ make installd
## Guidelines
### Adding a programming layout
### Adding a layout
A programming layout must contains every ASCII characters.
The current programming layouts are: QWERTY, Dvorak.
Layouts are defined in XML, see `res/xml/qwerty.xml`.
An entry must be added to the layout option in `res/values/arrays.xml`, to both
`pref_layout_values` (correspond to the file name) and `pref_layout_entries`
(display name).
Layouts are defined in XML, see `res/xml/qwerty.xml`. An entry must be added to
the layout option in `res/values/arrays.xml`, to both `pref_layout_values`
(correspond to the file name) and `pref_layout_entries` (display name).
The layout must also be referenced in `srcs/juloo.keyboard2/Config.java` in
`layoutId_of_string`.
#### Adding a programming layout
A programming layout must contains every ASCII characters.
The current programming layouts are: QWERTY, Dvorak and Colemak.
Keys with a name starting in `loc ` are hidden unless they are configured for
the user's installed languages in `res/xml/method.xml`. These keys are optional
and will be added automatically when necessary.
@@ -97,7 +102,7 @@ Some users cannot easily type the characters close the the edges of the screen
due to a bulky phone case. It is best to avoid placing important characters
there (such as the digits or punctuation).
### Adding a localized layout
#### Adding a localized layout
Localized layouts (a layout specific to a language) are gladly accepted.
See for example: 4333575 (Bulgarian), 88e2175 (Latvian), 133b6ec (German).
+1 -1
View File
@@ -19,7 +19,7 @@ Highlight of some of the features:
- Very light and fast. Use 500x times less space than Google's keyboard and 15x times less than the default keyboard. No ad, no tracking.
- Multiple layouts: QWERTY, QWERTZ, AZERTY. Themes: White, Dark, OLED Black. And many other options.
- Personalizable with many options, layouts and themes.
Like any other virtual keyboards, it must be enabled in the system settings. Open the System Settings and go to:
System > Languages & input > On-screen keyboard > Manage on-screen keyboards.
-908
View File
@@ -1,908 +0,0 @@
from enum import Enum
import sys
class Line(Enum):
IGNORE = 0
GROUP = 1
ENTRY = 2
def parse_line(line):
if line.startswith("# group:"):
return (Line.GROUP, line.split(":")[1].strip())
else:
lr = line.split("#", 1)
if lr[0] == "" or len(lr) != 2:
return (Line.IGNORE, line)
else:
code, status = lr[0].split(";", 1)
desc = lr[1].strip().split(" ", 2)[2]
return (Line.ENTRY, (code.strip(), status.strip(), desc))
def parse_lines(inp):
entries = {}
group = "none"
for line in inp:
tok, k = parse_line(line)
if tok == Line.GROUP:
group = k
elif tok == Line.ENTRY:
entries.setdefault(group, []).append(k)
return entries
name_map = {
"1F44D": ":+1:",
"1F44E": ":-1:",
"1F4AF": ":100:",
"1F522": ":1234:",
"1F3B1": ":8ball:",
"1F170": ":a:",
"1F18E": ":ab:",
"1F524": ":abc:",
"1F521": ":abcd:",
"1F251": ":accept:",
"1F6A1": ":aerial_tramway:",
"02708": ":airplane:",
"023F0": ":alarm_clock:",
"1F47D": ":alien:",
"1F691": ":ambulance:",
"02693": ":anchor:",
"1F47C": ":angel:",
"1F4A2": ":anger:",
"1F620": ":angry:",
"1F627": ":anguished:",
"1F41C": ":ant:",
"1F34E": ":apple:",
"02652": ":aquarius:",
"02648": ":aries:",
"025C0": ":arrow_backward:",
"023EC": ":arrow_double_down:",
"023EB": ":arrow_double_up:",
"02B07": ":arrow_down:",
"1F53D": ":arrow_down_small:",
"025B6": ":arrow_forward:",
"02935": ":arrow_heading_down:",
"02934": ":arrow_heading_up:",
"02B05": ":arrow_left:",
"02199": ":arrow_lower_left:",
"02198": ":arrow_lower_right:",
"027A1": ":arrow_right:",
"021AA": ":arrow_right_hook:",
"02B06": ":arrow_up:",
"02195": ":arrow_up_down:",
"1F53C": ":arrow_up_small:",
"02196": ":arrow_upper_left:",
"02197": ":arrow_upper_right:",
"1F503": ":arrows_clockwise:",
"1F504": ":arrows_counterclockwise:",
"1F3A8": ":art:",
"1F69B": ":articulated_lorry:",
"1F632": ":astonished:",
"1F45F": ":athletic_shoe:",
"1F3E7": ":atm:",
"1F171": ":b:",
"1F476": ":baby:",
"1F37C": ":baby_bottle:",
"1F424": ":baby_chick:",
"1F6BC": ":baby_symbol:",
"1F519": ":back:",
"1F6C4": ":baggage_claim:",
"1F388": ":balloon:",
"02611": ":ballot_box_with_check:",
"1F38D": ":bamboo:",
"1F34C": ":banana:",
"0203C": ":bangbang:",
"1F3E6": ":bank:",
"1F4CA": ":bar_chart:",
"1F488": ":barber:",
"026BE": ":baseball:",
"1F3C0": ":basketball:",
"1F6C0": ":bath:",
"1F6C1": ":bathtub:",
"1F50B": ":battery:",
"1F43B": ":bear:",
"1F41D": ":bee:",
"1F37A": ":beer:",
"1F37B": ":beers:",
"1F41E": ":beetle:",
"1F530": ":beginner:",
"1F514": ":bell:",
"1F371": ":bento:",
"1F6B4": ":bicyclist:",
"1F6B2": ":bike:",
"1F459": ":bikini:",
"1F426": ":bird:",
"1F382": ":birthday:",
"026AB": ":black_circle:",
"1F0CF": ":black_joker:",
"02B1B": ":black_large_square:",
"025FE": ":black_medium_small_square:",
"025FC": ":black_medium_square:",
"02712": ":black_nib:",
"025AA": ":black_small_square:",
"1F532": ":black_square_button:",
"1F33C": ":blossom:",
"1F421": ":blowfish:",
"1F4D8": ":blue_book:",
"1F699": ":blue_car:",
"1F499": ":blue_heart:",
"1F60A": ":blush:",
"1F417": ":boar:",
"026F5": ":boat:",
"1F4A3": ":bomb:",
"1F4D6": ":book:",
"1F516": ":bookmark:",
"1F4D1": ":bookmark_tabs:",
"1F4DA": ":books:",
"1F4A5": ":boom:",
"1F462": ":boot:",
"1F490": ":bouquet:",
"1F647": ":bow:",
"1F3B3": ":bowling:",
"1F466": ":boy:",
"1F35E": ":bread:",
"1F470": ":bride_with_veil:",
"1F309": ":bridge_at_night:",
"1F4BC": ":briefcase:",
"1F494": ":broken_heart:",
"1F41B": ":bug:",
"1F4A1": ":bulb:",
"1F685": ":bullettrain_front:",
"1F684": ":bullettrain_side:",
"1F68C": ":bus:",
"1F68F": ":busstop:",
"1F464": ":bust_in_silhouette:",
"1F465": ":busts_in_silhouette:",
"1F335": ":cactus:",
"1F370": ":cake:",
"1F4C6": ":calendar:",
"1F4F2": ":calling:",
"1F42B": ":camel:",
"1F4F7": ":camera:",
"0264B": ":cancer:",
"1F36C": ":candy:",
"1F520": ":capital_abcd:",
"02651": ":capricorn:",
"1F697": ":car:",
"1F4C7": ":card_index:",
"1F3A0": ":carousel_horse:",
"1F431": ":cat:",
"1F408": ":cat2:",
"1F4BF": ":cd:",
"1F4B9": ":chart:",
"1F4C9": ":chart_with_downwards_trend:",
"1F4C8": ":chart_with_upwards_trend:",
"1F3C1": ":checkered_flag:",
"1F352": ":cherries:",
"1F338": ":cherry_blossom:",
"1F330": ":chestnut:",
"1F414": ":chicken:",
"1F6B8": ":children_crossing:",
"1F36B": ":chocolate_bar:",
"1F384": ":christmas_tree:",
"026EA": ":church:",
"1F3A6": ":cinema:",
"1F3AA": ":circus_tent:",
"1F307": ":city_sunrise:",
"1F306": ":city_sunset:",
"1F191": ":cl:",
"1F44F": ":clap:",
"1F3AC": ":clapper:",
"1F4CB": ":clipboard:",
"1F550": ":clock1:",
"1F559": ":clock10:",
"1F565": ":clock1030:",
"1F55A": ":clock11:",
"1F566": ":clock1130:",
"1F55B": ":clock12:",
"1F567": ":clock1230:",
"1F55C": ":clock130:",
"1F551": ":clock2:",
"1F55D": ":clock230:",
"1F552": ":clock3:",
"1F55E": ":clock330:",
"1F553": ":clock4:",
"1F55F": ":clock430:",
"1F554": ":clock5:",
"1F560": ":clock530:",
"1F555": ":clock6:",
"1F561": ":clock630:",
"1F556": ":clock7:",
"1F562": ":clock730:",
"1F557": ":clock8:",
"1F563": ":clock830:",
"1F558": ":clock9:",
"1F564": ":clock930:",
"1F4D5": ":closed_book:",
"1F510": ":closed_lock_with_key:",
"1F302": ":closed_umbrella:",
"02601": ":cloud:",
"02663": ":clubs:",
"1F378": ":cocktail:",
"02615": ":coffee:",
"1F630": ":cold_sweat:",
"1F4A5": ":collision:",
"1F4BB": ":computer:",
"1F38A": ":confetti_ball:",
"1F616": ":confounded:",
"1F615": ":confused:",
"03297": ":congratulations:",
"1F6A7": ":construction:",
"1F477": ":construction_worker:",
"1F3EA": ":convenience_store:",
"1F36A": ":cookie:",
"1F192": ":cool:",
"1F46E": ":cop:",
"000A9": ":copyright:",
"1F33D": ":corn:",
"1F46B": ":couple:",
"1F491": ":couple_with_heart:",
"1F48F": ":couplekiss:",
"1F42E": ":cow:",
"1F404": ":cow2:",
"1F4B3": ":credit_card:",
"1F319": ":crescent_moon:",
"1F40A": ":crocodile:",
"1F38C": ":crossed_flags:",
"1F451": ":crown:",
"1F622": ":cry:",
"1F63F": ":crying_cat_face:",
"1F52E": ":crystal_ball:",
"1F498": ":cupid:",
"027B0": ":curly_loop:",
"1F4B1": ":currency_exchange:",
"1F35B": ":curry:",
"1F36E": ":custard:",
"1F6C3": ":customs:",
"1F300": ":cyclone:",
"1F483": ":dancer:",
"1F46F": ":dancers:",
"1F361": ":dango:",
"1F3AF": ":dart:",
"1F4A8": ":dash:",
"1F4C5": ":date:",
"1F333": ":deciduous_tree:",
"1F3EC": ":department_store:",
"1F4A0": ":diamond_shape_with_a_dot_inside:",
"02666": ":diamonds:",
"1F61E": ":disappointed:",
"1F625": ":disappointed_relieved:",
"1F4AB": ":dizzy:",
"1F635": ":dizzy_face:",
"1F6AF": ":do_not_litter:",
"1F436": ":dog:",
"1F415": ":dog2:",
"1F4B5": ":dollar:",
"1F38E": ":dolls:",
"1F42C": ":dolphin:",
"1F6AA": ":door:",
"1F369": ":doughnut:",
"1F409": ":dragon:",
"1F432": ":dragon_face:",
"1F457": ":dress:",
"1F42A": ":dromedary_camel:",
"1F4A7": ":droplet:",
"1F4C0": ":dvd:",
"1F4E7": ":e-mail:",
"1F442": ":ear:",
"1F33E": ":ear_of_rice:",
"1F30D": ":earth_africa:",
"1F30E": ":earth_americas:",
"1F30F": ":earth_asia:",
"1F373": ":egg:",
"1F346": ":eggplant:",
"02734": ":eight_pointed_black_star:",
"02733": ":eight_spoked_asterisk:",
"1F50C": ":electric_plug:",
"1F418": ":elephant:",
"02709": ":email:",
"1F51A": ":end:",
"02709": ":envelope:",
"1F4E9": ":envelope_with_arrow:",
"1F4B6": ":euro:",
"1F3F0": ":european_castle:",
"1F3E4": ":european_post_office:",
"1F332": ":evergreen_tree:",
"02757": ":exclamation:",
"1F611": ":expressionless:",
"1F453": ":eyeglasses:",
"1F440": ":eyes:",
"1F44A": ":facepunch:",
"1F3ED": ":factory:",
"1F342": ":fallen_leaf:",
"1F46A": ":family:",
"023E9": ":fast_forward:",
"1F4E0": ":fax:",
"1F628": ":fearful:",
"1F43E": ":feet:",
"1F3A1": ":ferris_wheel:",
"1F4C1": ":file_folder:",
"1F525": ":fire:",
"1F692": ":fire_engine:",
"1F386": ":fireworks:",
"1F313": ":first_quarter_moon:",
"1F31B": ":first_quarter_moon_with_face:",
"1F41F": ":fish:",
"1F365": ":fish_cake:",
"1F3A3": ":fishing_pole_and_fish:",
"0270A": ":fist:",
"1F38F": ":flags:",
"1F526": ":flashlight:",
"1F42C": ":flipper:",
"1F4BE": ":floppy_disk:",
"1F3B4": ":flower_playing_cards:",
"1F633": ":flushed:",
"1F301": ":foggy:",
"1F3C8": ":football:",
"1F463": ":footprints:",
"1F374": ":fork_and_knife:",
"026F2": ":fountain:",
"1F340": ":four_leaf_clover:",
"1F193": ":free:",
"1F364": ":fried_shrimp:",
"1F35F": ":fries:",
"1F438": ":frog:",
"1F626": ":frowning:",
"026FD": ":fuelpump:",
"1F315": ":full_moon:",
"1F31D": ":full_moon_with_face:",
"1F3B2": ":game_die:",
"1F48E": ":gem:",
"0264A": ":gemini:",
"1F47B": ":ghost:",
"1F381": ":gift:",
"1F49D": ":gift_heart:",
"1F467": ":girl:",
"1F310": ":globe_with_meridians:",
"1F410": ":goat:",
"026F3": ":golf:",
"1F347": ":grapes:",
"1F34F": ":green_apple:",
"1F4D7": ":green_book:",
"1F49A": ":green_heart:",
"02755": ":grey_exclamation:",
"02754": ":grey_question:",
"1F62C": ":grimacing:",
"1F601": ":grin:",
"1F600": ":grinning:",
"1F482": ":guardsman:",
"1F3B8": ":guitar:",
"1F52B": ":gun:",
"1F487": ":haircut:",
"1F354": ":hamburger:",
"1F528": ":hammer:",
"1F439": ":hamster:",
"0270B": ":hand:",
"1F45C": ":handbag:",
"1F4A9": ":hankey:",
"1F425": ":hatched_chick:",
"1F423": ":hatching_chick:",
"1F3A7": ":headphones:",
"1F649": ":hear_no_evil:",
"02764": ":heart:",
"1F49F": ":heart_decoration:",
"1F60D": ":heart_eyes:",
"1F63B": ":heart_eyes_cat:",
"1F493": ":heartbeat:",
"1F497": ":heartpulse:",
"02665": ":hearts:",
"02714": ":heavy_check_mark:",
"02797": ":heavy_division_sign:",
"1F4B2": ":heavy_dollar_sign:",
"02757": ":heavy_exclamation_mark:",
"02796": ":heavy_minus_sign:",
"02716": ":heavy_multiplication_x:",
"02795": ":heavy_plus_sign:",
"1F681": ":helicopter:",
"1F33F": ":herb:",
"1F33A": ":hibiscus:",
"1F506": ":high_brightness:",
"1F460": ":high_heel:",
"1F52A": ":hocho:",
"1F36F": ":honey_pot:",
"1F41D": ":honeybee:",
"1F434": ":horse:",
"1F3C7": ":horse_racing:",
"1F3E5": ":hospital:",
"1F3E8": ":hotel:",
"02668": ":hotsprings:",
"0231B": ":hourglass:",
"023F3": ":hourglass_flowing_sand:",
"1F3E0": ":house:",
"1F3E1": ":house_with_garden:",
"1F62F": ":hushed:",
"1F368": ":ice_cream:",
"1F366": ":icecream:",
"1F194": ":id:",
"1F250": ":ideograph_advantage:",
"1F47F": ":imp:",
"1F4E5": ":inbox_tray:",
"1F4E8": ":incoming_envelope:",
"1F481": ":information_desk_person:",
"02139": ":information_source:",
"1F607": ":innocent:",
"02049": ":interrobang:",
"1F4F1": ":iphone:",
"1F3EE": ":izakaya_lantern:",
"1F383": ":jack_o_lantern:",
"1F5FE": ":japan:",
"1F3EF": ":japanese_castle:",
"1F47A": ":japanese_goblin:",
"1F479": ":japanese_ogre:",
"1F456": ":jeans:",
"1F602": ":joy:",
"1F639": ":joy_cat:",
"1F511": ":key:",
"1F51F": ":keycap_ten:",
"1F458": ":kimono:",
"1F48B": ":kiss:",
"1F617": ":kissing:",
"1F63D": ":kissing_cat:",
"1F61A": ":kissing_closed_eyes:",
"1F618": ":kissing_heart:",
"1F619": ":kissing_smiling_eyes:",
"1F428": ":koala:",
"1F201": ":koko:",
"1F3EE": ":lantern:",
"1F535": ":large_blue_circle:",
"1F537": ":large_blue_diamond:",
"1F536": ":large_orange_diamond:",
"1F317": ":last_quarter_moon:",
"1F31C": ":last_quarter_moon_with_face:",
"1F606": ":laughing:",
"1F343": ":leaves:",
"1F4D2": ":ledger:",
"1F6C5": ":left_luggage:",
"02194": ":left_right_arrow:",
"021A9": ":leftwards_arrow_with_hook:",
"1F34B": ":lemon:",
"0264C": ":leo:",
"1F406": ":leopard:",
"0264E": ":libra:",
"1F688": ":light_rail:",
"1F517": ":link:",
"1F444": ":lips:",
"1F484": ":lipstick:",
"1F512": ":lock:",
"1F50F": ":lock_with_ink_pen:",
"1F36D": ":lollipop:",
"027BF": ":loop:",
"1F4E2": ":loudspeaker:",
"1F3E9": ":love_hotel:",
"1F48C": ":love_letter:",
"1F505": ":low_brightness:",
"024C2": ":m:",
"1F50D": ":mag:",
"1F50E": ":mag_right:",
"1F004": ":mahjong:",
"1F4EB": ":mailbox:",
"1F4EA": ":mailbox_closed:",
"1F4EC": ":mailbox_with_mail:",
"1F4ED": ":mailbox_with_no_mail:",
"1F468": ":man:",
"1F472": ":man_with_gua_pi_mao:",
"1F473": ":man_with_turban:",
"1F45E": ":mans_shoe:",
"1F341": ":maple_leaf:",
"1F637": ":mask:",
"1F486": ":massage:",
"1F356": ":meat_on_bone:",
"1F4E3": ":mega:",
"1F348": ":melon:",
"1F4DD": ":memo:",
"1F6B9": ":mens:",
"1F687": ":metro:",
"1F3A4": ":microphone:",
"1F52C": ":microscope:",
"1F30C": ":milky_way:",
"1F690": ":minibus:",
"1F4BD": ":minidisc:",
"1F4F4": ":mobile_phone_off:",
"1F4B8": ":money_with_wings:",
"1F4B0": ":moneybag:",
"1F412": ":monkey:",
"1F435": ":monkey_face:",
"1F69D": ":monorail:",
"1F314": ":moon:",
"1F393": ":mortar_board:",
"1F5FB": ":mount_fuji:",
"1F6B5": ":mountain_bicyclist:",
"1F6A0": ":mountain_cableway:",
"1F69E": ":mountain_railway:",
"1F42D": ":mouse:",
"1F401": ":mouse2:",
"1F3A5": ":movie_camera:",
"1F5FF": ":moyai:",
"1F4AA": ":muscle:",
"1F344": ":mushroom:",
"1F3B9": ":musical_keyboard:",
"1F3B5": ":musical_note:",
"1F3BC": ":musical_score:",
"1F507": ":mute:",
"1F485": ":nail_care:",
"1F4DB": ":name_badge:",
"1F454": ":necktie:",
"0274E": ":negative_squared_cross_mark:",
"1F610": ":neutral_face:",
"1F195": ":new:",
"1F311": ":new_moon:",
"1F31A": ":new_moon_with_face:",
"1F4F0": ":newspaper:",
"1F196": ":ng:",
"1F515": ":no_bell:",
"1F6B3": ":no_bicycles:",
"026D4": ":no_entry:",
"1F6AB": ":no_entry_sign:",
"1F645": ":no_good:",
"1F4F5": ":no_mobile_phones:",
"1F636": ":no_mouth:",
"1F6B7": ":no_pedestrians:",
"1F6AD": ":no_smoking:",
"1F6B1": ":non-potable_water:",
"1F443": ":nose:",
"1F4D3": ":notebook:",
"1F4D4": ":notebook_with_decorative_cover:",
"1F3B6": ":notes:",
"1F529": ":nut_and_bolt:",
"02B55": ":o:",
"1F17E": ":o2:",
"1F30A": ":ocean:",
"1F419": ":octopus:",
"1F362": ":oden:",
"1F3E2": ":office:",
"1F197": ":ok:",
"1F44C": ":ok_hand:",
"1F646": ":ok_woman:",
"1F474": ":older_man:",
"1F475": ":older_woman:",
"1F51B": ":on:",
"1F698": ":oncoming_automobile:",
"1F68D": ":oncoming_bus:",
"1F694": ":oncoming_police_car:",
"1F696": ":oncoming_taxi:",
"1F4D6": ":open_book:",
"1F4C2": ":open_file_folder:",
"1F450": ":open_hands:",
"1F62E": ":open_mouth:",
"026CE": ":ophiuchus:",
"1F4D9": ":orange_book:",
"1F4E4": ":outbox_tray:",
"1F402": ":ox:",
"1F4E6": ":package:",
"1F4C4": ":page_facing_up:",
"1F4C3": ":page_with_curl:",
"1F4DF": ":pager:",
"1F334": ":palm_tree:",
"1F43C": ":panda_face:",
"1F4CE": ":paperclip:",
"1F17F": ":parking:",
"0303D": ":part_alternation_mark:",
"026C5": ":partly_sunny:",
"1F6C2": ":passport_control:",
"1F43E": ":paw_prints:",
"1F351": ":peach:",
"1F350": ":pear:",
"1F4DD": ":pencil:",
"0270F": ":pencil2:",
"1F427": ":penguin:",
"1F614": ":pensive:",
"1F3AD": ":performing_arts:",
"1F623": ":persevere:",
"1F64D": ":person_frowning:",
"1F471": ":person_with_blond_hair:",
"1F64E": ":person_with_pouting_face:",
"0260E": ":phone:",
"1F437": ":pig:",
"1F416": ":pig2:",
"1F43D": ":pig_nose:",
"1F48A": ":pill:",
"1F34D": ":pineapple:",
"02653": ":pisces:",
"1F355": ":pizza:",
"1F447": ":point_down:",
"1F448": ":point_left:",
"1F449": ":point_right:",
"0261D": ":point_up:",
"1F446": ":point_up_2:",
"1F693": ":police_car:",
"1F429": ":poodle:",
"1F4A9": ":poop:",
"1F3E3": ":post_office:",
"1F4EF": ":postal_horn:",
"1F4EE": ":postbox:",
"1F6B0": ":potable_water:",
"1F45D": ":pouch:",
"1F357": ":poultry_leg:",
"1F4B7": ":pound:",
"1F63E": ":pouting_cat:",
"1F64F": ":pray:",
"1F478": ":princess:",
"1F44A": ":punch:",
"1F49C": ":purple_heart:",
"1F45B": ":purse:",
"1F4CC": ":pushpin:",
"1F6AE": ":put_litter_in_its_place:",
"02753": ":question:",
"1F430": ":rabbit:",
"1F407": ":rabbit2:",
"1F40E": ":racehorse:",
"1F4FB": ":radio:",
"1F518": ":radio_button:",
"1F621": ":rage:",
"1F683": ":railway_car:",
"1F308": ":rainbow:",
"0270B": ":raised_hand:",
"1F64C": ":raised_hands:",
"1F64B": ":raising_hand:",
"1F40F": ":ram:",
"1F35C": ":ramen:",
"1F400": ":rat:",
"0267B": ":recycle:",
"1F697": ":red_car:",
"1F534": ":red_circle:",
"000AE": ":registered:",
"0263A": ":relaxed:",
"1F60C": ":relieved:",
"1F501": ":repeat:",
"1F502": ":repeat_one:",
"1F6BB": ":restroom:",
"1F49E": ":revolving_hearts:",
"023EA": ":rewind:",
"1F380": ":ribbon:",
"1F35A": ":rice:",
"1F359": ":rice_ball:",
"1F358": ":rice_cracker:",
"1F391": ":rice_scene:",
"1F48D": ":ring:",
"1F680": ":rocket:",
"1F3A2": ":roller_coaster:",
"1F413": ":rooster:",
"1F339": ":rose:",
"1F6A8": ":rotating_light:",
"1F4CD": ":round_pushpin:",
"1F6A3": ":rowboat:",
"1F3C9": ":rugby_football:",
"1F3C3": ":runner:",
"1F3C3": ":running:",
"1F3BD": ":running_shirt_with_sash:",
"1F202": ":sa:",
"02650": ":sagittarius:",
"026F5": ":sailboat:",
"1F376": ":sake:",
"1F461": ":sandal:",
"1F385": ":santa:",
"1F4E1": ":satellite:",
"1F606": ":satisfied:",
"1F3B7": ":saxophone:",
"1F3EB": ":school:",
"1F392": ":school_satchel:",
"02702": ":scissors:",
"0264F": ":scorpius:",
"1F631": ":scream:",
"1F640": ":scream_cat:",
"1F4DC": ":scroll:",
"1F4BA": ":seat:",
"03299": ":secret:",
"1F648": ":see_no_evil:",
"1F331": ":seedling:",
"1F367": ":shaved_ice:",
"1F411": ":sheep:",
"1F41A": ":shell:",
"1F6A2": ":ship:",
"1F455": ":shirt:",
"1F4A9": ":shit:",
"1F45E": ":shoe:",
"1F6BF": ":shower:",
"1F4F6": ":signal_strength:",
"1F52F": ":six_pointed_star:",
"1F3BF": ":ski:",
"1F480": ":skull:",
"1F634": ":sleeping:",
"1F62A": ":sleepy:",
"1F3B0": ":slot_machine:",
"1F539": ":small_blue_diamond:",
"1F538": ":small_orange_diamond:",
"1F53A": ":small_red_triangle:",
"1F53B": ":small_red_triangle_down:",
"1F604": ":smile:",
"1F638": ":smile_cat:",
"1F603": ":smiley:",
"1F63A": ":smiley_cat:",
"1F608": ":smiling_imp:",
"1F60F": ":smirk:",
"1F63C": ":smirk_cat:",
"1F6AC": ":smoking:",
"1F40C": ":snail:",
"1F40D": ":snake:",
"1F3C2": ":snowboarder:",
"02744": ":snowflake:",
"026C4": ":snowman:",
"1F62D": ":sob:",
"026BD": ":soccer:",
"1F51C": ":soon:",
"1F198": ":sos:",
"1F509": ":sound:",
"1F47E": ":space_invader:",
"02660": ":spades:",
"1F35D": ":spaghetti:",
"02747": ":sparkle:",
"1F387": ":sparkler:",
"02728": ":sparkles:",
"1F496": ":sparkling_heart:",
"1F64A": ":speak_no_evil:",
"1F50A": ":speaker:",
"1F4AC": ":speech_balloon:",
"1F6A4": ":speedboat:",
"02B50": ":star:",
"1F31F": ":star2:",
"1F303": ":stars:",
"1F689": ":station:",
"1F5FD": ":statue_of_liberty:",
"1F682": ":steam_locomotive:",
"1F372": ":stew:",
"1F4CF": ":straight_ruler:",
"1F353": ":strawberry:",
"1F61B": ":stuck_out_tongue:",
"1F61D": ":stuck_out_tongue_closed_eyes:",
"1F61C": ":stuck_out_tongue_winking_eye:",
"1F31E": ":sun_with_face:",
"1F33B": ":sunflower:",
"1F60E": ":sunglasses:",
"02600": ":sunny:",
"1F305": ":sunrise:",
"1F304": ":sunrise_over_mountains:",
"1F3C4": ":surfer:",
"1F363": ":sushi:",
"1F69F": ":suspension_railway:",
"1F613": ":sweat:",
"1F4A6": ":sweat_drops:",
"1F605": ":sweat_smile:",
"1F360": ":sweet_potato:",
"1F3CA": ":swimmer:",
"1F523": ":symbols:",
"1F489": ":syringe:",
"1F389": ":tada:",
"1F38B": ":tanabata_tree:",
"1F34A": ":tangerine:",
"02649": ":taurus:",
"1F695": ":taxi:",
"1F375": ":tea:",
"0260E": ":telephone:",
"1F4DE": ":telephone_receiver:",
"1F52D": ":telescope:",
"1F3BE": ":tennis:",
"026FA": ":tent:",
"1F4AD": ":thought_balloon:",
"1F44E": ":thumbsdown:",
"1F44D": ":thumbsup:",
"1F3AB": ":ticket:",
"1F42F": ":tiger:",
"1F405": ":tiger2:",
"1F62B": ":tired_face:",
"02122": ":tm:",
"1F6BD": ":toilet:",
"1F5FC": ":tokyo_tower:",
"1F345": ":tomato:",
"1F445": ":tongue:",
"1F51D": ":top:",
"1F3A9": ":tophat:",
"1F69C": ":tractor:",
"1F6A5": ":traffic_light:",
"1F683": ":train:",
"1F686": ":train2:",
"1F68A": ":tram:",
"1F6A9": ":triangular_flag_on_post:",
"1F4D0": ":triangular_ruler:",
"1F531": ":trident:",
"1F624": ":triumph:",
"1F68E": ":trolleybus:",
"1F3C6": ":trophy:",
"1F379": ":tropical_drink:",
"1F420": ":tropical_fish:",
"1F69A": ":truck:",
"1F3BA": ":trumpet:",
"1F455": ":tshirt:",
"1F337": ":tulip:",
"1F422": ":turtle:",
"1F4FA": ":tv:",
"1F500": ":twisted_rightwards_arrows:",
"1F495": ":two_hearts:",
"1F46C": ":two_men_holding_hands:",
"1F46D": ":two_women_holding_hands:",
"1F239": ":u5272:",
"1F234": ":u5408:",
"1F23A": ":u55b6:",
"1F22F": ":u6307:",
"1F237": ":u6708:",
"1F236": ":u6709:",
"1F235": ":u6e80:",
"1F21A": ":u7121:",
"1F238": ":u7533:",
"1F232": ":u7981:",
"1F233": ":u7a7a:",
"02614": ":umbrella:",
"1F612": ":unamused:",
"1F51E": ":underage:",
"1F513": ":unlock:",
"1F199": ":up:",
"0270C": ":v:",
"1F6A6": ":vertical_traffic_light:",
"1F4FC": ":vhs:",
"1F4F3": ":vibration_mode:",
"1F4F9": ":video_camera:",
"1F3AE": ":video_game:",
"1F3BB": ":violin:",
"0264D": ":virgo:",
"1F30B": ":volcano:",
"1F19A": ":vs:",
"1F6B6": ":walking:",
"1F318": ":waning_crescent_moon:",
"1F316": ":waning_gibbous_moon:",
"026A0": ":warning:",
"0231A": ":watch:",
"1F403": ":water_buffalo:",
"1F349": ":watermelon:",
"1F44B": ":wave:",
"03030": ":wavy_dash:",
"1F312": ":waxing_crescent_moon:",
"1F314": ":waxing_gibbous_moon:",
"1F6BE": ":wc:",
"1F629": ":weary:",
"1F492": ":wedding:",
"1F433": ":whale:",
"1F40B": ":whale2:",
"0267F": ":wheelchair:",
"02705": ":white_check_mark:",
"026AA": ":white_circle:",
"1F4AE": ":white_flower:",
"02B1C": ":white_large_square:",
"025FD": ":white_medium_small_square:",
"025FB": ":white_medium_square:",
"025AB": ":white_small_square:",
"1F533": ":white_square_button:",
"1F390": ":wind_chime:",
"1F377": ":wine_glass:",
"1F609": ":wink:",
"1F43A": ":wolf:",
"1F469": ":woman:",
"1F45A": ":womans_clothes:",
"1F452": ":womans_hat:",
"1F6BA": ":womens:",
"1F61F": ":worried:",
"1F527": ":wrench:",
"0274C": ":x:",
"1F49B": ":yellow_heart:",
"1F4B4": ":yen:",
"1F60B": ":yum:",
"026A1": ":zap:",
"1F4A4": ":zzz:",
}
# Decode hex numbers separated by spaces into a string
def decode_points(code):
return "".join(map(lambda c: chr(int(c, 16)), code.split()))
def make_name(code):
return ":" + "".join(map(lambda c: "u" + c, code.split())) + ":"
# def fetch(url):
# return request.urlopen(url).read().decode().split("\n")
# https://unicode.org/Public/emoji/13.1/emoji-test.txt
with open(sys.argv[1]) as f:
entries = parse_lines(f)
def keep_emoji(e):
code, status, _ = e
code = code.split()
# Keep only interesting emojis (others are duplicates or won't render well)
# Remove skin tone variants, they are accessible through combinations
return status in [ "fully-qualified", "component" ] and \
not (len(code) > 1 and code[-1] in [ "1F3FB", "1F3FC", "1F3FD", "1F3FE", "1F3FF" ])
for group in entries.values():
group = list(filter(keep_emoji, group))
print("%d" % len(group))
for code, status, desc in group:
name = name_map[code] if code in name_map else make_name(code)
print("%s %s %s" % (name, decode_points(code), desc))
+7
View File
@@ -0,0 +1,7 @@
New supported languages: Hindi, Greek
Disable fullscreen mode.
Improvements to layouts and translations.
Various fixes and improvements.
Thanks to the contributors: @sdrapha, @lpv11, @Raj9039852537, @polyctena
+11
View File
@@ -0,0 +1,11 @@
New layouts: QWERTZ (Deutsch)
Add optional numpad for wide screens.
Add pin entry layout for numbers.
Remove option "Lockable modifiers".
Hide Alt and Meta keys by default.
Added more optional keys.
Allow typing password on boot.
Improvements to the layouts and bug fixes.
Thanks to the contributors: @geroxyz
-2
View File
@@ -23,8 +23,6 @@
<string name="pref_vibrate_summary">Zapnout/Vypnout vibrace při stisku klávesy</string>
<string name="pref_precise_repeat_title">Precizní posun kurzoru</string>
<string name="pref_precise_repeat_summary">Zda-li posun prstem ovlivňuje rychlost kurzoru</string>
<string name="pref_lockable_keys_title">Zastaralé: Zamykatelné modifikační klávesy</string>
<string name="pref_lockable_keys_summary">Tato možnost bude v budoucnu odebrána</string>
<string name="pref_lock_double_tap_title">Dvojklik pro aktivaci caps lock(u)</string>
<string name="pref_lock_double_tap_summary">Dvojklik namísto držení modifikačních kláves po nějakou dobu</string>
<string name="pref_category_style">Styl</string>
+13
View File
@@ -1,5 +1,7 @@
<?xml version="1.0" encoding="utf-8"?>
<resources>
<string name="app_name" product="debug">Unexpected Keyboard (Debug)</string>
<string name="app_name" product="default">Unexpected Keyboard</string>
<string name="settings_activity_label">Unexpected Keyboard - Einstellungen</string>
<string name="pref_category_layout">Layout</string>
<string name="pref_layout_title">Tastaturlayout ändern</string>
@@ -8,9 +10,16 @@
<string name="pref_accents_e_all_installed">Akzente für alle installierten Sprachen anzeigen</string>
<string name="pref_accents_e_selected">Akzente nur für die gewählte Sprache anzeigen</string>
<string name="pref_accents_e_none">Akzente verbergen</string>
<string name="pref_show_numpad_title">Ziffernblock anzeigen</string>
<string name="pref_show_numpad_never">Nie</string>
<string name="pref_show_numpad_landscape">Nur im Querformat</string>
<string name="pref_show_numpad_always">Immer</string>
<string name="pref_programming_layout_title">Tastaturlayout zum Programmieren</string>
<string name="pref_extra_keys_title">Zusätzliche Zeichen zur Tastatur hinzufügen</string>
<string name="pref_programming_layout_none">Keines</string>
<string name="pref_category_typing">Tippen</string>
<string name="pref_autocapitalisation_title">Automatische Großschreibung</string>
<string name="pref_autocapitalisation_summary">Shift-Taste am Satzanfang aktivieren</string>
<string name="pref_swipe_dist_title">Länge der Wischgeste</string>
<string name="pref_swipe_dist_summary">Abstand der Zeichen in den Ecken der Tasten (%s)</string>
<string name="pref_long_timeout_title">Zeitüberschreitung bei Tastenwiederholung</string>
@@ -19,9 +28,12 @@
<string name="pref_vibrate_summary">Vibration bei Tastendruck ein-/ausschalten</string>
<string name="pref_precise_repeat_title">Präzise Cursorsteuerung</string>
<string name="pref_precise_repeat_summary">Geschwindigkeit der Tastenwiederholung durch weniger oder mehr Wischen anpassen</string>
<string name="pref_lock_double_tap_title">Umschalttaste mit Doppeltippen einrasten</string>
<string name="pref_lock_double_tap_summary">Anstatt Taste längere Zeit gedrückt zu halten</string>
<string name="pref_category_style">Design</string>
<string name="pref_margin_bottom_title">Unterer Abstand</string>
<string name="pref_keyboard_height_title">Höhe der Tastatur</string>
<string name="pref_keyboard_height_landscape_title">Höhe der Tastatur im Querformat</string>
<string name="pref_horizontal_margin_title">Horizontaler Abstand</string>
<string name="pref_character_size_title">Größe der Beschriftung</string>
<string name="pref_character_size_summary">Größe der Buchstaben auf den Tasten (%.2fx)</string>
@@ -30,6 +42,7 @@
<string name="pref_theme_e_dark">Dunkel</string>
<string name="pref_theme_e_light">Hell</string>
<string name="pref_theme_e_black">Schwarz</string>
<string name="pref_theme_e_white">Weiß</string>
<string name="pref_swipe_dist_e_very_short">Sehr kurz</string>
<string name="pref_swipe_dist_e_short">Kurz</string>
<string name="pref_swipe_dist_e_default">Normal</string>
+4
View File
@@ -8,6 +8,10 @@
<string name="pref_accents_e_all_installed">Afficher les accents pour les langues installées</string>
<string name="pref_accents_e_selected">Afficher les accents pour la langue sélectionnée</string>
<string name="pref_accents_e_none">Cacher les accents</string>
<string name="pref_show_numpad_title">Afficher le pavé numérique</string>
<string name="pref_show_numpad_never">Jamais</string>
<string name="pref_show_numpad_landscape">Seulement en mode paysage</string>
<string name="pref_show_numpad_always">Toujour</string>
<string name="pref_autocapitalisation_title">Majuscule automatique</string>
<string name="pref_autocapitalisation_summary">Active Shift au début des phrases</string>
<string name="pref_category_typing">Saisie</string>
-1
View File
@@ -23,7 +23,6 @@
<string name="pref_vibrate_summary">Abilita/Disabilita Vibrazione alla pressione dei tasti</string>
<string name="pref_precise_repeat_title">Movimento puntatore preciso</string>
<string name="pref_precise_repeat_summary">Modula la veocità della ripetizione con lo swipe</string>
<string name="pref_lockable_keys_title">Deprecato: Modificatori bloccabili</string>
<string name="pref_lock_double_tap_title">Doppio tocco su Shift per attivare CapsLock</string>
<string name="pref_lock_double_tap_summary">Invece di premere i modificatori a lungo</string>
<string name="pref_category_style">Stile</string>
-2
View File
@@ -24,8 +24,6 @@
<string name="pref_vibrate_summary">Iespējot/atspējot taustiņa piespiešanas trīcēšanu</string>
<string name="pref_precise_repeat_title">Pielāgojama kursora kustība</string>
<string name="pref_precise_repeat_summary">Mainīt taustiņa atkārtošanās ātrumu ar pavilkšanas attālumu</string>
<string name="pref_lockable_keys_title">Novecojis: Slēdzami pārveidotāji</string>
<string name="pref_lockable_keys_summary">Šī iespēja tiks noņemta</string>
<string name="pref_lock_double_tap_title">Divkāršs piesitiens burtslēgam</string>
<string name="pref_lock_double_tap_summary">Tā vietā, lai ilstoši piespiestu pārveidotāju</string>
<string name="pref_category_style">Izskata pielāgojumi</string>
-2
View File
@@ -23,8 +23,6 @@
<string name="pref_vibrate_summary">Ativar/desativar vibração ao digitar</string>
<string name="pref_precise_repeat_title">Precisão nos movimentos do cursor</string>
<string name="pref_precise_repeat_summary">Varia a velocidade de repetição a depender do quanto deslizar</string>
<string name="pref_lockable_keys_title">Descontinuado: Modificadores fixáveis</string>
<string name="pref_lockable_keys_summary">Essa opção será removida</string>
<string name="pref_lock_double_tap_title">Tecle duas vezes no shift para caixa alta</string>
<string name="pref_lock_double_tap_summary">Ao invés de apertar e segurar por um tempo</string>
<string name="pref_category_style">Estilo</string>
-2
View File
@@ -20,8 +20,6 @@
<string name="pref_vibrate_summary">Включение/выключение вибрации при нажатии клавиши</string>
<string name="pref_precise_repeat_title">Точные перемещения курсора</string>
<string name="pref_precise_repeat_summary">Модулируйте скорость повторения клавиш, проводя пальцем больше или меньше</string>
<string name="pref_lockable_keys_title">Запираемые модификаторы</string>
<string name="pref_lockable_keys_summary">Модификаторы, которые можно заблокировать, введя их дважды</string>
<string name="pref_category_style">Стиль</string>
<string name="pref_margin_bottom_title">Нижняя граница поля</string>
<string name="pref_keyboard_height_title">Высота клавиатуры</string>
+18
View File
@@ -6,6 +6,7 @@
<item>qwerty</item>
<item>qwerty_pt</item>
<item>qwerty_es</item>
<item>qwerty_el</item>
<item>qwerty_ko</item>
<item>qwerty_lv</item>
<item>qwerty_no</item>
@@ -14,6 +15,8 @@
<item>qwerty_tr</item>
<item>ru_jcuken</item>
<item>qwertz</item>
<item>qwertz_cs</item>
<item>qwertz_de</item>
<item>qwertz_hu</item>
<item>bgph1</item>
<item>dvorak</item>
@@ -22,6 +25,7 @@
<item>bone</item>
<item>jcuken_ua</item>
<item>bangla</item>
<item>hindi</item>
</string-array>
<string-array name="pref_layout_entries">
<item>@string/pref_layout_e_system</item>
@@ -29,6 +33,7 @@
<item>QWERTY</item>
<item>QWERTY (Brasileiro)</item>
<item>QWERTY (Español)</item>
<item>QWERTY (Greek)</item>
<item>QWERTY (Korean)</item>
<item>QWERTY (Latvian)</item>
<item>QWERTY (Norwegian)</item>
@@ -37,6 +42,8 @@
<item>QWERTY (Türkçe)</item>
<item>ЙЦУКЕН (Русский)</item>
<item>QWERTZ</item>
<item>QWERTZ (Czech)</item>
<item>QWERTZ (Deutsch)</item>
<item>QWERTZ (Hungarian)</item>
<item>Bulgarian (Phonetic Traditional)</item>
<item>Dvorak</item>
@@ -45,6 +52,7 @@
<item>Bone</item>
<item>ЙЦУКЕН (Українська)</item>
<item>বাংলা</item>
<item>हिन्दी</item>
</string-array>
<string-array name="pref_programming_layout_values">
<item>none</item>
@@ -63,6 +71,16 @@
<item>@string/pref_accents_e_selected</item>
<item>@string/pref_accents_e_none</item>
</string-array>
<string-array name="pref_show_numpad_values">
<item>never</item>
<item>landscape</item>
<item>always</item>
</string-array>
<string-array name="pref_show_numpad_entries">
<item>@string/pref_show_numpad_never</item>
<item>@string/pref_show_numpad_landscape</item>
<item>@string/pref_show_numpad_always</item>
</string-array>
<string-array name="pref_accents_values">
<item>1</item>
<item>2</item>
+5 -3
View File
@@ -10,6 +10,10 @@
<string name="pref_accents_e_all_installed">Show accents for all installed languages</string>
<string name="pref_accents_e_selected">Only show accents for the selected language</string>
<string name="pref_accents_e_none">Hide accents</string>
<string name="pref_show_numpad_title">Show NumPad</string>
<string name="pref_show_numpad_never">Never</string>
<string name="pref_show_numpad_landscape">Only in landscape mode</string>
<string name="pref_show_numpad_always">Always</string>
<string name="pref_autocapitalisation_title">Automatic capitalisation</string>
<string name="pref_autocapitalisation_summary">Press Shift at the beginning of a sentence</string>
<string name="pref_extra_keys_title">Add keys to the keyboard</string>
@@ -24,10 +28,8 @@
<string name="pref_vibrate_summary">Enable/disable vibration on keypress</string>
<string name="pref_precise_repeat_title">Precise cursor movements</string>
<string name="pref_precise_repeat_summary">Modulate key repeat speed by swiping more or less</string>
<string name="pref_lockable_keys_title">Deprecated: Lockable modifiers</string>
<string name="pref_lockable_keys_summary">This option will be removed</string>
<string name="pref_lock_double_tap_title">Double tap on shift for caps lock</string>
<string name="pref_lock_double_tap_summary">Instead of holding modifiers for a time</string>
<string name="pref_lock_double_tap_summary">You can lock any modifier by holding it</string>
<string name="pref_category_style">Style</string>
<string name="pref_margin_bottom_title">Margin bottom</string>
<string name="pref_keyboard_height_title">Keyboard height</string>
+1 -1
View File
@@ -25,7 +25,7 @@
<key key0="m" key3="*"/>
</row>
<row>
<key width="2.0" key0="shift"/>
<key width="2.0" key0="shift" key2="loc capslock"/>
<key key0="w" key3="&lt;" key4="&gt;"/>
<key key0="x"/>
<key key0="c" key1="accent_cedille" key3="," key4="\?"/>
+1 -1
View File
@@ -24,7 +24,7 @@
<key key0="দ" key1="_" key2="ধ" key3="(" key4=")"/>
</row>
<row>
<key width="1.4" key0="shift"/>
<key width="1.4" key0="shift" key2="loc capslock"/>
<key shift="0.1" key0="্র" key2="্য" key3="\#" key4="*"/>
<key key0="ো" key1="ৌ" key2="ও" key3="ঔ" key4="\@"/>
<key key0="ে" key1="ৈ" key2="এ" key3="ঐ" key4="%"/>
+3 -3
View File
@@ -25,7 +25,7 @@
<key key0="g" key1="\@" key3=":"/>
</row>
<row>
<key width="1.5" key0="shift" key4="\#"/>
<key width="1.5" key0="shift" key4="\#" key2="loc capslock"/>
<key key0="f" key4="|"/>
<key key0="v" key4="~"/>
<key key0="ß" key4="`"/>
@@ -36,8 +36,8 @@
<key width="1.5" key0="backspace" key1="delete" key3=";"/>
</row>
<row height="0.95">
<key width="1.8" key0="ctrl" key2="meta" key4="switch_numeric"/>
<key width="1.2" key0="fn" key1="alt" key2="change_method" key3="switch_emoji" key4="config"/>
<key width="1.8" key0="ctrl" key2="loc meta" key4="switch_numeric"/>
<key width="1.2" key0="fn" key1="loc alt" key2="change_method" key3="switch_emoji" key4="config"/>
<key width="4.0" key0="space" key1="switch_programming" key2="0" edgekeys="true"/>
<key width="1.2" key1="up" key2="right" key3="left" key4="down" edgekeys="true"/>
<key width="1.8" key0="enter" key3="action"/>
+2 -2
View File
@@ -1,7 +1,7 @@
<?xml version="1.0" encoding="utf-8"?>
<row height="0.95">
<key width="1.8" key0="ctrl" key1="loc switch_greekmath" key2="meta" key4="switch_numeric"/>
<key width="1.2" key0="fn" key1="alt" key2="change_method" key3="switch_emoji" key4="config"/>
<key width="1.8" key0="ctrl" key1="loc switch_greekmath" key2="loc meta" key4="switch_numeric"/>
<key width="1.2" key0="fn" key1="loc alt" key2="change_method" key3="switch_emoji" key4="config"/>
<key width="4.0" key0="space" key1="switch_programming" edgekeys="true"/>
<key width="1.2" key1="up" key2="right" key3="left" key4="down" edgekeys="true"/>
<key width="1.8" key0="enter" key2="action"/>
+1 -1
View File
@@ -26,7 +26,7 @@
</row>
<row>
<key key0="shift" width="1.5" />
<key key0="shift" key2="loc capslock" width="1.5" />
<key key0="z" key1="," key2="."/>
<key key0="x" key1="&gt;" key2="&lt;"/>
<key key0="c" key1="{" key2="}" key3="loc accent_cedille"/>
+1 -1
View File
@@ -25,7 +25,7 @@
<key key0="γ" key1="⌀"/>
</row>
<row>
<key width="1.5" key0="shift"/>
<key width="1.5" key0="shift" key2="loc capslock"/>
<key key0="φ" key3="⇌" key4="√"/>
<key key0="η" key3="accent_arrow_right" key4="∪"/>
<key key0="ϡ" key4="∩"/>
+37
View File
@@ -0,0 +1,37 @@
<?xml version="1.0" encoding="utf-8"?>
<keyboard>
<row>
<key key0="ौ" key1="औ" key2="₹" key3="esc" key4="१"/>
<key key0="ै" key1="ऐ" key2="ऍ" key3="¶" key4="२"/>
<key key0="ा" key1="आ" key2="ॅ" key3="ग़" key4="३"/>
<key key0="ी" key1="ई" key2="ज्ञ" key3="ज़" key4="४"/>
<key key0="ू" key1="ऊ" key2="त्र" key3="ऩ" key4="५"/>
<key key0="ब" key1="भ" key2="क्ष" key3="÷" key4="६"/>
<key key0="ह" key1="ङ" key2="श्र" key3="×" key4="७"/>
<key key0="ग" key1="घ" key2="ः" key3="=" key4="८"/>
<key key0="द" key1="ध" key2="ऋ" key3="+" key4="९"/>
<key key0="ज" key1="झ" key2="ृ" key3="-" key4="०"/>
</row>
<row>
<key shift="0.5" key0="ो" key1="ओ" key2="ॉ" key3="tab" key4="ऑ"/>
<key key0="े" key1="ए" key2="ञ" key3="~" key4="॰"/>
<key key0="्" key1="अ" key2="़" key3="ऽ" key4="ऺ"/>
<key key0="ि" key1="इ" key2="ढ" key3="॥" key4="ॄ"/>
<key key0="ु" key1="उ" key2="ड" key3="\\" key4="/"/>
<key key0="प" key1="फ" key2="छ" key3="&lt;" key4="&gt;"/>
<key key0="र" key1="ऱ" key2="च" key3="[" key4="]"/>
<key key0="क" key1="ख" key2="क़" key3="{" key4="}"/>
<key key0="त" key1="थ" key2="ख़" key3="(" key4=")"/>
</row>
<row>
<key width="1.4" key0="shift" key2="loc capslock"/>
<key shift="0.1" key0="ट" key1="ठ" key2="ड़" key3="\#" key4="*"/>
<key key0="ं" key1="ँ" key2="।" key3="ॐ" key4="\@"/>
<key key0="म" key1="ण" key2="य" key3="य़" key4="%"/>
<key key0="न" key1="" key2="।" key3=":" key4="&amp;"/>
<key key0="व" key1="" key2="ढ़" key3=";" key4="."/>
<key key0="ल" key1="ळ" key2="फ़" key3="!" key4=","/>
<key key0="स" key1="श" key2="ष" key3="\?" key4="।"/>
<key shift="0.1" width="1.4" key0="backspace" key2="delete"/>
</row>
</keyboard>
+1 -1
View File
@@ -27,7 +27,7 @@
<key key0="є" key2="|" key3="\\"/>
</row>
<row>
<key width="1.1" key0="shift"/>
<key width="1.1" key0="shift" key2="loc capslock"/>
<key key0="я"/>
<key key0="ч" />
<key key0="с" />
+1 -1
View File
@@ -24,7 +24,7 @@
<key key0="л" key1="щ" key2="|" key3="\\" key4="ю"/>
</row>
<row>
<key width="1.5" key0="shift"/>
<key width="1.5" key0="shift" key2="loc capslock"/>
<key key0="з"/>
<key key0="ь" key3="ѝ"/>
<key key0="ц" key2="&lt;" key3="."/>
+1 -1
View File
@@ -28,7 +28,7 @@
<key key0="э" key2="|" key3="\\"/>
</row>
<row>
<key width="1.18" key0="shift"/>
<key width="1.18" key0="shift" key2="loc capslock"/>
<key width="0.96" key0="я"/>
<key width="0.96" key0="ч"/>
<key width="0.96" key0="с"/>
+3 -1
View File
@@ -2,7 +2,8 @@
<input-method xmlns:android="http://schemas.android.com/apk/res/android" android:settingsActivity="juloo.keyboard2.SettingsActivity" android:supportsSwitchingToNextInputMethod="true">
<subtype android:label="%s" android:languageTag="bg" android:imeSubtypeLocale="bg_BG" android:imeSubtypeMode="keyboard" android:isAsciiCapable="true" android:imeSubtypeExtraValue="default_layout=bgph1,extra_keys=€"/>
<subtype android:label="%s" android:languageTag="bn" android:imeSubtypeLocale="bn_BD" android:imeSubtypeMode="keyboard" android:isAsciiCapable="true" android:imeSubtypeExtraValue="default_layout=qwerty,extra_keys=৳"/>
<subtype android:label="%s" android:languageTag="de" android:imeSubtypeLocale="de_DE" android:imeSubtypeMode="keyboard" android:isAsciiCapable="true" android:imeSubtypeExtraValue="default_layout=qwertz,extra_keys=accent_trema|ß|€"/>
<subtype android:label="%s" android:languageTag="hi" android:imeSubtypeLocale="hi_IN" android:imeSubtypeMode="keyboard" android:isAsciiCapable="true" android:imeSubtypeExtraValue="default_layout=hindi,extra_keys=₹"/>
<subtype android:label="%s" android:languageTag="de" android:imeSubtypeLocale="de_DE" android:imeSubtypeMode="keyboard" android:isAsciiCapable="true" android:imeSubtypeExtraValue="default_layout=qwertz_de,extra_keys=accent_trema|ß|€"/>
<subtype android:label="%s" android:languageTag="en-GB" android:imeSubtypeLocale="en_GB" android:imeSubtypeMode="keyboard" android:isAsciiCapable="true" android:imeSubtypeExtraValue="default_layout=qwerty,extra_keys=£|€"/>
<subtype android:label="%s" android:languageTag="en-US" android:imeSubtypeLocale="en_US" android:imeSubtypeMode="keyboard" android:isAsciiCapable="true" android:imeSubtypeExtraValue="default_layout=qwerty"/>
<subtype android:label="%s" android:languageTag="es" android:imeSubtypeLocale="es_ES" android:imeSubtypeMode="keyboard" android:isAsciiCapable="true" android:imeSubtypeExtraValue="default_layout=qwerty_es,extra_keys=accent_grave|accent_aigu|accent_tilde|accent_trema|€"/>
@@ -21,4 +22,5 @@
<subtype android:label="%s" android:languageTag="tr" android:imeSubtypeLocale="tr_TR" android:imeSubtypeMode="keyboard" android:isAsciiCapable="true" android:imeSubtypeExtraValue="default_layout=qwerty_tr,extra_keys=accent_cedille|accent_trema|₺|ı|ğ"/>
<subtype android:label="%s" android:languageTag="uk" android:imeSubtypeLocale="uk_UA" android:imeSubtypeMode="keyboard" android:isAsciiCapable="true" android:imeSubtypeExtraValue="default_layout=jcuken_ua"/>
<subtype android:label="%s" android:languageTag="cs" android:imeSubtypeLocale="cs_CZ" android:imeSubtypeMode="keyboard" android:isAsciiCapable="true" android:imeSubtypeExtraValue="default_layout=qwertz_cs,extra_keys=a|accent_cedille|accent_circonflexe"/>
<subtype android:label="%s" android:languageTag="el" android:imeSubtypeLocale="el" android:imeSubtypeMode="keyboard" android:isAsciiCapable="true" android:imeSubtypeExtraValue="default_layout=qwerty_el,extra_keys=£|€"/>
</input-method>
+3 -3
View File
@@ -27,7 +27,7 @@
<key key0="y" key3="\@"/>
</row>
<row>
<key width="1.5" key0="shift" key1="esc"/>
<key width="1.5" key0="shift" key1="esc" key2="loc capslock"/>
<key key0="ü" key4="\#"/>
<key key0="ö" key4="$"/>
<key key0="ä" key4="|"/>
@@ -39,8 +39,8 @@
<key width="1.5" key0="backspace" key2="delete"/>
</row>
<row height="0.95">
<key width="1.8" key0="ctrl" key2="meta" key4="switch_numeric"/>
<key width="1.2" key0="fn" key1="alt" key2="change_method" key3="switch_emoji" key4="config"/>
<key width="1.8" key0="ctrl" key2="loc meta" key4="switch_numeric"/>
<key width="1.2" key0="fn" key1="loc alt" key2="change_method" key3="switch_emoji" key4="config"/>
<key width="4.0" key0="space" key1="switch_programming" edgekeys="true"/>
<key width="1.2" key1="up" key2="right" key3="left" key4="down" edgekeys="true"/>
<key key0="j" key4=";"/>
+2 -2
View File
@@ -1,5 +1,5 @@
<?xml version="1.0" encoding="utf-8"?>
<keyboard bottom_row="false" extra_keys="false">
<keyboard bottom_row="false" extra_keys="false" num_pad="false">
<row>
<key width="0.75" key0="esc" key2="~" key4="!"/>
<key width="0.75" key0="(" key2="[" key4="{"/>
@@ -20,7 +20,7 @@
</row>
<row>
<key width="0.75" key0="switch_greekmath"/>
<key width="0.75" key0="shift" key2="fn" key4="alt"/>
<key width="0.75" key0="shift" key2="fn" key4="loc alt"/>
<key key0="1" key1="superscript" key2="ordinal" key3="subscript"/>
<key key0="2"/>
<key key0="3"/>
+27
View File
@@ -0,0 +1,27 @@
<?xml version="1.0" encoding="utf-8"?>
<keyboard bottom_row="false">
<row>
<key key0="7"/>
<key key0="8"/>
<key key0="9"/>
<key key0="/"/>
</row>
<row>
<key key0="4"/>
<key key0="5"/>
<key key0="6"/>
<key key0="*"/>
</row>
<row>
<key key0="1"/>
<key key0="2"/>
<key key0="3"/>
<key key0="-"/>
</row>
<row height="0.95">
<key key0="0"/>
<key key0="."/>
<key key0="="/>
<key key0="+"/>
</row>
</keyboard>
+27
View File
@@ -0,0 +1,27 @@
<?xml version="1.0" encoding="utf-8"?>
<keyboard width="6.0" bottom_row="false" extra_keys="false" num_pad="false">
<row>
<key shift="1.0" key0="1"/>
<key key0="2" indication="ABC"/>
<key key0="3" indication="DEF"/>
<key key0="backspace" key2="delete"/>
</row>
<row>
<key shift="1.0" key0="4" indication="GHI"/>
<key key0="5" indication="JKL"/>
<key key0="6" indication="MNO"/>
<key key0="(" key3=":" key4="-"/>
</row>
<row>
<key shift="1.0" key0="7" indication="PQRS"/>
<key key0="8" indication="TUV"/>
<key key0="9" indication="WXYZ"/>
<key key0=")" key2="," key3="/" key4="."/>
</row>
<row>
<key shift="1.0" key0="*" key1="switch_text" key3="switch_numeric"/>
<key key0="0" key3="+" key4="space"/>
<key key0="\#" key1="up" key2="right" key3="left" key4="down" edgekeys="true"/>
<key key0="enter" key2="action"/>
</row>
</keyboard>
+1 -1
View File
@@ -24,7 +24,7 @@
<key key0="l" key2="|" key3="\\"/>
</row>
<row>
<key width="1.5" key0="shift"/>
<key width="1.5" key0="shift" key2="loc capslock"/>
<key key0="z"/>
<key key0="x"/>
<key key0="c" key1="loc accent_cedille" key2="&lt;" key3="."/>
+37
View File
@@ -0,0 +1,37 @@
<?xml version="1.0" encoding="utf-8"?>
<keyboard>
<row>
<key key0=";" key2="1" key4="esc"/>
<key key0="ς" key1="~" key2="2" key3="\@"/>
<key key0="ε" key1="!" key2="3" key3="\#" key4="loc €"/>
<key key0="ρ" key2="4" key3="$"/>
<key key0="τ" key2="5" key3="%"/>
<key key0="υ" key2="6" key3="^"/>
<key key0="θ" key2="7" key3="&amp;"/>
<key key0="ι" key1="accent_trema" key2="8" key3="*"/>
<key key0="ο" key2="9" key3="(" key4=")"/>
<key key0="π" key2="0" key3="f11_placeholder" key4="f12_placeholder"/>
</row>
<row>
<key shift="0.5" key0="α" key1="tab" key2="`"/>
<key key0="σ"/>
<key key0="δ" key2="loc £"/>
<key key0="φ"/>
<key key0="γ" key2="-" key3="_"/>
<key key0="η" key2="=" key3="+"/>
<key key0="ξ" key2="accent_aigu" key3="{" key4="}"/>
<key key0="κ" key2="accent_grave" key3="[" key4="]"/>
<key key0="λ" key2="|" key3="\\"/>
</row>
<row>
<key width="1.5" key0="shift" key2="loc capslock"/>
<key key0="ζ"/>
<key key0="χ"/>
<key key0="ψ" key2="&lt;" key3="."/>
<key key0="ω" key2="&gt;" key3=","/>
<key key0="β" key2="\?" key3="/"/>
<key key0="ν" key2=":" key3=";"/>
<key key0="μ" key2="&quot;" key3="'"/>
<key width="1.5" key0="backspace" key2="delete"/>
</row>
</keyboard>
+1 -1
View File
@@ -25,7 +25,7 @@
<key key0="ñ" key1="·" key3="ç" />
</row>
<row>
<key width="1.5" key0="shift"/>
<key width="1.5" key0="shift" key2="loc capslock"/>
<key key0="z"/>
<key key0="x"/>
<key key0="c" key1="loc accent_cedille" key2="&lt;" key3="."/>
+1 -1
View File
@@ -24,7 +24,7 @@
<key key0="l" key1="$" key3="/"/>
</row>
<row>
<key width="1.5" key0="shift"/>
<key width="1.5" key0="shift" key2="loc capslock"/>
<key key0="z" key3="&lt;" key4="&gt;"/>
<key key0="x" key4="\#"/>
<key key0="c" key4="&amp;"/>
+1 -1
View File
@@ -24,7 +24,7 @@
<key key0="ㅣ" key2="|" key3="\\"/>
</row>
<row>
<key width="1.5" key0="shift"/>
<key width="1.5" key0="shift" key2="loc capslock"/>
<key key0="ㅋ"/>
<key key0="ㅌ"/>
<key key0="ㅊ" key2="&lt;" key3="."/>
+1 -1
View File
@@ -24,7 +24,7 @@
<key key0="l" key1="ļ" key2="|" key3="/" key4="\\"/>
</row>
<row>
<key width="1.5" key0="shift"/>
<key width="1.5" key0="shift" key2="loc capslock"/>
<key key0="z" key1="ž"/>
<key key0="x"/>
<key key0="c" key1="č"/>
+1 -1
View File
@@ -24,7 +24,7 @@
<key key0="l" key2="|" key3="\\"/>
</row>
<row>
<key width="1.5" key0="shift"/>
<key width="1.5" key0="shift" key2="loc capslock"/>
<key key0="z"/>
<key key0="x"/>
<key key0="c" key1="loc accent_cedille" key2="&lt;" key3="."/>
+1 -1
View File
@@ -25,7 +25,7 @@
<key key0="ç" key1="|"/>
</row>
<row>
<key width="1.5" key0="shift"/>
<key width="1.5" key0="shift" key2="loc capslock"/>
<key key0="z"/>
<key key0="x"/>
<key key0="c"/>
+1 -1
View File
@@ -27,7 +27,7 @@
<key key0="ä" key1="'" key3="&quot;"/>
</row>
<row>
<key width="1.5" key0="shift"/>
<key width="1.5" key0="shift" key2="loc capslock"/>
<key key0="z"/>
<key key0="x"/>
<key key0="c"/>
+1 -1
View File
@@ -24,7 +24,7 @@
<key key0="l" key2="|" key3="\\"/>
</row>
<row>
<key width="1.5" key0="shift"/>
<key width="1.5" key0="shift" key2="loc capslock"/>
<key key0="z"/>
<key key0="x"/>
<key key0="c" key1="ç" key2="&lt;" key3="."/>
+1 -1
View File
@@ -24,7 +24,7 @@
<key key0="l" key1="'" key3="\#"/>
</row>
<row>
<key width="1.5" key0="shift"/>
<key width="1.5" key0="shift" key2="loc capslock"/>
<key key0="y" key1="&gt;" key2="|" key3="&lt;"/>
<key key0="x"/>
<key key0="c"/>
+1 -1
View File
@@ -24,7 +24,7 @@
<key key0="l" key2="ľ" key3="\\" key4="ĺ"/>
</row>
<row>
<key width="1.5" key0="shift"/>
<key width="1.5" key0="shift" key2="loc capslock"/>
<key key0="y" key1="÷" key2="ý"/>
<key key0="x" key1="∙" key3="×"/>
<key key0="c" key1="\#" key2="γ" key3="&amp;" key4="č"/>
+40
View File
@@ -0,0 +1,40 @@
<?xml version="1.0" encoding="utf-8"?>
<keyboard>
<row>
<key key0="q" key2="1" key4="esc"/>
<key key0="w" key1="^" key2="2" key3="&quot;" key4="\@"/>
<key key0="e" key1="§" key2="3" key3="!" key4="€"/>
<key key0="r" key2="4" key3="$" key4="f11_placeholder"/>
<key key0="t" key2="5" key3="%" key4="f12_placeholder"/>
<key key0="z" key2="6" key3="&amp;"/>
<key key0="u" key2="7" key3="{" key4="}"/>
<key key0="i" key2="8" key3="[" key4="]"/>
<key key0="o" key2="9" key3="(" key4=")"/>
<key key0="p" key2="0" key3="="/>
<key key0="ü" key3="\?"/>
</row>
<row>
<key key0="a" key2="tab"/>
<key key0="s" key1="`" key3="ß"/>
<key key0="d"/>
<key key0="f" key1="~"/>
<key key0="g" key3="-"/>
<key key0="h" key3="+"/>
<key key0="j" key3="*"/>
<key key0="k" key3="/"/>
<key key0="l" key1="'" key3="\\"/>
<key key0="ö" key3="\#"/>
<key key0="ä"/>
</row>
<row>
<key width="1.5" key0="shift" key2="loc capslock"/>
<key shift="0.5" key0="y" key1="&gt;" key2="|" key3="&lt;"/>
<key key0="x"/>
<key key0="c"/>
<key key0="v"/>
<key key0="b" key1=";" key3=","/>
<key key0="n" key1=":" key3="."/>
<key key0="m" key1="_"/>
<key shift="0.5" width="1.5" key0="backspace" key2="delete"/>
</row>
</keyboard>
+1 -1
View File
@@ -24,7 +24,7 @@
<key key0="l" key1="$" key3="/"/>
</row>
<row>
<key width="1.5" key0="shift"/>
<key width="1.5" key0="shift" key2="loc capslock"/>
<key key0="y" key3="&lt;" key4="&gt;"/>
<key key0="x" key4="\#"/>
<key key0="c" key4="&amp;"/>
+7 -9
View File
@@ -3,6 +3,7 @@
<PreferenceCategory android:title="@string/pref_category_layout">
<ListPreference android:key="layout" android:title="@string/pref_layout_title" android:summary="%s" android:defaultValue="system" android:entries="@array/pref_layout_entries" android:entryValues="@array/pref_layout_values"/>
<ListPreference android:key="accents" android:title="@string/pref_accents_title" android:summary="%s" android:defaultValue="1" android:entries="@array/pref_accents_entries" android:entryValues="@array/pref_accents_values"/>
<ListPreference android:key="show_numpad" android:title="@string/pref_show_numpad_title" android:summary="%s" android:defaultValue="1" android:entries="@array/pref_show_numpad_entries" android:entryValues="@array/pref_show_numpad_values"/>
<ListPreference android:key="programming_layout" android:title="@string/pref_programming_layout_title" android:summary="%s" android:defaultValue="none" android:entries="@array/pref_programming_layout_entries" android:entryValues="@array/pref_programming_layout_values"/>
<PreferenceScreen android:title="@string/pref_extra_keys_title">
<juloo.keyboard2.ExtraKeyCheckBoxPreference app:index="0"/>
@@ -21,6 +22,12 @@
<juloo.keyboard2.ExtraKeyCheckBoxPreference app:index="13"/>
<juloo.keyboard2.ExtraKeyCheckBoxPreference app:index="14"/>
<juloo.keyboard2.ExtraKeyCheckBoxPreference app:index="15"/>
<juloo.keyboard2.ExtraKeyCheckBoxPreference app:index="16"/>
<juloo.keyboard2.ExtraKeyCheckBoxPreference app:index="17"/>
<juloo.keyboard2.ExtraKeyCheckBoxPreference app:index="18"/>
<juloo.keyboard2.ExtraKeyCheckBoxPreference app:index="19"/>
<juloo.keyboard2.ExtraKeyCheckBoxPreference app:index="20"/>
<juloo.keyboard2.ExtraKeyCheckBoxPreference app:index="21"/>
</PreferenceScreen>
</PreferenceCategory>
<PreferenceCategory android:title="@string/pref_category_typing">
@@ -30,15 +37,6 @@
<juloo.common.IntSlideBarPreference android:key="longpress_interval" android:title="@string/pref_long_interval_title" android:summary="%sms" android:defaultValue="25" min="5" max="100"/>
<CheckBoxPreference android:key="precise_repeat" android:title="@string/pref_precise_repeat_title" android:summary="@string/pref_precise_repeat_summary" android:defaultValue="true"/>
<CheckBoxPreference android:key="lock_double_tap" android:title="@string/pref_lock_double_tap_title" android:summary="@string/pref_lock_double_tap_summary" android:defaultValue="false"/>
<PreferenceScreen android:title="@string/pref_lockable_keys_title" android:summary="@string/pref_lockable_keys_summary">
<CheckBoxPreference android:key="lockable_ctrl" android:title="Ctrl" android:defaultValue="false"/>
<CheckBoxPreference android:key="lockable_alt" android:title="Alt" android:defaultValue="false"/>
<CheckBoxPreference android:key="lockable_fn" android:title="Fn" android:defaultValue="false"/>
<CheckBoxPreference android:key="lockable_meta" android:title="Meta" android:defaultValue="false"/>
<CheckBoxPreference android:key="lockable_sup" android:title="Sup" android:defaultValue="false"/>
<CheckBoxPreference android:key="lockable_sub" android:title="Sub" android:defaultValue="false"/>
<CheckBoxPreference android:key="lockable_box" android:title="Box" android:defaultValue="false"/>
</PreferenceScreen>
<CheckBoxPreference android:key="vibrate_enabled" android:title="@string/pref_vibrate_title" android:summary="@string/pref_vibrate_summary" android:defaultValue="true"/>
</PreferenceCategory>
<PreferenceCategory android:title="@string/pref_category_style">
+46 -36
View File
@@ -27,25 +27,10 @@ final class Autocapitalisation
InputType.TYPE_TEXT_FLAG_CAP_SENTENCES |
InputType.TYPE_TEXT_FLAG_CAP_WORDS;
Runnable delayed_callback = new Runnable()
public Autocapitalisation(Looper looper, Callback cb)
{
public void run()
{
if (_should_update_caps_mode)
{
_should_enable_shift = _enabled && (_ic.getCursorCapsMode(_caps_mode) != 0);
_should_update_caps_mode = false;
}
_callback.update_shift_state(_should_enable_shift, _should_disable_shift);
}
};
void callback(final boolean might_disable)
{
_should_disable_shift = might_disable;
// The callback must be delayed because [getCursorCapsMode] would sometimes
// be called before the editor finished handling the previous event.
_handler.postDelayed(delayed_callback, 1);
_handler = new Handler(looper);
_callback = cb;
}
/**
@@ -53,11 +38,9 @@ final class Autocapitalisation
* [started] does initialisation work and must be called before any other
* event.
*/
public void started(Looper looper, Callback cb, EditorInfo info, InputConnection ic)
public void started(EditorInfo info, InputConnection ic)
{
_handler = new Handler(looper);
_ic = ic;
_callback = cb;
_caps_mode = info.inputType & TextUtils.CAP_MODE_SENTENCES;
if (!Config.globalConfig().autocapitalisation || _caps_mode == 0)
{
@@ -82,17 +65,14 @@ final class Autocapitalisation
callback(false);
}
void type_one_char(char c)
public void event_sent(int code, int meta)
{
_cursor++;
if (is_trigger_character(c))
_should_update_caps_mode = true;
else
if (meta != 0)
{
_should_enable_shift = false;
}
public void event_sent(int code)
{
_should_update_caps_mode = false;
return;
}
switch (code)
{
case KeyEvent.KEYCODE_DEL:
@@ -103,12 +83,17 @@ final class Autocapitalisation
callback(true);
}
public static interface Callback
{
public void update_shift_state(boolean should_enable, boolean should_disable);
}
/** Returns [true] if shift might be disabled. */
public void selection_updated(int old_cursor, int new_cursor)
{
if (new_cursor == _cursor) // Just typing
return;
if (new_cursor == 0)
if (new_cursor == 0 && _ic != null)
{
// Detect whether the input box has been cleared
CharSequence t = _ic.getTextAfterCursor(1, 0);
@@ -120,6 +105,36 @@ final class Autocapitalisation
callback(true);
}
Runnable delayed_callback = new Runnable()
{
public void run()
{
if (_should_update_caps_mode && _ic != null)
{
_should_enable_shift = _enabled && (_ic.getCursorCapsMode(_caps_mode) != 0);
_should_update_caps_mode = false;
}
_callback.update_shift_state(_should_enable_shift, _should_disable_shift);
}
};
void callback(final boolean might_disable)
{
_should_disable_shift = might_disable;
// The callback must be delayed because [getCursorCapsMode] would sometimes
// be called before the editor finished handling the previous event.
_handler.postDelayed(delayed_callback, 1);
}
void type_one_char(char c)
{
_cursor++;
if (is_trigger_character(c))
_should_update_caps_mode = true;
else
_should_enable_shift = false;
}
boolean is_trigger_character(char c)
{
switch (c)
@@ -130,9 +145,4 @@ final class Autocapitalisation
return false;
}
}
public static interface Callback
{
public void update_shift_state(boolean should_enable, boolean should_disable);
}
}
+24 -19
View File
@@ -25,6 +25,7 @@ final class Config
// From preferences
public int layout; // Or '-1' for the system defaults
public int programming_layout; // Or '-1' for none
public boolean show_numpad = false;
public float swipe_dist_px;
public boolean vibrateEnabled;
public long longPressTimeout;
@@ -35,7 +36,7 @@ final class Config
public float keyVerticalInterval;
public float keyHorizontalInterval;
public boolean preciseRepeat;
public Set<KeyValue.Modifier> lockable_modifiers = new HashSet<KeyValue.Modifier>();
public boolean double_tap_lock_shift;
public float characterSize; // Ratio
public int accents; // Values are R.values.pref_accents_v_*
public int theme; // Values are R.style.*
@@ -100,8 +101,12 @@ final class Config
// Scale some dimensions depending on orientation
float horizontalIntervalScale = 1.f;
float characterSizeScale = 1.f;
String show_numpad_s = prefs.getString("show_numpad", "never");
show_numpad = "always".equals(show_numpad_s);
if (res.getConfiguration().orientation == Configuration.ORIENTATION_LANDSCAPE) // Landscape mode
{
if ("landscape".equals(show_numpad_s))
show_numpad = true;
keyboardHeightPercent = prefs.getInt("keyboard_height_landscape", 50);
horizontalIntervalScale = 2.f;
characterSizeScale = 1.25f;
@@ -134,16 +139,7 @@ final class Config
getDipPref(dm, prefs, "horizontal_margin", horizontalMargin)
+ res.getDimension(R.dimen.extra_horizontal_margin);
preciseRepeat = prefs.getBoolean("precise_repeat", preciseRepeat);
lockable_modifiers.clear();
if (prefs.getBoolean("lock_double_tap", false))
lockable_modifiers.add(KeyValue.Modifier.SHIFT);
if (prefs.getBoolean("lockable_ctrl", false)) lockable_modifiers.add(KeyValue.Modifier.CTRL);
if (prefs.getBoolean("lockable_alt", false)) lockable_modifiers.add(KeyValue.Modifier.ALT);
if (prefs.getBoolean("lockable_fn", false)) lockable_modifiers.add(KeyValue.Modifier.FN);
if (prefs.getBoolean("lockable_meta", false)) lockable_modifiers.add(KeyValue.Modifier.META);
if (prefs.getBoolean("lockable_sup", false)) lockable_modifiers.add(KeyValue.Modifier.SUPERSCRIPT);
if (prefs.getBoolean("lockable_sub", false)) lockable_modifiers.add(KeyValue.Modifier.SUBSCRIPT);
if (prefs.getBoolean("lockable_box", false)) lockable_modifiers.add(KeyValue.Modifier.BOX);
double_tap_lock_shift = prefs.getBoolean("lock_double_tap", false);
characterSize =
prefs.getFloat("character_size", characterSize)
* characterSizeScale;
@@ -199,8 +195,12 @@ final class Config
}
break;
case Modifier:
if (lockable_modifiers.contains(key.getModifier()))
return key.withFlags(key.getFlags() | KeyValue.FLAG_LOCK);
switch (key.getModifier())
{
case SHIFT:
if (double_tap_lock_shift)
return key.withFlags(key.getFlags() | KeyValue.FLAG_LOCK);
}
break;
}
return key;
@@ -208,6 +208,8 @@ final class Config
});
if (extra_keys.size() > 0)
kw = kw.addExtraKeys(extra_keys.iterator());
if (original_kw.num_pad && show_numpad)
kw = kw.addNumPad();
return kw;
}
@@ -251,21 +253,24 @@ final class Config
case "bone": return R.xml.bone;
case "colemak": return R.xml.colemak;
case "dvorak": return R.xml.dvorak;
case "hindi": return R.xml.hindi;
case "jcuken_ua": return R.xml.jcuken_ua;
case "neo2": return R.xml.neo2;
case "qwerty": return R.xml.qwerty;
case "qwerty_el": return R.xml.qwerty_el;
case "qwerty_es": return R.xml.qwerty_es;
case "qwerty_hu": return R.xml.qwerty_hu;
case "qwerty_ko": return R.xml.qwerty_ko;
case "qwerty_lv": return R.xml.qwerty_lv;
case "qwerty_pt": return R.xml.qwerty_pt;
case "qwerty_tr": return R.xml.qwerty_tr;
case "qwerty": return R.xml.qwerty;
case "qwerty_no": return R.xml.qwerty_no;
case "qwerty_pt": return R.xml.qwerty_pt;
case "qwerty_sv_se": return R.xml.qwerty_sv_se;
case "qwertz_hu": return R.xml.qwertz_hu;
case "qwertz_cs": return R.xml.qwertz_cs;
case "qwerty_tr": return R.xml.qwerty_tr;
case "qwertz": return R.xml.qwertz;
case "qwertz_cs": return R.xml.qwertz_cs;
case "qwertz_de": return R.xml.qwertz_de;
case "qwertz_hu": return R.xml.qwertz_hu;
case "ru_jcuken": return R.xml.local_ru_jcuken;
case "jcuken_ua": return R.xml.jcuken_ua;
default: return R.xml.qwerty; // The config might store an invalid layout, don't crash
}
}
@@ -14,6 +14,8 @@ public class ExtraKeyCheckBoxPreference extends CheckBoxPreference
{
public static String[] extra_keys = new String[]
{
"alt",
"meta",
"accent_aigu",
"accent_grave",
"accent_double_aigu",
@@ -26,12 +28,25 @@ public class ExtraKeyCheckBoxPreference extends CheckBoxPreference
"accent_caron",
"accent_macron",
"accent_ogonek",
"accent_breve",
"accent_slash",
"accent_bar",
"€",
"ß",
"£",
"switch_greekmath",
"capslock",
};
public static boolean default_checked(String name)
{
switch (name)
{
default:
return false;
}
}
boolean _key_font;
public ExtraKeyCheckBoxPreference(Context context, AttributeSet attrs)
@@ -41,9 +56,14 @@ public class ExtraKeyCheckBoxPreference extends CheckBoxPreference
int index = a.getInteger(R.styleable.ExtraKeyCheckBoxPreference_index, 0);
a.recycle();
String key_name = extra_keys[index];
setKey(pref_key_of_key_name(key_name));
KeyValue kv = KeyValue.getKeyByName(key_name);
setTitle(kv.getString());
String title = kv.getString();
String descr = KeyValue.getKeyDescription(key_name);
if (descr != null)
title += " (" + descr + ")";
setKey(pref_key_of_key_name(key_name));
setDefaultValue(default_checked(key_name));
setTitle(title);
_key_font = kv.hasFlags(KeyValue.FLAG_KEY_FONT);
}
@@ -65,7 +85,7 @@ public class ExtraKeyCheckBoxPreference extends CheckBoxPreference
HashSet<KeyValue> ks = new HashSet<KeyValue>();
for (String key_name : extra_keys)
{
if (prefs.getBoolean(pref_key_of_key_name(key_name), false))
if (prefs.getBoolean(pref_key_of_key_name(key_name), default_checked(key_name)))
ks.add(KeyValue.getKeyByName(key_name));
}
return ks;
@@ -35,6 +35,7 @@ class KeyEventHandler implements Config.IKeyEventHandler
case ACTION: _recv.performAction(); break;
case SWITCH_PROGRAMMING: _recv.switchProgramming(); break;
case SWITCH_GREEKMATH: _recv.switchGreekmath(); break;
case CAPS_LOCK: _recv.enableCapsLock(); break;
}
break;
case Keyevent:
@@ -102,6 +103,7 @@ class KeyEventHandler implements Config.IKeyEventHandler
public void setPane_normal();
public void showKeyboardConfig();
public void performAction();
public void enableCapsLock();
public void switchMain();
public void switchNumeric();
+40 -2
View File
@@ -50,6 +50,7 @@ class KeyModifier
case MACRON: return apply_dead_char(k, '\u00AF');
case OGONEK: return apply_dead_char(k, '\u02DB');
case DOT_ABOVE: return apply_dead_char(k, '\u02D9');
case BREVE: return apply_dead_char(k, '\u02D8');
case DOUBLE_AIGU: return apply_map_char(k, map_char_double_aigu);
case ORDINAL: return apply_map_char(k, map_char_ordinal);
case SUPERSCRIPT: return apply_map_char(k, map_char_superscript);
@@ -57,6 +58,7 @@ class KeyModifier
case ARROWS: return apply_map_char(k, map_char_arrows);
case BOX: return apply_map_char(k, map_char_box);
case SLASH: return apply_map_char(k, map_char_slash);
case BAR: return apply_map_char(k, map_char_bar);
case ARROW_RIGHT: return apply_combining(k, "\u20D7");
default: return k;
}
@@ -144,6 +146,7 @@ class KeyModifier
case KeyEvent.KEYCODE_DPAD_LEFT: return "home";
case KeyEvent.KEYCODE_DPAD_RIGHT: return "end";
case KeyEvent.KEYCODE_ESCAPE: return "insert";
case KeyEvent.KEYCODE_TAB: return "\\t";
default: return null;
}
}
@@ -241,7 +244,6 @@ class KeyModifier
case '⊃': return "⊇";
case '±': return "∓";
// other
case '\t': return "\\t";
case ' ': return "nbsp";
default: return null;
}
@@ -354,6 +356,11 @@ class KeyModifier
case '─': return '═';
case '│': return '║';
case 'ß': return 'ẞ';
/* In Turkish, upper case of 'iı' is 'İI' but Java's toUpperCase will
return 'II'. To make 'İ' accessible, make it the shift of 'ı'. This
has the inconvenient of swapping i and ı on the keyboard. */
case 'ı': return 'İ';
case '₹': return '₨';
default: return c;
}
}
@@ -502,13 +509,44 @@ class KeyModifier
switch (c)
{
case 'a': return 'ⱥ';
case 'b': return '␢';
case 'c': return 'ȼ';
case 'e': return 'ɇ';
case 'g': return 'ꞡ';
case 'k': return 'ꝃ';
case 'l': return 'ł';
case 'n': return 'ꞥ';
case 'o': return 'ø';
case ' ': return '/';
case 'r': return 'ꞧ';
case 's': return 'ꞩ';
case 't': return 'ⱦ';
default: return c;
}
}
};
private static final Map_char map_char_bar =
new Map_char() {
public char apply(char c)
{
switch (c)
{
case 'b': return 'ƀ';
case 'c': return 'ꞓ';
case 'd': return 'đ';
case 'g': return 'ǥ';
case 'i': return 'ɨ';
case 'j': return 'ɉ';
case 'k': return 'ꝁ';
case 'l': return 'ƚ';
case 'o': return 'ɵ';
case 'p': return 'ᵽ';
case 'q': return 'ꝗ';
case 'r': return 'ɍ';
case 't': return 'ŧ';
case 'u': return 'ʉ';
case 'y': return 'ɏ';
case 'z': return 'ƶ';
default: return c;
}
}
+92 -47
View File
@@ -16,14 +16,14 @@ final class KeyValue
CHANGE_METHOD,
ACTION,
SWITCH_PROGRAMMING,
SWITCH_GREEKMATH
SWITCH_GREEKMATH,
CAPS_LOCK,
}
// Must be evaluated in the reverse order of their values.
public static enum Modifier
{
SHIFT,
FN,
CTRL,
ALT,
META,
@@ -45,7 +45,10 @@ final class KeyValue
BOX,
OGONEK,
SLASH,
ARROW_RIGHT
ARROW_RIGHT,
BREVE,
BAR,
FN, // Must be placed last to be applied first
}
// Behavior flags.
@@ -217,10 +220,22 @@ final class KeyValue
addKey(name, symbol, KIND_CHAR, c, flags);
}
private static void addModifierKey(String name, String symbol, Modifier m, int extra_flags)
private static void addModifierKey(String name, String symbol, Modifier m, int flags)
{
if (symbol.length() > 1)
flags |= FLAG_SMALLER_FONT;
addKey(name, symbol, KIND_MODIFIER, m.ordinal(),
FLAG_LATCH | FLAG_SPECIAL | extra_flags);
FLAG_LATCH | FLAG_SPECIAL | flags);
}
private static void addModifierKey(String name, int symbol, Modifier m, int flags)
{
addModifierKey(name, String.valueOf((char)symbol), m, flags | FLAG_KEY_FONT);
}
private static void addDiacritic(String name, int symbol, Modifier m)
{
addModifierKey(name, symbol, m, 0);
}
private static void addEventKey(String name, String symbol, Event e, int flags)
@@ -228,11 +243,21 @@ final class KeyValue
addKey(name, symbol, KIND_EVENT, e.ordinal(), flags | FLAG_SPECIAL);
}
private static void addEventKey(String name, int symbol, Event e, int flags)
{
addEventKey(name, String.valueOf((char)symbol), e, flags | FLAG_KEY_FONT);
}
private static void addKeyeventKey(String name, String symbol, int code, int flags)
{
addKey(name, symbol, KIND_KEYEVENT, code, flags);
}
private static void addKeyeventKey(String name, int symbol, int code, int flags)
{
addKeyeventKey(name, String.valueOf((char)symbol), code, flags | FLAG_KEY_FONT);
}
// Within VALUE_BITS
private static int placeholder_unique_id = 0;
@@ -245,55 +270,56 @@ final class KeyValue
static
{
addModifierKey("shift", "\n", // Can't write u000A because Java is stupid
Modifier.SHIFT, FLAG_KEY_FONT | FLAG_SMALLER_FONT);
addModifierKey("ctrl", "Ctrl", Modifier.CTRL, FLAG_SMALLER_FONT);
addModifierKey("alt", "Alt", Modifier.ALT, FLAG_SMALLER_FONT);
addModifierKey("accent_aigu", "\u0050", Modifier.AIGU, FLAG_KEY_FONT);
addModifierKey("accent_caron", "\u0051", Modifier.CARON, FLAG_KEY_FONT);
addModifierKey("accent_cedille", "\u0052", Modifier.CEDILLE, FLAG_KEY_FONT);
addModifierKey("accent_circonflexe", "\u0053", Modifier.CIRCONFLEXE, FLAG_KEY_FONT);
addModifierKey("accent_grave", "\u0054", Modifier.GRAVE, FLAG_KEY_FONT);
addModifierKey("accent_macron", "\u0055", Modifier.MACRON, FLAG_KEY_FONT);
addModifierKey("accent_ring", "\u0056", Modifier.RING, FLAG_KEY_FONT);
addModifierKey("accent_tilde", "\u0057", Modifier.TILDE, FLAG_KEY_FONT);
addModifierKey("accent_trema", "\u0058", Modifier.TREMA, FLAG_KEY_FONT);
addModifierKey("accent_ogonek", "\u0059", Modifier.OGONEK, FLAG_KEY_FONT);
addModifierKey("accent_dot_above", "\u005a", Modifier.DOT_ABOVE, FLAG_KEY_FONT);
addModifierKey("accent_double_aigu", "\u005b", Modifier.DOUBLE_AIGU, FLAG_KEY_FONT);
addModifierKey("accent_slash", "\134", // Can't write u005c
Modifier.SLASH, FLAG_KEY_FONT);
addModifierKey("accent_arrow_right", "\u005d", Modifier.ARROW_RIGHT, FLAG_KEY_FONT);
addModifierKey("superscript", "Sup", Modifier.SUPERSCRIPT, FLAG_SMALLER_FONT);
addModifierKey("subscript", "Sub", Modifier.SUBSCRIPT, FLAG_SMALLER_FONT);
addModifierKey("ordinal", "Ord", Modifier.ORDINAL, FLAG_SMALLER_FONT);
addModifierKey("arrows", "Arr", Modifier.ARROWS, FLAG_SMALLER_FONT);
addModifierKey("box", "Box", Modifier.BOX, FLAG_SMALLER_FONT);
addModifierKey("fn", "Fn", Modifier.FN, FLAG_SMALLER_FONT);
addModifierKey("meta", "Meta", Modifier.META, FLAG_SMALLER_FONT);
addModifierKey("shift", 0x0A, Modifier.SHIFT, 0);
addModifierKey("ctrl", "Ctrl", Modifier.CTRL, 0);
addModifierKey("alt", "Alt", Modifier.ALT, 0);
addDiacritic("accent_aigu", 0x50, Modifier.AIGU);
addDiacritic("accent_caron", 0x51, Modifier.CARON);
addDiacritic("accent_cedille", 0x52, Modifier.CEDILLE);
addDiacritic("accent_circonflexe", 0x53, Modifier.CIRCONFLEXE);
addDiacritic("accent_grave", 0x54, Modifier.GRAVE);
addDiacritic("accent_macron", 0x55, Modifier.MACRON);
addDiacritic("accent_ring", 0x56, Modifier.RING);
addDiacritic("accent_tilde", 0x57, Modifier.TILDE);
addDiacritic("accent_trema", 0x58, Modifier.TREMA);
addDiacritic("accent_ogonek", 0x59, Modifier.OGONEK);
addDiacritic("accent_dot_above", 0x5A, Modifier.DOT_ABOVE);
addDiacritic("accent_double_aigu", 0x5B, Modifier.DOUBLE_AIGU);
addDiacritic("accent_slash", 0x5C, Modifier.SLASH);
addDiacritic("accent_arrow_right", 0x5D, Modifier.ARROW_RIGHT);
addDiacritic("accent_breve", 0x5E, Modifier.BREVE);
addDiacritic("accent_bar", 0x5F, Modifier.BAR);
addModifierKey("superscript", "Sup", Modifier.SUPERSCRIPT, 0);
addModifierKey("subscript", "Sub", Modifier.SUBSCRIPT, 0);
addModifierKey("ordinal", "Ord", Modifier.ORDINAL, 0);
addModifierKey("arrows", "Arr", Modifier.ARROWS, 0);
addModifierKey("box", "Box", Modifier.BOX, 0);
addModifierKey("fn", "Fn", Modifier.FN, 0);
addModifierKey("meta", "Meta", Modifier.META, 0);
addEventKey("config", "\u0004", Event.CONFIG, FLAG_KEY_FONT | FLAG_SMALLER_FONT);
addEventKey("config", 0x04, Event.CONFIG, FLAG_SMALLER_FONT);
addEventKey("switch_text", "ABC", Event.SWITCH_TEXT, FLAG_SMALLER_FONT);
addEventKey("switch_numeric", "123+", Event.SWITCH_NUMERIC, FLAG_SMALLER_FONT);
addEventKey("switch_emoji", "\u0001" , Event.SWITCH_EMOJI, FLAG_KEY_FONT | FLAG_SMALLER_FONT);
addEventKey("switch_emoji", 0x01, Event.SWITCH_EMOJI, FLAG_SMALLER_FONT);
addEventKey("switch_back_emoji", "ABC", Event.SWITCH_BACK_EMOJI, 0);
addEventKey("switch_programming", "Prog", Event.SWITCH_PROGRAMMING, FLAG_SMALLER_FONT);
addEventKey("switch_greekmath", "πλ∇¬", Event.SWITCH_GREEKMATH, FLAG_SMALLER_FONT);
addEventKey("change_method", "\u0009", Event.CHANGE_METHOD, FLAG_KEY_FONT | FLAG_SMALLER_FONT);
addEventKey("change_method", 0x09, Event.CHANGE_METHOD, FLAG_SMALLER_FONT);
addEventKey("action", "Action", Event.ACTION, FLAG_SMALLER_FONT); // Will always be replaced
addEventKey("capslock", 0x12, Event.CAPS_LOCK, 0);
addKeyeventKey("esc", "Esc", KeyEvent.KEYCODE_ESCAPE, FLAG_SMALLER_FONT);
addKeyeventKey("enter", "\u000E", KeyEvent.KEYCODE_ENTER, FLAG_KEY_FONT);
addKeyeventKey("up", "\u0005", KeyEvent.KEYCODE_DPAD_UP, FLAG_KEY_FONT | FLAG_PRECISE_REPEAT);
addKeyeventKey("right", "\u0006", KeyEvent.KEYCODE_DPAD_RIGHT, FLAG_KEY_FONT | FLAG_PRECISE_REPEAT);
addKeyeventKey("down", "\u0007", KeyEvent.KEYCODE_DPAD_DOWN, FLAG_KEY_FONT | FLAG_PRECISE_REPEAT);
addKeyeventKey("left", "\u0008", KeyEvent.KEYCODE_DPAD_LEFT, FLAG_KEY_FONT | FLAG_PRECISE_REPEAT);
addKeyeventKey("page_up", "\u0002", KeyEvent.KEYCODE_PAGE_UP, FLAG_KEY_FONT);
addKeyeventKey("page_down", "\u0003", KeyEvent.KEYCODE_PAGE_DOWN, FLAG_KEY_FONT);
addKeyeventKey("home", "\u000B", KeyEvent.KEYCODE_MOVE_HOME, FLAG_KEY_FONT);
addKeyeventKey("end", "\u000C", KeyEvent.KEYCODE_MOVE_END, FLAG_KEY_FONT);
addKeyeventKey("backspace", "\u0011", KeyEvent.KEYCODE_DEL, FLAG_KEY_FONT);
addKeyeventKey("delete", "\u0010", KeyEvent.KEYCODE_FORWARD_DEL, FLAG_KEY_FONT);
addKeyeventKey("enter", 0x0E, KeyEvent.KEYCODE_ENTER, 0);
addKeyeventKey("up", 0x05, KeyEvent.KEYCODE_DPAD_UP, FLAG_PRECISE_REPEAT);
addKeyeventKey("right", 0x06, KeyEvent.KEYCODE_DPAD_RIGHT, FLAG_PRECISE_REPEAT);
addKeyeventKey("down", 0x07, KeyEvent.KEYCODE_DPAD_DOWN, FLAG_PRECISE_REPEAT);
addKeyeventKey("left", 0x08, KeyEvent.KEYCODE_DPAD_LEFT, FLAG_PRECISE_REPEAT);
addKeyeventKey("page_up", 0x02, KeyEvent.KEYCODE_PAGE_UP, 0);
addKeyeventKey("page_down", 0x03, KeyEvent.KEYCODE_PAGE_DOWN, 0);
addKeyeventKey("home", 0x0B, KeyEvent.KEYCODE_MOVE_HOME, 0);
addKeyeventKey("end", 0x0C, KeyEvent.KEYCODE_MOVE_END, 0);
addKeyeventKey("backspace", 0x11, KeyEvent.KEYCODE_DEL, 0);
addKeyeventKey("delete", 0x10, KeyEvent.KEYCODE_FORWARD_DEL, 0);
addKeyeventKey("insert", "Ins", KeyEvent.KEYCODE_INSERT, FLAG_SMALLER_FONT);
addKeyeventKey("f1", "F1", KeyEvent.KEYCODE_F1, 0);
addKeyeventKey("f2", "F2", KeyEvent.KEYCODE_F2, 0);
@@ -307,17 +333,36 @@ final class KeyValue
addKeyeventKey("f10", "F10", KeyEvent.KEYCODE_F10, 0);
addKeyeventKey("f11", "F11", KeyEvent.KEYCODE_F11, FLAG_SMALLER_FONT);
addKeyeventKey("f12", "F12", KeyEvent.KEYCODE_F12, FLAG_SMALLER_FONT);
addKeyeventKey("tab", "\u000F", KeyEvent.KEYCODE_TAB, FLAG_KEY_FONT | FLAG_SMALLER_FONT);
addKeyeventKey("tab", 0x0F, KeyEvent.KEYCODE_TAB, FLAG_SMALLER_FONT);
addCharKey("\\t", "\\t", '\t', 0); // Send the tab character
addCharKey("space", "\r", ' ', FLAG_KEY_FONT);
addCharKey("nbsp", "\u237d", '\u00a0', FLAG_KEY_FONT | FLAG_SMALLER_FONT);
addCharKey("nbsp", "\u237d", '\u00a0', FLAG_SMALLER_FONT);
addPlaceholderKey("removed");
addPlaceholderKey("f11_placeholder");
addPlaceholderKey("f12_placeholder");
}
static final HashMap<String, String> keys_descr = new HashMap<String, String>();
/* Some keys have a description attached. Return [null] if otherwise. */
public static String getKeyDescription(String name)
{
return keys_descr.get(name);
}
static void addKeyDescr(String name, String descr)
{
keys_descr.put(name, descr);
}
static {
/* Keys description is shown in the settings. */
addKeyDescr("capslock", "Caps lock");
addKeyDescr("switch_greekmath", "Greek & math symbols");
}
// Substitute for [assert], which has no effect on Android.
private static void check(boolean b)
{
+43 -11
View File
@@ -36,7 +36,7 @@ public class Keyboard2 extends InputMethodService
private ViewGroup _emojiPane = null;
private Config _config;
private Autocapitalisation _autocap = new Autocapitalisation();
private Autocapitalisation _autocap;
private boolean _debug_logs = false;
@@ -57,14 +57,15 @@ public class Keyboard2 extends InputMethodService
_keyboardView = (Keyboard2View)inflate_view(R.layout.keyboard);
_keyboardView.reset();
_debug_logs = getResources().getBoolean(R.bool.debug_logs);
_autocap = new Autocapitalisation(getMainLooper(), this);
}
public void update_shift_state(boolean should_enable, boolean should_disable)
{
if (should_enable)
_keyboardView.set_shift_state(true);
_keyboardView.set_shift_state(true, false);
else if (should_disable)
_keyboardView.set_shift_state(false);
_keyboardView.set_shift_state(false, false);
}
private List<InputMethodSubtype> getEnabledSubtypes(InputMethodManager imm)
@@ -147,8 +148,16 @@ public class Keyboard2 extends InputMethodService
else
{
InputMethodSubtype subtype = imm.getCurrentInputMethodSubtype();
refreshSubtypeLayout(subtype);
refreshAccentsOption(imm, subtype);
if (subtype == null)
{
// On some rare cases, [subtype] is null.
refreshSubtypeLegacyFallback();
}
else
{
refreshSubtypeLayout(subtype);
refreshAccentsOption(imm, subtype);
}
}
_config.shouldOfferSwitchingToProgramming =
_config.programming_layout != -1 &&
@@ -216,16 +225,27 @@ public class Keyboard2 extends InputMethodService
Log.d(TAG, "actionLabel: "+_config.actionLabel);
}
private int chooseLayout(EditorInfo info)
{
switch (info.inputType & InputType.TYPE_MASK_CLASS)
{
case InputType.TYPE_CLASS_NUMBER:
return R.xml.pin;
case InputType.TYPE_CLASS_PHONE:
case InputType.TYPE_CLASS_DATETIME:
return R.xml.pin;
default:
return _currentTextLayout;
}
}
@Override
public void onStartInputView(EditorInfo info, boolean restarting)
{
refreshConfig();
refresh_action_label(info);
if ((info.inputType & InputType.TYPE_CLASS_NUMBER) != 0)
_keyboardView.setKeyboard(getLayout(R.xml.numeric));
else
_keyboardView.setKeyboard(getLayout(_currentTextLayout));
_autocap.started(getMainLooper(), this, info, getCurrentInputConnection());
_keyboardView.setKeyboard(getLayout(chooseLayout(info)));
_autocap.started(info, getCurrentInputConnection());
setInputView(_keyboardView);
if (_debug_logs)
log_editor_info(info);
@@ -267,6 +287,13 @@ public class Keyboard2 extends InputMethodService
refreshConfig();
}
@Override
public boolean onEvaluateFullscreenMode()
{
/* Entirely disable fullscreen mode. */
return false;
}
/** Not static */
public class Receiver implements KeyEventHandler.IReceiver
{
@@ -298,6 +325,11 @@ public class Keyboard2 extends InputMethodService
conn.performEditorAction(_config.actionId);
}
public void enableCapsLock()
{
_keyboardView.set_shift_state(true, true);
}
public void switchMain()
{
_keyboardView.setKeyboard(getLayout(_currentTextLayout));
@@ -337,7 +369,7 @@ public class Keyboard2 extends InputMethodService
return;
conn.sendKeyEvent(new KeyEvent(1, 1, eventAction, eventCode, 0, meta));
if (eventAction == KeyEvent.ACTION_UP)
_autocap.event_sent(eventCode);
_autocap.event_sent(eventCode, meta);
}
public void showKeyboardConfig()
+26 -5
View File
@@ -100,12 +100,12 @@ public class Keyboard2View extends View
}
/** Called by auto-capitalisation. */
public void set_shift_state(boolean state)
public void set_shift_state(boolean state, boolean lock)
{
if (_keyboard == null || _shift_key == null)
return;
if (state)
_pointers.add_fake_pointer(_shift_kv, _shift_key);
_pointers.add_fake_pointer(_shift_kv, _shift_key, lock);
else
_pointers.remove_fake_pointer(_shift_kv, _shift_key);
invalidate();
@@ -199,9 +199,13 @@ public class Keyboard2View extends View
return null;
for (KeyboardData.Key key : row.keys)
{
x += (key.shift + key.width) * _keyWidth;
if (tx < x)
float xLeft = x + key.shift * _keyWidth;
float xRight = xLeft + key.width * _keyWidth;
if (tx < xLeft)
return null;
if (tx < xRight)
return key;
x = xRight;
}
return null;
}
@@ -263,6 +267,10 @@ public class Keyboard2View extends View
drawSubLabel(canvas, k.key2, x, y, keyW, keyH, Paint.Align.RIGHT, Vertical.TOP, isKeyDown);
drawSubLabel(canvas, k.key4, x, y, keyW, keyH, Paint.Align.RIGHT, Vertical.BOTTOM, isKeyDown);
}
if (k.indication != null)
{
drawIndication(canvas, k.indication, keyW / 2f + x, y, keyH);
}
x += _keyWidth * k.width;
}
y += row.height * _config.keyHeight;
@@ -305,7 +313,9 @@ public class Keyboard2View extends View
canvas.drawText(kv.getString(), x, (keyH - p.ascent() - p.descent()) / 2f + y, p);
}
private void drawSubLabel(Canvas canvas, KeyboardData.Corner k, float x, float y, float keyW, float keyH, Paint.Align a, Vertical v, boolean isKeyDown)
private void drawSubLabel(Canvas canvas, KeyboardData.Corner k, float x,
float y, float keyW, float keyH, Paint.Align a, Vertical v,
boolean isKeyDown)
{
if (k == null)
return;
@@ -328,6 +338,17 @@ public class Keyboard2View extends View
canvas.drawText(kv.getString(), x, y, p);
}
private void drawIndication(Canvas canvas, String indication, float x,
float y, float keyH)
{
float textSize = keyH * _config.sublabelTextSize * _config.characterSize;
Paint p = _theme.indicationPaint();
p.setColor(_theme.subLabelColor);
p.setTextSize(textSize);
canvas.drawText(indication, x,
(keyH - p.ascent() - p.descent()) * 4/5 + y, p);
}
private float scaleTextSize(KeyValue k, float rel_size, float keyH)
{
float smaller_font = k.hasFlags(KeyValue.FLAG_SMALLER_FONT) ? 0.75f : 1.f;
+56 -11
View File
@@ -18,13 +18,15 @@ class KeyboardData
public final float keysHeight;
/** Whether to add extra keys. */
public final boolean extra_keys;
/** Whether to possibly add NumPad. */
public final boolean num_pad;
public KeyboardData mapKeys(MapKey f)
{
ArrayList<Row> rows_ = new ArrayList<Row>();
for (Row r : rows)
rows_.add(r.mapKeys(f));
return new KeyboardData(rows_, keysWidth, extra_keys);
return new KeyboardData(rows_, keysWidth, extra_keys, num_pad);
}
/** Add keys from the given iterator into the keyboard. Extra keys are added
@@ -46,7 +48,32 @@ class KeyboardData
for (int c = 1; c <= 4; c++)
addExtraKeys_to_row(rows, k, r, c);
}
return new KeyboardData(rows, keysWidth, extra_keys);
return new KeyboardData(rows, keysWidth, extra_keys, num_pad);
}
public KeyboardData addNumPad()
{
if (!num_pad || _numPadKeyboardData == null)
return this;
ArrayList<Row> extendedRows = new ArrayList<Row>();
Iterator<Row> iterNumPadRows = _numPadKeyboardData.rows.iterator();
for (Row row : rows)
{
ArrayList<KeyboardData.Key> keys = new ArrayList<Key>(row.keys);
if (iterNumPadRows.hasNext())
{
Row numPadRow = iterNumPadRows.next();
List<Key> nps = numPadRow.keys;
if (nps.size() > 0) {
float firstNumPadShift = 0.5f + keysWidth - row.keysWidth;
keys.add(nps.get(0).withShift(firstNumPadShift));
for (int i = 1; i < nps.size(); i++)
keys.add(nps.get(i));
}
}
extendedRows.add(new Row(keys, row.height, row.shift));
}
return new KeyboardData(extendedRows, compute_max_width(extendedRows), extra_keys, num_pad);
}
public Key findKeyWithValue(KeyValue kv)
@@ -75,6 +102,7 @@ class KeyboardData
}
private static Row _bottomRow = null;
private static KeyboardData _numPadKeyboardData = null;
private static Map<Integer, KeyboardData> _layoutCache = new HashMap<Integer, KeyboardData>();
public static KeyboardData load(Resources res, int id)
@@ -86,6 +114,10 @@ class KeyboardData
{
if (_bottomRow == null)
_bottomRow = parse_bottom_row(res.getXml(R.xml.bottom_row));
if (_numPadKeyboardData == null)
{
_numPadKeyboardData = parse_keyboard(res.getXml(R.xml.numpad));
}
l = parse_keyboard(res.getXml(id));
_layoutCache.put(id, l);
}
@@ -103,13 +135,15 @@ class KeyboardData
throw new Exception("Empty layout file");
boolean bottom_row = parser.getAttributeBooleanValue(null, "bottom_row", true);
boolean extra_keys = parser.getAttributeBooleanValue(null, "extra_keys", true);
boolean num_pad = parser.getAttributeBooleanValue(null, "num_pad", true);
float specified_kw = parser.getAttributeFloatValue(null, "width", 0f);
ArrayList<Row> rows = new ArrayList<Row>();
while (expect_tag(parser, "row"))
rows.add(Row.parse(parser));
float kw = compute_max_width(rows);
float kw = (specified_kw != 0f) ? specified_kw : compute_max_width(rows);
if (bottom_row)
rows.add(_bottomRow.updateWidth(kw));
return new KeyboardData(rows, kw, extra_keys);
return new KeyboardData(rows, kw, extra_keys, num_pad);
}
private static float compute_max_width(List<Row> rows)
@@ -127,7 +161,7 @@ class KeyboardData
return Row.parse(parser);
}
protected KeyboardData(List<Row> rows_, float kw, boolean xk)
protected KeyboardData(List<Row> rows_, float kw, boolean xk, boolean np)
{
float kh = 0.f;
for (Row r : rows_)
@@ -136,6 +170,7 @@ class KeyboardData
keysWidth = kw;
keysHeight = kh;
extra_keys = xk;
num_pad = np;
}
public static class Row
@@ -146,7 +181,7 @@ class KeyboardData
/** Extra empty space on the top. */
public final float shift;
/** Total width of the row. */
private final float keysWidth;
public final float keysWidth;
protected Row(List<Key> keys_, float h, float s)
{
@@ -214,8 +249,9 @@ class KeyboardData
public final float shift;
/** Put keys 1 to 4 on the edges instead of the corners. */
public final boolean edgekeys;
public final String indication;
protected Key(Corner k0, Corner k1, Corner k2, Corner k3, Corner k4, float w, float s, boolean e)
protected Key(Corner k0, Corner k1, Corner k2, Corner k3, Corner k4, float w, float s, boolean e, String i)
{
key0 = k0;
key1 = k1;
@@ -225,6 +261,7 @@ class KeyboardData
width = w;
shift = s;
edgekeys = e;
indication = i;
}
public static Key parse(XmlResourceParser parser) throws Exception
@@ -237,15 +274,17 @@ class KeyboardData
float width = parser.getAttributeFloatValue(null, "width", 1f);
float shift = parser.getAttributeFloatValue(null, "shift", 0.f);
boolean edgekeys = parser.getAttributeBooleanValue(null, "edgekeys", false);
String indication = parser.getAttributeValue(null, "indication");
while (parser.next() != XmlResourceParser.END_TAG)
continue ;
return new Key(k0, k1, k2, k3, k4, width, shift, edgekeys);
return new Key(k0, k1, k2, k3, k4, width, shift, edgekeys, indication);
}
/** New key with the width multiplied by 's'. */
public Key scaleWidth(float s)
{
return new Key(key0, key1, key2, key3, key4, width * s, shift, edgekeys);
return new Key(key0, key1, key2, key3, key4, width * s, shift, edgekeys,
indication);
}
public KeyValue getKeyValue(int i)
@@ -275,7 +314,12 @@ class KeyboardData
case 3: k3 = k; break;
case 4: k4 = k; break;
}
return new Key(k0, k1, k2, k3, k4, width, shift, edgekeys);
return new Key(k0, k1, k2, k3, k4, width, shift, edgekeys, indication);
}
public Key withShift(float s)
{
return new Key(key0, key1, key2, key3, key4, width, s, edgekeys, indication);
}
/**
@@ -383,7 +427,8 @@ class KeyboardData
public Key apply(Key k)
{
return new Key(apply(k.key0), apply(k.key1), apply(k.key2),
apply(k.key3), apply(k.key4), k.width, k.shift, k.edgekeys);
apply(k.key3), apply(k.key4), k.width, k.shift, k.edgekeys,
k.indication);
}
private Corner apply(Corner c)
+7 -5
View File
@@ -75,13 +75,15 @@ public final class Pointers implements Handler.Callback
}
/** Fake pointers are latched and not lockable. */
public void add_fake_pointer(KeyValue kv, KeyboardData.Key key)
public void add_fake_pointer(KeyValue kv, KeyboardData.Key key, boolean locked)
{
// Avoid adding a fake pointer to a key that is already down.
if (isKeyDown(key))
return;
if (getLatched(key, kv) != null)
return; // Already latched, don't add an other pointer.
Pointer ptr = new Pointer(-1, key, kv, 0.f, 0.f, Modifiers.EMPTY);
ptr.flags = ptr.flags & ~(KeyValue.FLAG_LATCH | KeyValue.FLAG_LOCK | KeyValue.FLAG_FAKE_PTR);
ptr.flags &= ~KeyValue.FLAG_LATCH;
ptr.flags |= KeyValue.FLAG_LOCK | KeyValue.FLAG_FAKE_PTR;
if (locked)
ptr.flags = (ptr.flags & ~KeyValue.FLAG_LOCK) | KeyValue.FLAG_LOCKED;
_ptrs.add(ptr);
}
@@ -1,5 +1,7 @@
package juloo.keyboard2;
import android.content.res.Configuration;
import android.os.Build;
import android.os.Bundle;
import android.preference.PreferenceActivity;
@@ -8,7 +10,20 @@ public class SettingsActivity extends PreferenceActivity
@Override
public void onCreate(Bundle savedInstanceState)
{
detectSystemTheme();
super.onCreate(savedInstanceState);
addPreferencesFromResource(R.xml.settings);
}
/** The default theme is [Theme.DeviceDefault], which is dark. Detect if the
system is using light theme. */
void detectSystemTheme()
{
if (Build.VERSION.SDK_INT >= 14)
{
int ui_mode = getResources().getConfiguration().uiMode;
if ((ui_mode & Configuration.UI_MODE_NIGHT_NO) != 0)
setTheme(android.R.style.Theme_DeviceDefault_Light);
}
}
}
+7
View File
@@ -25,6 +25,7 @@ public class Theme
private final Paint _specialKeyLabelPaint;
private final Paint _keySubLabelPaint;
private final Paint _specialKeySubLabelPaint;
private final Paint _indicationPaint;
public Theme(Context context, AttributeSet attrs)
{
@@ -45,6 +46,7 @@ public class Theme
Typeface specialKeyFont = getKeyFont(context);
_specialKeyLabelPaint = initLabelPaint(Paint.Align.CENTER, specialKeyFont);
_specialKeySubLabelPaint = initLabelPaint(Paint.Align.LEFT, specialKeyFont);
_indicationPaint = initLabelPaint(Paint.Align.CENTER, null);
}
public Paint labelPaint(boolean special_font)
@@ -60,6 +62,11 @@ public class Theme
return p;
}
public Paint indicationPaint()
{
return _indicationPaint;
}
private Paint initLabelPaint(Paint.Align align, Typeface font)
{
Paint paint = new Paint(Paint.ANTI_ALIAS_FLAG);
+2
View File
@@ -0,0 +1,2 @@
<!-- materialdesignicons.com arrow-up-bold-box-outline by Austin Andrews @Templarian -->
<svg xmlns="http://www.w3.org/2000/svg" viewBox="0 0 24 24"><path d="M12,7L17,12H14V16H10V12H7L12,7M19,21H5A2,2 0 0,1 3,19V5A2,2 0 0,1 5,3H19A2,2 0 0,1 21,5V19A2,2 0 0,1 19,21M19,19V5H5V19H19Z" /></svg>

After

Width:  |  Height:  |  Size: 292 B

+13
View File
@@ -0,0 +1,13 @@
<?xml version="1.0" standalone="no"?>
<!DOCTYPE svg PUBLIC "-//W3C//DTD SVG 1.1//EN" "http://www.w3.org/Graphics/SVG/1.1/DTD/svg11.dtd" >
<svg xmlns="http://www.w3.org/2000/svg" xmlns:xlink="http://www.w3.org/1999/xlink" version="1.1" viewBox="-20 0 1168 2048">
<g transform="matrix(1 0 0 -1 0 1536)">
<path fill="currentColor"
d="M931.256 1002.78l-69.3145 -69.3145q-112.472 86.3154 -249.792 98.0859v99.3945q176.555 -11.7715 319.106 -128.166v0zM516.679 1031.55q-133.396 -10.4619 -249.792 -100.701q0 1.30859 -71.9297 74.5449l2.61523 -2.61523q142.554 116.396 319.106 128.166v-99.3945
v0zM197.572 860.229q-90.2393 -103.316 -107.24 -245.867h-99.3936q17.001 181.786 137.32 319.104l-6.53906 5.23145l3.92285 -2.61523l41.8506 -43.1582q30.0791 -31.3867 30.0791 -32.6953v0zM1137.89 614.361h-99.3936q-17.001 141.242 -107.239 248.483
l69.3135 70.6211q120.318 -137.319 137.319 -319.104v0zM1137.89 517.583q-14.3857 -189.633 -129.474 -326.953l-69.3135 70.6221q86.3154 111.164 99.3936 256.331h99.3936v0zM189.726 263.867h0.000976562q-86.3154 107.239 -99.3936 253.716h-99.3945
q13.0781 -189.633 128.165 -326.953l-3.92285 -3.92383q-1.30762 0 74.5449 77.1611zM939.103 121.315q-146.476 -124.242 -326.952 -136.014v99.3945q139.935 11.7705 257.639 105.934zM516.679 -14.6973q-180.478 11.7715 -326.953 136.013l69.3145 69.3145
q117.703 -90.2383 257.64 -105.933v-99.3945h-0.000976562zM881 1496q0 -121 -82.5 -194.5t-216.5 -73.5t-217 74t-83 194h151q0 -70 38 -109.5t111 -39.5q70 0 109.5 39t39.5 110h150z" />
</g>
</svg>

After

Width:  |  Height:  |  Size: 1.5 KiB

+13
View File
@@ -0,0 +1,13 @@
<?xml version="1.0" standalone="no"?>
<!DOCTYPE svg PUBLIC "-//W3C//DTD SVG 1.1//EN" "http://www.w3.org/Graphics/SVG/1.1/DTD/svg11.dtd" >
<svg xmlns="http://www.w3.org/2000/svg" xmlns:xlink="http://www.w3.org/1999/xlink" version="1.1" viewBox="-20 0 1256 2048">
<g transform="matrix(1 0 0 -1 0 1536)">
<path fill="currentColor"
d="M589 493v151v0h637v-151h-637zM931.256 1002.78l-69.3145 -69.3145q-112.472 86.3154 -249.792 98.0859v99.3945q176.555 -11.7715 319.106 -128.166v0v0zM516.679 1031.55q-133.396 -10.4619 -249.792 -100.701q0 1.30859 -71.9297 74.5449l2.61523 -2.61523
q142.555 116.396 319.106 128.166v-99.3945v0v0zM197.572 860.229q-90.2393 -103.315 -107.24 -245.866h-99.3936q17.001 181.786 137.32 319.104l-6.53906 5.23145l3.92285 -2.61523l41.8506 -43.1582q30.0791 -31.3867 30.0791 -32.6953v0v0zM1137.89 614.361h-99.3936
q-17.001 141.241 -107.238 248.482l69.3135 70.6211q120.317 -137.318 137.318 -319.104v0v0zM1137.89 517.58q-14.3857 -189.633 -129.474 -326.953l-69.3135 70.6221q86.3154 111.164 99.3936 256.331h99.3936v0v0zM189.726 263.87h0.000976562
q-86.3154 107.239 -99.3936 253.716h-99.3945q13.0781 -189.633 128.165 -326.953l-3.92285 -3.92383q-1.30762 0 74.5449 77.1611v0zM939.103 121.32q-146.476 -124.242 -326.951 -136.015v99.3945q139.935 11.7705 257.639 105.935zM516.679 -14.7002
q-180.478 11.7715 -326.953 136.014l69.3145 69.3145q117.703 -90.2383 257.641 -105.934v-99.3945h-0.000976562h-0.000976562z" />
</g>
</svg>

After

Width:  |  Height:  |  Size: 1.4 KiB

Binary file not shown.