> The issue is more general than just a single character with a
> modifier, because key sequences such as "C-x z" will still not
> work: the 'z' will become the corresponding non-ASCII character
> when a non-US keyboard layout is used. Therefore, the only general
> solution is for Emacs to be aware of the keyboard layout in use,
> and map the characters internally to their ASCII equivalents using
> that layout.
Probably yes, I don't know how other applications do it internally.
As I mentioned, LibreOffice and IDEA (both are probably Java) do
it somehow, so there is a way. Maybe I'll try to dig through it later,
since I'm very familiar with Java.
By the way, what I forgot to mention, is that Emacs input modes
perform exactly like I want (i.e. bind to physical keys, so that C-.
in Russian works as C-/ in English; also e.g. C-ч й is translated to
C-x q, so even non-modified characters inside bindings work), but
they have the advantage of knowing the layout, of course. And,
as I mentioned, there are two problems with them: 1) I have to
use C-\ to switch and 2) configuration of `xkb' is bypassed.
Paul