From mboxrd@z Thu Jan 1 00:00:00 1970 Path: news.gmane.io!.POSTED.blaine.gmane.org!not-for-mail From: Po Lu via "Bug reports for GNU Emacs, the Swiss army knife of text editors" Newsgroups: gmane.emacs.bugs Subject: bug#55362: 29.0.50; Super key no longer works on Wayland Date: Wed, 11 May 2022 20:46:55 +0800 Message-ID: <87y1z8z16o.fsf@yahoo.com> References: <871qx08k43.fsf@schnouki.net> Reply-To: Po Lu Mime-Version: 1.0 Content-Type: text/plain Injection-Info: ciao.gmane.io; posting-host="blaine.gmane.org:116.202.254.214"; logging-data="25648"; mail-complaints-to="usenet@ciao.gmane.io" User-Agent: Gnus/5.13 (Gnus v5.13) Emacs/28.0.91 (gnu/linux) Cc: 55362@debbugs.gnu.org To: Thomas Jost Original-X-From: bug-gnu-emacs-bounces+geb-bug-gnu-emacs=m.gmane-mx.org@gnu.org Wed May 11 14:48:52 2022 Return-path: Envelope-to: geb-bug-gnu-emacs@m.gmane-mx.org Original-Received: from lists.gnu.org ([209.51.188.17]) by ciao.gmane.io with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.92) (envelope-from ) id 1nollr-0006P3-RH for geb-bug-gnu-emacs@m.gmane-mx.org; Wed, 11 May 2022 14:48:51 +0200 Original-Received: from localhost ([::1]:44436 helo=lists1p.gnu.org) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1nollq-0002Qm-E7 for geb-bug-gnu-emacs@m.gmane-mx.org; Wed, 11 May 2022 08:48:50 -0400 Original-Received: from eggs.gnu.org ([2001:470:142:3::10]:46452) by lists.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1noll4-0002Me-Vq for bug-gnu-emacs@gnu.org; Wed, 11 May 2022 08:48:03 -0400 Original-Received: from debbugs.gnu.org ([209.51.188.43]:42539) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_128_GCM_SHA256:128) (Exim 4.90_1) (envelope-from ) id 1noll4-00055U-FD for bug-gnu-emacs@gnu.org; Wed, 11 May 2022 08:48:02 -0400 Original-Received: from Debian-debbugs by debbugs.gnu.org with local (Exim 4.84_2) (envelope-from ) id 1noll4-00076A-BA for bug-gnu-emacs@gnu.org; Wed, 11 May 2022 08:48:02 -0400 X-Loop: help-debbugs@gnu.org Resent-From: Po Lu Original-Sender: "Debbugs-submit" Resent-CC: bug-gnu-emacs@gnu.org Resent-Date: Wed, 11 May 2022 12:48:02 +0000 Resent-Message-ID: Resent-Sender: help-debbugs@gnu.org X-GNU-PR-Message: followup 55362 X-GNU-PR-Package: emacs Original-Received: via spool by 55362-submit@debbugs.gnu.org id=B55362.165227323726334 (code B ref 55362); Wed, 11 May 2022 12:48:02 +0000 Original-Received: (at 55362) by debbugs.gnu.org; 11 May 2022 12:47:17 +0000 Original-Received: from localhost ([127.0.0.1]:36436 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1nolkH-0006nT-P1 for submit@debbugs.gnu.org; Wed, 11 May 2022 08:47:17 -0400 Original-Received: from sonic303-21.consmr.mail.ne1.yahoo.com ([66.163.188.147]:45838) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1nolkG-0006hL-6r for 55362@debbugs.gnu.org; Wed, 11 May 2022 08:47:12 -0400 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=yahoo.com; s=s2048; t=1652273225; bh=oNhldLQVpbQhcoazYmFTL3vYqzJduh5yf6At4thOCkg=; h=From:To:Cc:Subject:References:Date:In-Reply-To:From:Subject:Reply-To; b=tjDZSsClnWXdGQlWB0Ib9y55K73EFF0/C/Cs/46GW7EKIh+qfQ36CNpjFtF9ukWOnENd55Les7Sqr4pz7OSZqk8nhypwq02UOGvZYHqYGVJivBl9T9ACFYqaS5gRlRnhHLcmms1IxHy8yljC6u4NGGx5eOQdjbOgRXvFpcUOoYWnj21wWOdASPuEjAyDH4tGVveHjA9HyFU1HC+95n/GFvwXTDANeokWtDyggNVZsieGri5Acj7p+vaFvrZNPXTzqT3r0TzteCztUBsIyUbtdlfRzC+TfQr+zp5qURyPMSdEyTj7yiIpW3lNIsb2llObPLkRd3pQktWT53U0yza4Hw== X-SONIC-DKIM-SIGN: v=1; a=rsa-sha256; c=relaxed/relaxed; d=yahoo.com; s=s2048; t=1652273225; bh=Aw1tgRb4B6mt7JrBmYJPBMagCiHitlA+0whQFMstEmA=; h=X-Sonic-MF:From:To:Subject:Date:From:Subject; b=aOXS44yFvXKibwMTqYt9jDC+tDnn0DOWyzZjIXu5UWmHDoR/Ic5CeBHhvqZHfdBt0faNlcml8kZBcvPUBJ3TLyPqWdCN1k60F+Ge6Ey7oiaxqWen8CbS+wWHJGRUULbAQUI1W3xDrv+biuaxxdNf7jJa6t/qV+N1OtHsBicL6CeWs7T8gq7IuNKALgCrJouZO0ys/xWbn61AMJg1P3Bq/CZPQ1ek5ZcpNen40EMtR/TU2+BoftzaU70DPJRRgreM9B0ghaVzsK1JJASnA2BexI55d7UjPF5AxOYE/procA//q0jBtAqReQrA4Sbezjmj8aclLHc28nzmkc/90WtWQA== X-YMail-OSG: MzbAOgkVM1nT9cTUSuj6M9CHPzMFyeanxJwKjrjfevYh5rtY1EqgZBo9t6mAWuN GkLa2Y3zUP.364xKuNreqQEBlrOrQzgCIsB1ZQbP7uwiWTPO01h0Zlq8ooRUUXm2jp4Q59aW7DzU IggSENDSN16QF.IJRTgqvnpprekukPsJ67Q0cdFjOm_N3opnTLqRQzYNSgPM5w9plie94Hkle3iJ SEL7uEvLO49lcJ0o_W5RLjvzHP4a.j9K9CDOxuS3TZ0SXFI2uvi664mmSa9lGGk7oYngAbMubPat jpe55GfD5uEk6a8Pa6JVBSwFm1OAqLlte8J1WKKV1X5y7QAmEioH3d8lM4jzktsnBCYf4Q5fjKyN .FiGSXrol8juIenR0fd.LnTtd4_DdvWUrBqPJL2rWaWN0K6URLzB.74tbUUBEHIt5isSUQcceNH8 mNG7mMxYMoTIJ9byAP5Oa1tqggMCO0BcXeAJvH4EPSHnAZ244q1GCBjegeUTp1RIViPi1BtGVFDo 1sRSYuVhuUqJ0s5UXhrGCZ0Z_.el6z7Wtm9ITGbb1LO155mimCeAWnw91_9JC.AXKlrpYJqd8G3D cgTq.RZ.eZhGouQDrc0SPKXXmBQSfw0qZDoQFoTJWTJ0tqRXMsLtNA7.OSHEzpYvK8rWZZ.92dNn ahZ_fuzpWhDqc7sdcrfStubghY97851bZ6YQ22OwY.62nJUcrOqgdtDIWGirIRr.B8tWnOprXyIX RkI53XonqrLy5lk5x8ZaxpMsKEQlpinqZaxqDv4l4iwbhl7oBhY5QEQxLlQ0CpRfN6zLXsg09aH6 317uu3F3VtvxbZ6ko9POzXl5kM.KGiQPOIfyfn8Mvp X-Sonic-MF: Original-Received: from sonic.gate.mail.ne1.yahoo.com by sonic303.consmr.mail.ne1.yahoo.com with HTTP; Wed, 11 May 2022 12:47:05 +0000 Original-Received: by hermes--canary-production-sg3-856bf69955-sx85m (Yahoo Inc. Hermes SMTP Server) with ESMTPA ID a104b62ac00da12249a213d560a00bae; Wed, 11 May 2022 12:47:01 +0000 (UTC) In-Reply-To: <871qx08k43.fsf@schnouki.net> (Thomas Jost's message of "Wed, 11 May 2022 12:00:12 +0200") X-Mailer: WebService/1.1.20188 mail.backend.jedi.jws.acl:role.jedi.acl.token.atz.jws.hermes.yahoo X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.18 Precedence: list X-BeenThere: bug-gnu-emacs@gnu.org List-Id: "Bug reports for GNU Emacs, the Swiss army knife of text editors" List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: bug-gnu-emacs-bounces+geb-bug-gnu-emacs=m.gmane-mx.org@gnu.org Original-Sender: "bug-gnu-emacs" Xref: news.gmane.io gmane.emacs.bugs:231916 Archived-At: Thomas Jost writes: > Hey folks, > > When using recent builds of Emacs with PGTK on Wayland (Sway), the Super > key is no longer detected. I use it in a lot of shortcuts, but now > typing e.g. `s-/' just inputs /. > > If I run an older build with the exact same config (or even with `emacs > -Q'), I don't experience that issue, and shortcuts using Super still > work. So, this seems to be an Emacs bug. > > Using git bisect, I was able to find that this started in commit > 1c1ae6ba802cc5813fa6f8f90f21050aae6bb459. Further investigation revealed > that when typing a shortcut with Super, the GDK_SUPER_MASK bit isn't > set, but GDK_MOD4_MASK is. > > I'm not sure what the best option is: restoring the former > x_find_modifier_meanings() function, or hard-coding that Mod4 is the > same as Super (like Mod1 and Meta). The bug is in GTK, not in Emacs. It doesn't set the virtual modifier masks corresponding to the Super key on some Wayland compositors, which it is supposed to. That patch (and the old code) is incorrect, and the code before its removal was another example of the PGTK port haphazardly copying code from xterm.c to do stuff GDK is supposed to do by itself. Mod4 is a real modifier and can correspond to any (number) of virtual modifiers, which might or might not contain Super. Please report the bug to the GTK developers. Something along the lines of "GDK_SUPER_MASK not set on keyboard events on wlroots-based compositors when the Super key is held down". After you do that, I'd appreciate it if you gave us a link to the bug report, so we can at least put it in etc/PROBLEMS. Thanks in advance.