deadpixi / sam

An updated version of the sam text editor.
Other
436 stars 47 forks source link

could not initialize keyboard under Wayland #56

Closed realwhz closed 7 years ago

realwhz commented 7 years ago

Hello.

Looks like sam cannot open under Wayland environment (GNOME 3.24). It complains: could not initialize keyboard. After changing to X11 based GNOME, it can work properly.

Not sure if it is a known issue. Suggestions are welcome. Thanks.

p.s., the sam from `plan9 from user space' works fine under the same environment.

realwhz commented 7 years ago

Perhaps the following bugreport is relevant. I will give it a try. https://bugs.freedesktop.org/show_bug.cgi?id=89240

realwhz commented 7 years ago

After switching to XkbGetMap resolves the problem. However, I'm not sure if it will affect its stability under X11 (two additional checks have to be removed too).

diff --git a/libXg/xtbinit.c b/libXg/xtbinit.c index 89e4b7c..63f66b8 100644 --- a/libXg/xtbinit.c +++ b/libXg/xtbinit.c @@ -234,8 +234,8 @@ xtbinit(Errfunc f, char class, int pargc, char argv, char fallbacks) keyid = devs[i].id; }

deadpixi commented 7 years ago

@realwhz Please check the latest master code and see if it works under Wayland. If not, please open a new issue. Thank you!