helloSystem / hello

Desktop system for creators with a focus on simplicity, elegance, and usability. Based on FreeBSD. Less, but better!
2.31k stars 57 forks source link

Consider adding a Compose key #186

Open probonopd opened 3 years ago

probonopd commented 3 years ago

Consider adding a Compose key as suggested by @linuxkettle.

Thoughts?

probonopd commented 3 years ago

On *nix systems, to type this character

`

one has to type

``

unless "nodeadkeys" is set, which

How come that the Mac does not suffer from this issue? Does this mean that on the Mac this whole topic is solved much more elegantly and does not need a Compose key?

probonopd commented 3 years ago

What is going on one the Mac is described at http://www.hcs.harvard.edu/~jrus/Site/Cocoa%20Text%20System.html and I really doubt this has been ported to *nix proper yet. @mszoek?

Accoding to http://lolengine.net/blog/2012/06/17/compose-key-on-os-x there is an advantage to having a "real Compose key" even on the Mac.

mszoek commented 3 years ago

What macOS has is called the AltGr (Alt Graphics) key in X11. AltGr gives you the "alternate" glyph for a key, which lets you type things like ë or ¥ without going through Compose sequences. It's right Option on my MacBook.

On a PC, I typically set my right Alt to AltGr and right Ctrl, Win or Menu key to Compose. The bindings are different from macOS but the functionality is the same, and the layouts can be changed to match. Try setxkbmap -layout us -variant altgr-intl if you have a US keyboard. AltGr should be on right Alt by default.

As @probonopd noted, AltGr is not available in all X11 layouts. The "elegant" solution is just to provide layouts with AltGr support :) We could build these missing variants and put them in a package, or submit them upstream. The advantage of Compose IMHO is that it works in all layouts without or with AltGr. I have rarely needed Compose if AltGr is there, but otherwise it is very useful.

kettle-7 commented 3 years ago

I use Compose mapped to Caps Lock.