My custom keyboard has very strange behaviour with the backspace key, as can be seen in the GIF below.
More Context:
I have created a custom keyboard for my computer using Keyman Developer. I am running Ubuntu 24.04 and Keyman Developer is Running in Wine. I finished off the project by editing the .kmn and .kpc files in VSCodium as Keyman Developer in WIne is very buggy, and I needed some fancier rules that the graphical editor didn’t support anyway. I was then able to build everything using the kmc command line tool, which does have Linux support. I also successfully added it to Keyman Desktop for Linux and it shows up fine in my Ubuntu desktop dropdown list of software keyboards. After a few iterations, I got everything working just as, except the backspace key has very strange behaviour (see GIF below). I just want every touch of the backspace key to delete the previous character, like it does in most standard keyboards. Please help.
My version info is as follows:
kmc: 17.0.335
Keyman for Linux: 17.0.335
Keyman Developer: Not sure and don’t know how to check, but I downloaded it within two weeks ago so I assume 19.0.18, based on the version history on the Keyman website.
I have tried to upload a .zip file of my source documents as a part of this reply, but this was not allowed by the website as I am a new user. I will try to modify the original post with this info.
It is useful to note also that I tried just creating a blank new keyman project in Keyman Developer, building it with kmc and adding that to Keyman for Windows. This yielded the same result in terms of backspace button behaviour. This indicates to me (though I may be wrong) that the source is not the issue.
Can you recompile your keyboard with the latest released version, 18.0.235?
If it still doesn’t work, please zip up your keyboard project folder (the directory that contains the .kpj file) and share it through Dropbox or wetransfer.com or something like that. Pasting the .kmn source file changed too many things, and after putting it in a state so that it compiles it works for me as expected, which means the file I reconstructed is probably different from yours…
You said you also tried it with an empty project on Windows and it didn’t work there either. Could you please send us a diagnostic report on Windows (Open Keyman Configuration, go to the Support tab and then click on the Diagnostics link. This will collect some system information that you then can send to us).
Thanks for looking at my file, Eberhard. This is truly appreciated.
First, I have decided to make my project publicly available for anyone who is interested, so it can be found at the link at the bottom of the message.
Second, I have updated kmc to version 18.0.235 as recommended. I removed my keyboard from Keyman Desktop, deleted the source folder, built with kmc and re-added the resulting build to Keyman Desktop. The issue persists.
Since I cannot provide links in the response here and don’t know of another way to get you to the git repo, I have pasted the link below and added as much white space as needed within it for the comment to be acceptable.
I realised after sending the last reply that I neglected to answer you on the topic of the Windows diagnostic report. I am running Linux (Ubuntu 24) so this precise info is not doable. Is there a Linux equivalent that could be helpful?
I wonder if it would help if you change your targets to include web.
I wasn’t able to test your keyboard on Firefox until I selected web. (I’m on Windows 11 though.). When I selected that and tested in Firefox the backspace seems to work for me.
I suspect that the problem is not the keyboard itself, but something on your Linux system. Would this post be relevant? Does the backspacing bug show up in multiple applications? What program were you using when you created the demonstration of the bug?
Hi Lorna, thanks for the suggestion. Changing the line to exactly what you suggested caused an error on build for me (not sure why, “Invalid token found”). Instead, I simply tacked web on at the end, making
store(&TARGETS) ‘windows macosx linux desktop web’
Build worked after that but the issue persists. I am confused.
Thanks for the input, Drowe. The bug shows up in most applications if not all. I have tested it on many. The application I was using in the submitted GIF is just the browser on this very webpage. I see the similarity with the issue you linked in your response, but I think the cause for my issue is likely different. My belief is based on the fact that I have another Keyman keyboard working fine on my computer, no backspace bug. This other keyboard was downloaded from the keyman website, not made by me. So, it seems like the issue must be in my code or in the build process. Since all of you seem to avoid issues, I am leaning towards the issue being with the kmc build. Thoughts?
And typing Backspace again, deletes the last remaining character and clears out the Keystroke log. Thus it seems that there’s nothing in the design of your keyboard that would account for the backspacing issue. It seems to me that there’s some interaction between the Linux Keyman engine and whatever your Linux system keyboard software is. @EberhardBeilharz, do you have suggestions for things to check for Keyman on Linux?
Unfortunately, the apostrophe (U+0027) characters were converted to left and right single quotation marks (U+2018 and U+2019) when the text was pasted into this forum.
I had a theory that the issue must be in the kmc build. To test, I punted my source over to a Windows machine to compile using natively-running Keyman Developer. I brought the resulting build into my Linux machine and installed it with Keyman Desktop (Linux). It presents the same issue. I am now perplexed because my Linux machine runs other Keyman keyboards without issue, just not anything that comes from me making it. If the steps along the way are (1) keyman developer default new project, (2) modifications / more code, (3) build, (4) import into Keyman Desktop, then I don’t know where this could be failing. (1) and (2) are seemingly eliminated because you guys have gotten the keyboard to work (Though I don’t think anyone else is on Linux here?). (4) seems to be eliminated too, because I can install other keyboards just fine and they don’t misbehave. (3) was the one left to check, but I just tried building it in Windows and there’s the same issue. Not sure where the issue could be then…
My last thought left is that there is something in the default project that Keyman Developer creates that does not jive with Linux. That’s weird though, because one would assume many online keyboards would be affected (as I assume many are based on this default) and this would have been flagged before…
My SECOND last thought left is that maybe I’m just missing something basic about building and can’t help doing it wrong, regardless of operating system. Would one of you mind providing me with a .kmp file you’ve built from this code? I’d appreciate it.
Note that I have seen (and STILL see, even though that post was closed…) a very similar problem to this, as described here:
But that is with Windows 11, Keyman 17.0.335, Firefox (I don’t see this problem with other browsers like Chrome), and it seems specifically with ESET antivirus installed. So a very different environment, but could these issues somehow be related?
(And one additional factor… The problem shows up when I am typing backspace in Google Docs, but it doesn’t really seem to occur when I am typing into other web pages.)
Issues don’t get closed until they are actually resolved (or really no longer relevant), whereas discussion topics get closed after a period of inactivity (prevents spam and unrelated discussions hijacking threads too much).
That said, I doubt these two issues have a common cause, being on different operating systems and very different environments
Hi Eberhard, thanks for reply. I will try to answer as best I can.
X11
I don’t know what that is, sorry. Probably whatever Ubuntu has by default.
The following is a copy-paste from my terminal. The two last commands were terminated with cntrl+z.
julien@comp:~$ echo $XDG_CURRENT_DESKTOP
ubuntu:GNOME
julien@comp:~$ echo $XDG_SESSION_DESKTOP
ubuntu-xorg
julien@comp:~$ echo $XDG_SESSION_TYPE
x11
julien@comp:~$ dpkg -l keyman
Souhait=inconnU/Installé/suppRimé/Purgé/H=à garder
| État=Non/Installé/fichier-Config/dépaqUeté/échec-conFig/H=semi-installé/W=att>
|/ Err?=(aucune)/besoin Réinstallation (État,Err: majuscule=mauvais)
||/ Nom Version Architecture Description
++±==============-=================-============-=============================>
ii keyman 17.0.335-1+focal1 all Type in your language with Ke>
…skipping…
Souhait=inconnU/Installé/suppRimé/Purgé/H=à garder
| État=Non/Installé/fichier-Config/dépaqUeté/échec-conFig/H=semi-installé/W=att>
|/ Err?=(aucune)/besoin Réinstallation (État,Err: majuscule=mauvais)
||/ Nom Version Architecture Description
++±==============-=================-============-=============================>
ii keyman 17.0.335-1+focal1 all Type in your language with Ke>
~
~
~
~
~
~
~
~
~
~
~
~
~
~
~
~
~
set mark: …skipping…
Souhait=inconnU/Installé/suppRimé/Purgé/H=à garder
| État=Non/Installé/fichier-Config/dépaqUeté/échec-conFig/H=semi-installé/W=att>
|/ Err?=(aucune)/besoin Réinstallation (État,Err: majuscule=mauvais)
||/ Nom Version Architecture Description
++±==============-=================-============-=============================>
ii keyman 17.0.335-1+focal1 all Type in your language with Ke>
~
~
~
~
~
~
~
~
~
~
~
~
~
~
~
~
~
[1]+ Arrêté dpkg -l keyman
julien@comp:~$ dpkg -l ibus
Souhait=inconnU/Installé/suppRimé/Purgé/H=à garder
| État=Non/Installé/fichier-Config/dépaqUeté/échec-conFig/H=semi-installé/W=att>
|/ Err?=(aucune)/besoin Réinstallation (État,Err: majuscule=mauvais)
||/ Nom Version Architecture Description
++±==============-==================-============-============================>
ii ibus 1.5.29-2sil1~noble amd64 Intelligent Input Bus - core