OESF Portables Forum

Model Specific Forums => Gemini PDA => Gemini PDA - Android => Topic started by: epertinez on July 16, 2018, 07:37:14 am

Title: Improve Spanish/Catalan keyboard layout
Post by: epertinez on July 16, 2018, 07:37:14 am
I managed to solve the most annoying problem I had with catalan/spanish physical keyboard. I am aware that others have similar problems with theirs.

It is a 3 minutes solution.

Problem: physical keyboards use Combining Diacritical Marks to type accentuated vowels. Catalan has lots of them. To type an accentuated vowel, you click on the accentuation symbol and then click on the letter. '+a=á, `+e=e, `+space=`. Virtual keyboards do not have those combining diacritical marks. It is espected for you to hold the letter and wait for it to show you all combinations.
I have found this behaviour very annoying with Gemini PDA physical keyboard in Catalan. I'd rather preffer the traditional combining/dead acute and grave keys.

Solution proposed: We can substitute ñ/Ñ from the spanish physical keyboard to '/`. ñ and Ñ are not as common as accents and you can create them in two ways. Long pressing n/N or using Alt+4 (not Fn+4). Ñ letter is in the natural position of accentuation marks in Catalan, so it is the natural key to substitute.

How to do it:

a) Open Play Store
 Install Apk Editor
c) Open Apk Editor
d) Select Apk from App -> Choose Gemini Keyboard package (its name may be translated to your language. In my case Teclat d'Gemini).
e) Choose Simple Edit (File Replacement) option to open it.
f) Navigate to res/raw and save keyboard_layout_spanish_gemini.kcm out of the package in any folder you preffer.

g) Jump to opened Play Store.
 Install QuickEdit.
c) Open QuickEdit and give it authorization to open files.
d) Use File -> Open to navigate to the folder you saved your file into. You must click on the filter button on the right top corner to be able to see the file. Open the file.
e) Look for the key APOSTROFE and change base and shift from '\u00f1' and '\u00d1' to '\u0301' and '\u0300'.
That is...
change

key APOSTROPHE {
    label:                              '\u00f1'
    base:                               '\u00f1'
    shift:                              '\u00d1'
    alt:                               '{'
    fn:                                 '\u00e7'
    fn+shift:                           '\u00c7'
}


 to

key APOSTROPHE {
    label:                              '\u00f1'
    base:                               '\u0301'
    shift:                              '\u0300'
    alt:                               '{'
    fn:                                 '\u00e7'
    fn+shift:                           '\u00c7'
}

f) Save the file.
g) Jump back to Apk Editor, click on the icon near to save of keyboard_layout_spanish_gemini.kcm and change the file with the new given.
h) Click Save.
i) After saving, click Remove to remove Planet official apk.
j) Click install to install the new one.
k) Click open to open the new apk and follow the instructions to configure the keyboard.

The new keyboard should be working without problems.

I assume no responsability if you follow this text. Playing with apks can bring you unexpected results, brick the PDA or mistakenly start 3rd world war.

PD: At some time you must change your security settings to let the system install 3rd party unsigned apk's.
Title: Improve Spanish/Catalan keyboard layout
Post by: carlesbellver on July 16, 2018, 12:24:11 pm
Quote from: epertinez
I managed to solve the most annoying problem I had with catalan/spanish physical keyboard. I am aware that others have similar problems with theirs.

It is a 3 minutes solution.


Solution proposed: We can substitute ñ/Ñ from the spanish physical keyboard to '/`. ñ and Ñ are not as common as accents and you can create them in two ways. Long pressing n/N or using Alt+4 (not Fn+4). Ñ letter is in the natural position of accentuation marks in Catalan, so it is the natural key to substitute.

Hi, Eduard. This is really the most annoying Gemini keyboard problem, and your solution seems great, but I can't get it to work. I've followed your instructions and now, when I type Ñ I just get the right single quote ´. Shift+Ñ outputs the left single quote `. It doesn't work as a dead key to produce accented letters. Any other key works ok, like before, key combinations included. I don't understand what I'm doing wrong
Title: Improve Spanish/Catalan keyboard layout
Post by: carlesbellver on July 16, 2018, 12:33:06 pm
Quote from: Carles Bellver
Hi, Eduard. This is really the most annoying Gemini keyboard problem, and your solution seems great, but I can't get it to work. I've followed your instructions and now, when I type Ñ I just get the right single quote ´. Shift+Ñ outputs the left single quote `. It doesn't work as a dead key to produce accented letters. Any other key works ok, like before, key combinations included. I don't understand what I'm doing wrong

