Richard W wrote: ↑Sun Nov 24, 2019 12:00 pmFirst, let me point out that you are currently talking about X, rather than Linux. There are other schemes in Linux, with frameworks like scim (abandoned?), ibus and fcitx, and interfacing keyboard definitions defined by, amongst others, KMfL and M17n, as well as input methods that include their own interfacing with these frameworks. KMfL relies on the characters formed by a US keyboard, which is rather limiting.
X has explicit dead key characters, but formally it is the responsibility of the
application to combine dead kay and following key to make the required character. The combination that should be supported is language-dependent, but fortunately, many applications support them all regardless.
Okay, I just spent an hour and a half reading about how keyboard input works on Linux. And huh. All this time I had been (wrongly) thinking that Fcitx and IBus were keyboard signal interpreters, which then passed their interpretation onto X or Wayland, which then passed the interpretation onto the application as input... But yeah, it seems Fcitx and IBus run as user apps and directly send input signals into programs, so it's the programs that handle dead keys. I guess it usually works because so many programs simply use appropriate GTK or Qt library inputs, or if they use something homemade, they're friendly to Fcitx and IBus (like LibreOffice and the Java GUI libraries).
Although I'm not quite sure what to think, because I'd find it incredible that LibreOffice and Java really have their own implementation of dead key input... Also, I'm on Ubuntu 19, which runs on the X window system and the IBus input method by default, and it is also the case that if I edit the "us" file in /usr/share/X11/xkb/symbols/ (ostensibly an X configuration directory, maybe for old XIM?), my IBus layout for the US keyboard layout does change. But maybe IBus just loads the files of this directory, besides the ones in /usr/share/ibus/.
It doesn't appear that IBus dead key behaviour is defined anywhere in /usr/share/ibus/ or /usr/share/X11/ though, so maybe it's hardcoded into the program itself. Just as you found it was the case with Fcitx...
Finally I'd like to mention that IBus works great with AltGr dead keys out of the box. If I select the "English (US, intl., with dead keys)" layout, I get a bunch of AltGr dead keys like AltGr+. (that is AltGr plus dot) for a dot above letters (ȧċėȯ), and even Shift combinations like AltGr+Shift+3 for macrons (āēōǖ). The problem is that to alter the behaviour of dead_macron, you'd probably need to patch IBus itself somewhere...
Richard W wrote: ↑Sun Nov 24, 2019 2:32 pmEgyptian works as an abjad script with an inordinate number of biliteral and multiliteral signs, plus a batch of logographic determinatives. Many determinatives double as phonetic signs. I've coded up the signs using what I could find of the MdeC (Manuel de Codage) codes, and with Gardiner codes available for everything. It's quicker to type nfrw and get 𓄤𓅱 than to be presented with a choice for nfr including 𓄤𓆑𓂋. (Unicode didn't have the layout characters when I encoded the keyboard.) I use hyphens to enforce character boundaries, but M17n works very quickly in this case because 'nfr' is not the prefix of any other character code. So, typing 'nfr-w-' also yields 𓄤𓅱.
Well, Egyptian writing varied like that, so perhaps it
would be desirable to type "nfr" and get a popup prompt with all of 𓄤, 𓄤𓂋, 𓄤𓆑𓂋. Also, aren't there logograms that in terms of their phonetic value would share the same consonant sequences?
I would take cuneiform systems as semisyllabaries with add-ons. Thus I would just type mush3 to get the logogram for "Inanna", and an-mush3 to prefix it with the determinative DINGIR to write it in the normal fashion. I'd also allow dingir-mush3 and probably dingir-inanna.
Now, one might consider adding prompts to a shared keyboard, but if I couldn't remember which 'mush' to use for Inanna, I'd just grep a plain text sign list - with a little work, the keyboard definition file would serve the function. Did you have in mind typing in an Akkadian word in ASCII and getting a list of possible spellings?
You know, it's funny because now you're making me wonder what Chinese and Japanese speakers do when they similarly forget something like that. Surely at some point users of Traditional Chinese must doubt which fù logogram they should use in a given compound out of 復 'again' and 複 'again, complex', since both characters stand for similar meanings but aren't always interchangeable, e.g. fùxí 'to review' can be 復習 or 複習, but fùhégōng 'composite bow' can only be 複合弓 because the first fù stands for "complex"). I've never seen a Mandarin speaker checking which logogram is needed in cases like this, and I wonder what websites or apps are popular, etc.
bradrn wrote: ↑Sun Nov 24, 2019 4:40 pmI should have expected something like this. Why can’t
anything in Linux be simple‽ (And yes, I know that Windows can be quite a bit more complicated in areas, but at least there are resources for Windows…)
Nah, that's not necessarily the case. It's just a matter of there not being many people wanting to do custom layouts. I can only imagine what it'd take to find out how to do a custom input method for Egyptian or some logographic conscript for Windows. I once saw someone's simple, homemade Windows input method for Cantonese so that it'd work with Jyutping, so I believe doing such a thing for Egyptian or a logographic conscript should be possible, but...
Anyway, given that I want to make Conkey available as widely as possible, which of the above (X, scim, ibus, fcitx, KMfL, M17n, compose key) do you think I should target?
In terms of
frameworks, since you use plenty of AltGr dead keys, I imagine IBus will turn out to be friendlier than Fcitx (or the now-abandoned SCIM, or the old and clunky X(IM)). I'm assuming (likely safely) that Richard is correct when talking about Fcitx's buggy behaviour with regard to AltGr dead keys.
In terms of
engines, I have no idea which of KMFL or M17N will turn out to be friendliest. The Compose engine is funny in this case because it already has a
large number of dead key combinations (that's its whole shtick). I see a bunch of Compose files organized by Linux locale (like "en_US.UTF-8") in /usr/share/X11/locale/, and the files do include definitions of dead key behaviour. That could be the easiest thing to do, but then there's the problem that the
people who use Compose likely won't want their Compose behaviour altered. XD