From mboxrd@z Thu Jan 1 00:00:00 1970 Path: news.gmane.io!.POSTED.blaine.gmane.org!not-for-mail From: =?utf-8?Q?Arsen_Arsenovi=C4=87?= Newsgroups: gmane.emacs.help Subject: Re: numpad doesnt seem to send kp events in wayland Date: Tue, 22 Oct 2024 23:55:32 +0200 Message-ID: <86r087ol9n.fsf@aarsen.me> References: <874j55qc5o.fsf@tanaka.verona.se> Mime-Version: 1.0 Content-Type: multipart/signed; boundary="=-=-="; micalg=pgp-sha512; protocol="application/pgp-signature" Injection-Info: ciao.gmane.io; posting-host="blaine.gmane.org:116.202.254.214"; logging-data="33910"; mail-complaints-to="usenet@ciao.gmane.io" Cc: help-gnu-emacs@gnu.org To: joakim@verona.se Original-X-From: help-gnu-emacs-bounces+geh-help-gnu-emacs=m.gmane-mx.org@gnu.org Tue Oct 22 23:56:24 2024 Return-path: Envelope-to: geh-help-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 1t3MrY-0008fh-2E for geh-help-gnu-emacs@m.gmane-mx.org; Tue, 22 Oct 2024 23:56:24 +0200 Original-Received: from localhost ([::1] helo=lists1p.gnu.org) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1t3Mqy-0008MZ-9t; Tue, 22 Oct 2024 17:55:48 -0400 Original-Received: from eggs.gnu.org ([2001:470:142:3::10]) by lists.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1t3Mqv-0008MI-Lg for help-gnu-emacs@gnu.org; Tue, 22 Oct 2024 17:55:46 -0400 Original-Received: from mout-p-201.mailbox.org ([80.241.56.171]) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_CHACHA20_POLY1305:256) (Exim 4.90_1) (envelope-from ) id 1t3Mqt-0000BH-QW for help-gnu-emacs@gnu.org; Tue, 22 Oct 2024 17:55:45 -0400 Original-Received: from smtp1.mailbox.org (smtp1.mailbox.org [10.196.197.1]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature RSA-PSS (4096 bits) server-digest SHA256) (No client certificate requested) by mout-p-201.mailbox.org (Postfix) with ESMTPS id 4XY5Zt4Vnrz9t1B; Tue, 22 Oct 2024 23:55:34 +0200 (CEST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=aarsen.me; s=MBO0001; t=1729634134; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:cc:mime-version:mime-version:content-type:content-type: in-reply-to:in-reply-to:references:references; bh=JSK0hnEZtoXXluGb89Zd5YiF/DCBhMM+6Kif3QX1KWU=; b=C5tsWgiQLm3GdUqonWrsLY0TSjtNkzs7j4T4yLxQkuJbrjVeo7VQ5ZuweuBLh61F+n6N8N MiY1amzxWqO3bO8veVoGJPp+0znDHIpHFB292K/3B7tVlMoPgo0XTi6My6DCWiZMeiEHjn /Qfvssbbd3zYoNkse3o7U3drT/l14samF/ZLXz5iv6KG/RxMkHwNEGC1Q8j3lcczqOrvM3 W9Qcl8EnuLNnP+9cYKV58gJg9pfmhS7iwxaHoU+rth4C6rFzRLR67sKBH41gIhl440+YFQ a0ID+RnEfQWphSb55V48qBUPr7JusT427vemQdGM+RWNojDYeLmoxlnzF65jBg== In-Reply-To: <874j55qc5o.fsf@tanaka.verona.se> (joakim@verona.se's message of "Tue, 22 Oct 2024 01:17:07 +0200") Received-SPF: pass client-ip=80.241.56.171; envelope-from=arsen@aarsen.me; helo=mout-p-201.mailbox.org X-Spam_score_int: -27 X-Spam_score: -2.8 X-Spam_bar: -- X-Spam_report: (-2.8 / 5.0 requ) BAYES_00=-1.9, DKIM_SIGNED=0.1, DKIM_VALID=-0.1, DKIM_VALID_AU=-0.1, DKIM_VALID_EF=-0.1, RCVD_IN_DNSWL_LOW=-0.7, RCVD_IN_VALIDITY_RPBL_BLOCKED=0.001, RCVD_IN_VALIDITY_SAFE_BLOCKED=0.001, SPF_HELO_NONE=0.001, SPF_PASS=-0.001 autolearn=ham autolearn_force=no X-Spam_action: no action X-BeenThere: help-gnu-emacs@gnu.org X-Mailman-Version: 2.1.29 Precedence: list List-Id: Users list for the GNU Emacs text editor List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: help-gnu-emacs-bounces+geh-help-gnu-emacs=m.gmane-mx.org@gnu.org Original-Sender: help-gnu-emacs-bounces+geh-help-gnu-emacs=m.gmane-mx.org@gnu.org Xref: news.gmane.io gmane.emacs.help:148214 Archived-At: --=-=-= Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: quoted-printable joakim@verona.se writes: > Hello, > > I used to use a numpad to bind to do things in emacs. > > This used to work really well on the i3wm window manager and a gtk emacs > build. > > Then I bought a nice new framework laptop which has a hidpi screen, so I > switched to using the sway wm, and emacs-pgtk. > > Now the numpad no longer sends keypad events in a way that emacs > recognizes, instead just plain numbers are received. > > for some reason i3 wont work anymore so I dont have anything to compare > with. > > Is this just me or is this a well known problem? > > below is an example of the code I use, but normally I just test with c-h > k to see which key emacs receives. > > I also tried xev, and there it seems I get kp events, at least under > xwayland I guess. > > (define-key cider-mode-map (kbd "") 'sylt-stop) > (define-key cider-mode-map (kbd "") 'sylt-play-metro) > > (defmacro sylt-song-event-map-key (key num) > `(define-key cider-mode-map (kbd ,key) > (lambda () (interactive) (cider-nrepl-sync-request:eval= ,(concat "(sylt.core/song-event \"" num "\")"))))) > > > > (sylt-song-event-map-key "" "init") > (sylt-song-event-map-key "" "1") FWIW, you can try checking against https://git.sr.ht/~sircmpwn/wev and WAYLAND_DEBUG=3D1 instead of xev to check whether there's matching keycodes. I don't have a keypad to test with right now but I suspect something can be arranged for your case. Consider (read-key) also as a test. =2D-=20 Arsen Arsenovi=C4=87 --=-=-= Content-Type: application/pgp-signature; name="signature.asc" -----BEGIN PGP SIGNATURE----- iOYEARYKAI4WIQT+4rPRE/wAoxYtYGFSwpQwHqLEkwUCZxgfVV8UgAAAAAAuAChp c3N1ZXItZnByQG5vdGF0aW9ucy5vcGVucGdwLmZpZnRoaG9yc2VtYW4ubmV0RkVF MkIzRDExM0ZDMDBBMzE2MkQ2MDYxNTJDMjk0MzAxRUEyQzQ5MxAcYXJzZW5AYWFy c2VuLm1lAAoJEFLClDAeosSTrOQBAKnF519G7EzZLH73oJ+VHWc5wVWWJLTdIPgy DS6SEzCvAP405BPpCOuUVHW4xBswnjDWo0e1BiRg/fVnOzLlKSJTAQ== =8uVm -----END PGP SIGNATURE----- --=-=-=--