Ok, it's not working in Google Keep, the only app I had tried before replying. But it works ok in every other app I've tried afterwards, including other Google apps like GMail.

Thanks, Eduard
Title: Improve Spanish/Catalan keyboard layout
Post by: epertinez on July 16, 2018, 01:08:36 pm
Quote from: Carles Bellver
Thanks, Eduard
You are very welcome!
Title: Improve Spanish/Catalan keyboard layout
Post by: zsalab2 on August 10, 2018, 04:46:36 pm
At the end I get:

App not installed.
Package conflicts with an existing package by the same name.


Any idea how to solve?
Title: Improve Spanish/Catalan keyboard layout
Post by: selig on September 15, 2018, 02:00:29 am
Quote from: zsalab2
At the end I get:

App not installed.
Package conflicts with an existing package by the same name.


Any idea how to solve?

You have to make sure to uninstall the previous version (step i in the description) prior to installing your modified one.
Title: Improve Spanish/Catalan keyboard layout
Post by: vldmr on November 23, 2019, 10:15:40 pm
I tried to use this method on new cosmo communicator. In apk editor step i completed but system notification was shown that uninstallation failed. Installation of modified version after that failed as well obviously.

Feeling very determined I tried to use adb for uninstallation:
Code: [Select]
$ adb uninstall com.gemini.keyboard
Failure [DELETE_FAILED_INTERNAL_ERROR]

OK, after some web search an alternative method was found:
Code: [Select]
$ adb shell
Cosmo_Communicator:/ $ pm uninstall -k --user 0 com.gemini.keyboard
Success
Cosmo_Communicator:/ $ ^D

A-ha, got ya!. Now try to install again:

Code: [Select]
$ adb install gen_signed.apk
adb: failed to install gen_signed.apk: Failure [INSTALL_FAILED_UPDATE_INCOMPATIBLE: Package com.gemini.keyboard signatures do not match previously installed version; ignoring!]

Ugh, why is that? Maybe pm will work?

Code: [Select]
Cosmo_Communicator:/data/local/tmp $ pm install --user 0 gen_signed.apk
Failure [INSTALL_FAILED_UPDATE_INCOMPATIBLE: Package com.gemini.keyboard signatures do not match previously installed version; ignoring!]

Oh, no! I guess its time to roll back to stock version of Planet keyboard. Go to app settings to reenable built-in application, and guess what - its not there any more. Uninstalled! But still remembers previous version, not letting me install my updated package!

Looks like I am screwed. Looks like the only remedy would be to reset device. Or go ask if anyone from cosmo community could extract and send me this original com.gemini.keyboard apk. Or maybe go ask Planet to send me that apk.

Oh, well, the only thing I am wondering -- why did it work on gemini, but fails on cosmo?
Title: Improve Spanish/Catalan keyboard layout
Post by: vldmr on November 23, 2019, 10:30:44 pm
Quote from: vldmr
Looks like I am screwed. Looks like the only remedy would be to reset device. Or go ask if anyone from cosmo community could extract and send me this original com.gemini.keyboard apk. Or maybe go ask Planet to send me that apk.

Well, the apk is actually available on google play store: https://play.google.com/store/apps/details?...gemini.keyboard (https://play.google.com/store/apps/details?id=com.gemini.keyboard)

So at least I am back to square one, wiping cold sweat from forehead. Still, why did not this work on cosmo?
Title: Improve Spanish/Catalan keyboard layout
Post by: carlesbellver on November 27, 2019, 10:35:10 am
I'm sorry. This tweak worked with my Gemini under Android 7.1.1, but when I tried it again after upgrading to Android 8 I got the same errors you are reporting. I just downgraded to 7.1.1


Quote from: vldmr
Quote from: vldmr
Looks like I am screwed. Looks like the only remedy would be to reset device. Or go ask if anyone from cosmo community could extract and send me this original com.gemini.keyboard apk. Or maybe go ask Planet to send me that apk.

Well, the apk is actually available on google play store: https://play.google.com/store/apps/details?...gemini.keyboard (https://play.google.com/store/apps/details?id=com.gemini.keyboard)

So at least I am back to square one, wiping cold sweat from forehead. Still, why did not this work on cosmo?
Title: Improve Spanish/Catalan keyboard layout
Post by: vldmr on November 27, 2019, 10:41:16 am
Well, I submitted my modified kcm file for alternative russian phonetic layout to PC humbly asking them to include it in next update. Will see if that would work