Received: (at 74423) by debbugs.gnu.org; 4 Jan 2025 04:56:04 +0000 From debbugs-submit-bounces <at> debbugs.gnu.org Fri Jan 03 23:56:04 2025 Received: from localhost ([127.0.0.1]:52970 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from <debbugs-submit-bounces <at> debbugs.gnu.org>) id 1tTwCh-0000tr-CX for submit <at> debbugs.gnu.org; Fri, 03 Jan 2025 23:56:03 -0500 Received: from mailscanner.iro.umontreal.ca ([132.204.25.50]:63226) by debbugs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.84_2) (envelope-from <monnier@HIDDEN>) id 1tTwCd-0000tJ-3q for 74423 <at> debbugs.gnu.org; Fri, 03 Jan 2025 23:56:01 -0500 Received: from pmg3.iro.umontreal.ca (localhost [127.0.0.1]) by pmg3.iro.umontreal.ca (Proxmox) with ESMTP id 0AD83440CF4; Fri, 3 Jan 2025 23:55:52 -0500 (EST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=iro.umontreal.ca; s=mail; t=1735966550; bh=6OFTmN76rrqJg49/MJWDIYKBUnyg9dVNUi7iW2eyJ9A=; h=From:To:Cc:Subject:In-Reply-To:References:Date:From; b=SBVzCp99zvUEw3YRKn+3uZ98hZk1dmqU3UVlUArvD3e8N+9SzJ0JK5xl/pmgudkxL H+Uu5H6G2X1op1r0769EevKcTc8O7XcgC5iudEg3N85AIrvv3wDaiSNHwYeFfduUlF XoztAanJmD5tI7GTT742g4WDVq62zprYH+RtM3jSmBbAW1+Os9Y0itNL62XRco+09p 6njeAw+e7Hs6NzyE2Pt7IQTZ1NWcR5NhG7W1U0iFiQ72QMB29Tau653TQeDU5qbTVW qHKhi0xNquyASlj4feVIaSHbo76j9cVEQNv4pjYUX8biWvmkC3dMoISWq2gnwcnGJl v0LuNM2LYAyhA== Received: from mail01.iro.umontreal.ca (unknown [172.31.2.1]) by pmg3.iro.umontreal.ca (Proxmox) with ESMTP id 1FE32440CDE; Fri, 3 Jan 2025 23:55:50 -0500 (EST) Received: from alfajor (104-195-200-87.cpe.teksavvy.com [104.195.200.87]) by mail01.iro.umontreal.ca (Postfix) with ESMTPSA id D4484120070; Fri, 3 Jan 2025 23:55:49 -0500 (EST) From: Stefan Monnier <monnier@HIDDEN> To: Cecilio Pardo <cpardo@HIDDEN> Subject: Re: bug#74423: Low level key events In-Reply-To: <e8833e75-c05f-43e2-81b4-464b9236211d@HIDDEN> (Cecilio Pardo's message of "Thu, 2 Jan 2025 16:42:34 +0100") Message-ID: <jwvpll3jlft.fsf-monnier+emacs@HIDDEN> References: <fb50ec11-7aec-481e-8a3a-ecdcf22eb7c0@HIDDEN> <31bdc55d-8c13-4de0-9cef-bd6cc4fb033f@HIDDEN> <s1r8qtzsvbe.fsf@HIDDEN> <d5c72818-e907-43f5-853a-89ec01264157@HIDDEN> <jwv4j43jisn.fsf-monnier+emacs@HIDDEN> <705fabb8-1ea0-4894-8c32-05097ab822c9@HIDDEN> <jwvplmqtuh1.fsf-monnier+emacs@HIDDEN> <b0b914a0-b454-41b0-aa3d-d9e243c210f5@HIDDEN> <868qsvz07i.fsf@HIDDEN> <162dada7-ad54-4ca5-8f11-d55dd6dccb3c@HIDDEN> <867c8ezny3.fsf@HIDDEN> <c0bd3bff-4546-4169-9e5d-ba60ef059b6c@HIDDEN> <86bjxev7ng.fsf@HIDDEN> <343e2854-a16e-4718-894a-470b733ae91f@HIDDEN> <jwvseqgbd1y.fsf-monnier+emacs@HIDDEN> <e8833e75-c05f-43e2-81b4-464b9236211d@HIDDEN> Date: Fri, 03 Jan 2025 23:55:49 -0500 User-Agent: Gnus/5.13 (Gnus v5.13) MIME-Version: 1.0 Content-Type: text/plain X-SPAM-INFO: Spam detection results: 0 ALL_TRUSTED -1 Passed through trusted hosts only via SMTP AWL -0.026 Adjusted score from AWL reputation of From: address BAYES_00 -1.9 Bayes spam probability is 0 to 1% DKIM_SIGNED 0.1 Message has a DKIM or DK signature, not necessarily valid DKIM_VALID -0.1 Message has at least one valid DKIM or DK signature DKIM_VALID_AU -0.1 Message has a valid DKIM or DK signature from author's domain DKIM_VALID_EF -0.1 Message has a valid DKIM or DK signature from envelope-from domain X-SPAM-LEVEL: X-Spam-Score: -2.3 (--) X-Debbugs-Envelope-To: 74423 Cc: luangruo@HIDDEN, 74423 <at> debbugs.gnu.org, Eli Zaretskii <eliz@HIDDEN> X-BeenThere: debbugs-submit <at> debbugs.gnu.org X-Mailman-Version: 2.1.18 Precedence: list List-Id: <debbugs-submit.debbugs.gnu.org> List-Unsubscribe: <https://debbugs.gnu.org/cgi-bin/mailman/options/debbugs-submit>, <mailto:debbugs-submit-request <at> debbugs.gnu.org?subject=unsubscribe> List-Archive: <https://debbugs.gnu.org/cgi-bin/mailman/private/debbugs-submit/> List-Post: <mailto:debbugs-submit <at> debbugs.gnu.org> List-Help: <mailto:debbugs-submit-request <at> debbugs.gnu.org?subject=help> List-Subscribe: <https://debbugs.gnu.org/cgi-bin/mailman/listinfo/debbugs-submit>, <mailto:debbugs-submit-request <at> debbugs.gnu.org?subject=subscribe> Errors-To: debbugs-submit-bounces <at> debbugs.gnu.org Sender: "Debbugs-submit" <debbugs-submit-bounces <at> debbugs.gnu.org> X-Spam-Score: -3.3 (---) > In this new version I changed the way events are handled. > Now llk-handle generates input events to be used with normal > keymaps, instead of running a command. The function llk-bind > activates event generation for a key and a combination of > events press, release, double, triple. I really like what I see. As I think I mentioned, I had made a related effort in local patches, but I couldn't figure out back then how to make the low-level events useful. I wouldn't be surprised if such low-level events remain limited in their use, but I suspect that some specific uses of them could become very popular. I haven't seen many opinions of late on your code (other than my own), sadly. I think we need some more reviewers here. > You suggested to auto generate the keysym table, but we > would still need a table to relate the Windows keys to the X > equivalent. I don't doubt some part has to be done manually, but I think we should strive to make it via code as much as possible. E.g. on each platform we should try to provide a programmatic way to map the integer key to/from a meaningful system-specific string or symbol (at least, to the extent that the underlying system provides such a functionality). Mapping between those symbols in different systems will likely be (at least partly) manual, inevitably, but I'm hoping this can be significantly smaller (especially I'm hoping we can "align" the system-specific symbols such that many are already identical between the different systems). Finally it's not 100% indispensable to have unified symbols that work identically on all systems: users could also just use the system-specific names. They'd need a mapping between them only for code/configuration that is used with different systems. So it's only really important when those names start to be used in libraries. > +@cindex @code{low-level-key} event > +@item (low-level-key @var{is-key-press} @var{key} @var{modifier} @var{time} @var{frame}) > +This event is sent on the physical press or release of keys, only on > +systems where it is supported, currently X, MS-Windows and PGTK, and > +only if the variable @code{enable-low-level-key-events} has a > +non-@code{nil} value. See its documentation for the values to use, that > +can activate the events for all or some keys. > + > +@var{is-key-press} is @code{t} for a key press, @code{nil} for a key > +release. @var{time} is the event's time in milliseconds, as reported by > +the underlying platform, and should only be used to measure time > +intervals between events of this same kind. [ This made me wonder if those timestamps can be compared between events coming from different X11 servers. ] > @var{frame} is the frame +receiving the event. Any chance this could be changed to a window? [ What does it even mean? Usually we associate keyboard events with the `window-point` of the currently selected window (and they don't come with the information attached), whereas we associated mouse events with the position of the mouse cursor. But when I do `down-meta down-mouse-1 up-mouse-1 up-meta` to generate a `M-mouse-1` event, the events on the `meta` key end up associated with the position of the mouse cursor even tho they come from the keyboard. ] > @var{modifier} is @code{nil} if the key is not a > +modifier key, @code{t} if it is, but it is unknown which one, or one of > +@code{shift}, @code{control}, @code{meta}, @code{alt}, @code{super}, > +@code{hyper}. In the docstring you mention that PGTK can't distinguish modifiers. It would be useful here to mention here also the kinds of reasons why we might get just `t`: can it happen for some keys and not others, or is it the case for all the events of a given kind of terminal? > Loading @file{low-level-key.el} sets a handler > +that can generate normal input events for key press, release and multi > +tap. See the function @code{llk-bind}. Any other ELisp code could do a similar task, tho. So, I'd probably present it a bit differently, like: Because generating these events for all keys would interfere with normal keyboard input, they are by default filtered out by a binding in `special-event-map`. @file{low-level-key.el} is a package that lets you configure which of those events to turn into normal input events. It is also able to recognize some specific patterns such a (multi) taps. [ BTW, you might like to explain what is a (multi) tap here, as well. ] > +(cl-defstruct (low-level-key (:type list)) I recommend you add `(:constructor nil)` and `(:copier nil)` so the macro doesn't auto-define `make-low-level-key` and `copy-low-level-key` functions. > +(defvar llk-bindings nil > + "List of bindings for low level key events (press/release/tap). > +Use the `llk-bind' function to add bindings. See its documentation for > +a description of the binding information.") [ Seeing how it's used, I suggest you use a hash-table instead of a list. ] > +EVENTS are symbols that activate one event. Possible values are `press', > +`release', `double' and `triple'. Any reason why there isn't an option to emit an event for a single press+release? > + (llk-bind xk-shift-l \\='double) > + > +will generate the event `double-xk-shift-l', than can be bound to a > +command with: AFAICT the event will be named `double-key-xk-shift-l`. Did I miss something? [ I like this "key-" in the event name, FWIW, so I suggest to keep the code but fix the doc rather than the reverse. Tho, if we can drop the `xk-`, I'd be happier yet. Maybe the generated event names should have "llk-" in them instead of "key-". ] > +(defun describe-low-level-key () > + "Wait for key press and describe the low-level key event it generates." > + (interactive) > + (define-key special-event-map [low-level-key] 'llk--describe)) This is brittle. I don't really have a better suggestion, sadly, but it deserves a comment. > +(setq llk-bindings nil) Why? Also the file lacks the usual end of file marker (and the call to `provide`). I'll try and take a look at the C code later. Stefan
bug-gnu-emacs@HIDDEN
:bug#74423
; Package emacs
.
Full text available.Received: (at 74423) by debbugs.gnu.org; 2 Jan 2025 15:42:47 +0000 From debbugs-submit-bounces <at> debbugs.gnu.org Thu Jan 02 10:42:47 2025 Received: from localhost ([127.0.0.1]:46201 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from <debbugs-submit-bounces <at> debbugs.gnu.org>) id 1tTNLR-0007gK-4w for submit <at> debbugs.gnu.org; Thu, 02 Jan 2025 10:42:47 -0500 Received: from mail.imayhem.com ([82.223.54.191]:39079 helo=zealous-pike.82-223-54-191.plesk.page) by debbugs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_128_GCM_SHA256:128) (Exim 4.84_2) (envelope-from <cpardo@HIDDEN>) id 1tTNLN-0007g0-C5 for 74423 <at> debbugs.gnu.org; Thu, 02 Jan 2025 10:42:43 -0500 Received: from [192.168.68.102] (111.red-88-21-7.staticip.rima-tde.net [88.21.7.111]) by zealous-pike.82-223-54-191.plesk.page (Postfix) with ESMTPSA id 0D8E88012A; Thu, 2 Jan 2025 15:42:35 +0000 (UTC) Authentication-Results: zealous-pike.82-223-54-191.plesk.page; spf=pass (sender IP is 88.21.7.111) smtp.mailfrom=cpardo@HIDDEN smtp.helo=[192.168.68.102] Received-SPF: pass (zealous-pike.82-223-54-191.plesk.page: connection is authenticated) Content-Type: multipart/mixed; boundary="------------eNHcmXNQvtsRN3BsZgn4RNX3" Message-ID: <e8833e75-c05f-43e2-81b4-464b9236211d@HIDDEN> Date: Thu, 2 Jan 2025 16:42:34 +0100 MIME-Version: 1.0 User-Agent: Mozilla Thunderbird Subject: Re: bug#74423: Low level key events To: Stefan Monnier <monnier@HIDDEN> References: <fb50ec11-7aec-481e-8a3a-ecdcf22eb7c0@HIDDEN> <31bdc55d-8c13-4de0-9cef-bd6cc4fb033f@HIDDEN> <s1r8qtzsvbe.fsf@HIDDEN> <d5c72818-e907-43f5-853a-89ec01264157@HIDDEN> <jwv4j43jisn.fsf-monnier+emacs@HIDDEN> <705fabb8-1ea0-4894-8c32-05097ab822c9@HIDDEN> <jwvplmqtuh1.fsf-monnier+emacs@HIDDEN> <b0b914a0-b454-41b0-aa3d-d9e243c210f5@HIDDEN> <868qsvz07i.fsf@HIDDEN> <162dada7-ad54-4ca5-8f11-d55dd6dccb3c@HIDDEN> <867c8ezny3.fsf@HIDDEN> <c0bd3bff-4546-4169-9e5d-ba60ef059b6c@HIDDEN> <86bjxev7ng.fsf@HIDDEN> <343e2854-a16e-4718-894a-470b733ae91f@HIDDEN> <jwvseqgbd1y.fsf-monnier+emacs@HIDDEN> Content-Language: es-ES From: Cecilio Pardo <cpardo@HIDDEN> In-Reply-To: <jwvseqgbd1y.fsf-monnier+emacs@HIDDEN> X-Spam-Score: 0.0 (/) X-Debbugs-Envelope-To: 74423 Cc: luangruo@HIDDEN, 74423 <at> debbugs.gnu.org, Eli Zaretskii <eliz@HIDDEN> X-BeenThere: debbugs-submit <at> debbugs.gnu.org X-Mailman-Version: 2.1.18 Precedence: list List-Id: <debbugs-submit.debbugs.gnu.org> List-Unsubscribe: <https://debbugs.gnu.org/cgi-bin/mailman/options/debbugs-submit>, <mailto:debbugs-submit-request <at> debbugs.gnu.org?subject=unsubscribe> List-Archive: <https://debbugs.gnu.org/cgi-bin/mailman/private/debbugs-submit/> List-Post: <mailto:debbugs-submit <at> debbugs.gnu.org> List-Help: <mailto:debbugs-submit-request <at> debbugs.gnu.org?subject=help> List-Subscribe: <https://debbugs.gnu.org/cgi-bin/mailman/listinfo/debbugs-submit>, <mailto:debbugs-submit-request <at> debbugs.gnu.org?subject=subscribe> Errors-To: debbugs-submit-bounces <at> debbugs.gnu.org Sender: "Debbugs-submit" <debbugs-submit-bounces <at> debbugs.gnu.org> X-Spam-Score: -1.0 (-) This is a multi-part message in MIME format. --------------eNHcmXNQvtsRN3BsZgn4RNX3 Content-Type: text/plain; charset=UTF-8; format=flowed Content-Transfer-Encoding: 7bit Hello, In this new version I changed the way events are handled. Now llk-handle generates input events to be used with normal keymaps, instead of running a command. The function llk-bind activates event generation for a key and a combination of events press, release, double, triple. I also made changes following your notes, such as: - Clarification on the event's time, documentation of keysyms variables moved, don't limit to GUI systems. - cl-defstruct for the event payload. - Format and naming conventions. - Default timeout to mouse double click timeout. You suggested to auto generate the keysym table, but we would still need a table to relate the Windows keys to the X equivalent. --------------eNHcmXNQvtsRN3BsZgn4RNX3 Content-Type: text/plain; charset=UTF-8; name="0001-Send-events-for-key-presses-and-key-releases.patch" Content-Disposition: attachment; filename="0001-Send-events-for-key-presses-and-key-releases.patch" Content-Transfer-Encoding: base64 RnJvbSA5ZjQ4ZGEzNzU3MWNmOTIxYzg1OGIwMWI5ZDc2ZTdkMTc5ODYyNWZlIE1vbiBTZXAg MTcgMDA6MDA6MDAgMjAwMQpGcm9tOiBDZWNpbGlvIF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nQuCihsbGst aGFuZGxlKTogSGFuZGxlciBmb3Iga2V5IGV2ZW50cy4KKGxsay0tZ2VuZXJhdGUtZXZlbnQp OiBHZW5lcmF0ZSBpbnB1dCBldmVudCBmb3Iga2V5LgoobGxrLS1nZW5lcmF0ZS1ldmVudHMp OiBHZW5lcmF0ZSBpbnB1dCBldmVudHMgZm9yIGtleS4KLS0tCiBkb2MvbGlzcHJlZi9jb21t YW5kcy50ZXhpIHwgIDI1ICsrKwogbGlzcC9sb3ctbGV2ZWwta2V5LmVsICAgICB8IDM3MyAr KysrKysrKysrKysrKysrKysrKysrKysrKysrKysrKysrKysrKwogc3JjL2d0a3V0aWwuYyAg ICAgICAgICAgICB8ICA4MSArKysrKysrKysKIHNyYy9rZXlib2FyZC5jICAgICAgICAgICAg fCAgNjAgKysrKysrCiBzcmMva2V5Ym9hcmQuaCAgICAgICAgICAgIHwgICAxICsKIHNyYy9w Z3RrdGVybS5jICAgICAgICAgICAgfCAgNTUgKysrKysrCiBzcmMvdGVybWhvb2tzLmggICAg ICAgICAgIHwgICAxICsKIHNyYy93MzJmbnMuYyAgICAgICAgICAgICAgfCAgMTEgKysKIHNy Yy93MzJ0ZXJtLmMgICAgICAgICAgICAgfCAgNDkgKysrKysKIHNyYy93MzJ0ZXJtLmggICAg ICAgICAgICAgfCAgIDMgKy0KIHNyYy94dGVybS5jICAgICAgICAgICAgICAgfCAxNDIgKysr KysrKysrKysrKysrCiBzcmMveHRlcm0uaCAgICAgICAgICAgICAgIHwgICAyICsKIDEyIGZp bGVzIGNoYW5nZWQsIDgwMiBpbnNlcnRpb25zKCspLCAxIGRlbGV0aW9uKC0pCiBjcmVhdGUg bW9kZSAxMDA2NDQgbGlzcC9sb3ctbGV2ZWwta2V5LmVsCgpkaWZmIC0tZ2l0IGEvZG9jL2xp c3ByZWYvY29tbWFuZHMudGV4aSBiL2RvYy9saXNwcmVmL2NvbW1hbmRzLnRleGkKaW5kZXgg N2NjMzJhN2ZkYjMuLjIzYzMzM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gKGNsLXRoaXJkIChjYXIgKGxhc3Qg bGxrLS1ldmVudC1oaXN0b3J5LWZvci10YXApKSkpCisgICAgICAgICAgdGltZW91dCkKKyAg ICAgICAocHJvZ24gKHNldHEgbGxrLS1ldmVudC1oaXN0b3J5LWZvci10YXAgbmlsKSB0KSkp CisKKyhkZWZ1biBsbGstLWdlbmVyYXRlLWV2ZW50IChrZXkgZXZlbnQtdHlwZSkKKyAgKHdo ZW4gKG51bWJlcnAga2V5KQorICAgIChsZXQgKChzeW0gKGNkciAoYXNzb2Mga2V5IGxsay1r ZXlzeW1zKSkpKQorICAgICAgKHdoZW4gc3ltCisgICAgICAgIChzZXRxIGtleSBzeW0pKSkp CisgIChwdXNoIChpbnRlcm4gKGZvcm1hdCAiJXMtJXMiIGV2ZW50LXR5cGUga2V5KSkKKyAg ICAgICAgICAgICAgICAgdW5yZWFkLWNvbW1hbmQtZXZlbnRzKSkKKworKGRlZnVuIGxsay0t Z2VuZXJhdGUtZXZlbnRzIChrZXkgaXMtcHJlc3MgYmluZGluZyB0aW1lc3RhbXApCisgIChp ZiBpcy1wcmVzcworICAgICAgKHdoZW4gKG1lbWJlciAncHJlc3MgYmluZGluZykKKyAgICAg ICAgKGxsay0tZ2VuZXJhdGUtZXZlbnQga2V5ICdwcmVzcy1rZXkpKQorICAgICh3aGVuICht ZW1iZXIgJ3JlbGVhc2UgYmluZGluZykKKyAgICAgIChsbGstLWdlbmVyYXRlLWV2ZW50IGtl eSAncmVsZWFzZS1rZXkpKSkKKworICAobGV0ICgoZG91YmxlIChtZW1iZXIgJ2RvdWJsZSBi aW5kaW5nKSkKKyAgICAgICAgKHRyaXBsZSAobWVtYmVyICd0cmlwbGUgYmluZGluZykpKQor ICAgIDs7IGEgbm9uLXRhcCBrZXkgY2xlYXJzIHRoZSBldmVudCBoaXN0b3J5LgorICAgIChp ZiAob3IgZG91YmxlIHRyaXBsZSkKKyAgICAgICAgKHByb2duCisgICAgICAgICAgOzsgQ2xl YXIgdGhlIGV2ZW50IGhpc3RvcnkgaWYgaXQgaGFzIGV2ZW50cyBmcm9tIGFub3RoZXIga2V5 LgorICAgICAgICAgICh1bmxlc3MgKGVxdWFsIChjYXIgKGNhciBsbGstLWV2ZW50LWhpc3Rv cnktZm9yLXRhcCkpIGtleSkKKyAgICAgICAgICAgIChzZXRxIGxsay0tZXZlbnQtaGlzdG9y eS1mb3ItdGFwIG5pbCkpCisgICAgICAgICAgKHB1c2ggKGxpc3Qga2V5IGlzLXByZXNzIHRp bWVzdGFtcCkgbGxrLS1ldmVudC1oaXN0b3J5LWZvci10YXApCisgICAgICAgICAgKGFuZCBk b3VibGUKKyAgICAgICAgICAgICAgIChsbGstLWRldGVjdC1uLXRhcCAyIGxsay10YXAtdGlt ZW91dCkKKyAgICAgICAgICAgICAgIChsbGstLWdlbmVyYXRlLWV2ZW50IGtleSAnZG91Ymxl LWtleSkpCisgICAgICAgICAgKGFuZCB0cmlwbGUKKyAgICAgICAgICAgICAgIChsbGstLWRl dGVjdC1uLXRhcCAzICgqIDIgbGxrLXRhcC10aW1lb3V0KSkKKyAgICAgICAgICAgICAgIChs bGstLWdlbmVyYXRlLWV2ZW50IGtleSAndHJpcGxlLWtleSkpKQorICAgICAgOzsgQSBub24t dGFwIGtleSBjbGVhcnMgdGhlIGV2ZW50IGhpc3RvcnkuCisgICAgICAoc2V0cSBsbGstLWV2 ZW50LWhpc3RvcnktZm9yLXRhcCBuaWwpKSkpCisKKyhkZWZ1biBsbGstaGFuZGxlICgpCisg IChpbnRlcmFjdGl2ZSkKKyAgKGxldCogKChrZXkgKGxvdy1sZXZlbC1rZXkta2V5IGxhc3Qt aW5wdXQtZXZlbnQpKQorICAgICAgICAgKG1vZGlmaWVyIChsb3ctbGV2ZWwta2V5LW1vZGlm aWVyIGxhc3QtaW5wdXQtZXZlbnQpKQorICAgICAgICAgKHRpbWVzdGFtcCAobG93LWxldmVs LWtleS10aW1lIGxhc3QtaW5wdXQtZXZlbnQpKQorICAgICAgICAgKGlzLXByZXNzIChsb3ct bGV2ZWwta2V5LWlzLWtleS1wcmVzcyBsYXN0LWlucHV0LWV2ZW50KSkKKyAgICAgICAgIChi aW5kaW5nIChhc3NvYyBrZXkgbGxrLWJpbmRpbmdzKSkKKyAgICAgICAgIChiaW5kaW5nLW1v ZGlmaWVyIChhc3NvYyBtb2RpZmllciBsbGstYmluZGluZ3MpKSkKKyAgICAoaWYgYmluZGlu ZworICAgICAgICAobGxrLS1nZW5lcmF0ZS1ldmVudHMga2V5IGlzLXByZXNzIGJpbmRpbmcg dGltZXN0YW1wKQorICAgICAgKHdoZW4gYmluZGluZy1tb2RpZmllcgorICAgICAgICAobGxr LS1nZW5lcmF0ZS1ldmVudHMgbW9kaWZpZXIgaXMtcHJlc3MgYmluZGluZy1tb2RpZmllciB0 aW1lc3RhbXApKSkpKQorCisoZGVmbWFjcm8gbGxrLS1kZWZpbmUteGsgKG5hbWUgeC1rZXlz eW0gdzMyLWtleXN5bSkKKyAgIkludGVybmFsIG1hY3JvIHRvIGRlZmluZSBrZXlzeW1zLiIK KyAgYChsZXQgKChrc3ltIChwY2FzZSAod2luZG93LXN5c3RlbSkKKyAgICAgICAgICAgICAg ICAgKChvciAncGd0ayAneCkgLHgta2V5c3ltKQorICAgICAgICAgICAgICAgICAoJ3czMiAs dzMyLWtleXN5bSkpKSkKKyAgICAgKGRlZmNvbnN0ICxuYW1lIGtzeW0gIkNvbnN0YW50IGZv ciBhIGtleXN5bSB2YWx1ZS4iKQorICAgICAocHVzaCAoY29ucyBrc3ltICcsbmFtZSkgbGxr LWtleXN5bXMpKSkKKworKGRlZnVuIGxsay0tZGVmaW5lLWtleXN5bXMgKCkKKyAgIkluaXRp YWxpemUgdGhlIGtleXN5bSBsaXN0LCBgbGxrLWtleXN5bXMnLiIKKyAgKHNldHEgbGxrLWtl eXN5bXMgbmlsKQorCisgIDs7IHR0eSBrZXlzCisgIChsbGstLWRlZmluZS14ayB4ay1iYWNr c3BhY2UgICAjeGZmMDggI3gwOC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WRlZmluZS14ayB4ay1kb3duICAgICAgICAjeGZm NTQgI3gyOCkgOzsgWEtfRG93biBWS19ET1dOCisgIChsbGstLWRlZmluZS14ayB4ay1wYWdl LXVwICAgICAjeGZmNTUgI3gyMSkgOzsgWEtfUGFnZV9VcCBWS19QUklPUgorICAobGxrLS1k ZWZpbmUteGsgeGstcGFnZS1kb3duICAgI3hmZjU2ICN4MjIpIDs7IFhLX1BhZ2VfRG93biBW S19ORVhUCisgIChsbGstLWRlZmluZS14ayB4ay1lbmQgICAgICAgICAjeGZmNTcgI3gyMykg OzsgWEtfRW5kIFZLX0VORAorICAobGxrLS1kZWZpbmUteGsgeGstYmVnaW4gICAgICAgI3hm ZjU4ICN4MjQpIDs7IFhLX0JlZ2luIFZLX0hPTUUKKworICA7OyBTcGVjaWFsIFdpbmRvd3Mg a2V5Ym9hcmQga2V5cworICAobGxrLS1kZWZpbmUteGsgeGstd2luLWwgICAgICAgI3hGRjVC ICN4NUIpIDs7IFhLX1dpbl9MIFZLX0xXSU4KKyAgKGxsay0tZGVmaW5lLXhrIHhrLXdpbi1y ICAgICAgICN4RkY1QyAjeDVDKSA7OyBYS19XaW5fUiBWS19SV0lOCisgIChsbGstLWRlZmlu ZS14ayB4ay1hcHAgICAgICAgICAjeEZGNUQgI3g1RCkgOzsgWEtfQXBwIFZLX0FQUFMKKwor ICA7OyBNaXNjIGZ1bmN0aW9ucworICAobGxrLS1kZWZpbmUteGsgeGstc2VsZWN0ICAgICAg I3hmZjYwICN4MjkpIDs7IFhLX1NlbGVjdCBWS19TRUxFQ1QKKyAgKGxsay0tZGVmaW5lLXhr IHhrLXByaW50ICAgICAgICN4ZmY2MSAjeDJBKSA7OyBYS19QcmludCBWS19QUklOVAorICAo bGxrLS1kZWZpbmUteGsgeGstaW5zZXJ0ICAgICAgI3hmZjY0ICN4MkQpIDs7IFhLX0luc2Vy dCBWS19JTlNFUlQKKyAgKGxsay0tZGVmaW5lLXhrIHhrLW51bS1sb2NrICAgICN4Zm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gKGxsay0tZGVmaW5lLXhrIHhrLWY4ICAgICAgICAgICN4ZmZj NSAjeDc3KSA7OyBYS19GOCBWS19GOAorICAobGxrLS1kZWZpbmUteGsgeGstZjkgICAgICAg ICAgI3hmZmM2ICN4NzgpIDs7IFhLX0Y5IFZLX0Y5CisgIChsbGstLWRlZmluZS14ayB4ay1m MTAgICAgICAgICAjeGZmYzcgI3g3OSkgOzsgWEtfRjEwIFZLX0YxMAorICAobGxrLS1kZWZp bmUteGsgeGstZjExICAgICAgICAgI3hmZmM4ICN4N0EpIDs7IFhLX0YxMSBWS19GMTEKKyAg KGxsay0tZGVmaW5lLXhrIHhrLWYxMiAgICAgICAgICN4ZmZjOSAjeDdCKSA7OyBYS19GMTIg VktfRjEyCisgIChsbGstLWRlZmluZS14ayB4ay1mMTMgICAgICAgICAjeGZmY2EgI3g3Qykg OzsgWEtfRjEzIFZLX0YxMworICAobGxrLS1kZWZpbmUteGsgeGstZjE0ICAgICAgICAgI3hm ZmNiICN4N0QpIDs7IFhLX0YxNCBWS19GMTQKKyAgKGxsay0tZGVmaW5lLXhrIHhrLWYxNSAg ICAgICAgICN4ZmZjYyAjeDdFKSA7OyBYS19GMTUgVktfRjE1CisgIChsbGstLWRlZmluZS14 ayB4ay1mMTYgICAgICAgICAjeGZmY2QgI3g3RikgOzsgWEtfRjE2IFZLX0YxNgorICAobGxr LS1kZWZpbmUteGsgeGstZjE3ICAgICAgICAgI3hmZmNlICN4ODApIDs7IFhLX0YxNyBWS19G MTcKKyAgKGxsay0tZGVmaW5lLXhrIHhrLWYxOCAgICAgICAgICN4ZmZjZiAjeDgxKSA7OyBY S19GMTggVktfRjE4CisgIChsbGstLWRlZmluZS14ayB4ay1mMTkgICAgICAgICAjeGZmZDAg I3g4MikgOzsgWEtfRjE5IFZLX0YxOQorICAobGxrLS1kZWZpbmUteGsgeGstZjIwICAgICAg ICAgI3hmZmQxICN4ODMpIDs7IFhLX0YyMCBWS19GMjAKKyAgKGxsay0tZGVmaW5l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gICAgI3gwMDMzICN4MzMpIDs7IFhL XzMKKyAgKGxsay0tZGVmaW5lLXhrIHhrLTQgICAgICAgICAgICN4MDAzNCAjeDM0KSA7OyBY S180CisgIChsbGstLWRlZmluZS14ayB4ay01ICAgICAgICAgICAjeDAwMzUgI3gzNSkgOzsg WEtfNQorICAobGxrLS1kZWZpbmUteGsgeGstNiAgICAgICAgICAgI3gwMDM2ICN4MzYpIDs7 IFhLXzYKKyAgKGxsay0tZGVmaW5lLXhrIHhrLTcgICAgICAgICAgICN4MDAzNyAjeDM3KSA7 OyBYS183CisgIChsbGstLWRlZmluZS14ayB4ay04ICAgICAgICAgICAjeDAwMzggI3gzOCkg OzsgWEtfOAorICAobGxrLS1kZWZpbmUteGsgeGstOSAgICAgICAgICAgI3gwMDM5ICN4Mzkp IDs7IFhLXzkKKyAgKGxsay0tZGVmaW5lLXhrIHhrLWEgICAgICAgICAgICN4MDA0MSAjeDQx KSA7OyBYS19BCisgIChsbGstLWRlZmluZS14ayB4ay1iICAgICAgICAgICAjeDAwNDIgI3g0 MikgOzsgWEtfQgorICAobGxrLS1kZWZpbmUteGsgeGstYyAgICAgICAgICAgI3gwMDQzICN4 NDMpIDs7IFhLX0MKKyAgKGxsay0tZGVmaW5lLXhrIHhrLWQgICAgICAgICAgICN4MDA0NCAj eDQ0KSA7OyBYS19ECisgIChsbGstLWRlZmluZS14ayB4ay1lICAgICAgICAgICAjeDAwNDUg I3g0NSkgOzsgWEtfRQorICAobGxrLS1kZWZpbmUteGsgeGstZiAgICAgICAgICAgI3gwMDQ2 ICN4NDYpIDs7IFhLX0YKKyAgKGxsay0tZGVmaW5lLXhrIHhrLWcgICAgICAgICAgICN4MDA0 NyAjeDQ3KSA7OyBYS19HCisgIChsbGstLWRlZmluZS14ayB4ay1oICAgICAgICAgICAjeDAw NDggI3g0OCkgOzsgWEtfSAorICAobGxrLS1kZWZpbmUteGsgeGstaSAgICAgICAgICAgI3gw MDQ5ICN4NDkpIDs7IFhLX0kKKyAgKGxsay0tZGVmaW5lLXhrIHhrLWogICAgICAgICAgICN4 MDA0QSAjeDRBKSA7OyBYS19KCisgIChsbGstLWRlZmluZS14ayB4ay1rICAgICAgICAgICAj eDAwNEIgI3g0QikgOzsgWEtfSworICAobGxrLS1kZWZpbmUteGsgeGstbCAgICAgICAgICAg I3gwMDRDICN4NEMpIDs7IFhLX0wKKyAgKGxsay0tZGVmaW5lLXhrIHhrLW0gICAgICAgICAg ICN4MDA0RCAjeDREKSA7OyBYS19NCisgIChsbGstLWRlZmluZS14ayB4ay1uICAgICAgICAg ICAjeDAwNEUgI3g0RSkgOzsgWEtfTgorICAobGxrLS1kZWZpbmUteGsgeGstbyAgICAgICAg ICAgI3gwMDRGICN4NEYpIDs7IFhLX08KKyAgKGxsay0tZGVmaW5lLXhrIHhrLXAgICAgICAg ICAgICN4MDA1MCAjeDUwKSA7OyBYS19QCisgIChsbGstLWRlZmluZS14ayB4ay1xICAgICAg ICAgICAjeDAwNTEgI3g1MSkgOzsgWEtfUQorICAobGxrLS1kZWZpbmUteGsgeGstciAgICAg ICAgICAgI3gwMDUyICN4NTIpIDs7IFhLX1IKKyAgKGxsay0tZGVmaW5lLXhrIHhrLXMgICAg ICAgICAgICN4MDA1MyAjeDUzKSA7OyBYS19TCisgIChsbGstLWRlZmluZS14ayB4ay10ICAg ICAgICAgICAjeDAwNTQgI3g1NCkgOzsgWEtfVAorICAobGxrLS1kZWZpbmUteGsgeGstdSAg ICAgICAgICAgI3gwMDU1ICN4NTUpIDs7IFhLX1UKKyAgKGxsay0tZGVmaW5lLXhrIHhrLXYg ICAgICAgICAgICN4MDA1NiAjeDU2KSA7OyBYS19WCisgIChsbGstLWRlZmluZS14ayB4ay13 ICAgICAgICAgICAjeDAwNTcgI3g1NykgOzsgWEtfVworICAobGxrLS1kZWZpbmUteGsgeGst eCAgICAgICAgICAgI3gwMDU4ICN4NTgpIDs7IFhLX1gKKyAgKGxsay0tZGVmaW5lLXhrIHhr LXkgICAgICAgICAgIC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YmVfc2VuZF9sb3dfbGV2ZWxfa2V5X2V2ZW50 IChzdHJ1Y3QgZnJhbWUgKmYsCisJCQkJICAgR2RrRXZlbnQgKnhldikKK3sKKyAgR2RrRXZl bnRLZXkgeGtleSA9IHhldi0+a2V5OworICBib29sIGlzX3ByZXNzOworICBMaXNwX09iamVj dCBrZXksIG1vZGlmaWVyOworICB1bmlvbiBidWZmZXJlZF9pbnB1dF9ldmVudCBpbmV2Owor CisgIGlmIChOSUxQIChWZW5hYmxlX2xvd19sZXZlbF9rZXlfZXZlbnRzKSkKKyAgICByZXR1 cm47CisKKyAgc3dpdGNoICh4ZXYtPnR5cGUpCisgICAgeworICAgIGNhc2UgR0RLX0tFWV9Q UkVTUzoKKyAgICAgIGlzX3ByZXNzID0gdHJ1ZTsKKyAgICAgIGJyZWFrOworICAgIGNhc2Ug R0RLX0tFWV9SRUxFQVNFOgorICAgICAgaXNfcHJlc3MgPSBmYWxzZTsKKyAgICAgIGJyZWFr OworICAgIGRlZmF1bHQ6CisgICAgICByZXR1cm47CisgICAgfQorCisgIG1vZGlmaWVyID0g eF9nZXRfbW9kaWZpZXJfZm9yX2tleWNvZGUgKEZSQU1FX09VVFBVVF9EQVRBIChmKS0+ZGlz cGxheV9pbmZvLAorCQkJCQkgeGV2LT5rZXkuaGFyZHdhcmVfa2V5Y29kZSk7CisKKyAgaW50 IGtleXN5bSA9IHhrZXkua2V5dmFsOworCisgIGlmIChrZXlzeW0gPj0gR0RLX0tFWV9hICYm IGtleXN5bSA8PSBHREtfS0VZX3opCisgICAga2V5c3ltIC09IEdES19LRVlfYSAtIEdES19L RVlfQTsKKworICBpZiAoIWtiZF9sb3dfbGV2ZWxfa2V5X2lzX2VuYWJsZWQgKGtleXN5bSwg bW9kaWZpZXIpKQorICAgIHJldHVybjsKKworICBrZXkgPSBtYWtlX2ZpeG51bSAoa2V5c3lt KTsKKworICBFVkVOVF9JTklUIChpbmV2LmllKTsKKyAgWFNFVEZSQU1FIChpbmV2LmllLmZ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VudCAoZXZlbnQpOwpAQCAtNzExNywxMiArNzExOCw0NyBAQCBtYWtlX2xpc3B5X2V2 ZW50IChzdHJ1Y3QgaW5wdXRfZXZlbnQgKmV2ZW50KQogICAgIGNhc2UgUFJFRURJVF9URVhU X0VWRU5UOgogICAgICAgcmV0dXJuIGxpc3QyIChRcHJlZWRpdF90ZXh0LCBldmVudC0+YXJn KTsKIAorICAgIGNhc2UgTE9XX0xFVkVMX0tFWV9FVkVOVDoKKyAgICAgIHJldHVybiBsaXN0 biAoNiwgUWxvd19sZXZlbF9rZXksCisJCSAgICBYQ0FSIChldmVudC0+YXJnKSwgLyogUHJl c3Mgb3IgcmVsZWFzZS4gICovCisJCSAgICBYQ0FSIChYQ0RSIChldmVudC0+YXJnKSksIC8q IFRoZSBrZXkgc3ltYm9sLiAgKi8KKwkJICAgIFhDQVIgKFhDRFIgKFhDRFIgKGV2ZW50LT5h cmcpKSksIC8qIFRoZSBtb2RpZmllci4gICovCisJCSAgICBtYWtlX2ZpeG51bSAoZXZlbnQt PnRpbWVzdGFtcCksCisJCSAgICBldmVudC0+ZnJhbWVfb3Jfd2luZG93KTsKKwogICAgICAg LyogVGhlICdraW5kJyBmaWVsZCBvZiB0aGUgZXZlbnQgaXMgc29tZXRoaW5nIHdlIGRvbid0 IHJlY29nbml6ZS4gICovCiAgICAgZGVmYXVsdDoKICAgICAgIGVtYWNzX2Fib3J0ICgpOwog ICAgIH0KIH0KIAorYm9vbAora2JkX2xvd19sZXZlbF9rZXlfaXNfZW5hYmxlZCAoaW50IGtl eXN5bSwgTGlzcF9PYmplY3QgbW9kaWZpZXIpCit7CisgIGlmIChWZW5hYmxlX2xvd19sZXZl bF9rZXlfZXZlbnRzID09IFF0KQorICAgIHJldHVybiB0cnVlOworCisgIGlmIChWZW5hYmxl X2xvd19sZXZlbF9rZXlfZXZlbnRzID09IFFuaWwpCisgICAgcmV0dXJuIGZhbHNlOworCisg IGlmIChGSVhOVU1QIChWZW5hYmxlX2xvd19sZXZ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llciA9IGV2 ZW50LT5rZXkuaXNfbW9kaWZpZXIgPyBRdCA6IFFuaWw7CisKKyAgaW50IGtleXN5bSA9IHhr ZXkua2V5dmFsOworCisgIGlmIChrZXlzeW0gPj0gR0RLX0tFWV9hICYmIGtleXN5bSA8PSBH REtfS0VZX3opCisgICAga2V5c3ltIC09IEdES19LRVlfYSAtIEdES19LRVlfQTsKKyAgaWYg KCFrYmRfbG93X2xldmVsX2tleV9pc19lbmFibGVkIChrZXlzeW0sIG1vZGlmaWVyKSkKKyAg ICByZXR1cm47CisKKyAgaWYgKCFmKQorICAgIGYgPSBwZ3RrX2FueV93aW5kb3dfdG9fZnJh bWUgKGV2ZW50LT5rZXkud2luZG93KTsKKyAgaWYgKCFmKQorICAgIHJldHVybjsKKworICBr ZXkgPSBtYWtlX2ZpeG51bSAoa2V5c3ltKTsKKworICBFVkVOVF9JTklUIChpbmV2LmllKTsK KyAgWFNFVEZSQU1FIChpbmV2LmllLmZyYW1lX29yX3dpbmRvdywgZik7CisgIGluZXYuaWUu a2luZCA9IExPV19MRVZFTF9LRVlfRVZFTlQ7CisgIGluZXYuaWUudGltZXN0YW1wID0gZXZl bnQtPmtleS50aW1lOworICBpbmV2LmllLmFyZyA9IGxpc3QzIChpc19wcmVzcyA/IFF0IDog UW5pbCwga2V5LCBtb2RpZmllcik7CisgIGV2cV9lbnF1ZXVlICgmaW5ldik7Cit9CisKIHN0 YXRpYyBnYm9vbGVhbgoga2V5X3ByZXNzX2V2ZW50IChHdGtXaWRnZXQgKndpZGdldCwgR2Rr RXZlbnQgKmV2ZW50LCBncG9pbnRlciAqdXNlcl9kYXRhKQogewpAQCAtNTIxMSw2ICs1MjYx LDkgQEAga2V5X3ByZXNzX2V2ZW50IChHdGtXaWRnZXQgKndpZGdldCwgR2RrRXZlbnQgKmV2 ZW50LCBncG9pbnRlciAqdXNlcl9kYXRhKQogICBzdHJ1Y3QgcGd0a19kaXNwbGF5X2luZm8g KmRweWluZm87CiAKICAgZiA9IHB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mlu ZSBTVE9SRV9LRVlTWU1fRk9SX0RFQlVHKGtleXN5bSkgKCh2b2lkKTApCiAKIHN0YXRpYyBz dHJ1Y3QgeF9kaXNwbGF5X2luZm8gKm5leHRfbm9vcF9kcHlpbmZvOwogCitMaXNwX09iamVj dAoreF9nZXRfbW9kaWZpZXJfZm9yX2tleWNvZGUgKHN0cnVjdCB4X2Rpc3BsYXlfaW5mbyAq ZHB5aW5mbywKKwkJCSAgICBpbnQga2V5Y29kZSkKK3sKKyNpZmRlZiBIQVZFX1hLQgorICBp ZiAoZHB5aW5mby0+eGtiX2Rlc2MpCisgICAgZm9yIChpbnQgbW9kID0gMDsgbW9kIDwgWGti TnVtTW9kaWZpZXJzOyBtb2QrKykKKyAgICAgIHsKKwlpbnQgbWFzayA9ICgxIDw8IG1vZCk7 CisJaWYgKGRweWluZm8tPnhrYl9kZXNjLT5tYXAtPm1vZG1hcFtrZXljb2RlXSAmIG1hc2sp CisJICB7CisJICAgIGlmIChtYXNrID09IFNoaWZ0TWFzaykKKwkgICAgICByZXR1cm4gUXNo aWZ0OworCSAgICBpZiAobWFzayA9PSBDb250cm9sTWFzaykKKwkgICAgICByZXR1cm4gUWN0 cmw7CisJICAgIGlmIChtYXNrID09IGRweWluZm8tPm1ldGFfbW9kX21hc2spCisJICAgICAg cmV0dXJuIFFtZXRhOworCSAgICBpZiAobWFzayA9PSBkcHlpbmZvLT5hbHRfbW9kX21hc2sp CisJICAgICAgcmV0dXJuIFFhbHQ7CisJICAgIGlmIChtYXNrID09IGRweWluZm8tPnN1cGVy X21vZF9tYXNrKQorCSAgICAgIHJldHVybiBRc3VwZXI7CisJICAgIGlmIChtYXNrID09IGRw eWluZm8tPmh5cGVyX21vZF9tYXNrKQorCSAgICAgIHJldHVybiBRaHlwZXI7CisJICB9Cisg ICAgICB9CisjZW5kaWYKKyAgWE1vZGlmaWVyS2V5bWFwICptYXAgPSBkcHlpbmZvLT5tb2Rt YXA7CisgIGlmIChtYXApCisgICAgZm9yIChpbnQgbW9kID0gMDsgbW9kIDwgODsgbW9kKysp CisgICAgICB7CisJaW50IG1hc2sgPSAoMSA8PCBtb2QpOworICAgICAgICBmb3IgKGludCBr ZXkgPSAwOyBrZXkgPCBtYXAtPm1heF9rZXlwZXJtb2Q7IGtleSsrKQorCSAgaWYgKG1hcC0+ bW9kaWZpZXJtYXBbbW9kICogbWFwLT5tYXhfa2V5cGVybW9kICsga2V5XSA9PSBrZXljb2Rl KQorCSAgICB7CisJICAgICAgaWYgKG1hc2sgPT0gU2hpZnRNYXNrKQorCQlyZXR1cm4gUXNo aWZ0OworCSAgICAgIGlmIChtYXNrID09IENvbnRyb2xNYXNrKQorCQlyZXR1cm4gUWN0cmw7 CisJICAgICAgaWYgKG1hc2sgPT0gZHB5aW5mby0+bWV0YV9tb2RfbWFzaykKKwkJcmV0dXJu IFFtZXRhOworCSAgICAgIGlmIChtYXNrID09IGRweWluZm8tPmFsdF9tb2RfbWFzaykKKwkJ cmV0dXJuIFFhbHQ7CisJICAgICAgaWYgKG1hc2sgPT0gZHB5aW5mby0+c3VwZXJfbW9kX21h c2spCisJCXJldHVybiBRc3VwZXI7CisJICAgICAgaWYgKG1hc2sgPT0gZHB5aW5mby0+aHlw ZXJfbW9kX21hc2spCisJCXJldHVybiBRaHlwZXI7CisJICAgIH0KKyAgICAgIH0KKyAgcmV0 dXJuIFFuaWw7Cit9CisKK3N0YXRpYyB2b2lkCit4X21heWJlX3NlbmRfbG93X2xldmVsX2tl eV9ldmVudCAoc3RydWN0IHhfZGlzcGxheV9pbmZvICpkcHlpbmZvLAorCQkJCSAgY29uc3Qg WEV2ZW50ICp4ZXYsIHN0cnVjdCBmcmFtZSAqZikKK3sKKyAgWEtleUV2ZW50IHhrZXk7Cisg IGJvb2wgaXNfcHJlc3M7CisgIEtleVN5bSBrZXlzeW07CisgIExpc3BfT2JqZWN0IGtleSwg bW9kaWZpZXI7CisgIHN0cnVjdCBpbnB1dF9ldmVudCBpZTsKKworICBpZiAoTklMUCAoVmVu YWJsZV9sb3dfbGV2ZWxfa2V5X2V2ZW50cykpCisgICAgcmV0dXJuOworCisgIHN3aXRjaCAo eGV2LT50eXBlKQorICAgIHsKKyAgICBjYXNlIEtleVByZXNzOgorICAgICAgaXNfcHJlc3Mg PSB0cnVlOworICAgICAgeGtleSA9IHhldi0+eGtleTsKKyAgICAgIGJyZWFrOworICAgIGNh c2UgS2V5UmVsZWFzZToKKyAgICAgIGlzX3ByZXNzID0gZmFsc2U7CisgICAgICB4a2V5ID0g eGV2LT54a2V5OworICAgICAgYnJlYWs7CisjaWZkZWYgSEFWRV9YSU5QVVQyCisgICAgY2Fz ZSBHZW5lcmljRXZlbnQ6CisgICAgICBYSURldmljZUV2ZW50ICp4aWV2ID0geGV2LT54Y29v a2llLmRhdGE7CisgICAgICBzd2l0Y2ggKHhldi0+eGdlbmVyaWMuZXZ0eXBlKQorCXsKKwlj YXNlIFhJX0tleVByZXNzOgorCSAgaXNfcHJlc3MgPSB0cnVlOworCSAgYnJlYWs7CisJY2Fz ZSBYSV9LZXlSZWxlYXNlOgorCSAgaXNfcHJlc3MgPSBmYWxzZTsKKwkgIGJyZWFrOworCWRl ZmF1bHQ6CisJICByZXR1cm47CisJfQorCisgICAgICB4a2V5LnNlcmlhbCA9IHhpZXYtPnNl cmlhbDsKKyAgICAgIHhrZXkuc2VuZF9ldmVudCA9IHhpZXYtPnNlbmRfZXZlbnQ7CisgICAg ICB4a2V5LmRpc3BsYXkgPSB4aWV2LT5kaXNwbGF5OworICAgICAgeGtleS53aW5kb3cgPSB4 aWV2LT5ldmVudDsKKyAgICAgIHhrZXkucm9vdCA9IHhpZXYtPnJvb3Q7CisgICAgICB4a2V5 LnN1YndpbmRvdyA9IHhpZXYtPmNoaWxkOworICAgICAgeGtleS50aW1lID0geGlldi0+dGlt ZTsKKyAgICAgIHhrZXkueCA9IHhpZXYtPmV2ZW50X3g7CisgICAgICB4a2V5LnkgPSB4aWV2 LT5ldmVudF95OworICAgICAgeGtleS54X3Jvb3QgPSB4aWV2LT5yb290X3g7CisgICAgICB4 a2V5Lnlfcm9vdCA9IHhpZXYtPnJvb3RfeTsKKyAgICAgIHhrZXkuc3RhdGUgPSB4aWV2LT5t b2RzLmVmZmVjdGl2ZTsKKyAgICAgIHhrZXkua2V5Y29kZSA9IHhpZXYtPmRldGFpbDsKKyAg ICAgIHhrZXkuc2FtZV9zY3JlZW4gPSAxOworICAgICAgYnJlYWs7CisjZW5kaWYKKyAgICBk ZWZhdWx0OgorICAgICAgcmV0dXJuOworICAgIH0KKworICBpZiAoIWYpCisgICAgZiA9IHhf YW55X3dpbmRvd190b19mcmFtZSAoZHB5aW5mbywgeGtleS53aW5kb3cpOworICBpZiAoIWYp CisgICAgcmV0dXJuOworCisgIFhMb29rdXBTdHJpbmcgKCZ4a2V5LCBOVUxMLCAwLCAma2V5 c3ltLCBOVUxMKTsKKworICBtb2RpZmllciA9IHhfZ2V0X21vZGlmaWVyX2Zvcl9rZXljb2Rl IChkcHlpbmZvLCB4a2V5LmtleWNvZGUpOworCisgIC8qIENvbnZlcnQgbG93ZXJjYXNlIGxh dGluIGxldHRlciB0byB1cHBlcmNhc2UuICAqLworICBpZiAoa2V5c3ltID49IFhLX2EgJiYg a2V5c3ltIDw9IFhLX3opCisgICAga2V5c3ltIC09IFhLX2EgLSBYS19BOworCisgIGlmICgh a2JkX2xvd19sZXZlbF9rZXlfaXNfZW5hYmxlZCAoa2V5c3ltLCBtb2RpZmllcikpCisgICAg cmV0dXJuOworCisgIGtleSA9IG1ha2VfZml4bnVtIChrZXlzeW0pOworCisgIEVWRU5UX0lO SVQgKGllKTsKKyAgWFNFVEZSQU1FIChpZS5mcmFtZV9vcl93aW5kb3csIGYpOworICBpZS5r aW5kID0gTE9XX0xFVkVMX0tFWV9FVkVOVDsKKyAgaWUudGltZXN0YW1wID0geGtleS50aW1l OworICBpZS5hcmcgPSBsaXN0MyAoaXNfcHJlc3MgPyBRdCA6IFFuaWwsIGtleSwgbW9kaWZp Z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aWVyKSk7CmRpZmYgLS1naXQgYS9zcmMveHRlcm0uaCBiL3NyYy94dGVybS5oCmluZGV4IDdj MmZhZGJmMDk0Li41NzM1ZTlkZmUxOSAxMDA2NDQKLS0tIGEvc3JjL3h0ZXJtLmgKKysrIGIv c3JjL3h0ZXJtLmgKQEAgLTE5MDYsNiArMTkwNiw4IEBAIHhfbXV0YWJsZV9jb2xvcm1hcCAo WFZpc3VhbEluZm8gKnZpc3VhbCkKIGV4dGVybiB2b2lkIHRlYXJfZG93bl94X2JhY2tfYnVm ZmVyIChzdHJ1Y3QgZnJhbWUgKmYpOwogZXh0ZXJuIHZvaWQgaW5pdGlhbF9zZXRfdXBfeF9i YWNrX2J1ZmZlciAoc3RydWN0IGZyYW1lICpmKTsKIAorZXh0ZXJuIExpc3BfT2JqZWN0IHhf Z2V0X21vZGlmaWVyX2Zvcl9rZXljb2RlIChzdHJ1Y3QgeF9kaXNwbGF5X2luZm8gKiwgaW50 KTsKKwogLyogRGVmaW5lZCBpbiB4Zm5zLmMuICAqLwogZXh0ZXJuIHZvaWQgeF9yZWFsX3Bv c2l0aW9ucyAoc3RydWN0IGZyYW1lICosIGludCAqLCBpbnQgKik7CiBleHRlcm4gdm9pZCB4 X2NoYW5nZV90YWJfYmFyX2hlaWdodCAoc3RydWN0IGZyYW1lICosIGludCk7Ci0tIAoyLjM1 LjEud2luZG93cy4yCgo= --------------eNHcmXNQvtsRN3BsZgn4RNX3--
bug-gnu-emacs@HIDDEN
:bug#74423
; Package emacs
.
Full text available.Stefan Kangas <stefankangas@HIDDEN>
to control <at> debbugs.gnu.org
.
Full text available.Received: (at 74423) by debbugs.gnu.org; 26 Dec 2024 14:54:26 +0000 From debbugs-submit-bounces <at> debbugs.gnu.org Thu Dec 26 09:54:26 2024 Received: from localhost ([127.0.0.1]:40598 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from <debbugs-submit-bounces <at> debbugs.gnu.org>) id 1tQpFp-0001kH-VP for submit <at> debbugs.gnu.org; Thu, 26 Dec 2024 09:54:26 -0500 Received: from mailscanner.iro.umontreal.ca ([132.204.25.50]:49404) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from <monnier@HIDDEN>) id 1tQpFn-0001k2-Cb for 74423 <at> debbugs.gnu.org; Thu, 26 Dec 2024 09:54:24 -0500 Received: from pmg1.iro.umontreal.ca (localhost.localdomain [127.0.0.1]) by pmg1.iro.umontreal.ca (Proxmox) with ESMTP id 72DCD10004A; Thu, 26 Dec 2024 09:54:17 -0500 (EST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=iro.umontreal.ca; s=mail; t=1735224856; bh=f3YkOMiYHpvpP3YxXVv+QTx8FOLB18iQp3Lf2cuOiik=; h=From:To:Cc:Subject:In-Reply-To:References:Date:From; b=VaXQUxb/Tl9D7hbMGmqMDPs0/308+TTPleGM3bGp5mwcdvY1mvVQ+wmoYP4+v+S83 nMF3OFfibmxH++Kq8cXFsfrZ/YkCj8syvrcNXyRqSmHurmhyDQAiGBf0kBpJsRGHcO 7brCkTg4Fuj8m2tyIeKsfuSO0xGKbmQqBYUbMTLi5/MXCozss1krzlGzmea6+BRfl8 UzQDvHIXJt96UHoyho6YM/DuTXO5hpr8epKNEQWGmhEP94rRJ5N8lneblj2akcl8Zq P7u1a0wjQCKevQku4dOatg1LUX5mcroDs1txjrqFJDVe7CS0k3yWHVlfQ+4WS+7DXA TcDBLUx3EsU/Q== Received: from mail01.iro.umontreal.ca (unknown [172.31.2.1]) by pmg1.iro.umontreal.ca (Proxmox) with ESMTP id BDE95100035; Thu, 26 Dec 2024 09:54:16 -0500 (EST) Received: from pastel (104-195-225-43.cpe.teksavvy.com [104.195.225.43]) by mail01.iro.umontreal.ca (Postfix) with ESMTPSA id 8A04B12056E; Thu, 26 Dec 2024 09:54:16 -0500 (EST) From: Stefan Monnier <monnier@HIDDEN> To: Cecilio Pardo <cpardo@HIDDEN> Subject: Re: bug#74423: Low level key events In-Reply-To: <b3e7839a-3fac-49e4-a507-fc34f6a71aa4@HIDDEN> (Cecilio Pardo's message of "Thu, 26 Dec 2024 11:16:11 +0100") Message-ID: <jwved1ucxgi.fsf-monnier+emacs@HIDDEN> References: <fb50ec11-7aec-481e-8a3a-ecdcf22eb7c0@HIDDEN> <31bdc55d-8c13-4de0-9cef-bd6cc4fb033f@HIDDEN> <s1r8qtzsvbe.fsf@HIDDEN> <d5c72818-e907-43f5-853a-89ec01264157@HIDDEN> <jwv4j43jisn.fsf-monnier+emacs@HIDDEN> <705fabb8-1ea0-4894-8c32-05097ab822c9@HIDDEN> <jwvplmqtuh1.fsf-monnier+emacs@HIDDEN> <b0b914a0-b454-41b0-aa3d-d9e243c210f5@HIDDEN> <868qsvz07i.fsf@HIDDEN> <162dada7-ad54-4ca5-8f11-d55dd6dccb3c@HIDDEN> <867c8ezny3.fsf@HIDDEN> <c0bd3bff-4546-4169-9e5d-ba60ef059b6c@HIDDEN> <86bjxev7ng.fsf@HIDDEN> <343e2854-a16e-4718-894a-470b733ae91f@HIDDEN> <jwvseqgbd1y.fsf-monnier+emacs@HIDDEN> <b3e7839a-3fac-49e4-a507-fc34f6a71aa4@HIDDEN> Date: Thu, 26 Dec 2024 09:54:15 -0500 User-Agent: Gnus/5.13 (Gnus v5.13) MIME-Version: 1.0 Content-Type: text/plain X-SPAM-INFO: Spam detection results: 0 ALL_TRUSTED -1 Passed through trusted hosts only via SMTP AWL -0.652 Adjusted score from AWL reputation of From: address BAYES_00 -1.9 Bayes spam probability is 0 to 1% DKIM_SIGNED 0.1 Message has a DKIM or DK signature, not necessarily valid DKIM_VALID -0.1 Message has at least one valid DKIM or DK signature DKIM_VALID_AU -0.1 Message has a valid DKIM or DK signature from author's domain DKIM_VALID_EF -0.1 Message has a valid DKIM or DK signature from envelope-from domain X-SPAM-LEVEL: X-Spam-Score: -2.3 (--) X-Debbugs-Envelope-To: 74423 Cc: luangruo@HIDDEN, 74423 <at> debbugs.gnu.org, Eli Zaretskii <eliz@HIDDEN> X-BeenThere: debbugs-submit <at> debbugs.gnu.org X-Mailman-Version: 2.1.18 Precedence: list List-Id: <debbugs-submit.debbugs.gnu.org> List-Unsubscribe: <https://debbugs.gnu.org/cgi-bin/mailman/options/debbugs-submit>, <mailto:debbugs-submit-request <at> debbugs.gnu.org?subject=unsubscribe> List-Archive: <https://debbugs.gnu.org/cgi-bin/mailman/private/debbugs-submit/> List-Post: <mailto:debbugs-submit <at> debbugs.gnu.org> List-Help: <mailto:debbugs-submit-request <at> debbugs.gnu.org?subject=help> List-Subscribe: <https://debbugs.gnu.org/cgi-bin/mailman/listinfo/debbugs-submit>, <mailto:debbugs-submit-request <at> debbugs.gnu.org?subject=subscribe> Errors-To: debbugs-submit-bounces <at> debbugs.gnu.org Sender: "Debbugs-submit" <debbugs-submit-bounces <at> debbugs.gnu.org> X-Spam-Score: -3.3 (---) > How can we make sure that only the user configures this, and external > packages do not? I can't think of a good reason why we would actively want to prevent external packages from touching this. At least not via technical means. As a matter of fact, I think we'd welcome packages dedicated to configuring this: your code is currently layered as a C part which provides the low-level events and an ELisp part which constructs useful semantics out of it, but that ELisp part can be thought of as a separate package, so we already have an example of useful "external" package configuring this. Another package could provide an alternative way to use those low-level events. As for "normal" packages (say major modes), I suspect they will tend to naturally refrain from touching it because it's not available everywhere. We may document guidelines about those low-level events alongside our conventions for key bindings, OTOH. Stefan
bug-gnu-emacs@HIDDEN
:bug#74423
; Package emacs
.
Full text available.Received: (at 74423) by debbugs.gnu.org; 26 Dec 2024 10:16:18 +0000 From debbugs-submit-bounces <at> debbugs.gnu.org Thu Dec 26 05:16:18 2024 Received: from localhost ([127.0.0.1]:40162 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from <debbugs-submit-bounces <at> debbugs.gnu.org>) id 1tQkug-0005oU-AF for submit <at> debbugs.gnu.org; Thu, 26 Dec 2024 05:16:18 -0500 Received: from mail.imayhem.com ([82.223.54.191]:38293 helo=zealous-pike.82-223-54-191.plesk.page) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from <cpardo@HIDDEN>) id 1tQkuf-0005oG-Gl for 74423 <at> debbugs.gnu.org; Thu, 26 Dec 2024 05:16:17 -0500 Received: from [10.0.12.81] (66.red-2-136-43.staticip.rima-tde.net [2.136.43.66]) by zealous-pike.82-223-54-191.plesk.page (Postfix) with ESMTPSA id A9A278011A; Thu, 26 Dec 2024 10:16:11 +0000 (UTC) Authentication-Results: zealous-pike.82-223-54-191.plesk.page; spf=pass (sender IP is 2.136.43.66) smtp.mailfrom=cpardo@HIDDEN smtp.helo=[10.0.12.81] Received-SPF: pass (zealous-pike.82-223-54-191.plesk.page: connection is authenticated) Message-ID: <b3e7839a-3fac-49e4-a507-fc34f6a71aa4@HIDDEN> Date: Thu, 26 Dec 2024 11:16:11 +0100 MIME-Version: 1.0 User-Agent: Mozilla Thunderbird Subject: Re: bug#74423: Low level key events To: Stefan Monnier <monnier@HIDDEN> References: <fb50ec11-7aec-481e-8a3a-ecdcf22eb7c0@HIDDEN> <31bdc55d-8c13-4de0-9cef-bd6cc4fb033f@HIDDEN> <s1r8qtzsvbe.fsf@HIDDEN> <d5c72818-e907-43f5-853a-89ec01264157@HIDDEN> <jwv4j43jisn.fsf-monnier+emacs@HIDDEN> <705fabb8-1ea0-4894-8c32-05097ab822c9@HIDDEN> <jwvplmqtuh1.fsf-monnier+emacs@HIDDEN> <b0b914a0-b454-41b0-aa3d-d9e243c210f5@HIDDEN> <868qsvz07i.fsf@HIDDEN> <162dada7-ad54-4ca5-8f11-d55dd6dccb3c@HIDDEN> <867c8ezny3.fsf@HIDDEN> <c0bd3bff-4546-4169-9e5d-ba60ef059b6c@HIDDEN> <86bjxev7ng.fsf@HIDDEN> <343e2854-a16e-4718-894a-470b733ae91f@HIDDEN> <jwvseqgbd1y.fsf-monnier+emacs@HIDDEN> Content-Language: es-ES From: Cecilio Pardo <cpardo@HIDDEN> In-Reply-To: <jwvseqgbd1y.fsf-monnier+emacs@HIDDEN> Content-Type: text/plain; charset=UTF-8; format=flowed Content-Transfer-Encoding: 7bit X-Spam-Score: 0.0 (/) X-Debbugs-Envelope-To: 74423 Cc: luangruo@HIDDEN, 74423 <at> debbugs.gnu.org, Eli Zaretskii <eliz@HIDDEN> X-BeenThere: debbugs-submit <at> debbugs.gnu.org X-Mailman-Version: 2.1.18 Precedence: list List-Id: <debbugs-submit.debbugs.gnu.org> List-Unsubscribe: <https://debbugs.gnu.org/cgi-bin/mailman/options/debbugs-submit>, <mailto:debbugs-submit-request <at> debbugs.gnu.org?subject=unsubscribe> List-Archive: <https://debbugs.gnu.org/cgi-bin/mailman/private/debbugs-submit/> List-Post: <mailto:debbugs-submit <at> debbugs.gnu.org> List-Help: <mailto:debbugs-submit-request <at> debbugs.gnu.org?subject=help> List-Subscribe: <https://debbugs.gnu.org/cgi-bin/mailman/listinfo/debbugs-submit>, <mailto:debbugs-submit-request <at> debbugs.gnu.org?subject=subscribe> Errors-To: debbugs-submit-bounces <at> debbugs.gnu.org Sender: "Debbugs-submit" <debbugs-submit-bounces <at> debbugs.gnu.org> X-Spam-Score: -1.0 (-) On 22/12/2024 5:31, Stefan Monnier wrote: > I'm not expert in the C level part of that code, so I provide > feedback below only for the Lisp-facing part. Thanks a lot for the review. I'm working on it. > Maybe instead of focusing on running a command, `llk-handle` and > `llk-bind` should concentrate on generating "normal" events that are > then looked up in the normal keymaps. > > So the user would use them only to specify which events should be > recognized and which should be ignored. Then the user can use the > standard keymaps to declare what to do in response to `double-xk-shift-l`. > WDYT? Yes, I think that's better. I did it the other way to keep it as separate as possible from normal events, as some people thought this was a bad idea. How can we make sure that only the user configures this, and external packages do not?
bug-gnu-emacs@HIDDEN
:bug#74423
; Package emacs
.
Full text available.Received: (at 74423) by debbugs.gnu.org; 22 Dec 2024 04:31:48 +0000 From debbugs-submit-bounces <at> debbugs.gnu.org Sat Dec 21 23:31:48 2024 Received: from localhost ([127.0.0.1]:48660 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from <debbugs-submit-bounces <at> debbugs.gnu.org>) id 1tPDd3-0003j8-ML for submit <at> debbugs.gnu.org; Sat, 21 Dec 2024 23:31:48 -0500 Received: from mailscanner.iro.umontreal.ca ([132.204.25.50]:48365) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from <monnier@HIDDEN>) id 1tPDd0-0003it-Qk for 74423 <at> debbugs.gnu.org; Sat, 21 Dec 2024 23:31:44 -0500 Received: from pmg1.iro.umontreal.ca (localhost.localdomain [127.0.0.1]) by pmg1.iro.umontreal.ca (Proxmox) with ESMTP id 27FB3100055; Sat, 21 Dec 2024 23:31:36 -0500 (EST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=iro.umontreal.ca; s=mail; t=1734841894; bh=gp6XnOjpAkHphxn+M78n5QISoexG8Zqg7VSEyZ0J2PQ=; h=From:To:Cc:Subject:In-Reply-To:References:Date:From; b=DbkgGzQyi5+CgsxgRGx7YAFDrf0GKVRu99yitthzFtG8JlDTjTT1gBAXDF7uAL0Sj A2A+QxboPubykdxE+VmEV0XWYyTdke29iDN8josc1THJRR0BatT+xE+meiEWwpS2Tj 0TV+vD1xYO3UlGMrwl2wWeYuRNDJlIy7Bsc60XwMhkb1o8hzT9WoBAap2vkeKwq9qL NX08h/t/HodX4UQeQZfaKSJ5eyjoP2DHAP2OBugCqqC/fAeOup1rPkvqcJzYdFXZac WX6bi8ouLD0+OG1dS2t12QHMQno2FHzOgq85Ge5O1ErMQQdGXKcisbqgycPq648IGZ wGKZU1rSxSwZg== Received: from mail01.iro.umontreal.ca (unknown [172.31.2.1]) by pmg1.iro.umontreal.ca (Proxmox) with ESMTP id A3E9F100043; Sat, 21 Dec 2024 23:31:34 -0500 (EST) Received: from asado (unknown [199.119.74.1]) by mail01.iro.umontreal.ca (Postfix) with ESMTPSA id 8C32712014F; Sat, 21 Dec 2024 23:31:33 -0500 (EST) From: Stefan Monnier <monnier@HIDDEN> To: Cecilio Pardo <cpardo@HIDDEN> Subject: Re: bug#74423: Low level key events In-Reply-To: <343e2854-a16e-4718-894a-470b733ae91f@HIDDEN> (Cecilio Pardo's message of "Wed, 18 Dec 2024 11:59:16 +0100") Message-ID: <jwvseqgbd1y.fsf-monnier+emacs@HIDDEN> References: <fb50ec11-7aec-481e-8a3a-ecdcf22eb7c0@HIDDEN> <31bdc55d-8c13-4de0-9cef-bd6cc4fb033f@HIDDEN> <s1r8qtzsvbe.fsf@HIDDEN> <d5c72818-e907-43f5-853a-89ec01264157@HIDDEN> <jwv4j43jisn.fsf-monnier+emacs@HIDDEN> <705fabb8-1ea0-4894-8c32-05097ab822c9@HIDDEN> <jwvplmqtuh1.fsf-monnier+emacs@HIDDEN> <b0b914a0-b454-41b0-aa3d-d9e243c210f5@HIDDEN> <868qsvz07i.fsf@HIDDEN> <162dada7-ad54-4ca5-8f11-d55dd6dccb3c@HIDDEN> <867c8ezny3.fsf@HIDDEN> <c0bd3bff-4546-4169-9e5d-ba60ef059b6c@HIDDEN> <86bjxev7ng.fsf@HIDDEN> <343e2854-a16e-4718-894a-470b733ae91f@HIDDEN> Date: Sat, 21 Dec 2024 23:31:31 -0500 User-Agent: Gnus/5.13 (Gnus v5.13) MIME-Version: 1.0 Content-Type: text/plain X-SPAM-INFO: Spam detection results: 0 ALL_TRUSTED -1 Passed through trusted hosts only via SMTP BAYES_00 -1.9 Bayes spam probability is 0 to 1% DKIM_SIGNED 0.1 Message has a DKIM or DK signature, not necessarily valid DKIM_VALID -0.1 Message has at least one valid DKIM or DK signature DKIM_VALID_AU -0.1 Message has a valid DKIM or DK signature from author's domain DKIM_VALID_EF -0.1 Message has a valid DKIM or DK signature from envelope-from domain X-SPAM-LEVEL: X-Spam-Score: -2.3 (--) X-Debbugs-Envelope-To: 74423 Cc: luangruo@HIDDEN, 74423 <at> debbugs.gnu.org, Eli Zaretskii <eliz@HIDDEN> X-BeenThere: debbugs-submit <at> debbugs.gnu.org X-Mailman-Version: 2.1.18 Precedence: list List-Id: <debbugs-submit.debbugs.gnu.org> List-Unsubscribe: <https://debbugs.gnu.org/cgi-bin/mailman/options/debbugs-submit>, <mailto:debbugs-submit-request <at> debbugs.gnu.org?subject=unsubscribe> List-Archive: <https://debbugs.gnu.org/cgi-bin/mailman/private/debbugs-submit/> List-Post: <mailto:debbugs-submit <at> debbugs.gnu.org> List-Help: <mailto:debbugs-submit-request <at> debbugs.gnu.org?subject=help> List-Subscribe: <https://debbugs.gnu.org/cgi-bin/mailman/listinfo/debbugs-submit>, <mailto:debbugs-submit-request <at> debbugs.gnu.org?subject=subscribe> Errors-To: debbugs-submit-bounces <at> debbugs.gnu.org Sender: "Debbugs-submit" <debbugs-submit-bounces <at> debbugs.gnu.org> X-Spam-Score: -3.3 (---) Hi, this is shaping up quite nicely, AFAICT. I'm not expert in the C level part of that code, so I provide feedback below only for the Lisp-facing part. Stefan > --- a/doc/lispref/commands.texi > +++ b/doc/lispref/commands.texi > @@ -2658,6 +2658,38 @@ Misc Events > respectively. They are usually interpreted as being relative to the > size of the object beneath the gesture: image, window, etc. > > +@cindex @code{low-level-key} event > +@item (low-level-key @var{is-key-press} @var{key} @var{modifier} @var{time} @var{frame}) > +This event is sent on the physical press or release of keys, only on GUI > +systems, currently X, MS-Windows and PGTK, and only if the variable > +@code{enable-low-level-key-events} has a non-@code{nil} value. See its > +documentation for the values it can take, that allow to filter which > +keys should generate this kind of event. Rather than saying it's sent "only on GUI systems", I'd say sent "only on systems where it is supported": I wouldn't be surprised to hear that some terminal emulators offer ways to support it. > +@var{is-key-press} is @code{t} for a key press, @code{nil} for a key release. > +@var{time} is the event's time in milliseconds, @var{frame} is the > +frame receiving it. Please clarify the origin of the event's time (or if possible make it a valid/normal Emacs time object). > +@var{key}, an integer, identifies the key pressed or released. This > +number is platform dependent, but there are variables for most keys that > +can be used in place of the numbers to identify them. For example, the > +variable @code{xk-backspace} identifies the @key{backspace} key. I get the impression that those variables/constants may be replaced/complemented in the future with alternatives, such as functions that convert the key number to a symbol, or functions that test whether the key number is within some set of keys described as symbols, ... So the documentation of the meaning of those key numbers via associated variables/constants should probably be placed elsewhere. > +These variables are initialized by calling the function @code{llk-init}. > +This function also binds a handler to this event, which allows to detect [ "Allow" is transitive, so you need to say "allows us" or "allows users" or something like (or use some other formulation altogether). ] > --- /dev/null > +++ b/lisp/low-level-key.el > @@ -0,0 +1,342 @@ > +;;; -*- lexical-binding: t -*- Please follow our convention for the first line of ELisp files, and then include our usual copyright+license blurb. > +;; The physical-key event is like this: > +;; (low-level-key IS-KEY-PRESS KEY MODIFIER TIME FRAME) > +;; IS-KEY-PRESS is t if the key has been pressed, nil if it has been released. > +;; KEY is the keysym number. > +;; MODIFIER is the modifier associated with this key. It is nil if the key is > +;; not a modifier. It can be one of the following symbols: shift, control, meta, > +;; super, hyper, alt. It can also be t if the key is a modifier but it can't be > +;; identified, as in the PGTK backend. > +;; TIME is the timestamp in milliseconds of the event. > +;; FRAME is the frame where the event happened. I suggest you replace that text with a `cl-defstruct` (where you can include the same information but in a way that's available via `cl-describe-type`). And then you can stop using `cl-third` and use proper accessors instead. > +(defvar llk-bindings nil > + "List of bindings for low level key events (press/release/tap). > + > +Use the `llk-bind' function to add bindings. See its documentation for > +a description of the binding information.") AFAICT this is a list of elements of the form `(tab KEY FUNCTION)`. Why not drop the `tap` and make it a "normal" keymap? > +(defvar llk-tap-count 2 > + "Number or key press/releases to consider a tap.") Shouldn't `llk-tap-count` be specified individually for each binding? > +(defvar llk-tap-timeout 1000 > + "Time (ms) between consecutive key presses/releases to consider a tap.") Default it to `mouse-double-click-time` (and maybe double it for triple taps)? > +(defvar llk-tap-keys > + '(xk-shift-l xk-shift-r xk-control-l xk-control-r meta) > + "Keys that can generate taps.") This seems redundant with `llk-bindings`. > +(defvar llk-describe-next-press nil > + "Internal variable to mark that next key press should be described.") Use a "--" in the var's name for internal variables. > +(defmacro define-xk (name x-keysym w32-keysym) > + "Internal macro to define keysyms." Same thing for macros. > + `(let ((ksym (pcase (window-system) > + ('pgtk ,x-keysym) > + ('x ,x-keysym) > + ('w32 ,w32-keysym)))) You can combine the first two branches into: ((or 'pgtk 'x) ,x-keysym) > + ;; tty keys > + (define-xk xk-backspace #xff08 #x08) ;; XK_BackSpace VK_BACK > + (define-xk xk-tab #xff09 #x09) ;; XK_Tab VK_TAB > + (define-xk xk-clear #xff0b #x0C) ;; XK_Clear VK_CLEAR > + (define-xk xk-return #xff0d #x0D) ;; XK_Return VK_RETURN > + (define-xk xk-pause #xff13 #x13) ;; XK_Pause VK_PAUSE > + (define-xk xk-scroll-lock #xff14 #x91) ;; XK_Scroll_Lock VK_SCROLL > + (define-xk xk-escape #xff1B #x1B) ;; XK_Escape VK_ESCAPE > + (define-xk xk-delete #xffff #x2E) ;; XK_Delete VK_DELETE > + > + ;; Cursor control and motion > + (define-xk xk-home #xff50 #x24) ;; XK_Home VK_HOME > + (define-xk xk-left #xff51 #x25) ;; XK_Left VK_LEFT > + (define-xk xk-up #xff52 #x26) ;; XK_Up VK_UP > + (define-xk xk-right #xff53 #x27) ;; XK_Right VK_RIGHT > + (define-xk xk-down #xff54 #x28) ;; XK_Down VK_DOWN > + (define-xk xk-page-up #xff55 #x21) ;; XK_Page_Up VK_PRIOR > + (define-xk xk-page-down #xff56 #x22) ;; XK_Page_Down VK_NEXT > + (define-xk xk-end #xff57 #x23) ;; XK_End VK_END > + (define-xk xk-begin #xff58 #x24) ;; XK_Begin VK_HOME > + > + ;; Special Windows keyboard keys > + (define-xk xk-win-l #xFF5B #x5B) ;; XK_Win_L VK_LWIN > + (define-xk xk-win-r #xFF5C #x5C) ;; XK_Win_R VK_RWIN > + (define-xk xk-app #xFF5D #x5D) ;; XK_App VK_APPS > + > + ;; Misc functions > + (define-xk xk-select #xff60 #x29) ;; XK_Select VK_SELECT > + (define-xk xk-print #xff61 #x2A) ;; XK_Print VK_PRINT > + (define-xk xk-insert #xff64 #x2D) ;; XK_Insert VK_INSERT > + (define-xk xk-num-lock #xff7f #x90) ;; XK_Num_Lock VK_NUMLOCK > + > + ;; Keypad > + ;; TODO: Check values for MS-Windows > + (define-xk xk-kp-enter #xff8d nil) ;; XK_KP_Enter ??? > + (define-xk xk-kp-multiply #xffaa nil) ;; XK_KP_Multiply ??? > + (define-xk xk-kp-add #xffab nil) ;; XK_KP_Add ??? > + (define-xk xk-kp-subtract #xffad nil) ;; XK_KP_Subtract ??? > + (define-xk xk-kp-decimal #xffae nil) ;; XK_KP_Decimal ??? > + (define-xk xk-kp-divide #xffaf nil) ;; XK_KP_Divide ??? > + (define-xk xk-kp-0 #xffb0 #x60) ;; XK_KP_0 VK_NUMPAD0 > + (define-xk xk-kp-1 #xffb1 #x61) ;; XK_KP_1 VK_NUMPAD1 > + (define-xk xk-kp-2 #xffb2 #x62) ;; XK_KP_2 VK_NUMPAD2 > + (define-xk xk-kp-3 #xffb3 #x63) ;; XK_KP_3 VK_NUMPAD3 > + (define-xk xk-kp-4 #xffb4 #x64) ;; XK_KP_4 VK_NUMPAD4 > + (define-xk xk-kp-5 #xffb5 #x65) ;; XK_KP_5 VK_NUMPAD5 > + (define-xk xk-kp-6 #xffb6 #x66) ;; XK_KP_6 VK_NUMPAD6 > + (define-xk xk-kp-7 #xffb7 #x67) ;; XK_KP_7 VK_NUMPAD7 > + (define-xk xk-kp-8 #xffb8 #x68) ;; XK_KP_8 VK_NUMPAD8 > + (define-xk xk-kp-9 #xffb9 #x69) ;; XK_KP_9 VK_NUMPAD9 > + > + ;; Function keys > + (define-xk xk-f1 #xffbe #x70) ;; XK_F1 VK_F1 > + (define-xk xk-f2 #xffbf #x71) ;; XK_F2 VK_F2 > + (define-xk xk-f3 #xffc0 #x72) ;; XK_F3 VK_F3 > + (define-xk xk-f4 #xffc1 #x73) ;; XK_F4 VK_F4 > + (define-xk xk-f5 #xffc2 #x74) ;; XK_F5 VK_F5 > + (define-xk xk-f6 #xffc3 #x75) ;; XK_F6 VK_F6 > + (define-xk xk-f7 #xffc4 #x76) ;; XK_F7 VK_F7 > + (define-xk xk-f8 #xffc5 #x77) ;; XK_F8 VK_F8 > + (define-xk xk-f9 #xffc6 #x78) ;; XK_F9 VK_F9 > + (define-xk xk-f10 #xffc7 #x79) ;; XK_F10 VK_F10 > + (define-xk xk-f11 #xffc8 #x7A) ;; XK_F11 VK_F11 > + (define-xk xk-f12 #xffc9 #x7B) ;; XK_F12 VK_F12 > + (define-xk xk-f13 #xffca #x7C) ;; XK_F13 VK_F13 > + (define-xk xk-f14 #xffcb #x7D) ;; XK_F14 VK_F14 > + (define-xk xk-f15 #xffcc #x7E) ;; XK_F15 VK_F15 > + (define-xk xk-f16 #xffcd #x7F) ;; XK_F16 VK_F16 > + (define-xk xk-f17 #xffce #x80) ;; XK_F17 VK_F17 > + (define-xk xk-f18 #xffcf #x81) ;; XK_F18 VK_F18 > + (define-xk xk-f19 #xffd0 #x82) ;; XK_F19 VK_F19 > + (define-xk xk-f20 #xffd1 #x83) ;; XK_F20 VK_F20 > + (define-xk xk-f21 #xffd2 #x84) ;; XK_F21 VK_F21 > + (define-xk xk-f22 #xffd3 #x85) ;; XK_F22 VK_F22 > + (define-xk xk-f23 #xffd4 #x86) ;; XK_F23 VK_F23 > + (define-xk xk-f24 #xffd5 #x87) ;; XK_F24 VK_F24 > + > + ;; Modifier keys > + (define-xk xk-shift-l #xffe1 #xA0) ;; XK_Shift_L VK_LSHIFT > + (define-xk xk-shift-r #xffe2 #xA1) ;; XK_Shift_R VK_RSHIFT > + (define-xk xk-control-l #xffe3 #xA2) ;; XK_Control_L VK_LCONTROL > + (define-xk xk-control-r #xffe4 #xA3) ;; XK_Control_R VK_RCONTROL > + (define-xk xk-caps-lock #xffe5 #x14) ;; XK_Caps_Lock VK_CAPITAL > + (define-xk xk-metal-l #xffe7 nil) ;; XK_Meta_L > + (define-xk xk-metal-t #xffee nil) ;; XK_Meta_R > + (define-xk xk-alt-l #xffe9 #xA4) ;; XK_Alt_L VK_LMENU > + (define-xk xk-alt-r #xffea #xA5) ;; XK_Alt_R VK_RMENU > + (define-xk xk-super-l #xffeb nil) ;; XK_Super_L > + (define-xk xk-super-r #xffec nil) ;; XK_Super_R > + (define-xk xk-hyper-l #xffed nil) ;; XK_Hyper_L > + (define-xk xk-hyper-r #xffee nil) ;; XK_Hyper_R > + > + ;; Latin 1 > + ;; For numbers and letters, MS-Windows does not define constant names. > + ;; X11 defines distinct keysyms for lowercase and uppercase > + ;; letters. We use only the uppercase ones. Events with lowercase > + ;; letters are converted to uppercase. > + (define-xk xk-space #x0020 #x20) ;; XK_space VK_SPACE > + (define-xk xk-0 #x0030 #x30) ;; XK_0 > + (define-xk xk-1 #x0031 #x31) ;; XK_1 > + (define-xk xk-2 #x0032 #x32) ;; XK_2 > + (define-xk xk-3 #x0033 #x33) ;; XK_3 > + (define-xk xk-4 #x0034 #x34) ;; XK_4 > + (define-xk xk-5 #x0035 #x35) ;; XK_5 > + (define-xk xk-6 #x0036 #x36) ;; XK_6 > + (define-xk xk-7 #x0037 #x37) ;; XK_7 > + (define-xk xk-8 #x0038 #x38) ;; XK_8 > + (define-xk xk-9 #x0039 #x39) ;; XK_9 > + (define-xk xk-a #x0041 #x41) ;; XK_A > + (define-xk xk-b #x0042 #x42) ;; XK_B > + (define-xk xk-c #x0043 #x43) ;; XK_C > + (define-xk xk-d #x0044 #x44) ;; XK_D > + (define-xk xk-e #x0045 #x45) ;; XK_E > + (define-xk xk-f #x0046 #x46) ;; XK_F > + (define-xk xk-g #x0047 #x47) ;; XK_G > + (define-xk xk-h #x0048 #x48) ;; XK_H > + (define-xk xk-i #x0049 #x49) ;; XK_I > + (define-xk xk-j #x004A #x4A) ;; XK_J > + (define-xk xk-k #x004B #x4B) ;; XK_K > + (define-xk xk-l #x004C #x4C) ;; XK_L > + (define-xk xk-m #x004D #x4D) ;; XK_M > + (define-xk xk-n #x004E #x4E) ;; XK_N > + (define-xk xk-o #x004F #x4F) ;; XK_O > + (define-xk xk-p #x0050 #x50) ;; XK_P > + (define-xk xk-q #x0051 #x51) ;; XK_Q > + (define-xk xk-r #x0052 #x52) ;; XK_R > + (define-xk xk-s #x0053 #x53) ;; XK_S > + (define-xk xk-t #x0054 #x54) ;; XK_T > + (define-xk xk-u #x0055 #x55) ;; XK_U > + (define-xk xk-v #x0056 #x56) ;; XK_V > + (define-xk xk-w #x0057 #x57) ;; XK_W > + (define-xk xk-x #x0058 #x58) ;; XK_X > + (define-xk xk-y #x0059 #x59) ;; XK_Y > + (define-xk xk-z #x005A #x5A));; XK_Z These tables should be somehow auto-generated, IMO. > +(defun llk-init () > + "Initialize low level key events. > + > +Fills the `llk-keysyms' list, and binds the `low-level-key' event > +to the `llk-handle' function. Resets the `llk-bindings' list. > +Besides calling this function, you need to set `enable-low-level-key-events' > +to a non-nil value." Does the user need to know about those things it does? Would there be any harm to call it automatically when the package is loaded, or the first time `llk-bind` is called? IOW, please try and make it unnecessary for the caller to know and call this function (and then make it internal with a "--" in its name). > + (interactive) Why interactive? > +(defsubst event-is-key-press (event) > + "Return the value of the IS-KEY-PRESS field of the EVENT, a low level key event." > + (declare (side-effect-free t)) > + (if (consp event) (nth 1 event))) > + > +(defsubst event-keysym (event) > + "Return the value of the KEY field of the EVENT, a low level key event." > + (declare (side-effect-free t)) > + (if (consp event) (nth 2 event))) > + > +(defsubst event-modifier (event) > + "Return the value of the MODIFIER field of the EVENT, a low level key event." > + (declare (side-effect-free t)) > + (if (consp event) (nth 3 event))) > + > +(defsubst event-time (event) > + "Return the value of the TIME field of the EVENT, a low level key event." > + (declare (side-effect-free t)) > + (if (consp event) (nth 4 event))) I think the `cl-defstruct` will define those functions for you (with a different name, but I think it's OK because these aren't applicable to other events anyway). > +;; We store the last events (key/modifier is-press timestamp) here to > +;; test for multitap. > +(defvar llk-events nil > + "Internal variable for detecting taps.") "--" > +;; If positive, return key (xk-shift-l, etc) else return nil. > +(defun llk-detect-n-tap (n timeout) > + "Internal function to detect n-tap keys." "--" I think it should not take `n` as an argument and instead it should automatically discover how many times the key has been tapped and generate events of the form `double-xk-shift-l`, `triple-xk-shift-l`, `tap-xk-shift-l`. > + (cl-every 'eq Please #' to quote function names. Here and elsewhere. > +(defun describe-low-level-key () > + "Wait for key press and describe the low level key event it generates." > + (interactive) > + (setq llk-describe-next-press t)) Can we get rid of `llk-describe-next-press` and instead temporarily (define-key special-event-map [low-level-key] 'llk--describe) or something like that? > +(defun llk-handle () > + "Internal function to handle low level key events." > + (interactive) > + (if (and (event-is-key-press last-input-event) > + llk-describe-next-press) > + (llk-show-event-description) > + (let ((tap-key (llk-detect-n-tap > + llk-tap-count > + llk-tap-timeout))) > + (when tap-key > + (let ((func (cl-third > + (seq-find > + (lambda (b) > + (and (eq (cl-first b) 'tap) > + (eq (cl-second b) tap-key))) > + llk-bindings)))) > + (cond > + ((commandp func) (call-interactively func)) Maybe instead of focusing on running a command, `llk-handle` and `llk-bind` should concentrate on generating "normal" events that are then looked up in the normal keymaps. So the user would use them only to specify which events should be recognized and which should be ignored. Then the user can use the standard keymaps to declare what to do in response to `double-xk-shift-l`. WDYT? > + ((functionp func) (funcall func)))))))) Why? Stefan
bug-gnu-emacs@HIDDEN
:bug#74423
; Package emacs
.
Full text available.Received: (at 74423) by debbugs.gnu.org; 18 Dec 2024 10:59:38 +0000 From debbugs-submit-bounces <at> debbugs.gnu.org Wed Dec 18 05:59:38 2024 Received: from localhost ([127.0.0.1]:33618 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from <debbugs-submit-bounces <at> debbugs.gnu.org>) id 1tNrm5-0004Re-LH for submit <at> debbugs.gnu.org; Wed, 18 Dec 2024 05:59:38 -0500 Received: from mail.imayhem.com ([82.223.54.191]:48129 helo=zealous-pike.82-223-54-191.plesk.page) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from <cpardo@HIDDEN>) id 1tNrlz-0004RA-56 for 74423 <at> debbugs.gnu.org; Wed, 18 Dec 2024 05:59:27 -0500 Received: from [192.168.68.103] (111.red-88-21-7.staticip.rima-tde.net [88.21.7.111]) by zealous-pike.82-223-54-191.plesk.page (Postfix) with ESMTPSA id 528BA80135; Wed, 18 Dec 2024 10:59:17 +0000 (UTC) Authentication-Results: zealous-pike.82-223-54-191.plesk.page; spf=pass (sender IP is 88.21.7.111) smtp.mailfrom=cpardo@HIDDEN smtp.helo=[192.168.68.103] Received-SPF: pass (zealous-pike.82-223-54-191.plesk.page: connection is authenticated) Content-Type: multipart/mixed; boundary="------------Ho0Ev8LvMd4RGoiUOUnpb8B7" Message-ID: <343e2854-a16e-4718-894a-470b733ae91f@HIDDEN> Date: Wed, 18 Dec 2024 11:59:16 +0100 MIME-Version: 1.0 User-Agent: Mozilla Thunderbird Subject: Re: bug#74423: Low level key events To: Eli Zaretskii <eliz@HIDDEN> References: <fb50ec11-7aec-481e-8a3a-ecdcf22eb7c0@HIDDEN> <31bdc55d-8c13-4de0-9cef-bd6cc4fb033f@HIDDEN> <s1r8qtzsvbe.fsf@HIDDEN> <d5c72818-e907-43f5-853a-89ec01264157@HIDDEN> <jwv4j43jisn.fsf-monnier+emacs@HIDDEN> <705fabb8-1ea0-4894-8c32-05097ab822c9@HIDDEN> <jwvplmqtuh1.fsf-monnier+emacs@HIDDEN> <b0b914a0-b454-41b0-aa3d-d9e243c210f5@HIDDEN> <868qsvz07i.fsf@HIDDEN> <162dada7-ad54-4ca5-8f11-d55dd6dccb3c@HIDDEN> <867c8ezny3.fsf@HIDDEN> <c0bd3bff-4546-4169-9e5d-ba60ef059b6c@HIDDEN> <86bjxev7ng.fsf@HIDDEN> Content-Language: es-ES From: Cecilio Pardo <cpardo@HIDDEN> In-Reply-To: <86bjxev7ng.fsf@HIDDEN> X-Spam-Score: 0.0 (/) X-Debbugs-Envelope-To: 74423 Cc: luangruo@HIDDEN, 74423 <at> debbugs.gnu.org, monnier@HIDDEN X-BeenThere: debbugs-submit <at> debbugs.gnu.org X-Mailman-Version: 2.1.18 Precedence: list List-Id: <debbugs-submit.debbugs.gnu.org> List-Unsubscribe: <https://debbugs.gnu.org/cgi-bin/mailman/options/debbugs-submit>, <mailto:debbugs-submit-request <at> debbugs.gnu.org?subject=unsubscribe> List-Archive: <https://debbugs.gnu.org/cgi-bin/mailman/private/debbugs-submit/> List-Post: <mailto:debbugs-submit <at> debbugs.gnu.org> List-Help: <mailto:debbugs-submit-request <at> debbugs.gnu.org?subject=help> List-Subscribe: <https://debbugs.gnu.org/cgi-bin/mailman/listinfo/debbugs-submit>, <mailto:debbugs-submit-request <at> debbugs.gnu.org?subject=subscribe> Errors-To: debbugs-submit-bounces <at> debbugs.gnu.org Sender: "Debbugs-submit" <debbugs-submit-bounces <at> debbugs.gnu.org> X-Spam-Score: -1.0 (-) This is a multi-part message in MIME format. --------------Ho0Ev8LvMd4RGoiUOUnpb8B7 Content-Type: text/plain; charset=UTF-8; format=flowed Content-Transfer-Encoding: 7bit On 14/12/2024 12:14, Eli Zaretskii wrote: > Aren't these events sent only if enable-low-level-key-events is > non-nil? If so, this should be documented, and the variable itself > should be documented. Fixed this and the style mistakes. --------------Ho0Ev8LvMd4RGoiUOUnpb8B7 Content-Type: text/plain; charset=UTF-8; name="0001-Send-events-for-key-presses-and-key-releases.patch" Content-Disposition: attachment; filename="0001-Send-events-for-key-presses-and-key-releases.patch" Content-Transfer-Encoding: base64 RnJvbSA5ZTdkMjE5NTQzYjJkZDQyNDcyNzEyNTkxMGVjNzExZjFhYTZjYjU1IE1vbiBTZXAg MTcgMDA6MDA6MDAgMjAwMQpGcm9tOiBDZWNpbGlvIFBhcmRvIDxjcGFyZG9AaW1heWhlbS5j b20+CkRhdGU6IE1vbiwgMiBEZWMgMjAyNCAxNzozMDo0MiArMDEwMApTdWJqZWN0OiBbUEFU Q0hdIFNlbmQgZXZlbnRzIGZvciBrZXkgcHJlc3NlcyBhbmQga2V5IHJlbGVhc2VzLgoKRGV0 ZWN0IGRvdWJsZS90cmlwbGUgdGFwcy4KCiogZG9jL2xpc3ByZWYvY29tbWFuZHMudGV4aTog QWRkZWQgaW5mb3JtYXRpb24gYWJvdXQgb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vdXQgYW4gZXZl bnQuCihsbGstaGFuZGxlKTogSGFuZGxlciBmb3Iga2V5IGV2ZW50cy4KLS0tCiBkb2MvbGlz cHJlZi9jb21tYW5kcy50ZXhpIHwgIDMyICsrKysKIGxpc3AvbG93LWxldmVsLWtleS5lbCAg ICAgfCAzNDIgKysrKysrKysrKysrKysrKysrKysrKysrKysrKysrKysrKysrKysKIHNyYy9n dGt1dGlsLmMgICAgICAgICAgICAgfCAgODEgKysrKysrKysrCiBzcmMva2V5Ym9hcmQuYyAg ICAgICAgICAgIHwgIDY1ICsrKysrKysrCiBzcmMva2V5Ym9hcmQuaCAgICAgICAgICAgIHwg ICAxICsKIHNyYy9wZ3RrdGVybS5jICAgICAgICAgICAgfCAgNTUgKysrKysrCiBzcmMvdGVy bWhvb2tzLmggICAgICAgICAgIHwgICAxICsKIHNyYy93MzJmbnMuYyAgICAgICAgICAgICAg fCAgMTEgKysKIHNyYy93MzJ0ZXJtLmMgICAgICAgICAgICAgfCAgNDkgKysrKysrCiBzcmMv dzMydGVybS5oICAgICAgICAgICAgIHwgICAzICstCiBzcmMveHRlcm0uYyAgICAgICAgICAg ICAgIHwgMTQyICsrKysrKysrKysrKysrKysKIHNyYy94dGVybS5oICAgICAgICAgICAgICAg fCAgIDIgKwogMTIgZmlsZXMgY2hhbmdlZCwgNzgzIGluc2VydGlvbnMoKyksIDEgZGVsZXRp b24oLSkKIGNyZWF0ZSBtb2RlIDEwMDY0NCBsaXNwL2xvdy1sZXZlbC1rZXkuZWwKCmRpZmYg LS1naXQgYS9kb2MvbGlzcHJlZi9jb21tYW5kcy50ZXhpIGIvZG9jL2xpc3ByZWYvY29tbWFu ZHMudGV4aQppbmRleCBkZjgyNjZhNzE1Ny4uODhkZDZkNGJhYTAgMTAwNjQ0Ci0tLSBhL2Rv Yy9saXNwcmVmL2NvbW1hbmRzLnRleGkKKysrIGIvZG9jL2xpc3ByZWYvY29tbWFuZHMudGV4 aQpAQCAtMjY1OCw2ICsyNjU4LDM4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HJlc3MgbmlsCisgICJJbnRlcm5hbCB2YXJpYWJs ZSB0byBtYXJrIHRoYXQgbmV4dCBrZXkgcHJlc3Mgc2hvdWxkIGJlIGRlc2NyaWJlZC4iKQor CisoZGVmbWFjcm8gZGVmaW5lLXhrIChuYW1lIHgta2V5c3ltIHczMi1rZXlzeW0pCisgICJJ bnRlcm5hbCBtYWNybyB0byBkZWZpbmUga2V5c3ltcy4iCisgIGAobGV0ICgoa3N5bSAocGNh c2UgKHdpbmRvdy1zeXN0ZW0pCisgICAgICAgICAgICAgICAgICgncGd0ayAseC1rZXlzeW0p CisgICAgICAgICAgICAgICAgICgneCAseC1rZXlzeW0pCisgICAgICAgICAgICAgICAgICgn dzMyICx3MzIta2V5c3ltKSkpKQorICAgICAoZGVmY29uc3QgLG5hbWUga3N5bSAiQ29uc3Rh bnQgZm9yIGEga2V5c3ltIHZhbHVlLiIpCisgICAgIChwdXNoIChjb25zIGtzeW0gJyxuYW1l KSBsbGsta2V5c3ltcykpKQorCisoZGVmdW4gbGxrLWRlZmluZS1rZXlzeW1zICgpCisgICJJ bml0aWFsaXplIHRoZSBrZXlzeW0gbGlzdCwgYGxsay1rZXlzeW1zJy4KKworQ2FsbGVkIGZy b20gYGxsay1pbml0Jy4iCisgIChzZXRxIGxsay1rZXlzeW1zIG5pbCkKKworICA7OyB0dHkg a2V5cworICAoZGVmaW5lLXhrIHhrLWJhY2tzcGFjZSAgICN4ZmYwOCAjeDA4KSA7OyBYS19C YWNrU3BhY2UgVktfQkFDSworICAoZGVmaW5lLXhrIHhrLXRhYiAgICAgICAgICN4ZmYwOSAj eDA5KSA7OyBYS19UYWIgVktfVEFCCisgIChkZWZpbmUteGsgeGstY2xlYXIgICAgICAgI3hm ZjBiICN4MEMpIDs7IFhLX0NsZWFyIFZLX0NMRUFSCisgIChkZWZpbmUteGsgeGstcmV0dXJu ICAgICAgI3hmZjBkICN4MEQpIDs7IFhLX1JldHVybiBWS19SRVRVUk4KKyAgKGRlZmluZS14 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gWEtfRjEgVktf RjEKKyAgKGRlZmluZS14ayB4ay1mMiAgICAgICAgICAjeGZmYmYgI3g3MSkgOzsgWEtfRjIg VktfRjIKKyAgKGRlZmluZS14ayB4ay1mMyAgICAgICAgICAjeGZmYzAgI3g3MikgOzsgWEtf RjMgVktfRjMKKyAgKGRlZmluZS14ayB4ay1mNCAgICAgICAgICAjeGZmYzEgI3g3MykgOzsg WEtfRjQgVktfRjQKKyAgKGRlZmluZS14ayB4ay1mNSAgICAgICAgICAjeGZmYzIgI3g3NCkg OzsgWEtfRjUgVktfRjUKKyAgKGRlZmluZS14ayB4ay1mNiAgICAgICAgICAjeGZmYzMgI3g3 NSkgOzsgWEtfRjYgVktfRjYKKyAgKGRlZmluZS14ayB4ay1mNyAgICAgICAgICAjeGZmYzQg I3g3NikgOzsgWEtfRjcgVktfRjcKKyAgKGRlZmluZS14ayB4ay1mOCAgICAgICAgICAjeGZm YzUgI3g3NykgOzsgWEtfRjggVktfRjgKKyAgKGRlZmluZS14ayB4ay1mOSAgICAgICAgICAj eGZmYzYgI3g3OCkgOzsgWEtfRjkgVktfRjkKKyAgKGRlZmluZS14ayB4ay1mMTAgICAgICAg ICAjeGZmYzcgI3g3OSkgOzsgWEtfRjEwIFZLX0YxMAorICAoZGVmaW5lLXhrIHhrLWYxMSAg ICAgICAgICN4ZmZjOCAjeDdBKSA7OyBYS19GMTEgVktfRjExCisgIChkZWZpbmUteGsgeGst ZjEyICAgICAgICAgI3hmZmM5ICN4N0IpIDs7IFhLX0YxMiBWS19GMTIKKyAgKGRlZmluZS14 ayB4ay1mMTMgICAgICAgICAjeGZmY2EgI3g3QykgOzsgWEtfRjEzIFZLX0YxMworICAoZGVm aW5lLXhrIHhrLWYxNCAgICAgICAgICN4ZmZjYiAjeDdEKSA7OyBYS19GMTQgVktfRjE0Cisg IChkZWZpbmUteGsgeGstZjE1ICAgICAgICAgI3hmZmNjICN4N0UpIDs7IFhLX0YxNSBWS19G MTUKKyAgKGRlZmluZS14ay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c3BhY2UgVktf U1BBQ0UKKyAgKGRlZmluZS14ayB4ay0wICAgICAgICAgICAjeDAwMzAgI3gzMCkgOzsgWEtf MAorICAoZGVmaW5lLXhrIHhrLTEgICAgICAgICAgICN4MDAzMSAjeDMxKSA7OyBYS18xCisg IChkZWZpbmUteGsgeGstMiAgICAgICAgICAgI3gwMDMyICN4MzIpIDs7IFhLXzIKKyAgKGRl ZmluZS14ayB4ay0zICAgICAgICAgICAjeDAwMzMgI3gzMykgOzsgWEtfMworICAoZGVmaW5l LXhrIHhrLTQgICAgICAgICAgICN4MDAzNCAjeDM0KSA7OyBYS180CisgIChkZWZpbmUteGsg eGstNSAgICAgICAgICAgI3gwMDM1ICN4MzUpIDs7IFhLXzUKKyAgKGRlZmluZS14ayB4ay02 ICAgICAgICAgICAjeDAwMzYgI3gzNikgOzsgWEtfNgorICAoZGVmaW5lLXhrIHhrLTcgICAg ICAgICAgICN4MDAzNyAjeDM3KSA7OyBYS183CisgIChkZWZpbmUteGsgeGstOCAgICAgICAg ICAgI3gwMDM4ICN4MzgpIDs7IFhLXzgKKyAgKGRlZmluZS14ayB4ay05ICAgICAgICAgICAj eDAwMzkgI3gzOSkgOzsgWEtfOQorICAoZGVmaW5lLXhrIHhrLWEgICAgICAgICAgICN4MDA0 MSAjeDQxKSA7OyBYS19BCisgIChkZWZpbmUteGsgeGstYiAgICAgICAgICAgI3gwMDQyICN4 NDIpIDs7IFhLX0IKKyAgKGRlZmluZS14ayB4ay1jICAgICAgICAgICAjeDAwNDMgI3g0Mykg OzsgWEtfQworICAoZGVmaW5lLXhrIHhrLWQgICAgICAgICAgICN4MDA0NCAjeDQ0KSA7OyBY S19ECisgIChkZWZpbmUteGsgeGstZSAgICAgICAgICAgI3gwMDQ1ICN4NDUpIDs7IFhLX0UK KyAgKGRlZmluZS14ayB4ay1mICAgICAgICAgICAjeDAwNDYgI3g0NikgOzsgWEtfRgorICAo ZGVmaW5lLXhrIHhrLWcgICAgICAgICAgICN4MDA0NyAjeDQ3KSA7OyBYS19HCisgIChkZWZp bmUteGsgeGstaCAgICAgICAgICAgI3gwMDQ4ICN4NDgpIDs7IFhLX0gKKyAgKGRlZmluZS14 ayB4ay1pICAgICAgICAgICAjeDAwNDkgI3g0OSkgOzsgWEtfSQorICAoZGVmaW5lLXhrIHhr LWogICAgICAgICAgICN4MDA0QSAjeDRBKSA7OyBYS19KCisgIChkZWZpbmUteGsgeGstayAg ICAgICAgICAgI3gwMDRCICN4NEIpIDs7IFhLX0sKKyAgKGRlZmluZS14ayB4ay1sICAgICAg ICAgICAjeDAwNEMgI3g0QykgOzsgWEtfTAorICAoZGVmaW5lLXhrIHhrLW0gICAgICAgICAg ICN4MDA0RCAjeDREKSA7OyBYS19NCisgIChkZWZpbmUteGsgeGstbiAgICAgICAgICAgI3gw MDRFICN4NEUpIDs7IFhLX04KKyAgKGRlZmluZS14ayB4ay1vICAgICAgICAgICAjeDAwNEYg I3g0RikgOzsgWEtfTworICAoZGVmaW5lLXhrIHhrLXAgICAgICAgICAgICN4MDA1MCAjeDUw KSA7OyBYS19QCisgIChkZWZpbmUteGsgeGstcSAgICAgICAgICAgI3gwMDUxICN4NTEpIDs7 IFhLX1EKKyAgKGRlZmluZS14ayB4ay1yICAgICAgICAgICAjeDAwNTIgI3g1MikgOzsgWEtf UgorICAoZGVmaW5lLXhrIHhrLXMgICAgICAgICAgICN4MDA1MyAjeDUzKSA7OyBYS19TCisg IChkZWZpbmUteGsgeGstdCAgICAgICAgICAgI3gwMDU0ICN4NTQpIDs7IFhLX1QKKyAgKGRl ZmluZS14ayB4ay11ICAgICAgICAgICAjeDAwNTUgI3g1NSkgOzsgWEtfVQorICAoZGVmaW5l LXhrIHhrLXYgICAgICAgICAgICN4MDA1NiAjeDU2KSA7OyBYS19WCisgIChkZWZpbmUteGsg eGstdyAgICAgICAgICAgI3gwMDU3ICN4NTcpIDs7IFhLX1cKKyAgKGRlZmluZS14ayB4ay14 ICAgICAgICAgICAjeDAwNTggI3g1OCkgO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iCisgIChsZXQg KGtleQorICAgICAgICAoaXMtcHJlc3MgKGV2ZW50LWlzLWtleS1wcmVzcyBsYXN0LWlucHV0 LWV2ZW50KSkKKyAgICAgICAgOzsgY29udmVydCBudW1iZXIgdG8ga2V5c3ltIHN5bWJvbAor ICAgICAgICAoa2V5c3ltIChjZHIgKGFzc29jIChldmVudC1rZXlzeW0gbGFzdC1pbnB1dC1l dmVudCkgbGxrLWtleXN5bXMpKSkKKyAgICAgICAgKHRpbWVzdGFtcCAoZXZlbnQtdGltZSBs YXN0LWlucHV0LWV2ZW50KSkKKyAgICAgICAgKG1vZGlmaWVyIChldmVudC1tb2RpZmllciBs YXN0LWlucHV0LWV2ZW50KSkpCisKKyAgICA7OyBpZiBlaHRlIGlzIG5vIHN5bWJvbCBmb3Ig dGhpcyBrZXksIHVzZSBpdHMga2V5c3ltIG51bWJlcgorICAgICh1bmxlc3Mga2V5c3ltIChz ZXRxIGtleXN5bSAoZXZlbnQta2V5c3ltIGxhc3QtaW5wdXQtZXZlbnQpKSkKKworICAgIDs7 IGxvb2sgaW4gbGxrLXRhcC1rZXlzIGZvciB0aGUga2V5LCB0aGVuIHRoZSBtb2RpZmllcgor ICAgIChpZiAobWVtYmVyIGtleXN5bSBsbGstdGFwLWtleXMpCisgICAgICAgIChzZXRxIGtl eSBrZXlzeW0pCisgICAgICAoaWYgKG1lbWJlciBtb2RpZmllciBsbGstdGFwLWtleXMpCisg ICAgICAgICAgKHNldHEga2V5IG1vZGlmaWVyKSkpCisKKyAgICAoaWYgKG5vdCBrZXkpCisg ICAgICAgIDs7IEtleSBub3QgaW4gdGFwIGxpc3QsIGNsZWFyIGhpc3RvcnkKKyAgICAgICAg KHNldHEgbGxrLWV2ZW50cyBuaWwpCisgICAgICA7OyBDbGVhciBpdCBhbHNvIGlmIHRoZSBm aXJzdCBlbGVtZW50IGlzIGZyb20gYSBkaWZmZXJlbnQga2V5CisgICAgICAoYW5kIGxsay1l dmVudHMKKyAgICAgICAgICAgKG5vdCAoZXF1YWwgKGNhciAoY2FyIGxsay1ldmVudHMpKSBr ZXkpKQorICAgICAgICAgICAoc2V0cSBsbGstZXZlbnRzIG5pbCkpCisgICAgICAocHVzaCAo bGlzdCBrZXkgaXMtcHJlc3MgdGltZXN0YW1wKSBsbGstZXZlbnRzKQorICAgICAgOzsgT25s eSBjYXJlIGFib3V0IGxhc3QgMnhOIGV2ZW50cworICAgICAgKG50YWtlICgqIDIgbikgbGxr LWV2ZW50cykKKyAgICAgIDs7IElmIHdlIGhhdmU6CisgICAgICA7OyAtIEV4YWN0bHkgMiAq IG4gZXZlbnRzLgorICAgICAgOzsgLSBkb3duLCB1cCwgZG93biwgdXAsIC4uLgorICAgICAg OzsgLSBub3QgdHdvIG11Y2ggdGltZSBiZXR3ZWVuIGZpcnN0IGFuZCBsYXN0CisgICAgICAo YW5kIChlcSAoKiAyIG4pIChsZW5ndGggbGxrLWV2ZW50cykpCisgICAgICAgICAgIChjbC1l dmVyeSAnZXEKKyAgICAgICAgICAgICAgICAgICAgIChudGFrZSAoKiAyIG4pCisgICAgICAg ICAgICAgICAgICAgICAgICAgICAgKGxpc3QgbmlsIHQgbmlsIHQgbmlsIHQgbmlsIHQKKyAg ICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICBuaWwgdCBuaWwgdCBuaWwgdCBuaWwg dCkpCisgICAgICAgICAgICAgICAgICAgICAobWFwY2FyICdjbC1zZWNvbmQgbGxrLWV2ZW50 cykpCisgICAgICAgICAgICg8ICgtIChjbC10aGlyZCAoY2wtZmlyc3QgbGxrLWV2ZW50cykp CisgICAgICAgICAgICAgICAgIChjbC10aGlyZCAoY2FyIChsYXN0IGxsay1ldmVudHMpKSkp CisgICAgICAgICAgICAgIHRpbWVvdXQpCisgICAgICAgICAgIChwcm9nbgorICAgICAgICAg ICAgIChzZXRxIGxsay1ldmVudHMgbmlsKQorICAgICAgICAgICAgIGtleSkpKSkpCisKKyhk ZWZ1biBkZXNjcmliZS1sb3ctbGV2ZWwta2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kpKQorICAgICAgICAo aW5zZXJ0ICJUaGlzIGtleSBkb2VzIG5vdCBjb3JyZXNwb25kIHRvIGEgbW9kaWZpZXIuXG5c biIpKQorICAgICAgKGluc2VydCAiU2VlIHRoZSB2YWx1ZSBvZiB0aGUgYGxsay1rZXlzeW1z JyB2YXJpYWJsZSBmb3IgYSBsaXN0IG9mIGtub3duIGtleXMuXG4iKSkpKQorCisoZGVmdW4g bGxrLWhhbmRsZSAoKQorICAiSW50ZXJuYWwgZnVuY3Rpb24gdG8gaGFuZGxlIGxvdyBsZXZl bCBrZXkgZXZlbnRzLiIKKyAgKGludGVyYWN0aXZlKQorICAoaWYgKGFuZCAoZXZlbnQtaXMt a2V5LXByZXNzIGxhc3QtaW5wdXQtZXZlbnQpCisgICAgICAgICAgIGxsay1kZXNjcmliZS1u ZXh0LXByZXNzKQorICAgICAgKGxsay1zaG93LWV2ZW50LWRlc2NyaXB0aW9uKQorICAgIChs ZXQgKCh0YXAta2V5IChsbGstZGV0ZWN0LW4tdGFwCisgICAgICAgICAgICAgICAgICAgIGxs ay10YXAtY291bnQKKyAgICAgICAgICAgICAgICAgICAgbGxrLXRhcC10aW1lb3V0KSkpCisg ICAgICAod2hlbiB0YXAta2V5CisgICAgICAgIChsZXQgKChmdW5jIChjbC10aGlyZAorICAg ICAgICAgICAgICAgICAgICAgKHNlcS1maW5kCisgICAgICAgICAgICAgICAgICAgICAgKGxh bWJkYSAoYikKKyAgICAgICAgICAgICAgICAgICAgICAgIChhbmQgKGVxIChjbC1maXJzdCBi KSAndGFwKQorICAgICAgICAgICAgICAgICAgICAgICAgICAgICAoZXEgKGNsLXNlY29uZCBi KSB0YXAta2V5KSkpCisgICAgICAgICAgICAgICAgICAgICAgbGxrLWJpbmRpbmdzKSkpKQor ICAgICAgICAgIChjb25kCisgICAgICAgICAgICgoY29tbWFuZHAgZnVuYykgKGNhbGwtaW50 ZXJhY3RpdmVseSBmdW5jKSkKKyAgICAgICAgICAgKChmdW5jdGlvbnAgZ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9sb3dfbGV2ZWxfa2V5 X2V2ZW50IChzdHJ1Y3QgZnJhbWUgKmYsIEdka0V2ZW50ICpldmVudCkKK3sKKyAgR2RrRXZl bnRLZXkgeGtleSA9IGV2ZW50LT5rZXk7CisgIGJvb2wgaXNfcHJlc3M7CisgIExpc3BfT2Jq ZWN0IGtleSwgbW9kaWZpZXI7CisgIHVuaW9uIGJ1ZmZlcmVkX2lucHV0X2V2ZW50IGluZXY7 CisKKyAgaWYgKE5JTFAgKFZlbmFibGVfbG93X2xldmVsX2tleV9ldmVudHMpKQorICAgIHJl dHVybjsKKworICBzd2l0Y2ggKGV2ZW50LT50eXBlKQorICAgIHsKKyAgICBjYXNlIEdES19L RVlfUFJFU1M6CisgICAgICBpc19wcmVzcyA9IHRydWU7CisgICAgICBicmVhazsKKyAgICBj YXNlIEdES19LRVlfUkVMRUFTRToKKyAgICAgIGlzX3ByZXNzID0gZmFsc2U7CisgICAgICBi cmVhazsKKyAgICBkZWZhdWx0OgorICAgICAgcmV0dXJuOworICAgIH0KKworICAvKiBXZSBk b24ndCBzdXBwb3J0IG1vZGlmaWVyIGlkZW50aWZpY2F0aW9uIG9uIFBHVEsuIFdlIG9ubHkg Y2FuIHRlbGwKKyAgICBpZiB0aGUga2V5IGNvcnJlc3BvbmRzIHRvIGEgbW9kaWZpZXIgb3Ig bm90LCB3aGljaCBpcyB1c2VkIGZvcgorICAgIGZpbHRlcmluZyBlbmFibGVkIGtleXMgd2l0 aCBrYmRfbG93X2xldmVsX2tleV9pc19lbmFibGVkLiAgKi8KKyAgbW9kaWZpZXIgPSBldmVu dC0+a2V5LmlzX21vZGlmaWVyID8gUXQgOiBRbmlsOworCisgIGludCBrZXlzeW0gPSB4a2V5 LmtleXZhbDsKKworICBpZiAoa2V5c3ltID49IEdES19LRVlfYSAmJiBrZXlzeW0gPD0gR0RL X0tFWV96KQorICAgIGtleXN5bSAtPSBHREtfS0VZX2EgLSBHREtfS0VZX0E7CisgIGlmICgh a2JkX2xvd19sZ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JCQkgICAgaW50IGtleWNvZGUpCit7CisjaWZkZWYgSEFWRV9YS0IKKyAgaWYg KGRweWluZm8tPnhrYl9kZXNjKQorICAgIGZvciAoaW50IG1vZCA9IDA7IG1vZCA8IFhrYk51 bU1vZGlmaWVyczsgbW9kKyspCisgICAgICB7CisJaW50IG1hc2sgPSAoMSA8PCBtb2QpOwor CWlmIChkcHlpbmZvLT54a2JfZGVzYy0+bWFwLT5tb2RtYXBba2V5Y29kZV0gJiBtYXNrKQor CSAgeworCSAgICBpZiAobWFzayA9PSBTaGlmdE1hc2spCisJICAgICAgcmV0dXJuIFFzaGlm dDsKKwkgICAgaWYgKG1hc2sgPT0gQ29udHJvbE1hc2spCisJICAgICAgcmV0dXJuIFFjdHJs OworCSAgICBpZiAobWFzayA9PSBkcHlpbmZvLT5tZXRhX21vZF9tYXNrKQorCSAgICAgIHJl dHVybiBRbWV0YTsKKwkgICAgaWYgKG1hc2sgPT0gZHB5aW5mby0+YWx0X21vZF9tYXNrKQor CSAgICAgIHJldHVybiBRYWx0OworCSAgICBpZiAobWFzayA9PSBkcHlpbmZvLT5zdXBlcl9t b2RfbWFzaykKKwkgICAgICByZXR1cm4gUXN1cGVyOworCSAgICBpZiAobWFzayA9PSBkcHlp bmZvLT5oeXBlcl9tb2RfbWFzaykKKwkgICAgICByZXR1cm4gUWh5cGVyOworCSAgfQorICAg ICAgfQorI2VuZGlmCisgIFhNb2RpZmllcktleW1hcCAqbWFwID0gZHB5aW5mby0+bW9kbWFw OworICBpZiAobWFwKQorICAgIGZvciAoaW50IG1vZCA9IDA7IG1vZCA8IDg7IG1vZCsrKQor ICAgICAgeworCWludCBtYXNrID0gKDEgPDwgbW9kKTsKKyAgICAgICAgZm9yIChpbnQga2V5 ID0gMDsga2V5IDwgbWFwLT5tYXhfa2V5cGVybW9kOyBrZXkrKykKKwkgIGlmIChtYXAtPm1v ZGlmaWVybWFwW21vZCAqIG1hcC0+bWF4X2tleXBlcm1vZCArIGtleV0gPT0ga2V5Y29kZSkK KwkgICAgeworCSAgICAgIGlmIChtYXNrID09IFNoaWZ0TWFzaykKKwkJcmV0dXJuIFFzaGlm dDsKKwkgICAgICBpZiAobWFzayA9PSBDb250cm9sTWFzaykKKwkJcmV0dXJuIFFjdHJsOwor CSAgICAgIGlmIChtYXNrID09IGRweWluZm8tPm1ldGFfbW9kX21hc2spCisJCXJldHVybiBR bWV0YTsKKwkgICAgICBpZiAobWFzayA9PSBkcHlpbmZvLT5hbHRfbW9kX21hc2spCisJCXJl dHVybiBRYWx0OworCSAgICAgIGlmIChtYXNrID09IGRweWluZm8tPnN1cGVyX21vZF9tYXNr KQorCQlyZXR1cm4gUXN1cGVyOworCSAgICAgIGlmIChtYXNrID09IGRweWluZm8tPmh5cGVy X21vZF9tYXNrKQorCQlyZXR1cm4gUWh5cGVyOworCSAgICB9CisgICAgICB9CisgIHJldHVy biBRbmlsOworfQorCitzdGF0aWMgdm9pZAoreF9tYXliZV9zZW5kX2xvd19sZXZlbF9rZXlf ZXZlbnQgKHN0cnVjdCB4X2Rpc3BsYXlfaW5mbyAqZHB5aW5mbywKKwkJCQkgIGNvbnN0IFhF dmVudCAqeGV2LCBzdHJ1Y3QgZnJhbWUgKmYpCit7CisgIFhLZXlFdmVudCB4a2V5OworICBi b29sIGlzX3ByZXNzOworICBLZXlTeW0ga2V5c3ltOworICBMaXNwX09iamVjdCBrZXksIG1v ZGlmaWVyOworICBzdHJ1Y3QgaW5wdXRfZXZlbnQgaWU7CisKKyAgaWYgKE5JTFAgKFZlbmFi bGVfbG93X2xldmVsX2tleV9ldmVudHMpKQorICAgIHJldHVybjsKKworICBzd2l0Y2ggKHhl di0+dHlwZSkKKyAgICB7CisgICAgY2FzZSBLZXlQcmVzczoKKyAgICAgIGlzX3ByZXNzID0g dHJ1ZTsKKyAgICAgIHhrZXkgPSB4ZXYtPnhrZXk7CisgICAgICBicmVhazsKKyAgICBjYXNl IEtleVJlbGVhc2U6CisgICAgICBpc19wcmVzcyA9IGZhbHNlOworICAgICAgeGtleSA9IHhl di0+eGtleTsKKyAgICAgIGJyZWFrOworI2lmZGVmIEhBVkVfWElOUFVUMgorICAgIGNhc2Ug R2VuZXJpY0V2ZW50OgorICAgICAgWElEZXZpY2VFdmVudCAqeGlldiA9IHhldi0+eGNvb2tp ZS5kYXRhOworICAgICAgc3dpdGNoICh4ZXYtPnhnZW5lcmljLmV2dHlwZSkKKwl7CisJY2Fz ZSBYSV9LZXlQcmVzczoKKwkgIGlzX3ByZXNzID0gdHJ1ZTsKKwkgIGJyZWFrOworCWNhc2Ug WElfS2V5UmVsZWFzZToKKwkgIGlzX3ByZXNzID0gZmFsc2U7CisJICBicmVhazsKKwlkZWZh dWx0OgorCSAgcmV0dXJuOworCX0KKworICAgICAgeGtleS5zZXJpYWwgPSB4aWV2LT5zZXJp YWw7CisgICAgICB4a2V5LnNlbmRfZXZlbnQgPSB4aWV2LT5zZW5kX2V2ZW50OworICAgICAg eGtleS5kaXNwbGF5ID0geGlldi0+ZGlzcGxheTsKKyAgICAgIHhrZXkud2luZG93ID0geGll di0+ZXZlbnQ7CisgICAgICB4a2V5LnJvb3QgPSB4aWV2LT5yb290OworICAgICAgeGtleS5z dWJ3aW5kb3cgPSB4aWV2LT5jaGlsZDsKKyAgICAgIHhrZXkudGltZSA9IHhpZXYtPnRpbWU7 CisgICAgICB4a2V5LnggPSB4aWV2LT5ldmVudF94OworICAgICAgeGtleS55ID0geGlldi0+ ZXZlbnRfeTsKKyAgICAgIHhrZXkueF9yb290ID0geGlldi0+cm9vdF94OworICAgICAgeGtl eS55X3Jvb3QgPSB4aWV2LT5yb290X3k7CisgICAgICB4a2V5LnN0YXRlID0geGlldi0+bW9k cy5lZmZlY3RpdmU7CisgICAgICB4a2V5LmtleWNvZGUgPSB4aWV2LT5kZXRhaWw7CisgICAg ICB4a2V5LnNhbWVfc2NyZWVuID0gMTsKKyAgICAgIGJyZWFrOworI2VuZGlmCisgICAgZGVm YXVsdDoKKyAgICAgIHJldHVybjsKK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NyBAQCBoYW5kbGVfb25lX3hldmVudCAo c3RydWN0IHhfZGlzcGxheV9pbmZvICpkcHlpbmZvLAogICAgICAgZ290byBPVEhFUjsKIAog ICAgIGNhc2UgS2V5UHJlc3M6CisgICAgICB4X21heWJlX3NlbmRfbG93X2xldmVsX2tleV9l dmVudCAoZHB5aW5mbywgZXZlbnQsIGFueSk7CiAgICAgICB4X2Rpc3BsYXlfc2V0X2xhc3Rf dXNlcl90aW1lIChkcHlpbmZvLCBldmVudC0+eGtleS50aW1lLAogCQkJCSAgICBldmVudC0+ eGtleS5zZW5kX2V2ZW50LAogCQkJCSAgICB0cnVlKTsKQEAgLTIwNzE1LDYgKzIwODUxLDcg QEAgaGFuZGxlX29uZV94ZXZlbnQgKHN0cnVjdCB4X2Rpc3BsYXlfaW5mbyAqZHB5aW5mbywK ICNlbmRpZgogCiAgICAgY2FzZSBLZXlSZWxlYXNlOgorICAgICAgeF9tYXliZV9zZW5kX2xv d19sZXZlbF9rZXlfZXZlbnQgKGRweWluZm8sIGV2ZW50LCBhbnkpOwogI2lmZGVmIEhBVkVf WF9JMThOCiAgICAgICAvKiBEb24ndCBkaXNwYXRjaCB0aGlzIGV2ZW50IHNpbmNlIFh0RGlz cGF0Y2hFdmVudCBjYWxscwogICAgICAgICAgWEZpbHRlckV2ZW50LCBhbmQgdHdvIGNhbGxz IGluIGEgcm93IG1heSBmcmVlemUgdGhlCkBAIC0yMzk3MCw2ICsyNDEwNyw4IEBAIGhhbmRs ZV9vbmVfeGV2ZW50IChzdHJ1Y3QgeF9kaXNwbGF5X2luZm8gKmRweWluZm8sCiAJICAgICAg c3RydWN0IHhpX2RldmljZV90ICpkZXZpY2UsICpzb3VyY2U7CiAJICAgICAgWEtleVByZXNz ZWRFdmVudCB4a2V5OwogCisJICAgICAgeF9tYXliZV9zZW5kX2xvd19sZXZlbF9rZXlfZXZl bnQgKGRweWluZm8sIGV2ZW50LCBhbnkpOworCiAJICAgICAgY29kaW5nID0gUWxhdGluXzE7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l ciAoc3RydWN0IGZyYW1lICpmKTsKIGV4dGVybiB2b2lkIGluaXRpYWxfc2V0X3VwX3hfYmFj a19idWZmZXIgKHN0cnVjdCBmcmFtZSAqZik7CiAKK2V4dGVybiBMaXNwX09iamVjdCB4X2dl dF9tb2RpZmllcl9mb3Jfa2V5Y29kZSAoc3RydWN0IHhfZGlzcGxheV9pbmZvICosIGludCk7 CisKIC8qIERlZmluZWQgaW4geGZucy5jLiAgKi8KIGV4dGVybiB2b2lkIHhfcmVhbF9wb3Np dGlvbnMgKHN0cnVjdCBmcmFtZSAqLCBpbnQgKiwgaW50ICopOwogZXh0ZXJuIHZvaWQgeF9j aGFuZ2VfdGFiX2Jhcl9oZWlnaHQgKHN0cnVjdCBmcmFtZSAqLCBpbnQpOwotLSAKMi4zNS4x LndpbmRvd3MuMgoK --------------Ho0Ev8LvMd4RGoiUOUnpb8B7--
bug-gnu-emacs@HIDDEN
:bug#74423
; Package emacs
.
Full text available.Received: (at 74423) by debbugs.gnu.org; 14 Dec 2024 11:14:29 +0000 From debbugs-submit-bounces <at> debbugs.gnu.org Sat Dec 14 06:14:29 2024 Received: from localhost ([127.0.0.1]:45725 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from <debbugs-submit-bounces <at> debbugs.gnu.org>) id 1tMQ6O-00039o-L0 for submit <at> debbugs.gnu.org; Sat, 14 Dec 2024 06:14:29 -0500 Received: from eggs.gnu.org ([209.51.188.92]:57718) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from <eliz@HIDDEN>) id 1tMQ6K-00039B-Hf for 74423 <at> debbugs.gnu.org; Sat, 14 Dec 2024 06:14:26 -0500 Received: from fencepost.gnu.org ([2001:470:142:3::e]) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from <eliz@HIDDEN>) id 1tMQ6D-0005pQ-89; Sat, 14 Dec 2024 06:14:17 -0500 DKIM-Signature: v=1; a=rsa-sha256; q=dns/txt; c=relaxed/relaxed; d=gnu.org; s=fencepost-gnu-org; h=References:Subject:In-Reply-To:To:From:Date: mime-version; bh=bd12ye0f1HZWgzvGLgLhBO9LtOMyofVwdtFvFWTTN/U=; b=rLPZvTaf3RQi oW7dT6mJA47evr54LrnIMtmVeZdj3GOT5zX2j1+tjesqY75KegrR3UhKYAHOxAHgxERgpoQtBHoQv XrGlgg11kI66m4Cc+MgaCxPF8nIRhVa73bkstN2wikX1fBZjiP8944vzNbZYuGP+veJqIv1H31kVQ AGf9aPK4cv1XOcN80Gdsvivgyi7C2qKDaqeqpMDrl7vyayE1NiBRuCGVyZ8OunwIeG/y8H2iJarUK fNOlZOalIxsykKEPjWtkRqUTDvfE3sbLNO1JUAIk4uXNkzdl3mCDSGdKgUoIFK6mlI8jJe5o/D7c1 jzUffk/UVzwqkk20aTGcCw==; Date: Sat, 14 Dec 2024 13:14:11 +0200 Message-Id: <86bjxev7ng.fsf@HIDDEN> From: Eli Zaretskii <eliz@HIDDEN> To: Cecilio Pardo <cpardo@HIDDEN> In-Reply-To: <c0bd3bff-4546-4169-9e5d-ba60ef059b6c@HIDDEN> (message from Cecilio Pardo on Fri, 13 Dec 2024 23:55:18 +0100) Subject: Re: bug#74423: Low level key events References: <fb50ec11-7aec-481e-8a3a-ecdcf22eb7c0@HIDDEN> <31bdc55d-8c13-4de0-9cef-bd6cc4fb033f@HIDDEN> <s1r8qtzsvbe.fsf@HIDDEN> <d5c72818-e907-43f5-853a-89ec01264157@HIDDEN> <jwv4j43jisn.fsf-monnier+emacs@HIDDEN> <705fabb8-1ea0-4894-8c32-05097ab822c9@HIDDEN> <jwvplmqtuh1.fsf-monnier+emacs@HIDDEN> <b0b914a0-b454-41b0-aa3d-d9e243c210f5@HIDDEN> <868qsvz07i.fsf@HIDDEN> <162dada7-ad54-4ca5-8f11-d55dd6dccb3c@HIDDEN> <867c8ezny3.fsf@HIDDEN> <c0bd3bff-4546-4169-9e5d-ba60ef059b6c@HIDDEN> X-Spam-Score: -2.3 (--) X-Debbugs-Envelope-To: 74423 Cc: luangruo@HIDDEN, 74423 <at> debbugs.gnu.org, monnier@HIDDEN X-BeenThere: debbugs-submit <at> debbugs.gnu.org X-Mailman-Version: 2.1.18 Precedence: list List-Id: <debbugs-submit.debbugs.gnu.org> List-Unsubscribe: <https://debbugs.gnu.org/cgi-bin/mailman/options/debbugs-submit>, <mailto:debbugs-submit-request <at> debbugs.gnu.org?subject=unsubscribe> List-Archive: <https://debbugs.gnu.org/cgi-bin/mailman/private/debbugs-submit/> List-Post: <mailto:debbugs-submit <at> debbugs.gnu.org> List-Help: <mailto:debbugs-submit-request <at> debbugs.gnu.org?subject=help> List-Subscribe: <https://debbugs.gnu.org/cgi-bin/mailman/listinfo/debbugs-submit>, <mailto:debbugs-submit-request <at> debbugs.gnu.org?subject=subscribe> Errors-To: debbugs-submit-bounces <at> debbugs.gnu.org Sender: "Debbugs-submit" <debbugs-submit-bounces <at> debbugs.gnu.org> X-Spam-Score: -3.3 (---) > Date: Fri, 13 Dec 2024 23:55:18 +0100 > Cc: luangruo@HIDDEN, 74423 <at> debbugs.gnu.org, monnier@HIDDEN > From: Cecilio Pardo <cpardo@HIDDEN> > > This new version includes a manual entry, and corrected doc strings and > comments. Thanks, a few minor comments. > +@cindex @code{low-level-key} event > +@item (low-level-key @var{is-key-press} @var{key} @var{modifier} @var{time} @var{frame}) > +This event is sent on the physical press or release of keys, only on GUI > +systems, currently X, MS-Windows and PGTK. Aren't these events sent only if enable-low-level-key-events is non-nil? If so, this should be documented, and the variable itself should be documented. > +@var{is-key-press} is @code{t} for a key press, @code{nil} for a key release. > +@var{time} is the event's time in milliseconds, @var{frame} is the > +frame receiving it. @var{modifier} is @code{nil} if the key is not a ^^ Two spaces between sentences. > + DEFVAR_LISP ("enable-low-level-key-events", Venable_low_level_key_events, > + doc: /* If non-nil, reception of low-level key events is enabled. > + > +The value configures the set of keys that are handled: > + > +If t, send events for all keys. > + > +If a number, send events for the corresponding keysym. When calling > +'llk-init', a set of variables with the xk- prefix is initialized with ^^^^^^^^^^ In doc strings, we quote symbols `like this'.
bug-gnu-emacs@HIDDEN
:bug#74423
; Package emacs
.
Full text available.Received: (at 74423) by debbugs.gnu.org; 14 Dec 2024 09:26:33 +0000 From debbugs-submit-bounces <at> debbugs.gnu.org Sat Dec 14 04:26:33 2024 Received: from localhost ([127.0.0.1]:45424 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from <debbugs-submit-bounces <at> debbugs.gnu.org>) id 1tMOPw-0006Do-VA for submit <at> debbugs.gnu.org; Sat, 14 Dec 2024 04:26:33 -0500 Received: from mail.imayhem.com ([82.223.54.191]:49977 helo=zealous-pike.82-223-54-191.plesk.page) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from <cpardo@HIDDEN>) id 1tMOPu-0006DV-Bx for 74423 <at> debbugs.gnu.org; Sat, 14 Dec 2024 04:26:31 -0500 Received: from [192.168.68.102] (111.red-88-21-7.staticip.rima-tde.net [88.21.7.111]) by zealous-pike.82-223-54-191.plesk.page (Postfix) with ESMTPSA id 2F30D80184; Sat, 14 Dec 2024 09:26:24 +0000 (UTC) Authentication-Results: zealous-pike.82-223-54-191.plesk.page; spf=pass (sender IP is 88.21.7.111) smtp.mailfrom=cpardo@HIDDEN smtp.helo=[192.168.68.102] Received-SPF: pass (zealous-pike.82-223-54-191.plesk.page: connection is authenticated) Message-ID: <ecd8b7b6-6dfc-434f-a922-896414cf5ce7@HIDDEN> Date: Sat, 14 Dec 2024 10:26:23 +0100 MIME-Version: 1.0 User-Agent: Mozilla Thunderbird Subject: Re: bug#74423: Low level key events To: Po Lu <luangruo@HIDDEN> References: <fb50ec11-7aec-481e-8a3a-ecdcf22eb7c0@HIDDEN> <31bdc55d-8c13-4de0-9cef-bd6cc4fb033f@HIDDEN> <s1r8qtzsvbe.fsf@HIDDEN> <d5c72818-e907-43f5-853a-89ec01264157@HIDDEN> <jwv4j43jisn.fsf-monnier+emacs@HIDDEN> <705fabb8-1ea0-4894-8c32-05097ab822c9@HIDDEN> <jwvplmqtuh1.fsf-monnier+emacs@HIDDEN> <b0b914a0-b454-41b0-aa3d-d9e243c210f5@HIDDEN> <868qsvz07i.fsf@HIDDEN> <162dada7-ad54-4ca5-8f11-d55dd6dccb3c@HIDDEN> <867c8ezny3.fsf@HIDDEN> <c0bd3bff-4546-4169-9e5d-ba60ef059b6c@HIDDEN> <87ldwjqd1e.fsf@HIDDEN> Content-Language: es-ES From: Cecilio Pardo <cpardo@HIDDEN> In-Reply-To: <87ldwjqd1e.fsf@HIDDEN> Content-Type: text/plain; charset=UTF-8; format=flowed Content-Transfer-Encoding: 7bit X-Spam-Score: 0.0 (/) X-Debbugs-Envelope-To: 74423 Cc: 74423 <at> debbugs.gnu.org, Eli Zaretskii <eliz@HIDDEN>, monnier@HIDDEN X-BeenThere: debbugs-submit <at> debbugs.gnu.org X-Mailman-Version: 2.1.18 Precedence: list List-Id: <debbugs-submit.debbugs.gnu.org> List-Unsubscribe: <https://debbugs.gnu.org/cgi-bin/mailman/options/debbugs-submit>, <mailto:debbugs-submit-request <at> debbugs.gnu.org?subject=unsubscribe> List-Archive: <https://debbugs.gnu.org/cgi-bin/mailman/private/debbugs-submit/> List-Post: <mailto:debbugs-submit <at> debbugs.gnu.org> List-Help: <mailto:debbugs-submit-request <at> debbugs.gnu.org?subject=help> List-Subscribe: <https://debbugs.gnu.org/cgi-bin/mailman/listinfo/debbugs-submit>, <mailto:debbugs-submit-request <at> debbugs.gnu.org?subject=subscribe> Errors-To: debbugs-submit-bounces <at> debbugs.gnu.org Sender: "Debbugs-submit" <debbugs-submit-bounces <at> debbugs.gnu.org> X-Spam-Score: -1.0 (-) On 14/12/2024 2:16, Po Lu wrote: > Cecilio Pardo <cpardo@HIDDEN> writes: > >> +#ifndef HAVE_XINPUT2 >> +static void >> +xg_maybe_send_low_level_key_event (struct frame *f, >> + GdkEvent *xev) >> +{ >> + GdkEventKey xkey = xev->key; > Why is this !HAVE_XINPUT2? GTK input method support exists > independently of XInput 2. When XInput 2 is active, we get the event through it (XI_KeyPress) first. That gives the information we need. The GTK code is used when there is no XInput and use_native_input is active.
bug-gnu-emacs@HIDDEN
:bug#74423
; Package emacs
.
Full text available.Received: (at 74423) by debbugs.gnu.org; 14 Dec 2024 01:17:11 +0000 From debbugs-submit-bounces <at> debbugs.gnu.org Fri Dec 13 20:17:11 2024 Received: from localhost ([127.0.0.1]:44857 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from <debbugs-submit-bounces <at> debbugs.gnu.org>) id 1tMGmN-0008P2-0B for submit <at> debbugs.gnu.org; Fri, 13 Dec 2024 20:17:11 -0500 Received: from [66.163.191.206] (port=43194 helo=sonic312-25.consmr.mail.ne1.yahoo.com) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from <luangruo@HIDDEN>) id 1tMGmJ-0008OI-GV for 74423 <at> debbugs.gnu.org; Fri, 13 Dec 2024 20:17:10 -0500 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=yahoo.com; s=s2048; t=1734139015; bh=uo9I+srJwYo1FwkONd0I20DXr/OyjzvPTAgbLbgFIRI=; h=From:To:Cc:Subject:In-Reply-To:References:Date:From:Subject:Reply-To; b=n14dAkHTPoihZovsBmyWdP6uCpmxcgIE4+k+ToEidT5PvzxTX9S8S+IwJSQPfsewswndKf6H3atQJENRpgS7CMqJJrx4jErbaL9zZndTseK2NWhEYcGyJh6uukkurH0Fya4lLr5rvfCcRi90H/IABmED7S/F7XxlgkCBKYnB4t732EV+3/aBKbk5KA0/7khABI34JD3a5IJOYKq54tCN002u8Rgnvp/PTg/F1k/K2FL0ij9htroCQrZF5jysqAySEifXVR18ZxkxoROpe//CSJHbKQTIxmoV6HLEm2ktfQRBYFT0VjfyI6/DT5X7kZw1Mi1GxoqN/EaUJGmX2ELiRA== X-SONIC-DKIM-SIGN: v=1; a=rsa-sha256; c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ws_P GbkLbA1ed15xkaW8qXpBtntMz3a9PzJGis8UY.yZaLAetWEw8R7zVp7CEkU6YzGo0.V6uiB_hJrM XveyyHznDIUtsqSC5biHQdsq_fC5.LA1_4jT2.5B4395ReZkGdVNQSXZi2sGBUaXPDnE1Y05Yt_d 1_OAzovPusGp9kjEo4gwyv8f9pnDnFeeb1wGCBZDG1EQAL8SB2i8dq61TFD4lnp_ZoGdAaQJOHtZ 24D1LjpLPVoEtqzeW13NeHMzOsJxRVuKvWJFh9EAtjL.wt7Q2.7y2KjhpxuD7U6gQsSoCdPUYHR6 79vW17IXUm3EvXH2EeahdZRfTQ6y9WZDxe93044oeAa76YH03XmavM5mOK40EK4YTSqPuNs2H8LZ BXz5aYgPnLqV9BolQXVohb4zIJiygyYRUknhT9F21ewtKXdiZph2lMn6iF0VRVjlu8IagaDvJCbH D12z7aldvqFDLWGGhD8iqJojlBu4nvB0n4FpAyUCNLBY.HctEUsO6Hp9cEwJN70JCL4v6FVZXEBc ouy.t4J2Qf2SFYS.BAMsAKfq1K0hYPxJHXyKjcsI99bXSxqkpmHvf3N_ulDZcUThXuhcel7a._Nm pkLIauPxUkocs4O4OtVZ5l8Tr4nPn96S25L8NVxo0c7AcR3RhSi6AOGso X-Sonic-MF: <luangruo@HIDDEN> X-Sonic-ID: 22b03926-2eab-4c0a-8ded-915aef95437a Received: from sonic.gate.mail.ne1.yahoo.com by sonic312.consmr.mail.ne1.yahoo.com with HTTP; Sat, 14 Dec 2024 01:16:55 +0000 Received: by hermes--production-sg3-5b7954b588-wvg78 (Yahoo Inc. Hermes SMTP Server) with ESMTPA ID 33346bddb3cfa286c1b5c31d84f311fe; Sat, 14 Dec 2024 01:16:50 +0000 (UTC) From: Po Lu <luangruo@HIDDEN> To: Cecilio Pardo <cpardo@HIDDEN> Subject: Re: bug#74423: Low level key events In-Reply-To: <c0bd3bff-4546-4169-9e5d-ba60ef059b6c@HIDDEN> (Cecilio Pardo's message of "Fri, 13 Dec 2024 23:55:18 +0100") References: <fb50ec11-7aec-481e-8a3a-ecdcf22eb7c0@HIDDEN> <31bdc55d-8c13-4de0-9cef-bd6cc4fb033f@HIDDEN> <s1r8qtzsvbe.fsf@HIDDEN> <d5c72818-e907-43f5-853a-89ec01264157@HIDDEN> <jwv4j43jisn.fsf-monnier+emacs@HIDDEN> <705fabb8-1ea0-4894-8c32-05097ab822c9@HIDDEN> <jwvplmqtuh1.fsf-monnier+emacs@HIDDEN> <b0b914a0-b454-41b0-aa3d-d9e243c210f5@HIDDEN> <868qsvz07i.fsf@HIDDEN> <162dada7-ad54-4ca5-8f11-d55dd6dccb3c@HIDDEN> <867c8ezny3.fsf@HIDDEN> <c0bd3bff-4546-4169-9e5d-ba60ef059b6c@HIDDEN> Date: Sat, 14 Dec 2024 09:16:45 +0800 Message-ID: <87ldwjqd1e.fsf@HIDDEN> User-Agent: Gnus/5.13 (Gnus v5.13) MIME-Version: 1.0 Content-Type: text/plain X-Mailer: WebService/1.1.23040 mail.backend.jedi.jws.acl:role.jedi.acl.token.atz.jws.hermes.yahoo Content-Length: 1336 X-Spam-Score: 2.3 (++) X-Spam-Report: Spam detection software, running on the system "debbugs.gnu.org", has NOT identified this incoming email as spam. The original message has been attached to this so you can view it or label similar future email. If you have any questions, see the administrator of that system for details. Content preview: Cecilio Pardo writes: > +#ifndef HAVE_XINPUT2 > +static void > +xg_maybe_send_low_level_key_event (struct frame *f, > + GdkEvent *xev) > +{ > + GdkEventKey xkey = xev->key; > + bool is_press; > + Lisp_Object key, modifier; [...] Content analysis details: (2.3 points, 10.0 required) pts rule name description ---- ---------------------- -------------------------------------------------- 0.0 FREEMAIL_FROM Sender email is commonly abused enduser mail provider (luangruo[at]yahoo.com) 0.0 SPF_HELO_NONE SPF: HELO does not publish an SPF Record 1.0 FORGED_YAHOO_RCVD 'From' yahoo.com does not match 'Received' headers -0.0 SPF_PASS SPF: sender matches SPF record -0.0 RCVD_IN_MSPIKE_H2 RBL: Average reputation (+2) [66.163.191.206 listed in wl.mailspike.net] 0.0 RCVD_IN_VALIDITY_RPBL_BLOCKED RBL: ADMINISTRATOR NOTICE: The query to Validity was blocked. See https://knowledge.validity.com/hc/en-us/articles/20961730681243 for more information. [66.163.191.206 listed in bl.score.senderscore.com] -0.0 RCVD_IN_DNSWL_NONE RBL: Sender listed at https://www.dnswl.org/, no trust [66.163.191.206 listed in list.dnswl.org] 0.0 RCVD_IN_VALIDITY_CERTIFIED_BLOCKED RBL: ADMINISTRATOR NOTICE: The query to Validity was blocked. See https://knowledge.validity.com/hc/en-us/articles/20961730681243 for more information. [66.163.191.206 listed in sa-trusted.bondedsender.org] 1.3 RDNS_NONE Delivered to internal network by a host with no rDNS X-Debbugs-Envelope-To: 74423 Cc: 74423 <at> debbugs.gnu.org, Eli Zaretskii <eliz@HIDDEN>, monnier@HIDDEN X-BeenThere: debbugs-submit <at> debbugs.gnu.org X-Mailman-Version: 2.1.18 Precedence: list List-Id: <debbugs-submit.debbugs.gnu.org> List-Unsubscribe: <https://debbugs.gnu.org/cgi-bin/mailman/options/debbugs-submit>, <mailto:debbugs-submit-request <at> debbugs.gnu.org?subject=unsubscribe> List-Archive: <https://debbugs.gnu.org/cgi-bin/mailman/private/debbugs-submit/> List-Post: <mailto:debbugs-submit <at> debbugs.gnu.org> List-Help: <mailto:debbugs-submit-request <at> debbugs.gnu.org?subject=help> List-Subscribe: <https://debbugs.gnu.org/cgi-bin/mailman/listinfo/debbugs-submit>, <mailto:debbugs-submit-request <at> debbugs.gnu.org?subject=subscribe> Errors-To: debbugs-submit-bounces <at> debbugs.gnu.org Sender: "Debbugs-submit" <debbugs-submit-bounces <at> debbugs.gnu.org> X-Spam-Score: 1.3 (+) X-Spam-Report: Spam detection software, running on the system "debbugs.gnu.org", has NOT identified this incoming email as spam. The original message has been attached to this so you can view it or label similar future email. If you have any questions, see the administrator of that system for details. Content preview: Cecilio Pardo writes: > +#ifndef HAVE_XINPUT2 > +static void > +xg_maybe_send_low_level_key_event (struct frame *f, > + GdkEvent *xev) > +{ > + GdkEventKey xkey = xev->key; > + bool is_press; > + Lisp_Object key, modifier; [...] Content analysis details: (1.3 points, 10.0 required) pts rule name description ---- ---------------------- -------------------------------------------------- 0.0 RCVD_IN_VALIDITY_CERTIFIED_BLOCKED RBL: ADMINISTRATOR NOTICE: The query to Validity was blocked. See https://knowledge.validity.com/hc/en-us/articles/20961730681243 for more information. [66.163.191.206 listed in sa-accredit.habeas.com] -0.0 RCVD_IN_DNSWL_NONE RBL: Sender listed at https://www.dnswl.org/, no trust [66.163.191.206 listed in list.dnswl.org] 0.0 RCVD_IN_VALIDITY_RPBL_BLOCKED RBL: ADMINISTRATOR NOTICE: The query to Validity was blocked. See https://knowledge.validity.com/hc/en-us/articles/20961730681243 for more information. [66.163.191.206 listed in bl.score.senderscore.com] -0.0 RCVD_IN_MSPIKE_H2 RBL: Average reputation (+2) [66.163.191.206 listed in wl.mailspike.net] 0.0 FREEMAIL_FROM Sender email is commonly abused enduser mail provider (luangruo[at]yahoo.com) 0.0 SPF_HELO_NONE SPF: HELO does not publish an SPF Record 1.0 FORGED_YAHOO_RCVD 'From' yahoo.com does not match 'Received' headers -0.0 SPF_PASS SPF: sender matches SPF record 1.3 RDNS_NONE Delivered to internal network by a host with no rDNS -1.0 MAILING_LIST_MULTI Multiple indicators imply a widely-seen list manager Cecilio Pardo <cpardo@HIDDEN> writes: > +#ifndef HAVE_XINPUT2 > +static void > +xg_maybe_send_low_level_key_event (struct frame *f, > + GdkEvent *xev) > +{ > + GdkEventKey xkey = xev->key; > + bool is_press; > + Lisp_Object key, modifier; > + union buffered_input_event inev; > + > + if (NILP (Venable_low_level_key_events)) > + return; > + > + switch (xev->type) > + { > + case GDK_KEY_PRESS: > + is_press = true; > + break; > + case GDK_KEY_RELEASE: > + is_press = false; > + break; > + default: > + return; > + } > + > + modifier = x_get_modifier_for_keycode (FRAME_OUTPUT_DATA (f)->display_info, > + xev->key.hardware_keycode); > + > + int keysym = xkey.keyval; > + > + if (keysym >= GDK_KEY_a && keysym <= GDK_KEY_z) > + keysym -= GDK_KEY_a - GDK_KEY_A; > + > + if (!kbd_low_level_key_is_enabled (keysym, modifier)) > + return; > + > + key = make_fixnum (keysym); > + > + EVENT_INIT (inev.ie); > + XSETFRAME (inev.ie.frame_or_window, f); > + inev.ie.kind = LOW_LEVEL_KEY_EVENT; > + inev.ie.timestamp = xkey.time; > + inev.ie.arg = list3 (is_press ? Qt : Qnil, key, modifier); > + kbd_buffer_store_buffered_event (&inev, &xg_pending_quit_event); > +} > +#endif Why is this !HAVE_XINPUT2? GTK input method support exists independently of XInput 2.
bug-gnu-emacs@HIDDEN
:bug#74423
; Package emacs
.
Full text available.Received: (at 74423) by debbugs.gnu.org; 13 Dec 2024 22:55:34 +0000 From debbugs-submit-bounces <at> debbugs.gnu.org Fri Dec 13 17:55:34 2024 Received: from localhost ([127.0.0.1]:44527 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from <debbugs-submit-bounces <at> debbugs.gnu.org>) id 1tMEZI-0001BE-2y for submit <at> debbugs.gnu.org; Fri, 13 Dec 2024 17:55:34 -0500 Received: from mail.imayhem.com ([82.223.54.191]:57887 helo=zealous-pike.82-223-54-191.plesk.page) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from <cpardo@HIDDEN>) id 1tMEZC-0001At-GZ for 74423 <at> debbugs.gnu.org; Fri, 13 Dec 2024 17:55:30 -0500 Received: from [192.168.68.102] (111.red-88-21-7.staticip.rima-tde.net [88.21.7.111]) by zealous-pike.82-223-54-191.plesk.page (Postfix) with ESMTPSA id 055E380155; Fri, 13 Dec 2024 22:55:19 +0000 (UTC) Authentication-Results: zealous-pike.82-223-54-191.plesk.page; spf=pass (sender IP is 88.21.7.111) smtp.mailfrom=cpardo@HIDDEN smtp.helo=[192.168.68.102] Received-SPF: pass (zealous-pike.82-223-54-191.plesk.page: connection is authenticated) Content-Type: multipart/mixed; boundary="------------sxrzhc8vUyFc3eu2Z97hOBFd" Message-ID: <c0bd3bff-4546-4169-9e5d-ba60ef059b6c@HIDDEN> Date: Fri, 13 Dec 2024 23:55:18 +0100 MIME-Version: 1.0 User-Agent: Mozilla Thunderbird Subject: Re: bug#74423: Low level key events To: Eli Zaretskii <eliz@HIDDEN> References: <fb50ec11-7aec-481e-8a3a-ecdcf22eb7c0@HIDDEN> <31bdc55d-8c13-4de0-9cef-bd6cc4fb033f@HIDDEN> <s1r8qtzsvbe.fsf@HIDDEN> <d5c72818-e907-43f5-853a-89ec01264157@HIDDEN> <jwv4j43jisn.fsf-monnier+emacs@HIDDEN> <705fabb8-1ea0-4894-8c32-05097ab822c9@HIDDEN> <jwvplmqtuh1.fsf-monnier+emacs@HIDDEN> <b0b914a0-b454-41b0-aa3d-d9e243c210f5@HIDDEN> <868qsvz07i.fsf@HIDDEN> <162dada7-ad54-4ca5-8f11-d55dd6dccb3c@HIDDEN> <867c8ezny3.fsf@HIDDEN> Content-Language: es-ES From: Cecilio Pardo <cpardo@HIDDEN> In-Reply-To: <867c8ezny3.fsf@HIDDEN> X-Spam-Score: 0.0 (/) X-Debbugs-Envelope-To: 74423 Cc: luangruo@HIDDEN, 74423 <at> debbugs.gnu.org, monnier@HIDDEN X-BeenThere: debbugs-submit <at> debbugs.gnu.org X-Mailman-Version: 2.1.18 Precedence: list List-Id: <debbugs-submit.debbugs.gnu.org> List-Unsubscribe: <https://debbugs.gnu.org/cgi-bin/mailman/options/debbugs-submit>, <mailto:debbugs-submit-request <at> debbugs.gnu.org?subject=unsubscribe> List-Archive: <https://debbugs.gnu.org/cgi-bin/mailman/private/debbugs-submit/> List-Post: <mailto:debbugs-submit <at> debbugs.gnu.org> List-Help: <mailto:debbugs-submit-request <at> debbugs.gnu.org?subject=help> List-Subscribe: <https://debbugs.gnu.org/cgi-bin/mailman/listinfo/debbugs-submit>, <mailto:debbugs-submit-request <at> debbugs.gnu.org?subject=subscribe> Errors-To: debbugs-submit-bounces <at> debbugs.gnu.org Sender: "Debbugs-submit" <debbugs-submit-bounces <at> debbugs.gnu.org> X-Spam-Score: -1.0 (-) This is a multi-part message in MIME format. --------------sxrzhc8vUyFc3eu2Z97hOBFd Content-Type: text/plain; charset=UTF-8; format=flowed Content-Transfer-Encoding: 7bit This new version includes a manual entry, and corrected doc strings and comments. --------------sxrzhc8vUyFc3eu2Z97hOBFd Content-Type: text/plain; charset=UTF-8; name="0001-Send-events-for-key-presses-and-key-releases.patch" Content-Disposition: attachment; filename="0001-Send-events-for-key-presses-and-key-releases.patch" Content-Transfer-Encoding: base64 RnJvbSBmMjM4MWZmMzgxNTczODdjNGIzZThjYTM1MDA5Njc1OTc2ZmQ5NzE3IE1vbiBTZXAg MTcgMDA6MDA6MDAgMjAwMQpGcm9tOiBDZWNpbGlvIFBhcmRvIDxjcGFyZG9AaW1heWhlbS5j b20+CkRhdGU6IE1vbiwgMiBEZWMgMjAyNCAxNzozMDo0MiArMDEwMApTdWJqZWN0OiBbUEFU Q0hdIFNlbmQgZXZlbnRzIGZvciBrZXkgcHJlc3NlcyBhbmQga2V5IHJlbGVhc2VzLgoKRGV0 ZWN0IGRvdWJsZS90cmlwbGUgdGFwcy4KCiogZG9jL2xpc3ByZWYvY29tbWFuZHMudGV4aTog QWRkZWQgaW5mb3JtYXRpb24gYWJvdXQgbmV3IGV2ZW50LgoqIHNyYy9ndGt1dGlsLmMgKHhn X2NyZWF0ZV9mcmFtZV93aWRnZXRzKTogTW9kaWZpZWQgdG8gaGFuZGxlIGtleQpyZWxlYXNl IGV2ZW50cy4KKHhnX21heWJlX3NlbmRfbG93X2xldmVsX2tleV9ldmVudCk6IE5ldyBmdW5j dGlvbiB0aGF0IHNlbmRzIGtleQpldmVudHMuCih4Z193aWRnZXRfa2V5X3ByZXNzX2V2ZW50 X2NiKTogTW9kaWZpZWQgdG8gc2VuZCBsb3cgbGV2ZWwga2V5IGV2ZW50cy4KKHhnX3dpZGdl dF9rZXlfcmVsZWFzZV9ldmVudF9jYik6IE5ldyBmdW5jdGlvbiB0byBzZ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F81IFZLX05VTVBBRDUKKyAg KGRlZmluZS14ayB4ay1rcC02ICAgICAgICAjeGZmYjYgI3g2NikgOzsgWEtfS1BfNiBWS19O VU1QQUQ2CisgIChkZWZpbmUteGsgeGsta3AtNyAgICAgICAgI3hmZmI3ICN4NjcpIDs7IFhL X0tQXzcgVktfTlVNUEFENworICAoZGVmaW5lLXhrIHhrLWtwLTggICAgICAgICN4ZmZiOCAj eDY4KSA7OyBYS19LUF84IFZLX05VTVBBRDgKKyAgKGRlZmluZS14ayB4ay1rcC05ICAgICAg ICAjeGZmYjkgI3g2OSkgOzsgWEtfS1BfOSBWS19OVU1QQUQ5CisKKyAgOzsgRnVuY3Rpb24g a2V5cworICAoZGVmaW5lLXhrIHhrLWYxICAgICAgICAgICN4ZmZiZSAjeDcwKSA7OyBYS19G MSBWS19GMQorICAoZGVmaW5lLXhrIHhrLWYyICAgICAgICAgICN4ZmZiZiAjeDcxKSA7OyBY S19GMiBWS19GMgorICAoZGVmaW5lLXhrIHhrLWYzICAgICAgICAgICN4ZmZjMCAjeDcyKSA7 OyBYS19GMyBWS19GMworICAoZGVmaW5lLXhrIHhrLWY0ICAgICAgICAgICN4ZmZjMSAjeDcz KSA7OyBYS19GNCBWS19GNAorICAoZGVmaW5lLXhrIHhrLWY1ICAgICAgICAgICN4ZmZjMiAj eDc0KSA7OyBYS19GNSBWS19GNQorICAoZGVmaW5lLXhrIHhrLWY2ICAgICAgICAgICN4ZmZj MyAjeDc1KSA7OyBYS19GNiBWS19GNgorICAoZGVmaW5lLXhrIHhrLWY3ICAgICAgICAgICN4 ZmZjNCAjeDc2KSA7OyBYS19GNyBWS19GNworICAoZGVmaW5lLXhrIHhrLWY4ICAgICAgICAg ICN4ZmZjNSAjeDc3KSA7OyBYS19GOCBWS19GOAorICAoZGVmaW5lLXhrIHhrLWY5ICAgICAg ICAgICN4ZmZjNiAjeDc4KSA7OyBYS19GOSBWS19GOQorICAoZGVmaW5lLXhrIHhrLWYxMCAg ICAgICAgICN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ICAgICN4MDAzOSAjeDM5KSA7OyBYS185CisgIChkZWZpbmUteGsgeGstYSAgICAgICAgICAg I3gwMDQxICN4NDEpIDs7IFhLX0EKKyAgKGRlZmluZS14ayB4ay1iICAgICAgICAgICAjeDAw NDIgI3g0MikgOzsgWEtfQgorICAoZGVmaW5lLXhrIHhrLWMgICAgICAgICAgICN4MDA0MyAj eDQzKSA7OyBYS19DCisgIChkZWZpbmUteGsgeGstZCAgICAgICAgICAgI3gwMDQ0ICN4NDQp IDs7IFhLX0QKKyAgKGRlZmluZS14ayB4ay1lICAgICAgICAgICAjeDAwNDUgI3g0NSkgOzsg WEtfRQorICAoZGVmaW5lLXhrIHhrLWYgICAgICAgICAgICN4MDA0NiAjeDQ2KSA7OyBYS19G CisgIChkZWZpbmUteGsgeGstZyAgICAgICAgICAgI3gwMDQ3ICN4NDcpIDs7IFhLX0cKKyAg KGRlZmluZS14ayB4ay1oICAgICAgICAgICAjeDAwNDggI3g0OCkgOzsgWEtfSAorICAoZGVm aW5lLXhrIHhrLWkgICAgICAgICAgICN4MDA0OSAjeDQ5KSA7OyBYS19JCisgIChkZWZpbmUt eGsgeGstaiAgICAgICAgICAgI3gwMDRBICN4NEEpIDs7IFhLX0oKKyAgKGRlZmluZS14ayB4 ay1rICAgICAgICAgICAjeDAwNEIgI3g0QikgOzsgWEtfSworICAoZGVmaW5lLXhrIHhrLWwg ICAgICAgICAgICN4MDA0QyAjeDRDKSA7OyBYS19MCisgIChkZWZpbmUteGsgeGstbSAgICAg ICAgICAgI3gwMDREICN4NEQpIDs7IFhLX00KKyAgKGRlZmluZS14ayB4ay1uICAgICAgICAg ICAjeDAwNEUgI3g0RSkgOzsgWEtfTgorICAoZGVmaW5lLXhrIHhrLW8gICAgICAgICAgICN4 MDA0RiAjeDRGKSA7OyBYS19PCisgIChkZWZpbmUteGsgeGstcCAgICAgICAgICAgI3gwMDUw ICN4NTApIDs7IFhLX1AKKyAgKGRlZmluZS14ayB4ay1xICAgICAgICAgICAj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1wbGU6Cis7OyBCaW5kIGtleSB0YXAgdG8gY29tbWFu ZAorOzsgICAgKGxsay1iaW5kICd0YXAgJ3hrLXNoaWZ0LWwgJ2RlbGV0ZS1vdGhlci13aW5k b3dzKQorOzsgQmluZCBtb2RpZmllciB0YXAgdG8gY29tbWFuZAorOzsgICAgIChsbGstYmlu ZCAndGFwICdzaGlmdCAnZGVsZXRlLW90aGVyLXdpbmRvd3MpCis7OyBCaW5kIHRhcCB0byBo eXBlciBtb2RpZmllcgorOzsgICAgICAobGxrLWJpbmQgJ3RhcCAneGstc2hpZnQtciAobGFt YmRhICgpCis7OyAgICAgICAgICAgICAgICAgICAgICAgICAgICAgIChtZXNzYWdlICJILS4u LiIpCis7OyAgICAgICAgICAgICAgICAgICAgICAgICAgICAgIChzZXRxIHVucmVhZC1jb21t YW5kLWV2ZW50cworOzsgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAoYXBw ZW5kIChldmVudC1hcHBseS1oeXBlci1tb2RpZmllciBuaWwpIG5pbCkpKSkKKzs7IENhbiBi aW5kIHRvIGEgY29tbWFuZCBvciBmdW5jdGlvbgorKGRlZnVuIGxsay1iaW5kIChhY3Rpb24g a2V5IGZ1bmN0aW9uKQorICAiQmluZCBhIGNvbW1hbmQgb3IgZnVuY3Rpb24gdG8gYSBsb3cg bGV2ZWwga2V5IGV2ZW50LgorCitUaGUgb25seSBhY3Rpb24gc3VwcG9ydGVkIGN1cnJlbnRs eSBpcyBgdGFwJy4gIFRoZSBrZXkgY2FuIGJlIGEga2V5c3ltCitzeW1ib2wsIG9yIGEgbW9k aWZpZXIgc3ltYm9sIChzaGlmdCwgY29udHJvbCwgYWx0LCBtZXRhLCBoeXBlciwgc3VwZXIp LgorSWYgdGhlcmUgaXMgbm8ga2V5c3ltIHN5bWJvbCBmb3IgYSBrZXksIHVzZSB0aGUga2V5 c3ltIG51bWJlci4iCisgIChwdXNoIChsaXN0IGFjdGlvbiBrZXkgZnVuY3Rpb24pIGxsay1i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1iZXIga2V5c3ltIGxsay10YXAta2V5cykKKyAgICAgICAgKHNl dHEga2V5IGtleXN5bSkKKyAgICAgIChpZiAobWVtYmVyIG1vZGlmaWVyIGxsay10YXAta2V5 cykKKyAgICAgICAgICAoc2V0cSBrZXkgbW9kaWZpZXIpKSkKKworICAgIChpZiAobm90IGtl eSkKKyAgICAgICAgOzsgS2V5IG5vdCBpbiB0YXAgbGlzdCwgY2xlYXIgaGlzdG9yeQorICAg ICAgICAoc2V0cSBsbGstZXZlbnRzIG5pbCkKKyAgICAgIDs7IENsZWFyIGl0IGFsc28gaWYg dGhlIGZpcnN0IGVsZW1lbnQgaXMgZnJvbSBhIGRpZmZlcmVudCBrZXkKKyAgICAgIChhbmQg bGxrLWV2ZW50cworICAgICAgICAgICAobm90IChlcXVhbCAoY2FyIChjYXIgbGxrLWV2ZW50 cykpIGtleSkpCisgICAgICAgICAgIChzZXRxIGxsay1ldmVudHMgbmlsKSkKKyAgICAgIChw dXNoIChsaXN0IGtleSBpcy1wcmVzcyB0aW1lc3RhbXApIGxsay1ldmVudHMpCisgICAgICA7 OyBPbmx5IGNhcmUgYWJvdXQgbGFzdCAyeE4gZXZlbnRzCisgICAgICAobnRha2UgKCogMiBu KSBsbGstZXZlbnRzKQorICAgICAgOzsgSWYgd2UgaGF2ZToKKyAgICAgIDs7IC0gRXhhY3Rs eSAyICogbiBldmVudHMuCisgICAgICA7OyAtIGRvd24sIHVwLCBkb3duLCB1cCwgLi4uCisg ICAgICA7OyAtIG5vdCB0d28gbXVjaCB0aW1lIGJldHdlZW4gZmlyc3QgYW5kIGxhc3QKKyAg ICAgIChhbmQgKGVxICgqIDIgbikgKGxlbmd0aCBsbGstZXZlbnRzKSkKKyAgICAgICAgICAg KGNsLWV2ZXJ5ICdlcQorICAgICAgICAgICAgICAgICAgICAgKG50YWtlICgqIDIgbikKKyAg ICAgICAgICAgICAgICAgICAgICAgICAgICAobGlzdCBuaWwgdCBuaWwgdCBuaWwgdCBuaWwg dAorICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgIG5pbCB0IG5pbCB0IG5pbCB0 IG5pbCB0KSkKKyAgICAgICAgICAgICAgICAgICAgIChtYXBjYXIgJ2NsLXNlY29uZCBsbGst ZXZlbnRzKSkKKyAgICAgICAgICAgKDwgKC0gKGNsLXRoaXJkIChjbC1maXJzdCBsbGstZXZl bnRzKSkKKyAgICAgICAgICAgICAgICAgKGNsLXRoaXJkIChjYXIgKGxhc3QgbGxrLWV2ZW50 cykpKSkKKyAgICAgICAgICAgICAgdGltZW91dCkKKyAgICAgICAgICAgKHByb2duCisgICAg ICAgICAgICAgKHNldHEgbGxrLWV2ZW50cyBuaWwpCisgICAgICAgICAgICAga2V5KSkpKSkK KworKGRlZnVuIGRlc2NyaWJlLWxvdy1sZXZlbC1rZXkgKCkKKyAgIldhaXQgZm9yIGtleSBw cmVzcyBhbmQgZGVzY3JpYmUgdGhlIGxvdyBsZXZlbCBrZXkgZXZlbnQgaXQgZ2VuZXJhdGVz LiIKKyAgKGludGVyYWN0aXZlKQorICAoc2V0cSBsbGstZGVzY3JpYmUtbmV4dC1wcmVzcyB0 KSkKKworKGRlZnVuIGxsay1zaG93LWV2ZW50LWRlc2NyaXB0aW9uICgpCisgICJTaG93IGlu Zm9ybWF0aW9uIGFib3V0IHRoZSBsYXN0IGxvdyBsZXZlbCBrZXkgZXZlbnQuIgorICAoc2V0 cSBsbGstZGVzY3JpYmUtbmV4dC1wcmVzcyBuaWwpCisgICh3aXRoLWhlbHAtd2luZG93ICho ZWxwLWJ1ZmZlcikKKyAgICAoaW5zZXJ0ICJcbiIpCisgICAgKGxldCogKCh4ayAoZXZlbnQt a2V5c3ltIGxhc3QtaW5wdXQtZXZlbnQpKQorICAgICAgICAgICAoc3ltIChhc3NvYyB4ayBs bGsta2V5c3ltcykpKQorICAgICAgKGluc2VydCAoZm9ybWF0ICJLZXlzeW0gbnVtYmVyOiAl ZCAoI3glWCksXG4iIHhrIHhrKSkKKyAgICAgIChpZiBzeW0KKyAgICAgICAgICAoaW5zZXJ0 IChmb3JtYXQgIndoaWNoIGNvcnJlc3BvbmRzIHRvIG5hbWVkIGtleSAlcy5cblxuIiAoY2Ry IHN5bSkpKQorICAgICAgICAoaW5zZXJ0ICJ3aGljaCBkb2VzIG5vdCBjb3JyZXNwb25kIHRv IGFueSBrbm93biBuYW1lZCBrZXkuXG5cbiIpKQorICAgICAgKGlmIChldmVudC1tb2RpZmll ciBsYXN0LWlucHV0LWV2ZW50KQorICAgICAgICAgIChpbnNlcnQgKGZvcm1hdCAiVGhpcyBr ZXkgY29ycmVzcG9uZHMgdG8gdGhlICVzIG1vZGlmaWVyLlxuXG4iCisgICAgICAgICAgICAg ICAgICAgICAgICAgIChldmVudC1tb2RpZmllciBsYXN0LWlucHV0LWV2ZW50KSkpCisgICAg ICAgIChpbnNlcnQgIlRoaXMga2V5IGRvZXMgbm90IGNvcnJlc3BvbmQgdG8gYSBtb2RpZmll ci5cblxuIikpCisgICAgICAoaW5zZXJ0ICJTZWUgdGhlIHZhbHVlIG9mIHRoZSBgbGxrLWtl eXN5bXMnIHZhcmlhYmxlIGZvciBhIGxpc3Qgb2Yga25vd24ga2V5cy5cbiIpKSkpCisKKyhk ZWZ1biBsbGstaGFuZGxlICgpCisgICJJbnRlcm5hbCBmdW5jdGlvbiB0byBoYW5kbGUgbG93 IGxldmVsIGtleSBldmVudHMuIgorICAoaW50ZXJhY3RpdmUpCisgIChpZiAoYW5kIChldmVu dC1pcy1rZXktcHJlc3MgbGFzdC1pbnB1dC1ldmVudCkKKyAgICAgICAgICAgbGxrLWRlc2Ny aWJlLW5leHQtcHJlc3MpCisgICAgICAobGxrLXNob3ctZXZlbnQtZGVzY3JpcHRpb24pCisg ICAgKGxldCAoKHRhcC1rZXkgKGxsay1kZXRlY3Qtbi10YXAKKyAgICAgICAgICAgICAgICAg ICAgbGxrLXRhcC1jb3VudAorICAgICAgICAgICAgICAgICAgICBsbGstdGFwLXRpbWVvdXQp KSkKKyAg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MT1dfTEVWRUxfS0VZX0VWRU5U OgorICAgICAgcmV0dXJuIGxpc3RuICg2LCBRbG93X2xldmVsX2tleSwKKwkJICAgIFhDQVIg KGV2ZW50LT5hcmcpLCAvKiBQcmVzcyBvciByZWxlYXNlLiAgKi8KKwkJICAgIFhDQVIgKFhD RFIgKGV2ZW50LT5hcmcpKSwgLyogVGhlIGtleSBzeW1ib2wuICAqLworCQkgICAgWENBUiAo WENEUiAoWENEUiAoZXZlbnQtPmFyZykpKSwgLyogVGhlIG1vZGlmaWVyLiAgKi8KKwkJICAg IG1ha2VfZml4bnVtIChldmVudC0+dGltZXN0YW1wKSwKKwkJICAgIGV2ZW50LT5mcmFtZV9v cl93aW5kb3cpOworCiAgICAgICAvKiBUaGUgJ2tpbmQnIGZpZWxkIG9mIHRoZSBldmVudCBp cyBzb21ldGhpbmcgd2UgZG9uJ3QgcmVjb2duaXplLiAgKi8KICAgICBkZWZhdWx0OgogICAg ICAgZW1hY3NfYWJvcnQgKCk7CiAgICAgfQogfQogCitib29sCitrYmRfbG93X2xldmVsX2tl eV9pc19lbmFibGVkIChpbnQga2V5c3ltLCBMaXNwX09iamVjdCBtb2RpZmllcikKK3sKKyAg aWYgKFZlbmFibGVfbG93X2xldmVsX2tleV9ldmVudHMgPT0gUXQpCisgICAgcmV0dXJuIHRy dWU7CisKKyAgaWYgKFZlbmFibGVfbG93X2xldmVsX2tleV9ldmVudHMgPT0gUW5pbCkKKyAg ICByZXR1cm4gZmFsc2U7CisKKyAgaWYgKEZJWE5VTVAgKFZlbmFibGVfbG93X2xldmVsX2tl eV9ldmVudHMpKQorICAgIHJldHVybiBrZXlzeW0gPT0gWEZJWE5VTSAoVmVuYWJsZV9sb3df bGV2ZWxfa2V5X2V2ZW50cyk7CisKKyAgaWYgKFZlbmFibGVfbG93X2xldmVsX2tleV9ldmVu dHMgPT0gUW1vZGlmaWVycykKKyAgICByZXR1cm4gbW9kaWZpZXIgIT0gUW5pbDsKKworICBm b3IgKExpc3BfT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WZpZXIgaWRlbnRpZmljYXRpb24gb24gUEdUSy4gV2Ug b25seSBjYW4gdGVsbAorICAgIGlmIHRoZSBrZXkgY29ycmVzcG9uZHMgdG8gYSBtb2RpZmll ciBvciBub3QsIHdoaWNoIGlzIHVzZWQgZm9yCisgICAgZmlsdGVyaW5nIGVuYWJsZWQga2V5 cyB3aXRoIGtiZF9sb3dfbGV2ZWxfa2V5X2lzX2VuYWJsZWQuICAqLworICBtb2RpZmllciA9 IGV2ZW50LT5rZXkuaXNfbW9kaWZpZXIgPyBRdCA6IFFuaWw7CisKKyAgaW50IGtleXN5bSA9 IHhrZXkua2V5dmFsOworCisgIGlmIChrZXlzeW0gPj0gR0RLX0tFWV9hICYmIGtleXN5bSA8 PSBHREtfS0VZX3opCisgICAga2V5c3ltIC09IEdES19LRVlfYSAtIEdES19LRVlfQTsKKyAg aWYgKCFrYmRfbG93X2xldmVsX2tleV9pc19lbmFibGVkIChrZXlzeW0sIG1vZGlmaWVyKSkK KyAgICByZXR1cm47CisKKyAgaWYgKCFmKQorICAgIGYgPSBwZ3RrX2FueV93aW5kb3dfdG9f ZnJhbWUgKGV2ZW50LT5rZXkud2luZG93KTsKKyAgaWYgKCFmKQorICAgIHJldHVybjsKKwor ICBrZXkgPSBtYWtlX2ZpeG51bSAoa2V5c3ltKTsKKworICBFVkVOVF9JTklUIChpbmV2Lmll KTsKKyAgWFNFVEZSQU1FIChpbmV2LmllLmZyYW1lX29yX3dpbmRvdywgZik7CisgIGluZXYu aWUua2luZCA9IExPV19MRVZFTF9LRVlfRVZFTlQ7CisgIGluZXYuaWUudGltZXN0YW1wID0g ZXZlbnQtPmtleS50aW1lOworICBpbmV2LmllLmFyZyA9IGxpc3QzIChpc19wcmVzcyA/IFF0 IDogUW5pbCwga2V5LCBtb2RpZmllcik7CisgIGV2cV9lbnF1ZXVlICgmaW5ldik7Cit9CisK IHN0YXRpYyBnYm9vbGVhbgoga2V5X3ByZXNzX2V2ZW50IChHdGtXaWRnZXQgKnd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8tPnN1 cGVyX21vZF9tYXNrKQorCSAgICAgIHJldHVybiBRc3VwZXI7CisJICAgIGlmIChtYXNrID09 IGRweWluZm8tPmh5cGVyX21vZF9tYXNrKQorCSAgICAgIHJldHVybiBRaHlwZXI7CisJICB9 CisgICAgICB9CisjZW5kaWYKKyAgWE1vZGlmaWVyS2V5bWFwICptYXAgPSBkcHlpbmZvLT5t b2RtYXA7CisgIGlmIChtYXApCisgICAgZm9yIChpbnQgbW9kID0gMDsgbW9kIDwgODsgbW9k KyspCisgICAgICB7CisJaW50IG1hc2sgPSAoMSA8PCBtb2QpOworICAgICAgICBmb3IgKGlu dCBrZXkgPSAwOyBrZXkgPCBtYXAtPm1heF9rZXlwZXJtb2Q7IGtleSsrKQorCSAgaWYgKG1h cC0+bW9kaWZpZXJtYXBbbW9kICogbWFwLT5tYXhfa2V5cGVybW9kICsga2V5XSA9PSBrZXlj b2RlKQorCSAgICB7CisJICAgICAgaWYgKG1hc2sgPT0gU2hpZnRNYXNrKQorCQlyZXR1cm4g UXNoaWZ0OworCSAgICAgIGlmIChtYXNrID09IENvbnRyb2xNYXNrKQorCQlyZXR1cm4gUWN0 cmw7CisJICAgICAgaWYgKG1hc2sgPT0gZHB5aW5mby0+bWV0YV9tb2RfbWFzaykKKwkJcmV0 dXJuIFFtZXRhOworCSAgICAgIGlmIChtYXNrID09IGRweWluZm8tPmFsdF9tb2RfbWFzaykK KwkJcmV0dXJuIFFhbHQ7CisJICAgICAgaWYgKG1hc2sgPT0gZHB5aW5mby0+c3VwZXJfbW9k X21hc2spCisJCXJldHVybiBRc3VwZXI7CisJICAgICAgaWYgKG1hc2sgPT0gZHB5aW5mby0+ aHlwZXJfbW9kX21hc2spCisJCXJldHVybiBRaHlwZXI7CisJICAgIH0KKyAgICAgIH0KKyAg cmV0dXJuIFFuaWw7Cit9CisKK3N0YXRpYyB2b2lkCit4X21heWJlX3NlbmRfbG93X2xldmVs X2tleV9ldmVudCAoc3RydWN0IHhfZGlzcGxheV9pbmZvICpkcHlpbmZvLAorCQkJCSAgY29u c3QgWEV2ZW50ICp4ZXYsIHN0cnVjdCBmcmFtZSAqZikKK3sKKyAgWEtleUV2ZW50IHhrZXk7 CisgIGJvb2wgaXNfcHJlc3M7CisgIEtleVN5bSBrZXlzeW07CisgIExpc3BfT2JqZWN0IGtl eSwgbW9kaWZpZXI7CisgIHN0cnVjdCBpbnB1dF9ldmVudCBpZTsKKworICBpZiAoTklMUCAo VmVuYWJsZV9sb3dfbGV2ZWxfa2V5X2V2ZW50cykpCisgICAgcmV0dXJuOworCisgIHN3aXRj aCAoeGV2LT50eXBlKQorICAgIHsKKyAgICBjYXNlIEtleVByZXNzOgorICAgICAgaXNfcHJl c3MgPSB0cnVlOworICAgICAgeGtleSA9IHhldi0+eGtleTsKKyAgICAgIGJyZWFrOworICAg IGNhc2UgS2V5UmVsZWFzZToKKyAgICAgIGlzX3ByZXNzID0gZmFsc2U7CisgICAgICB4a2V5 ID0geGV2LT54a2V5OworICAgICAgYnJlYWs7CisjaWZkZWYgSEFWRV9YSU5QVVQyCisgICAg Y2FzZSBHZW5lcmljRXZlbnQ6CisgICAgICBYSURldmljZUV2ZW50ICp4aWV2ID0geGV2LT54 Y29va2llLmRhdGE7CisgICAgICBzd2l0Y2ggKHhldi0+eGdlbmVyaWMuZXZ0eXBlKQorCXsK KwljYXNlIFhJX0tleVByZXNzOgorCSAgaXNfcHJlc3MgPSB0cnVlOworCSAgYnJlYWs7CisJ Y2FzZSBYSV9LZXlSZWxlYXNlOgorCSAgaXNfcHJlc3MgPSBmYWxzZTsKKwkgIGJyZWFrOwor CWRlZmF1bHQ6CisJICByZXR1cm47CisJfQorCisgICAgICB4a2V5LnNlcmlhbCA9IHhpZXYt PnNlcmlhbDsKKyAgICAgIHhrZXkuc2VuZF9ldmVudCA9IHhpZXYtPnNlbmRfZXZlbnQ7Cisg ICAgICB4a2V5LmRpc3BsYXkgPSB4aWV2LT5kaXNwbGF5OworICAgICAgeGtleS53aW5kb3cg PSB4aWV2LT5ldmVudDsKKyAgICAgIHhrZXkucm9vdCA9IHhpZXYtPnJvb3Q7CisgICAgICB4 a2V5LnN1YndpbmRvdyA9IHhpZXYtPmNoaWxkOworICAgICAgeGtleS50aW1lID0geGlldi0+ dGltZTsKKyAgICAgIHhrZXkueCA9IHhpZXYtPmV2ZW50X3g7CisgICAgICB4a2V5LnkgPSB4 aWV2LT5ldmVudF95OworICAgICAgeGtleS54X3Jvb3QgPSB4aWV2LT5yb290X3g7CisgICAg ICB4a2V5Lnlfcm9vdCA9IHhpZXYtPnJvb3RfeTsKKyAgICAgIHhrZXkuc3RhdGUgPSB4aWV2 LT5tb2RzLmVmZmVjdGl2ZTsKKyAgICAgIHhrZXkua2V5Y29kZSA9IHhpZXYtPmRldGFpbDsK KyAgICAgIHhrZXkuc2FtZV9zY3JlZW4gPSAxOworICAgICAgYnJlYWs7CisjZW5kaWYKKyAg ICBkZWZhdWx0OgorICAgICAgcmV0dXJuOworICAgIH0KKworICBpZiAoIWYpCisgICAgZiA9 IHhfYW55X3dpbmRvd190b19mcmFtZSAoZHB5aW5mbywgeGtleS53aW5kb3cpOworICBpZiAo IWYpCisgICAgcmV0dXJuOworCisgIFhMb29rdXBTdHJpbmcgKCZ4a2V5LCBOVUxMLCAwLCAm a2V5c3ltLCBOVUxMKTsKKworICBtb2RpZmllciA9IHhfZ2V0X21vZGlmaWVyX2Zvcl9rZXlj b2RlIChkcHlpbmZvLCB4a2V5LmtleWNvZGUpOworCisgIC8qIENvbnZlcnQgbG93ZXJjYXNl IGxhdGluIGxldHRlciB0byB1cHBlcmNhc2UuICAqLworICBpZiAoa2V5c3ltID49IFhLX2Eg JiYga2V5c3ltIDw9IFhLX3opCisgICAga2V5c3ltIC09IFhLX2EgLSBYS19BOworCisgIGlm ICgha2JkX2xvd19sZXZlbF9rZXlfaXNfZW5hYmxlZCAoa2V5c3ltLCBtb2RpZmllcikpCisg ICAgcmV0dXJuOworCisgIGtleSA9IG1ha2VfZml4bnVt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2xsX2JhcnMgPSBRbmlsOwogI2Vu ZGlmCiAKKyAgREVGU1lNIChRc2hpZnQsICJzaGlmdCIpOwogICBERUZTWU0gKFFtb2RpZmll cl92YWx1ZSwgIm1vZGlmaWVyLXZhbHVlIik7CiAgIERFRlNZTSAoUWN0cmwsICJjdHJsIik7 CiAgIEZwdXQgKFFjdHJsLCBRbW9kaWZpZXJfdmFsdWUsIG1ha2VfZml4bnVtIChjdHJsX21v ZGlmaWVyKSk7CmRpZmYgLS1naXQgYS9zcmMveHRlcm0uaCBiL3NyYy94dGVybS5oCmluZGV4 IDhkNWM5OTE3NzQ5Li42NmUwNTJlN2FjZCAxMDA2NDQKLS0tIGEvc3JjL3h0ZXJtLmgKKysr IGIvc3JjL3h0ZXJtLmgKQEAgLTE5MDYsNiArMTkwNiw4IEBAIHhfbXV0YWJsZV9jb2xvcm1h cCAoWFZpc3VhbEluZm8gKnZpc3VhbCkKIGV4dGVybiB2b2lkIHRlYXJfZG93bl94X2JhY2tf YnVmZmVyIChzdHJ1Y3QgZnJhbWUgKmYpOwogZXh0ZXJuIHZvaWQgaW5pdGlhbF9zZXRfdXBf eF9iYWNrX2J1ZmZlciAoc3RydWN0IGZyYW1lICpmKTsKIAorZXh0ZXJuIExpc3BfT2JqZWN0 IHhfZ2V0X21vZGlmaWVyX2Zvcl9rZXljb2RlIChzdHJ1Y3QgeF9kaXNwbGF5X2luZm8gKiwg aW50KTsKKwogLyogRGVmaW5lZCBpbiB4Zm5zLmMuICAqLwogZXh0ZXJuIHZvaWQgeF9yZWFs X3Bvc2l0aW9ucyAoc3RydWN0IGZyYW1lICosIGludCAqLCBpbnQgKik7CiBleHRlcm4gdm9p ZCB4X2NoYW5nZV90YWJfYmFyX2hlaWdodCAoc3RydWN0IGZyYW1lICosIGludCk7Ci0tIAoy LjM1LjEud2luZG93cy4yCgo= --------------sxrzhc8vUyFc3eu2Z97hOBFd--
bug-gnu-emacs@HIDDEN
:bug#74423
; Package emacs
.
Full text available.Received: (at submit) by debbugs.gnu.org; 7 Dec 2024 21:52:20 +0000 From debbugs-submit-bounces <at> debbugs.gnu.org Sat Dec 07 16:52:20 2024 Received: from localhost ([127.0.0.1]:48798 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from <debbugs-submit-bounces <at> debbugs.gnu.org>) id 1tK2iq-0005cO-Ct for submit <at> debbugs.gnu.org; Sat, 07 Dec 2024 16:52:20 -0500 Received: from lists.gnu.org ([209.51.188.17]:51352) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from <cpardo@HIDDEN>) id 1tK2io-0005cC-BS for submit <at> debbugs.gnu.org; Sat, 07 Dec 2024 16:52:18 -0500 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 <cpardo@HIDDEN>) id 1tK2io-0001CD-3A for bug-gnu-emacs@HIDDEN; Sat, 07 Dec 2024 16:52:18 -0500 Received: from mail.imayhem.com ([82.223.54.191] helo=zealous-pike.82-223-54-191.plesk.page) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_128_GCM_SHA256:128) (Exim 4.90_1) (envelope-from <cpardo@HIDDEN>) id 1tK2il-0005Bt-GS for bug-gnu-emacs@HIDDEN; Sat, 07 Dec 2024 16:52:17 -0500 Received: from [192.168.68.104] (111.red-88-21-7.staticip.rima-tde.net [88.21.7.111]) by zealous-pike.82-223-54-191.plesk.page (Postfix) with ESMTPSA id 5EFF480102 for <bug-gnu-emacs@HIDDEN>; Sat, 7 Dec 2024 21:52:09 +0000 (UTC) Authentication-Results: zealous-pike.82-223-54-191.plesk.page; spf=pass (sender IP is 88.21.7.111) smtp.mailfrom=cpardo@HIDDEN smtp.helo=[192.168.68.104] Received-SPF: pass (zealous-pike.82-223-54-191.plesk.page: connection is authenticated) Message-ID: <7284332b-1cdb-4ceb-ae02-a79eda2503fc@HIDDEN> Date: Sat, 7 Dec 2024 22:52:08 +0100 MIME-Version: 1.0 User-Agent: Mozilla Thunderbird Subject: Re: bug#74423: Low level key events To: bug-gnu-emacs@HIDDEN References: <fb50ec11-7aec-481e-8a3a-ecdcf22eb7c0@HIDDEN> <31bdc55d-8c13-4de0-9cef-bd6cc4fb033f@HIDDEN> <s1r8qtzsvbe.fsf@HIDDEN> <d5c72818-e907-43f5-853a-89ec01264157@HIDDEN> <jwv4j43jisn.fsf-monnier+emacs@HIDDEN> <705fabb8-1ea0-4894-8c32-05097ab822c9@HIDDEN> <jwvplmqtuh1.fsf-monnier+emacs@HIDDEN> <b0b914a0-b454-41b0-aa3d-d9e243c210f5@HIDDEN> <868qsvz07i.fsf@HIDDEN> <162dada7-ad54-4ca5-8f11-d55dd6dccb3c@HIDDEN> <867c8ezny3.fsf@HIDDEN> <87ttbhhbf9.fsf@HIDDEN> Content-Language: es-ES From: Cecilio Pardo <cpardo@HIDDEN> In-Reply-To: <87ttbhhbf9.fsf@HIDDEN> Content-Type: text/plain; charset=UTF-8; format=flowed Content-Transfer-Encoding: 7bit Received-SPF: pass client-ip=82.223.54.191; envelope-from=cpardo@HIDDEN; helo=zealous-pike.82-223-54-191.plesk.page X-Spam_score_int: -18 X-Spam_score: -1.9 X-Spam_bar: - X-Spam_report: (-1.9 / 5.0 requ) BAYES_00=-1.9, RCVD_IN_VALIDITY_CERTIFIED_BLOCKED=0.001, RCVD_IN_VALIDITY_RPBL_BLOCKED=0.001, SPF_HELO_NONE=0.001, SPF_PASS=-0.001 autolearn=ham autolearn_force=no X-Spam_action: no action X-Spam-Score: -1.3 (-) X-Debbugs-Envelope-To: submit X-BeenThere: debbugs-submit <at> debbugs.gnu.org X-Mailman-Version: 2.1.18 Precedence: list List-Id: <debbugs-submit.debbugs.gnu.org> List-Unsubscribe: <https://debbugs.gnu.org/cgi-bin/mailman/options/debbugs-submit>, <mailto:debbugs-submit-request <at> debbugs.gnu.org?subject=unsubscribe> List-Archive: <https://debbugs.gnu.org/cgi-bin/mailman/private/debbugs-submit/> List-Post: <mailto:debbugs-submit <at> debbugs.gnu.org> List-Help: <mailto:debbugs-submit-request <at> debbugs.gnu.org?subject=help> List-Subscribe: <https://debbugs.gnu.org/cgi-bin/mailman/listinfo/debbugs-submit>, <mailto:debbugs-submit-request <at> debbugs.gnu.org?subject=subscribe> Errors-To: debbugs-submit-bounces <at> debbugs.gnu.org Sender: "Debbugs-submit" <debbugs-submit-bounces <at> debbugs.gnu.org> X-Spam-Score: -2.3 (--) On 06/12/2024 2:01, Po Lu: > I suggest calling XKeysymToString rather than interning the numerical > value of keysyms received. This gives users some indication of the > identity of these keysyms without tediously referring to (at times > vendor-specific) keysymdef.h files. Do you mean replacing variable names like xk-backspace, xk-tab with the strings returned by XKeysymToString?
bug-gnu-emacs@HIDDEN
:bug#74423
; Package emacs
.
Full text available.Received: (at 74423) by debbugs.gnu.org; 6 Dec 2024 01:01:52 +0000 From debbugs-submit-bounces <at> debbugs.gnu.org Thu Dec 05 20:01:52 2024 Received: from localhost ([127.0.0.1]:41455 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from <debbugs-submit-bounces <at> debbugs.gnu.org>) id 1tJMjA-0006BJ-7M for submit <at> debbugs.gnu.org; Thu, 05 Dec 2024 20:01:52 -0500 Received: from sonic311-25.consmr.mail.ne1.yahoo.com ([66.163.188.206]:34409) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from <luangruo@HIDDEN>) id 1tJMj5-0006B1-LT for 74423 <at> debbugs.gnu.org; Thu, 05 Dec 2024 20:01:51 -0500 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=yahoo.com; s=s2048; t=1733446902; bh=wot3N9HJoiOKKiXzVLp1AHhbn16sqh+MK1T/zx+0l68=; h=From:To:Cc:Subject:In-Reply-To:References:Date:From:Subject:Reply-To; b=gkl6hw1ipDIIzceQPWApKU7i0A5J6KZPgmCvRUxd8KIjIkzknreLy9S15kXKRcodGnRbn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ukln7dfJmnANyZtPLfxNxtWxpAViKMw6V6q0H3iJ0nsRa0 .2zQFh_.DyUqzjx6xvUqfFiif4xAf1_an7qn_gpM91OvFHbvBoI.d7tVyfC9rCcnqLC_dEcCi4OR N0DqtFoZaqPYFHzbsue351IODAEC325V4cA9YYiCWsNUtZHMUtnSVIb23Hsfa.Jp2YGrOYjWxPTJ gQecRmDfHODpHbteMGqkeIyuWyI81mUQ150bv0L.R3B7eP7.OcRGsbGYcUl1o.27eIle9PaBhlmO Se6OZlB1m5JhKbBpNWE8x5I5qMp8sfB7eL1iDsqOov5aIdRvq9O6WXwfoVu9cQNBOZE7UfEgO.eW TAKBwAe_JsUaF08lfTx52Bo9xRFZFGvDt5b2sXG0F2EY84osMllUsK058_evqRwECP61_3DdvoWG .Ksk8n7h1gVy102.BVzqiX6LT1drJUTnX4Bv3TPWZ62DnN6z.EuWkj_CoVNJjKoLEW1gi9BmFHWy 9QL_xz.QR8OHlbflkgkFivRgWW9pvtXEhzY64rRAmQv.J2zrEPSd6QKwBXOZG38SzUL11BctQvmR Sww809wdGmB1DQM2N6mGW_29REUmgWljPznHJQJiuw8YQtEPA8LiCd_cQZlgnCOruwiKKlyu5SsL uHgHc5NBHsRPpU4igb6SjSuZyEtppkfvxqkIdEDk4FuTTElimsC9YtsVpBVyvyKnoVhau1xBo_6C CpiwIO20ClC6mu.VJA4vu9nrWJN5Y9CsUD77ZXxFSQv7oL4s_ESN40feT9XK7u5eQfvZOpkR45Zk veRFLT7ZS29HR3kQgcAYGTsV.RlcdKsZ1.qi5rDyKaah49doUcDnANkbYAVBnqHlxv99JZbQx0sC S3bDNdyjuilZPBO4K4b9eJ..WRp6hoywLuGaG.BNiwNJJLhae1h4pA7G8 X-Sonic-MF: <luangruo@HIDDEN> X-Sonic-ID: 3af35865-82eb-4e4d-94d0-14a11474d139 Received: from sonic.gate.mail.ne1.yahoo.com by sonic311.consmr.mail.ne1.yahoo.com with HTTP; Fri, 6 Dec 2024 01:01:42 +0000 Received: by hermes--production-sg3-5b7954b588-bd2kk (Yahoo Inc. Hermes SMTP Server) with ESMTPA ID 1c6f5a6351711b82c513ede023a0beb1; Fri, 06 Dec 2024 01:01:35 +0000 (UTC) From: Po Lu <luangruo@HIDDEN> To: Eli Zaretskii <eliz@HIDDEN> Subject: Re: bug#74423: Low level key events In-Reply-To: <867c8ezny3.fsf@HIDDEN> (Eli Zaretskii's message of "Thu, 05 Dec 2024 07:41:24 +0200") References: <fb50ec11-7aec-481e-8a3a-ecdcf22eb7c0@HIDDEN> <31bdc55d-8c13-4de0-9cef-bd6cc4fb033f@HIDDEN> <s1r8qtzsvbe.fsf@HIDDEN> <d5c72818-e907-43f5-853a-89ec01264157@HIDDEN> <jwv4j43jisn.fsf-monnier+emacs@HIDDEN> <705fabb8-1ea0-4894-8c32-05097ab822c9@HIDDEN> <jwvplmqtuh1.fsf-monnier+emacs@HIDDEN> <b0b914a0-b454-41b0-aa3d-d9e243c210f5@HIDDEN> <868qsvz07i.fsf@HIDDEN> <162dada7-ad54-4ca5-8f11-d55dd6dccb3c@HIDDEN> <867c8ezny3.fsf@HIDDEN> Date: Fri, 06 Dec 2024 09:01:30 +0800 Message-ID: <87ttbhhbf9.fsf@HIDDEN> User-Agent: Gnus/5.13 (Gnus v5.13) MIME-Version: 1.0 Content-Type: text/plain X-Mailer: WebService/1.1.23040 mail.backend.jedi.jws.acl:role.jedi.acl.token.atz.jws.hermes.yahoo Content-Length: 2578 X-Spam-Score: 0.0 (/) X-Debbugs-Envelope-To: 74423 Cc: 74423 <at> debbugs.gnu.org, Cecilio Pardo <cpardo@HIDDEN>, monnier@HIDDEN X-BeenThere: debbugs-submit <at> debbugs.gnu.org X-Mailman-Version: 2.1.18 Precedence: list List-Id: <debbugs-submit.debbugs.gnu.org> List-Unsubscribe: <https://debbugs.gnu.org/cgi-bin/mailman/options/debbugs-submit>, <mailto:debbugs-submit-request <at> debbugs.gnu.org?subject=unsubscribe> List-Archive: <https://debbugs.gnu.org/cgi-bin/mailman/private/debbugs-submit/> List-Post: <mailto:debbugs-submit <at> debbugs.gnu.org> List-Help: <mailto:debbugs-submit-request <at> debbugs.gnu.org?subject=help> List-Subscribe: <https://debbugs.gnu.org/cgi-bin/mailman/listinfo/debbugs-submit>, <mailto:debbugs-submit-request <at> debbugs.gnu.org?subject=subscribe> Errors-To: debbugs-submit-bounces <at> debbugs.gnu.org Sender: "Debbugs-submit" <debbugs-submit-bounces <at> debbugs.gnu.org> X-Spam-Score: -1.0 (-) Eli Zaretskii <eliz@HIDDEN> writes: >> Date: Wed, 4 Dec 2024 22:25:32 +0100 >> Cc: monnier@HIDDEN, luangruo@HIDDEN, 74423 <at> debbugs.gnu.org >> From: Cecilio Pardo <cpardo@HIDDEN> >> >> On 04/12/2024 21:01, Eli Zaretskii wrote: >> >> + DEFVAR_LISP ("enable-low-level-key-events", Venable_low_level_key_events, >> >> + doc: /* If non-nil, reception of low-level key events is enabled. >> >> + >> >> +The value configures the set of keys that are handled: >> >> + >> >> +If t, send events for all keys. >> >> + >> >> +If a number, send events for the corresponding keysym. When calling >> >> +'llk-init', a set of variables with the xk- prefix is initialized with >> >> +the numeric values for keysyms. This numbers are platform dependent. >> > >> > This seems to say that it is impossible to make the value do the same >> > on all platforms? If so, I think it's less useful than it could be, >> > because Emacs generally tries to abstract platform-specific issues as >> > much as possible, to facilitate platform-independent Lisp programs >> > that work the same on all supported systems. >> > >> > Also, there's no information here where to find the list of these xk- >> > numbers. >> >> Those are variables, like xk-shift-l, xk-a, xk-f1. There is also >> llk-keysyms, that has a list of all xk-* symbols and their numeric values. >> >> llk-init initializes all of these variables, using numbers that are >> platform dependent (XK_* constant KeySyms for X, VK_* "virtual keys" for >> windows. GDK keys match X keys. >> >> Numbers are different, but users should use the variables, not the >> numbers, for binding and comparing to event values. > > This should be explicitly told in the doc string. Also, if the xk-* > variables are platform-independent, the rule to map their names to > keyboard keys should be explained somewhere, perhaps in the manual, so > that Lisp programmers could easily know how to identify the keys which > they stand for. > >> I can translate the Windows numbers to the X equivalents, so that they >> are equal on both platforms. > > I'm not sure this is needed, if the xk-* names are the same. > >> In any case, I will document this better, with a manual change >> proposal. > > Thanks. This facility definitely needs to be in the ELisp manual > before we install it. I suggest calling XKeysymToString rather than interning the numerical value of keysyms received. This gives users some indication of the identity of these keysyms without tediously referring to (at times vendor-specific) keysymdef.h files.
bug-gnu-emacs@HIDDEN
:bug#74423
; Package emacs
.
Full text available.Received: (at 74423) by debbugs.gnu.org; 5 Dec 2024 05:43:48 +0000 From debbugs-submit-bounces <at> debbugs.gnu.org Thu Dec 05 00:43:48 2024 Received: from localhost ([127.0.0.1]:37770 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from <debbugs-submit-bounces <at> debbugs.gnu.org>) id 1tJ4eR-0007vJ-PU for submit <at> debbugs.gnu.org; Thu, 05 Dec 2024 00:43:48 -0500 Received: from eggs.gnu.org ([209.51.188.92]:40458) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from <eliz@HIDDEN>) id 1tJ4eO-0007uw-MW for 74423 <at> debbugs.gnu.org; Thu, 05 Dec 2024 00:43:45 -0500 Received: from fencepost.gnu.org ([2001:470:142:3::e]) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from <eliz@HIDDEN>) id 1tJ4cB-0003AC-UB; Thu, 05 Dec 2024 00:41:27 -0500 DKIM-Signature: v=1; a=rsa-sha256; q=dns/txt; c=relaxed/relaxed; d=gnu.org; s=fencepost-gnu-org; h=References:Subject:In-Reply-To:To:From:Date: mime-version; bh=a3bEC1iroRYNkMH3JLrqAgX8+oFcHBmHcgriZfpmboQ=; b=pQSwtGBrG0by NX2NU+5+AkRE/U324frYRPEdOzVijNl6gU237tjoOofMANye8f3HG7DvFpASkT2yiI6DKEPQ5ILvd JJFMUIlMq0zlW3rEOpgKcl8VGysy/ESgWnkyLg3VTP90dvD97SYtHUWa3C64MuBq1njzGMv1KuxYW D/lwO419hSzfAywdDSEMcK6+mSJe6egvfCqAyy4PjckaVo15bRpm2eWuaNrfoerFPPhn/x97Tjfrb 88GgvExv+GrLEo/29p61StcIzfjewUQ6Q6R8ZF+m7RWuhRl3jNXP9bueY2z/LqRu5BgusJlgOx12D vGV1f15HS1I3ZX80F+Ayvw==; Date: Thu, 05 Dec 2024 07:41:24 +0200 Message-Id: <867c8ezny3.fsf@HIDDEN> From: Eli Zaretskii <eliz@HIDDEN> To: Cecilio Pardo <cpardo@HIDDEN> In-Reply-To: <162dada7-ad54-4ca5-8f11-d55dd6dccb3c@HIDDEN> (message from Cecilio Pardo on Wed, 4 Dec 2024 22:25:32 +0100) Subject: Re: bug#74423: Low level key events References: <fb50ec11-7aec-481e-8a3a-ecdcf22eb7c0@HIDDEN> <31bdc55d-8c13-4de0-9cef-bd6cc4fb033f@HIDDEN> <s1r8qtzsvbe.fsf@HIDDEN> <d5c72818-e907-43f5-853a-89ec01264157@HIDDEN> <jwv4j43jisn.fsf-monnier+emacs@HIDDEN> <705fabb8-1ea0-4894-8c32-05097ab822c9@HIDDEN> <jwvplmqtuh1.fsf-monnier+emacs@HIDDEN> <b0b914a0-b454-41b0-aa3d-d9e243c210f5@HIDDEN> <868qsvz07i.fsf@HIDDEN> <162dada7-ad54-4ca5-8f11-d55dd6dccb3c@HIDDEN> X-Spam-Score: -2.3 (--) X-Debbugs-Envelope-To: 74423 Cc: luangruo@HIDDEN, 74423 <at> debbugs.gnu.org, monnier@HIDDEN X-BeenThere: debbugs-submit <at> debbugs.gnu.org X-Mailman-Version: 2.1.18 Precedence: list List-Id: <debbugs-submit.debbugs.gnu.org> List-Unsubscribe: <https://debbugs.gnu.org/cgi-bin/mailman/options/debbugs-submit>, <mailto:debbugs-submit-request <at> debbugs.gnu.org?subject=unsubscribe> List-Archive: <https://debbugs.gnu.org/cgi-bin/mailman/private/debbugs-submit/> List-Post: <mailto:debbugs-submit <at> debbugs.gnu.org> List-Help: <mailto:debbugs-submit-request <at> debbugs.gnu.org?subject=help> List-Subscribe: <https://debbugs.gnu.org/cgi-bin/mailman/listinfo/debbugs-submit>, <mailto:debbugs-submit-request <at> debbugs.gnu.org?subject=subscribe> Errors-To: debbugs-submit-bounces <at> debbugs.gnu.org Sender: "Debbugs-submit" <debbugs-submit-bounces <at> debbugs.gnu.org> X-Spam-Score: -3.3 (---) > Date: Wed, 4 Dec 2024 22:25:32 +0100 > Cc: monnier@HIDDEN, luangruo@HIDDEN, 74423 <at> debbugs.gnu.org > From: Cecilio Pardo <cpardo@HIDDEN> > > On 04/12/2024 21:01, Eli Zaretskii wrote: > >> + DEFVAR_LISP ("enable-low-level-key-events", Venable_low_level_key_events, > >> + doc: /* If non-nil, reception of low-level key events is enabled. > >> + > >> +The value configures the set of keys that are handled: > >> + > >> +If t, send events for all keys. > >> + > >> +If a number, send events for the corresponding keysym. When calling > >> +'llk-init', a set of variables with the xk- prefix is initialized with > >> +the numeric values for keysyms. This numbers are platform dependent. > > > > This seems to say that it is impossible to make the value do the same > > on all platforms? If so, I think it's less useful than it could be, > > because Emacs generally tries to abstract platform-specific issues as > > much as possible, to facilitate platform-independent Lisp programs > > that work the same on all supported systems. > > > > Also, there's no information here where to find the list of these xk- > > numbers. > > Those are variables, like xk-shift-l, xk-a, xk-f1. There is also > llk-keysyms, that has a list of all xk-* symbols and their numeric values. > > llk-init initializes all of these variables, using numbers that are > platform dependent (XK_* constant KeySyms for X, VK_* "virtual keys" for > windows. GDK keys match X keys. > > Numbers are different, but users should use the variables, not the > numbers, for binding and comparing to event values. This should be explicitly told in the doc string. Also, if the xk-* variables are platform-independent, the rule to map their names to keyboard keys should be explained somewhere, perhaps in the manual, so that Lisp programmers could easily know how to identify the keys which they stand for. > I can translate the Windows numbers to the X equivalents, so that they > are equal on both platforms. I'm not sure this is needed, if the xk-* names are the same. > In any case, I will document this better, with a manual change > proposal. Thanks. This facility definitely needs to be in the ELisp manual before we install it.
bug-gnu-emacs@HIDDEN
:bug#74423
; Package emacs
.
Full text available.Received: (at 74423) by debbugs.gnu.org; 4 Dec 2024 21:25:41 +0000 From debbugs-submit-bounces <at> debbugs.gnu.org Wed Dec 04 16:25:41 2024 Received: from localhost ([127.0.0.1]:37083 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from <debbugs-submit-bounces <at> debbugs.gnu.org>) id 1tIwsO-0000Qb-IQ for submit <at> debbugs.gnu.org; Wed, 04 Dec 2024 16:25:40 -0500 Received: from mail.imayhem.com ([82.223.54.191]:42839 helo=zealous-pike.82-223-54-191.plesk.page) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from <cpardo@HIDDEN>) id 1tIwsL-0000QJ-Hq for 74423 <at> debbugs.gnu.org; Wed, 04 Dec 2024 16:25:38 -0500 Received: from [192.168.68.104] (111.red-88-21-7.staticip.rima-tde.net [88.21.7.111]) by zealous-pike.82-223-54-191.plesk.page (Postfix) with ESMTPSA id BFD0780108; Wed, 4 Dec 2024 21:25:31 +0000 (UTC) Authentication-Results: zealous-pike.82-223-54-191.plesk.page; spf=pass (sender IP is 88.21.7.111) smtp.mailfrom=cpardo@HIDDEN smtp.helo=[192.168.68.104] Received-SPF: pass (zealous-pike.82-223-54-191.plesk.page: connection is authenticated) Message-ID: <162dada7-ad54-4ca5-8f11-d55dd6dccb3c@HIDDEN> Date: Wed, 4 Dec 2024 22:25:32 +0100 MIME-Version: 1.0 User-Agent: Mozilla Thunderbird Subject: Re: bug#74423: Low level key events To: Eli Zaretskii <eliz@HIDDEN> References: <fb50ec11-7aec-481e-8a3a-ecdcf22eb7c0@HIDDEN> <31bdc55d-8c13-4de0-9cef-bd6cc4fb033f@HIDDEN> <s1r8qtzsvbe.fsf@HIDDEN> <d5c72818-e907-43f5-853a-89ec01264157@HIDDEN> <jwv4j43jisn.fsf-monnier+emacs@HIDDEN> <705fabb8-1ea0-4894-8c32-05097ab822c9@HIDDEN> <jwvplmqtuh1.fsf-monnier+emacs@HIDDEN> <b0b914a0-b454-41b0-aa3d-d9e243c210f5@HIDDEN> <868qsvz07i.fsf@HIDDEN> Content-Language: es-ES From: Cecilio Pardo <cpardo@HIDDEN> In-Reply-To: <868qsvz07i.fsf@HIDDEN> Content-Type: text/plain; charset=UTF-8; format=flowed Content-Transfer-Encoding: 7bit X-Spam-Score: 0.0 (/) X-Debbugs-Envelope-To: 74423 Cc: luangruo@HIDDEN, 74423 <at> debbugs.gnu.org, monnier@HIDDEN X-BeenThere: debbugs-submit <at> debbugs.gnu.org X-Mailman-Version: 2.1.18 Precedence: list List-Id: <debbugs-submit.debbugs.gnu.org> List-Unsubscribe: <https://debbugs.gnu.org/cgi-bin/mailman/options/debbugs-submit>, <mailto:debbugs-submit-request <at> debbugs.gnu.org?subject=unsubscribe> List-Archive: <https://debbugs.gnu.org/cgi-bin/mailman/private/debbugs-submit/> List-Post: <mailto:debbugs-submit <at> debbugs.gnu.org> List-Help: <mailto:debbugs-submit-request <at> debbugs.gnu.org?subject=help> List-Subscribe: <https://debbugs.gnu.org/cgi-bin/mailman/listinfo/debbugs-submit>, <mailto:debbugs-submit-request <at> debbugs.gnu.org?subject=subscribe> Errors-To: debbugs-submit-bounces <at> debbugs.gnu.org Sender: "Debbugs-submit" <debbugs-submit-bounces <at> debbugs.gnu.org> X-Spam-Score: -1.0 (-) On 04/12/2024 21:01, Eli Zaretskii wrote: >> + DEFVAR_LISP ("enable-low-level-key-events", Venable_low_level_key_events, >> + doc: /* If non-nil, reception of low-level key events is enabled. >> + >> +The value configures the set of keys that are handled: >> + >> +If t, send events for all keys. >> + >> +If a number, send events for the corresponding keysym. When calling >> +'llk-init', a set of variables with the xk- prefix is initialized with >> +the numeric values for keysyms. This numbers are platform dependent. > > This seems to say that it is impossible to make the value do the same > on all platforms? If so, I think it's less useful than it could be, > because Emacs generally tries to abstract platform-specific issues as > much as possible, to facilitate platform-independent Lisp programs > that work the same on all supported systems. > > Also, there's no information here where to find the list of these xk- > numbers. Those are variables, like xk-shift-l, xk-a, xk-f1. There is also llk-keysyms, that has a list of all xk-* symbols and their numeric values. llk-init initializes all of these variables, using numbers that are platform dependent (XK_* constant KeySyms for X, VK_* "virtual keys" for windows. GDK keys match X keys. Numbers are different, but users should use the variables, not the numbers, for binding and comparing to event values. I can translate the Windows numbers to the X equivalents, so that they are equal on both platforms. In any case, I will document this better, with a manual change proposal.
bug-gnu-emacs@HIDDEN
:bug#74423
; Package emacs
.
Full text available.Received: (at 74423) by debbugs.gnu.org; 4 Dec 2024 20:02:08 +0000 From debbugs-submit-bounces <at> debbugs.gnu.org Wed Dec 04 15:02:08 2024 Received: from localhost ([127.0.0.1]:36972 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from <debbugs-submit-bounces <at> debbugs.gnu.org>) id 1tIvZY-0004dB-Cl for submit <at> debbugs.gnu.org; Wed, 04 Dec 2024 15:02:08 -0500 Received: from eggs.gnu.org ([209.51.188.92]:57954) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from <eliz@HIDDEN>) id 1tIvZV-0004cc-TB for 74423 <at> debbugs.gnu.org; Wed, 04 Dec 2024 15:02:06 -0500 Received: from fencepost.gnu.org ([2001:470:142:3::e]) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from <eliz@HIDDEN>) id 1tIvZM-0007Bn-Uk; Wed, 04 Dec 2024 15:01:58 -0500 DKIM-Signature: v=1; a=rsa-sha256; q=dns/txt; c=relaxed/relaxed; d=gnu.org; s=fencepost-gnu-org; h=References:Subject:In-Reply-To:To:From:Date: mime-version; bh=VaJGnGERExV7SU0TEX1sxXtZ62ytI+bhJWmeUDGxmDI=; b=hIJXRoQuZc+B 36SFQjqlWwK8utc9F+01624SvVf2ngEDUTmjj508MXweblxIqpG1Yv8tEebGmMEdAg5ul0UZ5zh67 w+W6K1XWyNKNKjIKb5yubSwJndEBIkAZo2LyFsgDQblP+p8ITEkcuUgb0MmiFgPOhtVeG/RXRQphN 9ABbfGC0O8XRwOmL8b0iwaZOeqjM7F1TzlrQdCbRd+1nt6NJnIBvLE3GvkRvhMSCUG1V5bwDRKrFp 6aUL3BFZfxDQNrqu5YGov8X7mpV+35X0RVXx4EZlm5ag08ozRoOqwmGBkABa2lWSL9qRiR7OV6vqN X1yj8OCwgQdsBxzWSmWWhw==; Date: Wed, 04 Dec 2024 22:01:53 +0200 Message-Id: <868qsvz07i.fsf@HIDDEN> From: Eli Zaretskii <eliz@HIDDEN> To: Cecilio Pardo <cpardo@HIDDEN> In-Reply-To: <b0b914a0-b454-41b0-aa3d-d9e243c210f5@HIDDEN> (message from Cecilio Pardo on Mon, 2 Dec 2024 17:54:03 +0100) Subject: Re: bug#74423: Low level key events References: <fb50ec11-7aec-481e-8a3a-ecdcf22eb7c0@HIDDEN> <31bdc55d-8c13-4de0-9cef-bd6cc4fb033f@HIDDEN> <s1r8qtzsvbe.fsf@HIDDEN> <d5c72818-e907-43f5-853a-89ec01264157@HIDDEN> <jwv4j43jisn.fsf-monnier+emacs@HIDDEN> <705fabb8-1ea0-4894-8c32-05097ab822c9@HIDDEN> <jwvplmqtuh1.fsf-monnier+emacs@HIDDEN> <b0b914a0-b454-41b0-aa3d-d9e243c210f5@HIDDEN> X-Spam-Score: -2.3 (--) X-Debbugs-Envelope-To: 74423 Cc: luangruo@HIDDEN, 74423 <at> debbugs.gnu.org, monnier@HIDDEN X-BeenThere: debbugs-submit <at> debbugs.gnu.org X-Mailman-Version: 2.1.18 Precedence: list List-Id: <debbugs-submit.debbugs.gnu.org> List-Unsubscribe: <https://debbugs.gnu.org/cgi-bin/mailman/options/debbugs-submit>, <mailto:debbugs-submit-request <at> debbugs.gnu.org?subject=unsubscribe> List-Archive: <https://debbugs.gnu.org/cgi-bin/mailman/private/debbugs-submit/> List-Post: <mailto:debbugs-submit <at> debbugs.gnu.org> List-Help: <mailto:debbugs-submit-request <at> debbugs.gnu.org?subject=help> List-Subscribe: <https://debbugs.gnu.org/cgi-bin/mailman/listinfo/debbugs-submit>, <mailto:debbugs-submit-request <at> debbugs.gnu.org?subject=subscribe> Errors-To: debbugs-submit-bounces <at> debbugs.gnu.org Sender: "Debbugs-submit" <debbugs-submit-bounces <at> debbugs.gnu.org> X-Spam-Score: -3.3 (---) > Date: Mon, 2 Dec 2024 17:54:03 +0100 > Cc: 74423 <at> debbugs.gnu.org > From: Cecilio Pardo <cpardo@HIDDEN> > > Here is a new version of the patch. Sorry it took so long. It > addresses most of the notes I got: Thanks. There are several minor issues with this (first line of doc strings not a single complete sentence, one space between sentences, etc.), but I guess this is too early for such details. Other than that, I have only one comment: > + DEFVAR_LISP ("enable-low-level-key-events", Venable_low_level_key_events, > + doc: /* If non-nil, reception of low-level key events is enabled. > + > +The value configures the set of keys that are handled: > + > +If t, send events for all keys. > + > +If a number, send events for the corresponding keysym. When calling > +'llk-init', a set of variables with the xk- prefix is initialized with > +the numeric values for keysyms. This numbers are platform dependent. This seems to say that it is impossible to make the value do the same on all platforms? If so, I think it's less useful than it could be, because Emacs generally tries to abstract platform-specific issues as much as possible, to facilitate platform-independent Lisp programs that work the same on all supported systems. Also, there's no information here where to find the list of these xk- numbers.
bug-gnu-emacs@HIDDEN
:bug#74423
; Package emacs
.
Full text available.Received: (at 74423) by debbugs.gnu.org; 2 Dec 2024 16:54:19 +0000 From debbugs-submit-bounces <at> debbugs.gnu.org Mon Dec 02 11:54:19 2024 Received: from localhost ([127.0.0.1]:56362 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from <debbugs-submit-bounces <at> debbugs.gnu.org>) id 1tI9ge-00033s-GQ for submit <at> debbugs.gnu.org; Mon, 02 Dec 2024 11:54:18 -0500 Received: from mail.imayhem.com ([82.223.54.191]:36863 helo=zealous-pike.82-223-54-191.plesk.page) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from <cpardo@HIDDEN>) id 1tI9gY-000333-IW for 74423 <at> debbugs.gnu.org; Mon, 02 Dec 2024 11:54:13 -0500 Received: from [192.168.68.104] (111.red-88-21-7.staticip.rima-tde.net [88.21.7.111]) by zealous-pike.82-223-54-191.plesk.page (Postfix) with ESMTPSA id DB4AF80147; Mon, 2 Dec 2024 16:54:04 +0000 (UTC) Authentication-Results: zealous-pike.82-223-54-191.plesk.page; spf=pass (sender IP is 88.21.7.111) smtp.mailfrom=cpardo@HIDDEN smtp.helo=[192.168.68.104] Received-SPF: pass (zealous-pike.82-223-54-191.plesk.page: connection is authenticated) Content-Type: multipart/mixed; boundary="------------kdIRyaCiBUPUB4DSQ0iPV24t" Message-ID: <b0b914a0-b454-41b0-aa3d-d9e243c210f5@HIDDEN> Date: Mon, 2 Dec 2024 17:54:03 +0100 MIME-Version: 1.0 User-Agent: Mozilla Thunderbird Subject: Re: bug#74423: Low level key events To: Stefan Monnier <monnier@HIDDEN>, Eli Zaretskii <eliz@HIDDEN>, Po Lu <luangruo@HIDDEN> References: <fb50ec11-7aec-481e-8a3a-ecdcf22eb7c0@HIDDEN> <31bdc55d-8c13-4de0-9cef-bd6cc4fb033f@HIDDEN> <s1r8qtzsvbe.fsf@HIDDEN> <d5c72818-e907-43f5-853a-89ec01264157@HIDDEN> <jwv4j43jisn.fsf-monnier+emacs@HIDDEN> <705fabb8-1ea0-4894-8c32-05097ab822c9@HIDDEN> <jwvplmqtuh1.fsf-monnier+emacs@HIDDEN> Content-Language: es-ES From: Cecilio Pardo <cpardo@HIDDEN> In-Reply-To: <jwvplmqtuh1.fsf-monnier+emacs@HIDDEN> X-Spam-Score: 0.0 (/) X-Debbugs-Envelope-To: 74423 Cc: 74423 <at> debbugs.gnu.org X-BeenThere: debbugs-submit <at> debbugs.gnu.org X-Mailman-Version: 2.1.18 Precedence: list List-Id: <debbugs-submit.debbugs.gnu.org> List-Unsubscribe: <https://debbugs.gnu.org/cgi-bin/mailman/options/debbugs-submit>, <mailto:debbugs-submit-request <at> debbugs.gnu.org?subject=unsubscribe> List-Archive: <https://debbugs.gnu.org/cgi-bin/mailman/private/debbugs-submit/> List-Post: <mailto:debbugs-submit <at> debbugs.gnu.org> List-Help: <mailto:debbugs-submit-request <at> debbugs.gnu.org?subject=help> List-Subscribe: <https://debbugs.gnu.org/cgi-bin/mailman/listinfo/debbugs-submit>, <mailto:debbugs-submit-request <at> debbugs.gnu.org?subject=subscribe> Errors-To: debbugs-submit-bounces <at> debbugs.gnu.org Sender: "Debbugs-submit" <debbugs-submit-bounces <at> debbugs.gnu.org> X-Spam-Score: -1.0 (-) This is a multi-part message in MIME format. --------------kdIRyaCiBUPUB4DSQ0iPV24t Content-Type: text/plain; charset=UTF-8; format=flowed Content-Transfer-Encoding: 7bit Here is a new version of the patch. Sorry it took so long. It addresses most of the notes I got: Notes by Po Lu: - I think now the associated modifier for a key is computed properly, with or without XKB for plain X, and for gtk. - 'ralt' not generated for ISO_Level3_Shift. This will have to stay like this. What we know about the keys if what the system lets us. - Don't call x_any_window_to_frame if already called for the event. Notes by Eli: - Change testing for Venable_low_level_key_events. This variable now is more complex. Notes by Stefan: - Created and used event-* functions to access event. - Only one event with both pieces of information. - Selection of keys. Now the variable enable-low-level-key-events can be used to select exactly which keys we want to process. - About creating lisp object in handle_one_xevent, it is done in other events too. The lisp interface is as follows: - A list of variables with keysym values is initialized (xk-*), so the user can select keys, not just modifiers. - Users can bind globally commands or functions with llk-bind to taps. - To use a tapped key as a new modifier, this works: (llk-bind 'tap 'xk-shift-r (lambda () (message "H-...") (setq unread-command-events (append (event-apply-hyper-modifier nil) nil)))) - Added the function describe-low-level-key to see what keysym/modifier it triggers. This is implemented for X, pgtkw and MS-Windows. The pgtj implementation detects that a key is a modifier to filter it, but can't decide which one it its. --------------kdIRyaCiBUPUB4DSQ0iPV24t Content-Type: text/plain; charset=UTF-8; name="0001-Send-event-for-key-presses-and-key-releases.patch" Content-Disposition: attachment; filename="0001-Send-event-for-key-presses-and-key-releases.patch" Content-Transfer-Encoding: base64 RnJvbSA4NjMwNjhmNGUxZTE4N2JhMzMzODJjMG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QgaGlzdG9yeSBmb3IgdGFwIGRldGVjdGlvbi4KKGxsay1kZXRlY3Qtbi10 YXApOiBGdW5jdGlvbiB0byBkZXRlY3QgdGFwcy4KKGRlc2NyaWJlLWxvdy1sZXZlbC1rZXkp OiBDb21tYW5kIHRvIGdldCBpbmZvcm1hdGlvbiBhYm91dCBhIGtleS4KKGxsay1zaG93LWV2 ZW50LWRlc2NyaXB0aW9uKTogU2hvdyBoZWxwIGJ1ZmZlciB3aXRoIGluZm9ybWF0aW9uCmFi b3V0IGFuIGV2ZW50LgoobGxrLWhhbmRsZSk6IEhhbmRsZXIgZm9yIGtleSBldmVudHMuCi0t LQogbGlzcC9sb3ctbGV2ZWwta2V5LmVsIHwgMzM1ICsrKysrKysrKysrKysrKysrKysrKysr KysrKysrKysrKysrKysrKysrKwogc3JjL2d0a3V0aWwuYyAgICAgICAgIHwgIDgxICsrKysr KysrKysKIHNyYy9rZXlib2FyZC5jICAgICAgICB8ICA2MSArKysrKysrKwogc3JjL2tleWJv YXJkLmggICAgICAgIHwgICAxICsKIHNyYy9wZ3RrdGVybS5jICAgICAgICB8ICA1NSArKysr KysrCiBzcmMvdGVybWhvb2tzLmggICAgICAgfCAgIDEgKwogc3JjL3czMmZucy5jICAgICAg ICAgIHwgIDExICsrCiBzcmMvdzMydGVybS5jICAgICAgICAgfCAgNDkgKysrKysrCiBzcmMv dzMydGVybS5oICAgICAgICAgfCAgIDMgKy0KIHNyYy94dGVybS5jICAgICAgICAgICB8IDE0 MiArKysrKysrKysrKysrKysrKysKIHNyYy94dGVybS5oICAgICAgICAgICB8ICAgMiArCiAx MSBmaWxlcyBjaGFuZ2VkLCA3NDAgaW5zZXJ0aW9ucygrKSwgMSBkZWxldGlvbigtKQogY3Jl YXRlIG1vZGUgMTAwNjQ0IGxpc3AvbG93LWxldmVsLWtleS5lbAoKZGlmZiAtLWdpdCBhL2xp c3AvbG93LWxldmVsLWtleS5lbCBiL2xpc3AvbG93LWxldmVsLWtleS5lbApuZXcg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4ICN4NjgpIDs7IFhLX0tQXzgg VktfTlVNUEFEOAorICAoZGVmaW5lLXhrIHhrLWtwLTkgICAgICAgICN4ZmZiOSAjeDY5KSA7 OyBYS19LUF85IFZLX05VTVBBRDkKKworICA7OyBGdW5jdGlvbiBrZXlzCisgIChkZWZpbmUt eGsgeGstZjEgICAgICAgICAgI3hmZmJlICN4NzApIDs7IFhLX0YxIFZLX0YxCisgIChkZWZp bmUteGsgeGstZjIgICAgICAgICAgI3hmZmJmICN4NzEpIDs7IFhLX0YyIFZLX0YyCisgIChk ZWZpbmUteGsgeGstZjMgICAgICAgICAgI3hmZmMwICN4NzIpIDs7IFhLX0YzIFZLX0YzCisg IChkZWZpbmUteGsgeGstZjQgICAgICAgICAgI3hmZmMxICN4NzMpIDs7IFhLX0Y0IFZLX0Y0 CisgIChkZWZpbmUteGsgeGstZjUgICAgICAgICAgI3hmZmMyICN4NzQpIDs7IFhLX0Y1IFZL X0Y1CisgIChkZWZpbmUteGsgeGstZjYgICAgICAgICAgI3hmZmMzICN4NzUpIDs7IFhLX0Y2 IFZLX0Y2CisgIChkZWZpbmUteGsgeGstZjcgICAgICAgICAgI3hmZmM0ICN4NzYpIDs7IFhL X0Y3IFZLX0Y3CisgIChkZWZpbmUteGsgeGstZjggICAgICAgICAgI3hmZmM1ICN4NzcpIDs7 IFhLX0Y4IFZLX0Y4CisgIChkZWZpbmUteGsgeGstZjkgICAgICAgICAgI3hmZmM2ICN4Nzgp IDs7IFhLX0Y5IFZLX0Y5CisgIChkZWZpbmUteGsgeGstZjEwICAgICAgICAgI3hmZmM3ICN4 NzkpIDs7IFhLX0YxMCBWS19GMTAKKyAgKGRlZmluZS14ayB4ay1mMTEgICAgICAgICAjeGZm YzggI3g3QSkgOzsgWEtfRjExIFZLX0YxMQorICAoZGVmaW5lLXhrIHhrLWYxMiAgICAgICAg ICN4ZmZjOSAjeDdCKSA7OyBYS19GMTIgVktfRjEyCisgIChkZWZpbmUteGsgeGstZjEzICAg ICAgICA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QorICA7OyBsZXR0ZXJzLiBXZSB1 c2Ugb25seSB0aGUgdXBwZXJjYXNlIG9uZXMuIEV2ZW50cyB3aXRoIGxvd2VyY2FzZQorICA7 OyBsZXR0ZXJzIGFyZSBjb252ZXJ0ZWQgdG8gdXBwZXJjYXNlLgorICAoZGVmaW5lLXhrIHhr LXNwYWNlICAgICAgICN4MDAyMCAjeDIwKSA7OyBYS19zcGFjZSBWS19TUEFDRQorICAoZGVm aW5lLXhrIHhrLTAgICAgICAgICAgICN4MDAzMCAjeDMwKSA7OyBYS18wCisgIChkZWZpbmUt eGsgeGstMSAgICAgICAgICAgI3gwMDMxICN4MzEpIDs7IFhLXzEKKyAgKGRlZmluZS14ayB4 ay0yICAgICAgICAgICAjeDAwMzIgI3gzMikgOzsgWEtfMgorICAoZGVmaW5lLXhrIHhrLTMg ICAgICAgICAgICN4MDAzMyAjeDMzKSA7OyBYS18zCisgIChkZWZpbmUteGsgeGstNCAgICAg ICAgICAgI3gwMDM0ICN4MzQpIDs7IFhLXzQKKyAgKGRlZmluZS14ayB4ay01ICAgICAgICAg ICAjeDAwMzUgI3gzNSkgOzsgWEtfNQorICAoZGVmaW5lLXhrIHhrLTYgICAgICAgICAgICN4 MDAzNiAjeDM2KSA7OyBYS182CisgIChkZWZpbmUteGsgeGstNyAgICAgICAgICAgI3gwMDM3 ICN4MzcpIDs7IFhLXzcKKyAgKGRlZmluZS14ayB4ay04ICAgICAgICAgICAjeDAwMzggI3gz OCkgOzsgWEtfOAorICAoZGVmaW5lLXhrIHhrLTkgICAgICAgICAgICN4MDAzOSAjeDM5KSA7 OyBYS185CisgIChkZWZpbmUteGsgeGstYSAgICAgICAgICAgI3gwMDQxICN4NDEpIDs7IFhL X0EKKyAgKGRlZmluZS14ayB4ay1iICAgICAgICAgICAjeDAwNDIgI3g0MikgOzsgWEtfQgor ICAoZGVmaW5lLXhrIHhrLWMgICAgICAgICAgICN4MDA0MyAjeDQzKSA7OyBYS19DCisgIChk ZWZpbmUteGsgeGstZCAgICAgICAgICAgI3gwMDQ0ICN4NDQpIDs7IFhLX0QKKyAgKGRlZmlu ZS14ayB4ay1lICAgICAgICAgICAjeDAwNDUgI3g0NSkgOzsgWEtfRQorICAoZGVmaW5lLXhr IHhrLWYgICAgICAgICAgICN4MDA0NiAjeDQ2KSA7OyBYS19GCisgIChkZWZpbmUteGsgeGst ZyAgICAgICAgICAgI3gwMDQ3ICN4NDcpIDs7IFhLX0cKKyAgKGRlZmluZS14ayB4ay1oICAg ICAgICAgICAjeDAwNDggI3g0OCkgOzsgWEtfSAorICAoZGVmaW5lLXhrIHhrLWkgICAgICAg ICAgICN4MDA0OSAjeDQ5KSA7OyBYS19JCisgIChkZWZpbmUteGsgeGstaiAgICAgICAgICAg I3gwMDRBICN4NEEpIDs7IFhLX0oKKyAgKGRlZmluZS14ayB4ay1rICAgICAgICAgICAjeDAw NEIgI3g0QikgOzsgWEtfSworICAoZGVmaW5lLXhrIHhrLWwgICAgICAgICAgICN4MDA0QyAj eDRDKSA7OyBYS19MCisgIChkZWZpbmUteGsgeGstbSAgICAgICAgICAgI3gwMDREICN4NEQp IDs7IFhLX00KKyAgKGRlZmluZS14ayB4ay1uICAgICAgICAgICAjeDAwNEUgI3g0RSkgOzsg WEtfTgorICAoZGVmaW5lLXhrIHhrLW8gICAgICAgICAgICN4MDA0RiAjeDRGKSA7OyBYS19P CisgIChkZWZpbmUteGsgeGstcCAgICAgICAgICAgI3gwMDUwICN4NTApIDs7IFhLX1AKKyAg KGRlZmluZS14ayB4ay1xICAgICAgICAgICAjeDAwNTEgI3g1MSkgOzsgWEtfUQorICAoZGVm aW5lLXhrIHhrLXIgICAgICAgICAgICN4MDA1MiAjeDUyKSA7OyBYS19SCisgIChkZWZpbmUt eGsgeGstcyAgICAgICAgICAgI3gwMDUzICN4NTMpIDs7IFhLX1MKKyAgKGRlZmluZS14ayB4 ay10ICAgICAgICAgICAjeDAwNTQgI3g1NCkgOzsgWEtfVAorICAoZGVmaW5lLXhrIH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yBCaW5kIHRhcCB0byBoeXBlciBtb2RpZmllcgorOzsgICAg ICAobGxrLWJpbmQgJ3RhcCAneGstc2hpZnQtciAobGFtYmRhICgpCis7OyAgICAgICAgICAg ICAgICAgICAgICAgICAgICAgIChtZXNzYWdlICJILS4uLiIpCis7OyAgICAgICAgICAgICAg ICAgICAgICAgICAgICAgIChzZXRxIHVucmVhZC1jb21tYW5kLWV2ZW50cworOzsgICAgICAg ICAgICAgICAgICAgICAgICAgICAgICAgICAgICAoYXBwZW5kIChldmVudC1hcHBseS1oeXBl ci1tb2RpZmllciBuaWwpIG5pbCkpKSkKKzs7IENhbiBiaW5kIHRvIGEgY29tbWFuZCBvciBm dW5jdGlvbgorKGRlZnVuIGxsay1iaW5kIChhY3Rpb24ga2V5IGZ1bmN0aW9uKQorICAiQmlu ZCBhIGNvbW1hbmQgYSBmdW5jdGlvbiB0byBhIGxvdyBsZXZlbCBrZXkgZXZlbnQuCitUaGUg b25seSBhY3Rpb24gc3VwcG9ydGVkIGN1cnJlbnRseSBpcyBgdGFwJy4gVGhlIGtleSBjYW4g YmUgYSBrZXlzeW0KK3N5bWJvbCwgb3IgYSBtb2RpZmllciBzeW1ib2wgKHNoaWZ0LCBjb250 cm9sLCBhbHQsIG1ldGEsIGh5cGVyLCBzdXBlcikuCitJZiB0aGVyZSBpcyBubyBrZXlzeW0g c3ltYm9sIGZvciBhIGtleSwgdXNlIHRoZSBrZXlzeW0gbnVtYmVyLiAgIgorICAocHVzaCAo bGlzdCBhY3Rpb24ga2V5IGZ1bmN0aW9uKSBsbGstYmluZGluZ3MpKQorCis7OyBXZSBzdG9y ZSB0aGUgbGFzdCBldmVudHMgKGtleS9tb2RpZmllciBpcy1wcmVzcyB0aW1lc3RhbXApIGhl cmUgdG8KKzs7IHRlc3QgZm9yIG11bHRpdGFwLgorKGRlZnZhciBsbGstZXZlbnRzIG5pbAor ICAiSW50ZXJuYWwgdmFyaWFibGUgZm9yIGRldGVjdGluZyB0YXBzLiIpCisKKzs7IElmIHBv c2l0aXZlLCByZXR1cm4ga2V5ICh4ay1zaGlmdC1sLCBldGMpIGVsc2UgcmV0dXJuIG5pbC4K KyhkZWZ1biBsbGstZGV0ZWN0LW4tdGFwIChuIHRpbWVvdXQpCisgICJJbnRlcm5hbCBmdW5j dGlvbiB0byBkZXRlY3Qgbi10YXAga2V5cy4iCisgIChsZXQgKGtleQorICAgICAgICAoaXMt cHJlc3MgKGV2ZW50LWlzLWtleS1wcmVzcyBsYXN0LWlucHV0LWV2ZW50KSkKKyAgICAgICAg OzsgY29udmVydCBudW1iZXIgdG8ga2V5c3ltIHN5bWJvbAorICAgICAgICAoa2V5c3ltIChj ZHIgKGFzc29jIChldmVudC1rZXlzeW0gbGFzdC1pbnB1dC1ldmVudCkgbGxrLWtleXN5bXMp KSkKKyAgICAgICAgKHRpbWVzdGFtcCAoZXZlbnQtdGltZSBsYXN0LWlucHV0LWV2ZW50KSkK KyAgICAgICAgKG1vZGlmaWVyIChldmVudC1tb2RpZmllciBsYXN0LWlucHV0LWV2ZW50KSkp CisKKyAgICA7OyBpZiBlaHRlIGlzIG5vIHN5bWJvbCBmb3IgdGhpcyBrZXksIHVzZSBpdHMg a2V5c3ltIG51bWJlcgorICAgICh1bmxlc3Mga2V5c3ltIChzZXRxIGtleXN5bSAoZXZlbnQt a2V5c3ltIGxhc3QtaW5wdXQtZXZlbnQpKSkKKworICAgIDs7IGxvb2sgaW4gbGxrLXRhcC1r ZXlzIGZvciB0aGUga2V5LCB0aGVuIHRoZSBtb2RpZmllcgorICAgIChpZiAobWVtYmVyIGtl eXN5bSBsbGstdGFwLWtleXMpCisgICAgICAgIChzZXRxIGtleSBrZXlzeW0pCisgICAgICAo aWYgKG1lbWJlciBtb2RpZmllciBsbGstdGFwLWtleXMpCisgICAgICAgICAgKHNldHEga2V5 IG1vZGlmaWVyKSkpCisKKyAgICAoaWYgKG5vdCBrZXkpCisgICAgICAgIDs7IEtleSBub3Qg aW4gdGFwIGxpc3QsIGNsZWFyIGhpc3RvcnkKKyAgICAgICAgKHNldHEgbGxrLWV2ZW50cyBu aWwpCisgICAgICA7OyBDbGVhciBpdCBhbHNvIGlmIHRoZSBmaXJzdCBlbGVtZW50IGlzIGZy b20gYSBkaWZmZXJlbnQga2V5CisgICAgICAoYW5kIGxsay1ldmVudHMKKyAgICAgICAgICAg KG5vdCAoZXF1YWwgKGNhciAoY2FyIGxsay1ldmVudHMpKSBrZXkpKQorICAgICAgICAgICAo c2V0cSBsbGstZXZlbnRzIG5pbCkpCisgICAgICAocHVzaCAobGlzdCBrZXkgaXMtcHJlc3Mg dGltZXN0YW1wKSBsbGstZXZlbnRzKQorICAgICAgOzsgT25seSBjYXJlIGFib3V0IGxhc3Qg MnhOIGV2ZW50cworICAgICAgKG50YWtlICgqIDIgbikgbGxrLWV2ZW50cykKKyAgICAgIDs7 IElmIHdlIGhhdmU6CisgICAgICA7OyAtIEV4YWN0bHkgMiAqIG4gZXZlbnRzLgorICAgICAg OzsgLSBkb3duLCB1cCwgZG93biwgdXAsIC4uLgorICAgICAgOzsgLSBub3QgdHdvIG11Y2gg dGltZSBiZXR3ZWVuIGZpcnN0IGFuZCBsYXN0CisgICAgICAoYW5kIChlcSAoKiAyIG4pIChs ZW5ndGggbGxrLWV2ZW50cykpCisgICAgICAgICAgIChjbC1ldmVyeSAnZXEKKyAgICAgICAg ICAgICAgICAgICAgIChudGFrZSAoKiAyIG4pCisgICAgICAgICAgICAgICAgICAgICAgICAg ICAgKGxpc3QgbmlsIHQgbmlsIHQgbmlsIHQgbmlsIHQKKyAgICAgICAgICAgICAgICAgICAg ICAgICAgICAgICAgICBuaWwgdCBuaWwgdCBuaWwgdCBuaWwgdCkpCisgICAgICAgICAgICAg ICAgICAgICAobWFwY2FyICdjbC1zZWNvbmQgbGxrLWV2ZW50cykpCisgICAgICAgICAgICg8 ICgtIChjbC10aGlyZCAoY2wtZmlyc3QgbGxrLWV2ZW50cykpCisgICAgICAgICAgICAgICAg IChjbC10aGlyZCAoY2FyIChsYXN0IGxsay1ldmVudHMpKSkpCisgICAgICAgICAgICAgIHRp bWVvdXQpCisgICAgICAgICAgIChwcm9nbgorICAgICAgICAgICAgIChzZXRxIGxsay1ldmVu dHMgbmlsKQorICAgICAgICAgICAgIGtleSkpKSkpCisKKyhkZWZ1biBkZXNjcmliZS1sb3ct bGV2ZWwta2V5ICgpCisgICJXYWl0IGZvciB0aGUgbmV4dCBrZXkgcHJlc3MgYW5kIGRlc2Ny aWJlIHRoZSBsb3cgbGV2ZWwga2V5IGV2ZW50IGl0CitnZW5lcmF0ZXMuIgorICAoaW50ZXJh Y3RpdmUpCisgIChzZXRxIGxsay1kZXNjcmliZS1uZXh0LXByZXNzIHQpKQorCisoZGVmdW4g bGxrLXNob3ctZXZlbnQtZGVzY3JpcHRpb24gKCkKKyAgIlNob2UgaW5mb3JtYXRpb24gYWJv dXQgdGhlIGxhc3QgbG93IGxldmVsIGtleSBldmVudC4iCisgIChzZXRxIGxsay1kZXNjcmli ZS1uZXh0LXByZXNzIG5pbCkKKyAgKHdpdGgtaGVscC13aW5kb3cgKGhlbHAtYnVmZmVyKQor ICAgIChpbnNlcnQgIlxuIikKKyAgICAobGV0KiAoKHhrIChldmVudC1rZXlzeW0gbGFzdC1p bnB1dC1ldmVudCkpCisgICAgICAgICAgIChzeW0gKGFzc29jIHhrIGxsay1rZXlzeW1zKSkp CisgICAgICAoaW5zZXJ0IChmb3JtYXQgIktleXN5bSBudW1iZXI6ICVkICgjeCVYKSxcbiIg eGsgeGspKQorICAgICAgKGlmIHN5bQorICAgICAgICAgIChpbnNlcnQgKGZvcm1hdCAid2hp Y2ggY29ycmVzcG9uZHMgdG8gbmFtZWQga2V5ICVzLlxuXG4iIChjZHIgc3ltKSkpCisgICAg ICAgIChpbnNlcnQgIndoaWNoIGRvZXMgbm90IGNvcnJlc3BvbmQgdG8gYW55IGtub3duIG5h bWVkIGtleS5cblxuIikpCisgICAgICAoaWYgKGV2ZW50LW1vZGlmaWVyIGxhc3QtaW5wdXQt ZXZlbnQpCisgICAgICAgICAgKGluc2VydCAoZm9ybWF0ICJUaGlzIGtleSBjb3JyZXNwb25k cyB0byB0aGUgJXMgbW9kaWZpZXIuXG5cbiIKKyAgICAgICAgICAgICAgICAgICAgICAgICAg KGV2ZW50LW1vZGlmaWVyIGxhc3QtaW5wdXQtZXZlbnQpKSkKKyAgICAgICAgKGluc2VydCAi VGhpcyBrZXkgZG9lcyBub3QgY29ycmVzcG9uZCB0byBhIG1vZGlmaWVyLlxuXG4iKSkKKyAg ICAgIChpbnNlcnQgIlNlZSB0aGUgdmFsdWUgb2YgdGhlIGBsbGsta2V5c3ltcycgdmFyaWFi bGUgZm9yIGEgbGlzdCBvZiBrbm93biBrZXlzLlxuIikpKSkKKworKGRlZnVuIGxsay1oYW5k bGUgKCkKKyAgIkludGVybmFsIGZ1bmN0aW9uIHRvIGhhbmRsZSBsb3cgbGV2ZWwga2V5IGV2 ZW50cy4iCisgIChpbnRlcmFjdGl2ZSkKKyAgKGlmIChhbmQgKGV2ZW50LWlzLWtleS1wcmVz cyBsYXN0LWlucHV0LWV2ZW50KQorICAgICAgICAgICBsbGstZGVzY3JpYmUtbmV4dC1wcmVz cykKKyAgICAgIChsbGstc2hvdy1ldmVudC1kZXNjcmlwdGlvbikKKyAgICAobGV0ICgodGFw LWtleSAobGxrLWRldGVjdC1uLXRhcAorICAgICAgICAgICAgICAgICAgICBsbGstdGFwLWNv dW50CisgICAgICAgICAgICAgICAgICAgIGxsay10YXAtdGltZW91dCkpKQorICAgICAgKHdo ZW4gdGFwLWtleQorICAgICAgICAobGV0ICgoZnVuYyAoY2wtdGhpcmQKKyAgICAgICAgICAg ICAgICAgICAgIChzZXEtZmluZAorICAgICAgICAgICAgICAgICAgICAgIChsYW1iZGEgKGIp CisgICAgICAgICAgICAgICAgICAgICAgICAoYW5kIChlcSAoY2wtZmlyc3QgYikgJ3RhcCkK KyAgICAgICAgICAgICAgICAgICAgICAgICAgICAgKGVxIChjbC1zZW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amVj dCBrZXksIG1vZGlmaWVyOworICB1bmlvbiBidWZmZXJlZF9pbnB1dF9ldmVudCBpbmV2Owor CisgIGlmIChOSUxQIChWZW5hYmxlX2xvd19sZXZlbF9rZXlfZXZlbnRzKSkKKyAgICByZXR1 cm47CisKKyAgc3dpdGNoIChldmVudC0+dHlwZSkKKyAgICB7CisgICAgY2FzZSBHREtfS0VZ X1BSRVNTOgorICAgICAgaXNfcHJlc3MgPSB0cnVlOworICAgICAgYnJlYWs7CisgICAgY2Fz ZSBHREtfS0VZX1JFTEVBU0U6CisgICAgICBpc19wcmVzcyA9IGZhbHNlOworICAgICAgYnJl YWs7CisgICAgZGVmYXVsdDoKKyAgICAgIHJldHVybjsKKyAgICB9CisKKyAgLyogV2UgZG9u J3Qgc3VwcG9ydCBtb2RpZmllciBpZGVudGlmaWNhdGlvbiBvbiBQR1RLLiBXZSBvbmx5IGNh biB0ZWxsCisgICAgaWYgdGhlIGtleSBjb3JyZXNwb25kcyB0byBhIG1vZGlmaWVyIG9yIG5v dCwgd2hpY2ggaXMgdXNlZCBmb3IKKyAgICBmaWx0ZXJpbmcgZW5hYmxlZCBrZXlzIHdpdGgg a2JkX2xvd19sZXZlbF9rZXlfaXNfZW5hYmxlZC4gICovCisgIG1vZGlmaWVyID0gZXZlbnQt PmtleS5pc19tb2RpZmllciA/IFF0IDogUW5pbDsKKworICBpbnQga2V5c3ltID0geGtleS5r ZXl2YWw7CisKKyAgaWYgKGtleXN5bSA+PSBHREtfS0VZX2EgJiYga2V5c3ltIDw9IEdES19L RVlfeikKKyAgICBrZXlzeW0gLT0gR0RLX0tFWV9hIC0gR0RLX0tFWV9BOworICBpZiAoIWti ZF9sb3dfbGV2ZWxfa2V5X2lzX2VuYWJsZWQgKGtleXN5bSwgbW9kaWZpZXIpKQorICAgIHJl dHVybjsKKworICBpZiAoIWYpCisgICAgZiA9IHBndGtfYW55X3dpbmRvd190b19mcmFtZSAo ZXZlbnQtPmtleS53aW5kb3cpOworICBpZiAo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wLDU1IEBAIHczMl9yZWFkX3NvY2tldCAoc3RydWN0 IHRlcm1pbmFsICp0ZXJtaW5hbCwKIAkgICAgfQogCSAgYnJlYWs7CiAKKwljYXNlIFdNX0VN QUNTX0xPV19MRVZFTF9LRVk6CisJICBXT1JEIGtleV9mbGFncyA9IEhJV09SRCAobXNnLm1z Zy5sUGFyYW0pOworCSAgQk9PTCBpc193bV9rZXl1cCA9IGtleV9mbGFncyAmIEtGX1VQOwor CisJICBpZiAoaXNfd21fa2V5dXAgfHwgKGtleV9mbGFncyAmIEtGX1JFUEVBVCkgPT0gMCkg LyogV01fS0VZRE9XTiwgbm90IHJlcGVhdGluZy4gICovCisJICAgIHsKKwkgICAgICBXT1JE IHNjYW5fY29kZSA9IExPQllURSAoa2V5X2ZsYWdzKTsKKwkgICAgICBpZiAoa2V5X2ZsYWdz ICYgS0ZfRVhURU5ERUQpCisJCXNjYW5fY29kZSA9IE1BS0VXT1JEIChzY2FuX2NvZGUsIDB4 RTApOworCisJICAgICAgVUlOVCB0cmFuc2xhdGVkID0gTWFwVmlydHVhbEtleSAoc2Nhbl9j b2RlLCBNQVBWS19WU0NfVE9fVktfRVgpOworCSAgICAgIFdPUkQgdmsgPSBMT1dPUkQgKG1z Zy5tc2cud1BhcmFtKTsKKwkgICAgICBpZiAodHJhbnNsYXRlZCkKKwkJdmsgPSBMT1dPUkQg KHRyYW5zbGF0ZWQpOworCisJICAgICAgTGlzcF9PYmplY3Qga2V5ID0gbWFrZV9maXhudW0g KHZrKTsKKwkgICAgICBMaXNwX09iamVjdCBtb2RpZmllciA9IFFuaWw7CisKKwkgICAgICBz d2l0Y2ggKHZrKQorCQl7CisJCWNhc2UgVktfTFNISUZUOgorCQljYXNlIFZLX1JTSElGVDoK KwkJICBtb2RpZmllciA9IFFzaGlmdDsKKwkJICBicmVhazsKKwkJY2FzZSBWS19MQ09OVFJP TDoKKwkJY2FzZSBWS19SQ09OVFJPTDoKKwkJICBtb2RpZmllciA9IFFjdHJsOworC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worCWludCBtYXNrID0gKDEgPDwgbW9kKTsKKwlp ZiAoZHB5aW5mby0+eGtiX2Rlc2MtPm1hcC0+bW9kbWFwW2tleWNvZGVdICYgbWFzaykKKwkg IHsKKwkgICAgaWYgKG1hc2sgPT0gU2hpZnRNYXNrKQorCSAgICAgIHJldHVybiBRc2hpZnQ7 CisJICAgIGlmIChtYXNrID09IENvbnRyb2xNYXNrKQorCSAgICAgIHJldHVybiBRY3RybDsK KwkgICAgaWYgKG1hc2sgPT0gZHB5aW5mby0+bWV0YV9tb2RfbWFzaykKKwkgICAgICByZXR1 cm4gUW1ldGE7CisJICAgIGlmIChtYXNrID09IGRweWluZm8tPmFsdF9tb2RfbWFzaykKKwkg ICAgICByZXR1cm4gUWFsdDsKKwkgICAgaWYgKG1hc2sgPT0gZHB5aW5mby0+c3VwZXJfbW9k X21hc2spCisJICAgICAgcmV0dXJuIFFzdXBlcjsKKwkgICAgaWYgKG1hc2sgPT0gZHB5aW5m by0+aHlwZXJfbW9kX21hc2spCisJICAgICAgcmV0dXJuIFFoeXBlcjsKKwkgIH0KKyAgICAg IH0KKyNlbmRpZgorICBYTW9kaWZpZXJLZXltYXAgKm1hcCA9IGRweWluZm8tPm1vZG1hcDsK KyAgaWYgKG1hcCkKKyAgICBmb3IgKGludCBtb2QgPSAwOyBtb2QgPCA4OyBtb2QrKykKKyAg ICAgIHsKKwlpbnQgbWFzayA9ICgxIDw8IG1vZCk7CisgICAgICAgIGZvciAoaW50IGtleSA9 IDA7IGtleSA8IG1hcC0+bWF4X2tleXBlcm1vZDsga2V5KyspCisJICBpZiAobWFwLT5tb2Rp Zmllcm1hcFttb2QgKiBtYXAtPm1heF9rZXlwZXJtb2QgKyBrZXldID09IGtleWNvZGUpCisJ ICAgIHsKKwkgICAgICBpZiAobWFzayA9PSBTaGlmdE1hc2spCisJCXJldHVybiBRc2hpZnQ7 CisJICAgICAgaWYgKG1hc2sgPT0gQ29udHJvbE1hc2spCisJCXJldHVybiBRY3RybDsKKwkg ICAgICBpZiAobWFzayA9PSBkcHlpbmZvLT5tZXRhX21vZF9tYXNrKQorCQlyZXR1cm4gUW1l dGE7CisJICAgICAgaWYgKG1hc2sgPT0gZHB5aW5mby0+YWx0X21vZF9tYXNrKQorCQlyZXR1 cm4gUWFsdDsKKwkgICAgICBpZiAobWFzayA9PSBkcHlpbmZvLT5zdXBlcl9tb2RfbWFzaykK KwkJcmV0dXJuIFFzdXBlcjsKKwkgICAgICBpZiAobWFzayA9PSBkcHlpbmZvLT5oeXBlcl9t b2RfbWFzaykKKwkJcmV0dXJuIFFoeXBlcjsKKwkgICAgfQorICAgICAgfQorICByZXR1cm4g UW5pbDsKK30KKworc3RhdGljIHZvaWQKK3hfbWF5YmVfc2VuZF9sb3dfbGV2ZWxfa2V5X2V2 ZW50IChzdHJ1Y3QgeF9kaXNwbGF5X2luZm8gKmRweWluZm8sCisJCQkJICBjb25zdCBYRXZl bnQgKnhldiwgc3RydWN0IGZyYW1lICpmKQoreworICBYS2V5RXZlbnQgeGtleTsKKyAgYm9v bCBpc19wcmVzczsKKyAgS2V5U3ltIGtleXN5bTsKKyAgTGlzcF9PYmplY3Qga2V5LCBtb2Rp ZmllcjsKKyAgc3RydWN0IGlucHV0X2V2ZW50IGllOworCisgIGlmIChOSUxQIChWZW5hYmxl X2xvd19sZXZlbF9rZXlfZXZlbnRzKSkKKyAgICByZXR1cm47CisKKyAgc3dpdGNoICh4ZXYt PnR5cGUpCisgICAgeworICAgIGNhc2UgS2V5UHJlc3M6CisgICAgICBpc19wcmVzcyA9IHRy dWU7CisgICAgICB4a2V5ID0geGV2LT54a2V5OworICAgICAgYnJlYWs7CisgICAgY2FzZSBL ZXlSZWxlYXNlOgorICAgICAgaXNfcHJlc3MgPSBmYWxzZTsKKyAgICAgIHhrZXkgPSB4ZXYt PnhrZXk7CisgICAgICBicmVhazsKKyNpZmRlZiBIQVZFX1hJTlBVVDIKKyAgICBjYXNlIEdl bmVyaWNFdmVudDoKKyAgICAgIFhJRGV2aWNlRXZlbnQgKnhpZXYgPSB4ZXYtPnhjb29raWUu ZGF0YTsKKyAgICAgIHN3aXRjaCAoeGV2LT54Z2VuZXJpYy5ldnR5cGUpCisJeworCWNhc2Ug WElfS2V5UHJlc3M6CisJICBpc19wcmVzcyA9IHRydWU7CisJICBicmVhazsKKwljYXNlIFhJ X0tleVJlbGVhc2U6CisJICBpc19wcmVzcyA9IGZhbHNlOworCSAgYnJlYWs7CisJZGVmYXVs dDoKKwkgIHJldHVybjsKKwl9CisKKyAgICAgIHhrZXkuc2VyaWFsID0geGlldi0+c2VyaWFs OworICAgICAgeGtleS5zZW5kX2V2ZW50ID0geGlldi0+c2VuZF9ldmVudDsKKyAgICAgIHhr ZXkuZGlzcGxheSA9IHhpZXYtPmRpc3BsYXk7CisgICAgICB4a2V5LndpbmRvdyA9IHhpZXYt PmV2ZW50OworICAgICAgeGtleS5yb290ID0geGlldi0+cm9vdDsKKyAgICAgIHhrZXkuc3Vi d2luZG93ID0geGlldi0+Y2hpbGQ7CisgICAgICB4a2V5LnRpbWUgPSB4aWV2LT50aW1lOwor ICAgICAgeGtleS54ID0geGlldi0+ZXZlbnRfeDsKKyAgICAgIHhrZXkueSA9IHhpZXYtPmV2 ZW50X3k7CisgICAgICB4a2V5Lnhfcm9vdCA9IHhpZXYtPnJvb3RfeDsKKyAgICAgIHhrZXku eV9yb290ID0geGlldi0+cm9vdF95OworICAgICAgeGtleS5zdGF0ZSA9IHhpZXYtPm1vZHMu ZWZmZWN0aXZlOworICAgICAgeGtleS5rZXljb2RlID0geGlldi0+ZGV0YWlsOworICAgICAg eGtleS5zYW1lX3NjcmVlbiA9IDE7CisgICAgICBicmVhazsKKyNlbmRpZgorICAgIGRlZmF1 bHQ6CisgICAgICByZXR1cm47CisgICAgfQorCisgIGlmICghZikKKyAgICBmID0geF9hbnlf d2luZG93X3RvX2ZyYW1lIChkcHlpbmZvLCB4a2V5LndpbmRvdyk7CisgIGlmICghZikKKyAg ICByZXR1cm47CisKK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pOwogCitleHRlcm4gTGlzcF9PYmplY3QgeF9nZXRf bW9kaWZpZXJfZm9yX2tleWNvZGUgKHN0cnVjdCB4X2Rpc3BsYXlfaW5mbyAqLCBpbnQpOwor CiAvKiBEZWZpbmVkIGluIHhmbnMuYy4gICovCiBleHRlcm4gdm9pZCB4X3JlYWxfcG9zaXRp b25zIChzdHJ1Y3QgZnJhbWUgKiwgaW50ICosIGludCAqKTsKIGV4dGVybiB2b2lkIHhfY2hh bmdlX3RhYl9iYXJfaGVpZ2h0IChzdHJ1Y3QgZnJhbWUgKiwgaW50KTsKLS0gCjIuMzUuMS53 aW5kb3dzLjIKCg== --------------kdIRyaCiBUPUB4DSQ0iPV24t--
bug-gnu-emacs@HIDDEN
:bug#74423
; Package emacs
.
Full text available.Received: (at 74423) by debbugs.gnu.org; 23 Nov 2024 12:08:37 +0000 From debbugs-submit-bounces <at> debbugs.gnu.org Sat Nov 23 07:08:37 2024 Received: from localhost ([127.0.0.1]:56923 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from <debbugs-submit-bounces <at> debbugs.gnu.org>) id 1tEowH-00037p-1v for submit <at> debbugs.gnu.org; Sat, 23 Nov 2024 07:08:37 -0500 Received: from mail.imayhem.com ([82.223.54.191]:38121 helo=zealous-pike.82-223-54-191.plesk.page) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from <cpardo@HIDDEN>) id 1tEowD-00037Y-U8 for 74423 <at> debbugs.gnu.org; Sat, 23 Nov 2024 07:08:35 -0500 Received: from [192.168.68.104] (111.red-88-21-7.staticip.rima-tde.net [88.21.7.111]) by zealous-pike.82-223-54-191.plesk.page (Postfix) with ESMTPSA id 90F8080127; Sat, 23 Nov 2024 12:08:25 +0000 (UTC) Authentication-Results: zealous-pike.82-223-54-191.plesk.page; spf=pass (sender IP is 88.21.7.111) smtp.mailfrom=cpardo@HIDDEN smtp.helo=[192.168.68.104] Received-SPF: pass (zealous-pike.82-223-54-191.plesk.page: connection is authenticated) Message-ID: <dce2177f-bf03-4da3-94cd-ac1bd9f26dfc@HIDDEN> Date: Sat, 23 Nov 2024 13:08:24 +0100 MIME-Version: 1.0 User-Agent: Mozilla Thunderbird Subject: Re: bug#74423: Low level key events To: Po Lu <luangruo@HIDDEN> References: <fb50ec11-7aec-481e-8a3a-ecdcf22eb7c0@HIDDEN> <31bdc55d-8c13-4de0-9cef-bd6cc4fb033f@HIDDEN> <s1r8qtzsvbe.fsf@HIDDEN> <d5c72818-e907-43f5-853a-89ec01264157@HIDDEN> <87ttc4hzmb.fsf@HIDDEN> Content-Language: es-ES From: Cecilio Pardo <cpardo@HIDDEN> In-Reply-To: <87ttc4hzmb.fsf@HIDDEN> Content-Type: text/plain; charset=UTF-8; format=flowed Content-Transfer-Encoding: 7bit X-Spam-Score: 0.0 (/) X-Debbugs-Envelope-To: 74423 Cc: 74423 <at> debbugs.gnu.org X-BeenThere: debbugs-submit <at> debbugs.gnu.org X-Mailman-Version: 2.1.18 Precedence: list List-Id: <debbugs-submit.debbugs.gnu.org> List-Unsubscribe: <https://debbugs.gnu.org/cgi-bin/mailman/options/debbugs-submit>, <mailto:debbugs-submit-request <at> debbugs.gnu.org?subject=unsubscribe> List-Archive: <https://debbugs.gnu.org/cgi-bin/mailman/private/debbugs-submit/> List-Post: <mailto:debbugs-submit <at> debbugs.gnu.org> List-Help: <mailto:debbugs-submit-request <at> debbugs.gnu.org?subject=help> List-Subscribe: <https://debbugs.gnu.org/cgi-bin/mailman/listinfo/debbugs-submit>, <mailto:debbugs-submit-request <at> debbugs.gnu.org?subject=subscribe> Errors-To: debbugs-submit-bounces <at> debbugs.gnu.org Sender: "Debbugs-submit" <debbugs-submit-bounces <at> debbugs.gnu.org> X-Spam-Score: -1.0 (-) On 19/11/2024 0:49, Po Lu wrote: > You are computing the modifier event to be generated incorrectly. You > should search the modifier map (dpyinfo->modmap) for columns containing > received keysyms, and compare modifier bits derived from the rows where > they appear against meta_mod_mask, shift_lock_mask, alt_mod_mask, > super_mod_mask, and hyper_mod_mask in the display structure, or CtrlMask > and ShiftMask. Thanks for the guidance. Does this look ok? Lisp_Object x_get_modifier_for_keycode (struct x_display_info *dpyinfo, int keycode) { #ifdef HAVE_XKB if (dpyinfo->xkb_desc) for (int mod = 0; mod < XkbNumModifiers; mod++) { int mask = (1 << mod); if (dpyinfo->xkb_desc->map->modmap[keycode] & mask) { if (mask == ShiftMask) return Qshift; if (mask == ControlMask) return Qctrl; if (mask == dpyinfo->meta_mod_mask) return Qmeta; if (mask == dpyinfo->alt_mod_mask) return Qalt; if (mask == dpyinfo->super_mod_mask) return Qsuper; if (mask == dpyinfo->hyper_mod_mask) return Qhyper; } } #endif XModifierKeymap *map = dpyinfo->modmap; if (map) for (int mod = 0; mod < 8; mod++) { int mask = (1 << mod); for (int key = 0; key < map->max_keypermod; key++) if (map->modifiermap[mod * map->max_keypermod + key] == keycode) { if (mask == ShiftMask) return Qshift; if (mask == ControlMask) return Qctrl; if (mask == dpyinfo->meta_mod_mask) return Qmeta; if (mask == dpyinfo->alt_mod_mask) return Qalt; if (mask == dpyinfo->super_mod_mask) return Qsuper; if (mask == dpyinfo->hyper_mod_mask) return Qhyper; } } return Qnil; }
bug-gnu-emacs@HIDDEN
:bug#74423
; Package emacs
.
Full text available.Received: (at 74423) by debbugs.gnu.org; 20 Nov 2024 04:21:19 +0000 From debbugs-submit-bounces <at> debbugs.gnu.org Tue Nov 19 23:21:19 2024 Received: from localhost ([127.0.0.1]:44821 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from <debbugs-submit-bounces <at> debbugs.gnu.org>) id 1tDcDP-0003pl-F9 for submit <at> debbugs.gnu.org; Tue, 19 Nov 2024 23:21:19 -0500 Received: from mailscanner.iro.umontreal.ca ([132.204.25.50]:41626) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from <monnier@HIDDEN>) id 1tDcDM-0003pS-68 for 74423 <at> debbugs.gnu.org; Tue, 19 Nov 2024 23:21:17 -0500 Received: from pmg2.iro.umontreal.ca (localhost.localdomain [127.0.0.1]) by pmg2.iro.umontreal.ca (Proxmox) with ESMTP id 54EE68093F; Tue, 19 Nov 2024 23:21:09 -0500 (EST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=iro.umontreal.ca; s=mail; t=1732076468; bh=u/dlODuMNVgCgj7eJr94SIpIsmXAVObelSgDWwbkYwM=; h=From:To:Cc:Subject:In-Reply-To:References:Date:From; b=Hsz6SJbByqYiPLJhXpTNmqBBjicWYaWnhgp72MiA/DXXKSSHHJFCKJ1moRdOa9xAy PdOXu+V9kaGQlB1W84uHf4mpGmu3FNBCdk/Z67D/DjbI1QAW6Oh3BxyLOnYYAH2wsZ h8v15FDZISqPoOk6zXtj8yawzl5odG8AFHM3kQLN/RhXjdH7wS0o4ZCLNrW89xt78X tkbTkVUq7PH+Iq7+3xDBk+wlZlaXUYDhv4bNcu5/7ibg7z5bkzsTKE8VbY78+He46Y HH+1OaBNdWv3mIBeBbItBOEAt40vOya4vHisOkkkrxo8T7r8sznmllLnADaMn3hxOB wkq5He0RNEPCQ== Received: from mail01.iro.umontreal.ca (unknown [172.31.2.1]) by pmg2.iro.umontreal.ca (Proxmox) with ESMTP id 7091C80394; Tue, 19 Nov 2024 23:21:08 -0500 (EST) Received: from pastel (104-195-225-43.cpe.teksavvy.com [104.195.225.43]) by mail01.iro.umontreal.ca (Postfix) with ESMTPSA id 41DA712038D; Tue, 19 Nov 2024 23:21:08 -0500 (EST) From: Stefan Monnier <monnier@HIDDEN> To: Cecilio Pardo <cpardo@HIDDEN> Subject: Re: bug#74423: Low level key events In-Reply-To: <705fabb8-1ea0-4894-8c32-05097ab822c9@HIDDEN> (Cecilio Pardo's message of "Tue, 19 Nov 2024 21:05:06 +0100") Message-ID: <jwvplmqtuh1.fsf-monnier+emacs@HIDDEN> References: <fb50ec11-7aec-481e-8a3a-ecdcf22eb7c0@HIDDEN> <31bdc55d-8c13-4de0-9cef-bd6cc4fb033f@HIDDEN> <s1r8qtzsvbe.fsf@HIDDEN> <d5c72818-e907-43f5-853a-89ec01264157@HIDDEN> <jwv4j43jisn.fsf-monnier+emacs@HIDDEN> <705fabb8-1ea0-4894-8c32-05097ab822c9@HIDDEN> Date: Tue, 19 Nov 2024 23:21:07 -0500 User-Agent: Gnus/5.13 (Gnus v5.13) MIME-Version: 1.0 Content-Type: text/plain X-SPAM-INFO: Spam detection results: 0 ALL_TRUSTED -1 Passed through trusted hosts only via SMTP AWL 0.001 Adjusted score from AWL reputation of From: address BAYES_00 -1.9 Bayes spam probability is 0 to 1% DKIM_SIGNED 0.1 Message has a DKIM or DK signature, not necessarily valid DKIM_VALID -0.1 Message has at least one valid DKIM or DK signature DKIM_VALID_AU -0.1 Message has a valid DKIM or DK signature from author's domain DKIM_VALID_EF -0.1 Message has a valid DKIM or DK signature from envelope-from domain X-SPAM-LEVEL: X-Spam-Score: -2.3 (--) X-Debbugs-Envelope-To: 74423 Cc: 74423 <at> debbugs.gnu.org X-BeenThere: debbugs-submit <at> debbugs.gnu.org X-Mailman-Version: 2.1.18 Precedence: list List-Id: <debbugs-submit.debbugs.gnu.org> List-Unsubscribe: <https://debbugs.gnu.org/cgi-bin/mailman/options/debbugs-submit>, <mailto:debbugs-submit-request <at> debbugs.gnu.org?subject=unsubscribe> List-Archive: <https://debbugs.gnu.org/cgi-bin/mailman/private/debbugs-submit/> List-Post: <mailto:debbugs-submit <at> debbugs.gnu.org> List-Help: <mailto:debbugs-submit-request <at> debbugs.gnu.org?subject=help> List-Subscribe: <https://debbugs.gnu.org/cgi-bin/mailman/listinfo/debbugs-submit>, <mailto:debbugs-submit-request <at> debbugs.gnu.org?subject=subscribe> Errors-To: debbugs-submit-bounces <at> debbugs.gnu.org Sender: "Debbugs-submit" <debbugs-submit-bounces <at> debbugs.gnu.org> X-Spam-Score: -3.3 (---) >> Move that code to a function, so you can get rid of this `hyper` >> special case. BTW, any reason why you couldn't use >> `event-apply-hyper-modifier`? > No, no reason. I will change that. To be clear: I don't know that it works here. >> I think the list of low-level keys handled here should not be hard-coded. >> IOW, maybe `enable-low-level-keys` should not be a boolean but >> a list/map/table indicating which keys to handle. > I was sending the keys for which I have an immediate use case. Using a list > looks got, adding some special symbols to choose groups, such as "all > modifier keys". I was also thinking that maybe the list/table could be used to avoid having to define in the C code what is a "modifier key" and things like that. >> So, IIUC you might generate 2 low-level events for a single key press? >> Why? > We want to allow to detect modifier keys, regardless of the key that is > used. For example, when you press Shift_L we generate an event for 'lshift > and other (of different type) for the modifier 'shift. But my question is about the fact that you generate two events, not about the two pieces of information. IOW you could also generate a single event with both pieces of information (and if use the "normal" keymaps instead of `special-event-map` then you might even have a `function-key-map` rule which converts a `Shift_L` down to a `shift` if there was no binding for the `Shift_L` event). Stefan
bug-gnu-emacs@HIDDEN
:bug#74423
; Package emacs
.
Full text available.Received: (at 74423) by debbugs.gnu.org; 19 Nov 2024 20:05:18 +0000 From debbugs-submit-bounces <at> debbugs.gnu.org Tue Nov 19 15:05:18 2024 Received: from localhost ([127.0.0.1]:44132 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from <debbugs-submit-bounces <at> debbugs.gnu.org>) id 1tDUTO-0007Vx-Bv for submit <at> debbugs.gnu.org; Tue, 19 Nov 2024 15:05:18 -0500 Received: from mail.imayhem.com ([82.223.54.191]:38879 helo=zealous-pike.82-223-54-191.plesk.page) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from <cpardo@HIDDEN>) id 1tDUTL-0007VV-QK for 74423 <at> debbugs.gnu.org; Tue, 19 Nov 2024 15:05:17 -0500 Received: from [192.168.68.104] (111.red-88-21-7.staticip.rima-tde.net [88.21.7.111]) by zealous-pike.82-223-54-191.plesk.page (Postfix) with ESMTPSA id BC5C7800F3; Tue, 19 Nov 2024 20:05:08 +0000 (UTC) Authentication-Results: zealous-pike.82-223-54-191.plesk.page; spf=pass (sender IP is 88.21.7.111) smtp.mailfrom=cpardo@HIDDEN smtp.helo=[192.168.68.104] Received-SPF: pass (zealous-pike.82-223-54-191.plesk.page: connection is authenticated) Message-ID: <705fabb8-1ea0-4894-8c32-05097ab822c9@HIDDEN> Date: Tue, 19 Nov 2024 21:05:06 +0100 MIME-Version: 1.0 User-Agent: Mozilla Thunderbird Subject: Re: bug#74423: Low level key events To: Stefan Monnier <monnier@HIDDEN> References: <fb50ec11-7aec-481e-8a3a-ecdcf22eb7c0@HIDDEN> <31bdc55d-8c13-4de0-9cef-bd6cc4fb033f@HIDDEN> <s1r8qtzsvbe.fsf@HIDDEN> <d5c72818-e907-43f5-853a-89ec01264157@HIDDEN> <jwv4j43jisn.fsf-monnier+emacs@HIDDEN> Content-Language: es-ES From: Cecilio Pardo <cpardo@HIDDEN> In-Reply-To: <jwv4j43jisn.fsf-monnier+emacs@HIDDEN> Content-Type: text/plain; charset=UTF-8; format=flowed Content-Transfer-Encoding: 7bit X-Spam-Score: 0.0 (/) X-Debbugs-Envelope-To: 74423 Cc: 74423 <at> debbugs.gnu.org X-BeenThere: debbugs-submit <at> debbugs.gnu.org X-Mailman-Version: 2.1.18 Precedence: list List-Id: <debbugs-submit.debbugs.gnu.org> List-Unsubscribe: <https://debbugs.gnu.org/cgi-bin/mailman/options/debbugs-submit>, <mailto:debbugs-submit-request <at> debbugs.gnu.org?subject=unsubscribe> List-Archive: <https://debbugs.gnu.org/cgi-bin/mailman/private/debbugs-submit/> List-Post: <mailto:debbugs-submit <at> debbugs.gnu.org> List-Help: <mailto:debbugs-submit-request <at> debbugs.gnu.org?subject=help> List-Subscribe: <https://debbugs.gnu.org/cgi-bin/mailman/listinfo/debbugs-submit>, <mailto:debbugs-submit-request <at> debbugs.gnu.org?subject=subscribe> Errors-To: debbugs-submit-bounces <at> debbugs.gnu.org Sender: "Debbugs-submit" <debbugs-submit-bounces <at> debbugs.gnu.org> X-Spam-Score: -1.0 (-) On 19/11/2024 17:43, Stefan Monnier wrote: >> + ((functionp func) (funcall func)) >> + ((eq 'hyper func) >> + (message "H-...") >> + (let ((r (read-event))) >> + (setq unread-command-events >> + (list (event-apply-modifier >> + r 'hyper 24 "H-")))))))))) > > Move that code to a function, so you can get rid of this `hyper` > special case. BTW, any reason why you couldn't use > `event-apply-hyper-modifier`? No, no reason. I will change that. > I think the list of low-level keys handled here should not be hard-coded. > IOW, maybe `enable-low-level-keys` should not be a boolean but > a list/map/table indicating which keys to handle. I was sending the keys for which I have an immediate use case. Using a list looks got, adding some special symbols to choose groups, such as "all modifier keys". > So, IIUC you might generate 2 low-level events for a single key press? > Why? We want to allow to detect modifier keys, regardless of the key that is used. For example, when you press Shift_L we generate an event for 'lshift and other (of different type) for the modifier 'shift. > Other note: in the distant past (back around Emacs-21) I seem to > remember Gerd making changes to the event structure so as to avoid > allocating Lisp objects for this code. I think it was related to > problems due to running this low-level event-handler code from within > a C signal handler, which is a practice was have since stopped, luckily, > but maybe there are still good reasons to try and avoid involving > allocating objects into the Lisp heap in this low-level code. I will look into this. Thanks for your comments!
bug-gnu-emacs@HIDDEN
:bug#74423
; Package emacs
.
Full text available.Received: (at 74423) by debbugs.gnu.org; 19 Nov 2024 16:43:22 +0000 From debbugs-submit-bounces <at> debbugs.gnu.org Tue Nov 19 11:43:22 2024 Received: from localhost ([127.0.0.1]:43814 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from <debbugs-submit-bounces <at> debbugs.gnu.org>) id 1tDRJx-0006yk-Se for submit <at> debbugs.gnu.org; Tue, 19 Nov 2024 11:43:22 -0500 Received: from mailscanner.iro.umontreal.ca ([132.204.25.50]:62784) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from <monnier@HIDDEN>) id 1tDRJv-0006yW-D5 for 74423 <at> debbugs.gnu.org; Tue, 19 Nov 2024 11:43:20 -0500 Received: from pmg3.iro.umontreal.ca (localhost [127.0.0.1]) by pmg3.iro.umontreal.ca (Proxmox) with ESMTP id CBC28444FC9; Tue, 19 Nov 2024 11:43:12 -0500 (EST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=iro.umontreal.ca; s=mail; t=1732034591; bh=x0U5QRphRWOBhk3qTb+t1GYb3TTKXwrTBdou9IHDK4k=; h=From:To:Cc:Subject:In-Reply-To:References:Date:From; b=TGxWCQ7QfpmZFyNlgQgVwZe7NIYKAS+KWhrwf+CCz8DtRFcwAfQHuLW+l5kw1FVV9 s3Vkynne5Pb6M27mgIvciUE5R+7KKyGwy0M/af5AL2Q7/+Pu5wxagEZHQCG9mG7z61 NxIu2luKuze2gwpQjBYOSG2YHPEUIioZgtHy8GSFX5aLfUf+25l8JhQjvZbuByXJ4/ hQp7ZPo9uROQPK5CzBsWIoBnfiLzFxZ7cA7kuWeTQCjGLYuDNlgeuEMGZ/dJLJ1zQp YwUTOE+XU5wUION6r7yX1HjFOHNLXR8U7BL1ZBqoFFIUNZx4wELGGNgn0G0fK3hG/+ Xxhq0NKJ56ILQ== Received: from mail01.iro.umontreal.ca (unknown [172.31.2.1]) by pmg3.iro.umontreal.ca (Proxmox) with ESMTP id 46EB5444FC1; Tue, 19 Nov 2024 11:43:11 -0500 (EST) Received: from lechazo (lechon.iro.umontreal.ca [132.204.27.242]) by mail01.iro.umontreal.ca (Postfix) with ESMTPSA id 35F50120370; Tue, 19 Nov 2024 11:43:11 -0500 (EST) From: Stefan Monnier <monnier@HIDDEN> To: Cecilio Pardo <cpardo@HIDDEN> Subject: Re: bug#74423: Low level key events In-Reply-To: <d5c72818-e907-43f5-853a-89ec01264157@HIDDEN> (Cecilio Pardo's message of "Mon, 18 Nov 2024 21:35:40 +0100") Message-ID: <jwv4j43jisn.fsf-monnier+emacs@HIDDEN> References: <fb50ec11-7aec-481e-8a3a-ecdcf22eb7c0@HIDDEN> <31bdc55d-8c13-4de0-9cef-bd6cc4fb033f@HIDDEN> <s1r8qtzsvbe.fsf@HIDDEN> <d5c72818-e907-43f5-853a-89ec01264157@HIDDEN> Date: Tue, 19 Nov 2024 11:43:08 -0500 User-Agent: Gnus/5.13 (Gnus v5.13) MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: quoted-printable X-SPAM-INFO: Spam detection results: 0 ALL_TRUSTED -1 Passed through trusted hosts only via SMTP AWL 0.203 Adjusted score from AWL reputation of From: address BAYES_00 -1.9 Bayes spam probability is 0 to 1% DKIM_SIGNED 0.1 Message has a DKIM or DK signature, not necessarily valid DKIM_VALID -0.1 Message has at least one valid DKIM or DK signature DKIM_VALID_AU -0.1 Message has a valid DKIM or DK signature from author's domain DKIM_VALID_EF -0.1 Message has a valid DKIM or DK signature from envelope-from domain X-SPAM-LEVEL: X-Spam-Score: -2.3 (--) X-Debbugs-Envelope-To: 74423 Cc: 74423 <at> debbugs.gnu.org X-BeenThere: debbugs-submit <at> debbugs.gnu.org X-Mailman-Version: 2.1.18 Precedence: list List-Id: <debbugs-submit.debbugs.gnu.org> List-Unsubscribe: <https://debbugs.gnu.org/cgi-bin/mailman/options/debbugs-submit>, <mailto:debbugs-submit-request <at> debbugs.gnu.org?subject=unsubscribe> List-Archive: <https://debbugs.gnu.org/cgi-bin/mailman/private/debbugs-submit/> List-Post: <mailto:debbugs-submit <at> debbugs.gnu.org> List-Help: <mailto:debbugs-submit-request <at> debbugs.gnu.org?subject=help> List-Subscribe: <https://debbugs.gnu.org/cgi-bin/mailman/listinfo/debbugs-submit>, <mailto:debbugs-submit-request <at> debbugs.gnu.org?subject=subscribe> Errors-To: debbugs-submit-bounces <at> debbugs.gnu.org Sender: "Debbugs-submit" <debbugs-submit-bounces <at> debbugs.gnu.org> X-Spam-Score: -3.3 (---) > It provides events for press/release of keys, independently of the normal > keyboard events. These events are bound int the special-event-map. Some l= isp > is included to implement detection of multiple tapping on keys, and runni= ng > commands or simulating modifiers. I hadn't followed the discussion over at emacs-devel, but this is cool. I used to have a local patch which generated extra events for all key presses/releases. I never wrote any useful Lisp-level code for it (all I had were bindings to ignore those events so Emacs was still usable =F0=9F=99=82), but I really think it would make for fun new hacks. I haven't had time to look at your whole patch, but here are some comments. > + (let ((key (cl-third last-input-event))) Please try and use `event-*` functions. If none serve (as will often be the case), define local "replacements" until they can be promoted to `subr.el`. > + ((functionp func) (funcall func)) > + ((eq 'hyper func) > + (message "H-...") > + (let ((r (read-event))) > + (setq unread-command-events > + (list (event-apply-modifier > + r 'hyper 24 "H-")))))))))) Move that code to a function, so you can get rid of this `hyper` special case. BTW, any reason why you couldn't use `event-apply-hyper-modifier`? [ BTW, this becomes more ... interesting ... when you want to be able to cumulative that for several modifiers, in which case your `read-event` might return an event which is not the one to which you want to add `H-`. ] > + switch (keysym) > + { > + case GDK_KEY_Shift_L: key =3D Qlshift; break; > + case GDK_KEY_Shift_R: key =3D Qrshift; break; > + case GDK_KEY_Control_L: key =3D Qlctrl; break; > + case GDK_KEY_Control_R: key =3D Qrctrl; break; > + case GDK_KEY_Alt_L: key =3D Qlalt; break; > + case GDK_KEY_Alt_R: key =3D Qralt; break; > + default: > + key =3D Qnil; > + } > + > + switch (keysym) > + { > + case GDK_KEY_Shift_L: > + case GDK_KEY_Shift_R: > + modifier =3D Qshift; > + break; > + case GDK_KEY_Control_L: > + case GDK_KEY_Control_R: > + modifier =3D Vx_ctrl_keysym; > + if (NILP (modifier)) > + modifier =3D Qctrl; > + break; > + case GDK_KEY_Alt_L: > + case GDK_KEY_Alt_R: > + modifier =3D Vx_meta_keysym; > + if (NILP (modifier)) > + modifier =3D Qalt; > + break; > + case GDK_KEY_Meta_L: > + case GDK_KEY_Meta_R: > + modifier =3D Vx_meta_keysym; > + if (NILP (modifier)) > + modifier =3D Qmeta; > + break; > + case GDK_KEY_Hyper_L: > + case GDK_KEY_Hyper_R: > + modifier =3D Vx_hyper_keysym; > + if (NILP (modifier)) > + modifier =3D Qhyper; > + break; > + case GDK_KEY_Super_L: > + case GDK_KEY_Super_R: > + modifier =3D Vx_super_keysym; > + if (NILP (modifier)) > + modifier =3D Qsuper; > + break; > + default: > + modifier =3D Qnil; > + } I think the list of low-level keys handled here should not be hard-coded. IOW, maybe `enable-low-level-keys` should not be a boolean but a list/map/table indicating which keys to handle. > + if (!NILP (key)) > + { > + EVENT_INIT (inev.ie); > + XSETFRAME (inev.ie.frame_or_window, f); > + inev.ie.kind =3D LOW_LEVEL_KEY_EVENT; > + inev.ie.timestamp =3D xkey.time; > + inev.ie.arg =3D list2 (is_press ? Qt : Qnil, key); > + kbd_buffer_store_buffered_event (&inev, &xg_pending_quit_event); > + } > + > + if (!NILP (modifier)) > + { > + EVENT_INIT (inev.ie); > + XSETFRAME (inev.ie.frame_or_window, f); > + inev.ie.kind =3D LOW_LEVEL_MODIFIER_KEY_EVENT; > + inev.ie.timestamp =3D xkey.time; > + inev.ie.arg =3D list2 (is_press ? Qt : Qnil, modifier); > + kbd_buffer_store_buffered_event (&inev, &xg_pending_quit_event); > + } > +} So, IIUC you might generate 2 low-level events for a single key press? Why? Other note: in the distant past (back around Emacs-21) I seem to remember Gerd making changes to the event structure so as to avoid allocating Lisp objects for this code. I think it was related to problems due to running this low-level event-handler code from within a C signal handler, which is a practice was have since stopped, luckily, but maybe there are still good reasons to try and avoid involving allocating objects into the Lisp heap in this low-level code. Stefan
bug-gnu-emacs@HIDDEN
:bug#74423
; Package emacs
.
Full text available.Received: (at 74423) by debbugs.gnu.org; 19 Nov 2024 15:29:13 +0000 From debbugs-submit-bounces <at> debbugs.gnu.org Tue Nov 19 10:29:13 2024 Received: from localhost ([127.0.0.1]:43672 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from <debbugs-submit-bounces <at> debbugs.gnu.org>) id 1tDQAC-0003ZL-KG for submit <at> debbugs.gnu.org; Tue, 19 Nov 2024 10:29:12 -0500 Received: from eggs.gnu.org ([209.51.188.92]:32918) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from <eliz@HIDDEN>) id 1tDQA9-0003Z5-QN for 74423 <at> debbugs.gnu.org; Tue, 19 Nov 2024 10:29:10 -0500 Received: from fencepost.gnu.org ([2001:470:142:3::e]) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from <eliz@HIDDEN>) id 1tDQA2-0007ci-Gf; Tue, 19 Nov 2024 10:29:02 -0500 DKIM-Signature: v=1; a=rsa-sha256; q=dns/txt; c=relaxed/relaxed; d=gnu.org; s=fencepost-gnu-org; h=References:Subject:In-Reply-To:To:From:Date: mime-version; bh=00rfOvUGulpPowx1DN4JifuMT1rz9RLWJYkR48FS9D4=; b=gtX3lteCA7Nh Gd0S1o0nRaR4zx3+u+Pslj7gSqlUARZzoz0465PZIhRYulfhIvh8LfctbnPcdLh1g3wwCBmnkO4Ek lA6zC+LiftRpq0MxCHXxXZmK8PD8IJHJhLPAWf4E8YJd5r4K5uu2O2aSEMJGrPVUPDdD0p3hdRUE7 eiJh7GQn6v3zIgge/VaORijGuMu01bvX+528Cp5SMF7SQKv61NVXGbJuv4jNLbLzDwFKwwhTrFQKI GJqUpSGnWPz3qgt/HNjc79A/2aXiQsGbJfoo3UoZlROfOKiqlr0IDuGd6VVcVPWjxBzCnTsX1XZma 6yilzsBboaRxnJa5kZiGIA==; Date: Tue, 19 Nov 2024 17:29:00 +0200 Message-Id: <86ttc3tf7n.fsf@HIDDEN> From: Eli Zaretskii <eliz@HIDDEN> To: Cecilio Pardo <cpardo@HIDDEN>, Stefan Monnier <monnier@HIDDEN> In-Reply-To: <d5c72818-e907-43f5-853a-89ec01264157@HIDDEN> (message from Cecilio Pardo on Mon, 18 Nov 2024 21:35:40 +0100) Subject: Re: bug#74423: Low level key events References: <fb50ec11-7aec-481e-8a3a-ecdcf22eb7c0@HIDDEN> <31bdc55d-8c13-4de0-9cef-bd6cc4fb033f@HIDDEN> <s1r8qtzsvbe.fsf@HIDDEN> <d5c72818-e907-43f5-853a-89ec01264157@HIDDEN> X-Spam-Score: -2.3 (--) X-Debbugs-Envelope-To: 74423 Cc: 74423 <at> debbugs.gnu.org X-BeenThere: debbugs-submit <at> debbugs.gnu.org X-Mailman-Version: 2.1.18 Precedence: list List-Id: <debbugs-submit.debbugs.gnu.org> List-Unsubscribe: <https://debbugs.gnu.org/cgi-bin/mailman/options/debbugs-submit>, <mailto:debbugs-submit-request <at> debbugs.gnu.org?subject=unsubscribe> List-Archive: <https://debbugs.gnu.org/cgi-bin/mailman/private/debbugs-submit/> List-Post: <mailto:debbugs-submit <at> debbugs.gnu.org> List-Help: <mailto:debbugs-submit-request <at> debbugs.gnu.org?subject=help> List-Subscribe: <https://debbugs.gnu.org/cgi-bin/mailman/listinfo/debbugs-submit>, <mailto:debbugs-submit-request <at> debbugs.gnu.org?subject=subscribe> Errors-To: debbugs-submit-bounces <at> debbugs.gnu.org Sender: "Debbugs-submit" <debbugs-submit-bounces <at> debbugs.gnu.org> X-Spam-Score: -3.3 (---) > Date: Mon, 18 Nov 2024 21:35:40 +0100 > From: Cecilio Pardo <cpardo@HIDDEN> > > Here is a still incomplete patch for this, renamed from "physical > keyboard events", following up to > https://lists.gnu.org/archive/html/emacs-devel/2024-11/msg00085.html > > It provides events for press/release of keys, independently of the > normal keyboard events. These events are bound int the > special-event-map. Some lisp is included to implement detection of > multiple tapping on keys, and running commands or simulating modifiers. Thanks, I have some minor comments, and also added Stefan to the discussion, in case he will also have comments. > + if (!Venable_low_level_key_events) You treat this variable as a C boolean, i.e. assume it was defined with DEFVAR_BOOL, but in that case our convention is to call the C variables without the leading 'V'. OTOH, if you envision that this variable could be something other than nil or t in Lisp, then you need to use NILP here. > + DEFVAR_LISP ("enable-low-level-key-events", Venable_low_level_key_events, > + doc: /* Enabled the recepcion of low level key events. ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ "If non-nil, reception of low-level key events is enabled." > +static void > +pgtk_maybe_send_low_level_key_event (GdkEvent *event) > +{ > + if (!Venable_low_level_key_events) > + return; Same problem with the test here. > --- a/src/w32fns.c > +++ b/src/w32fns.c > @@ -4669,6 +4669,11 @@ w32_wnd_proc (HWND hwnd, UINT msg, WPARAM wParam, LPARAM lParam) > case WM_KEYUP: > case WM_SYSKEYUP: > record_keyup (wParam, lParam); > + if (Venable_low_level_key_events) > + { > + signal_user_input (); > + my_post_msg( &wmsg, hwnd, WM_EMACS_LOW_LEVEL_KEY, wParam, lParam ); > + } And here (and in several other places in the patch).
bug-gnu-emacs@HIDDEN
:bug#74423
; Package emacs
.
Full text available.Received: (at 74423) by debbugs.gnu.org; 18 Nov 2024 23:49:20 +0000 From debbugs-submit-bounces <at> debbugs.gnu.org Mon Nov 18 18:49:19 2024 Received: from localhost ([127.0.0.1]:39732 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from <debbugs-submit-bounces <at> debbugs.gnu.org>) id 1tDBUd-0001mH-Ap for submit <at> debbugs.gnu.org; Mon, 18 Nov 2024 18:49:19 -0500 Received: from sonic305-22.consmr.mail.ne1.yahoo.com ([66.163.185.148]:42475) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from <luangruo@HIDDEN>) id 1tDBUb-0001m3-3d for 74423 <at> debbugs.gnu.org; Mon, 18 Nov 2024 18:49:18 -0500 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=yahoo.com; s=s2048; t=1731973749; bh=ttAABeWMdbRhbjs7VJmQqYowkdTubale70Qoe3SS8cE=; h=From:To:Cc:Subject:In-Reply-To:References:Date:From:Subject:Reply-To; b=T4NeX2OKm6CQa9H8BxXTxMEadwtDi5CHwJuGBUggV+k8LFPsa178qvXs7osYZRQRe64zELMoVmizqA+QI++UBT0zeE6Cm+e4hqXNcDKo0lcxX41PMG3r/qGSdlP6jmpMav+1ITEmd8Cdb5BECWRRV/BoJBRwII9AFaOln169prxtTBqtPsJB9VWzsRhCFXTV+bZc0nFbYSAkwd/n4rhFnfYcCew36nTAAD4NXIXElcioTM6ZhDBpWvMuBwStzkhYSOL8vLxeY7psCkwrZba0qwHZcj/Aa2SqTA+MfGzVdQohEMM159qGTQemNW//2FhGe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aSXPo7ja2FhTkcDA2Zo6zO2nMPlqtzO9gXtyyhVpd rMu8kiMDoJfgOVxqDk_a49UrA8Ss4.XTBV.6YSdBkpzE3LZPqV39Z9IUJG.VZpyR2ac2X02fTo2Q dl0EEe7uy53VEh_CO79kW0uK1GMRTXutaZ8AF3M8CLXIRBk8oG_Jmr3WOwNqYKI_mhXJCsQWm67R 7inHz7DOyhbYOw_DDQdsKuu8MUOHV2ihmpYs4D9sLV9z0wri6k5sgn_BR9B0ibntsz_0NJZyLPpS xiE8P3GIX1HIjlTQRTg.n0MsQiVO.rreRf_rY9F9vQTAY0z82QuzQ8o8_E_tpueYs0Yd5CIvXeIR fkYJ97mC78t9hZWN5E_7y4umkrCuiyoFAri.cUl49isFxMqmyu6g3SndqnTjCdjLAoD7GEHgNjz7 d6kv.KW544zK6pRyZ9U4E43o7T.HKVOYVcqJNwCajHveDOhR7IpRIUUQhTX9hTki0Cg3UH_uXpoX CFkhZgMe7DuV6H95N6Rc56m3WCCwfBJlQKF1agajhx8034AWFN4z7DiATexxdBGxZCEQigUrSUvn aszC3CvdJEdf1q5Tu5Dv2wL9F3GMYc3zUtp.FQ_QmwyeZCul1pxxzzh1RIn4HseZ9GkynrRE8hzm RYkaXCOY8FjNXvTci4I8MFhKZtUK4D5d3JWMD3qSSPBWHdmIEOocgbf0- X-Sonic-MF: <luangruo@HIDDEN> X-Sonic-ID: 3cc06c86-8e89-47fe-a847-8c3487786ba1 Received: from sonic.gate.mail.ne1.yahoo.com by sonic305.consmr.mail.ne1.yahoo.com with HTTP; Mon, 18 Nov 2024 23:49:09 +0000 Received: by hermes--production-sg3-5b7954b588-2czcw (Yahoo Inc. Hermes SMTP Server) with ESMTPA ID e1b6994a9d0bab8ead690504911ef7e4; Mon, 18 Nov 2024 23:49:04 +0000 (UTC) From: Po Lu <luangruo@HIDDEN> To: Cecilio Pardo <cpardo@HIDDEN> Subject: Re: bug#74423: Low level key events In-Reply-To: <d5c72818-e907-43f5-853a-89ec01264157@HIDDEN> (Cecilio Pardo's message of "Mon, 18 Nov 2024 21:35:40 +0100") References: <fb50ec11-7aec-481e-8a3a-ecdcf22eb7c0@HIDDEN> <31bdc55d-8c13-4de0-9cef-bd6cc4fb033f@HIDDEN> <s1r8qtzsvbe.fsf@HIDDEN> <d5c72818-e907-43f5-853a-89ec01264157@HIDDEN> Date: Tue, 19 Nov 2024 07:49:00 +0800 Message-ID: <87ttc4hzmb.fsf@HIDDEN> User-Agent: Gnus/5.13 (Gnus v5.13) MIME-Version: 1.0 Content-Type: text/plain X-Mailer: WebService/1.1.22941 mail.backend.jedi.jws.acl:role.jedi.acl.token.atz.jws.hermes.yahoo Content-Length: 5934 X-Spam-Score: 0.0 (/) X-Debbugs-Envelope-To: 74423 Cc: 74423 <at> debbugs.gnu.org X-BeenThere: debbugs-submit <at> debbugs.gnu.org X-Mailman-Version: 2.1.18 Precedence: list List-Id: <debbugs-submit.debbugs.gnu.org> List-Unsubscribe: <https://debbugs.gnu.org/cgi-bin/mailman/options/debbugs-submit>, <mailto:debbugs-submit-request <at> debbugs.gnu.org?subject=unsubscribe> List-Archive: <https://debbugs.gnu.org/cgi-bin/mailman/private/debbugs-submit/> List-Post: <mailto:debbugs-submit <at> debbugs.gnu.org> List-Help: <mailto:debbugs-submit-request <at> debbugs.gnu.org?subject=help> List-Subscribe: <https://debbugs.gnu.org/cgi-bin/mailman/listinfo/debbugs-submit>, <mailto:debbugs-submit-request <at> debbugs.gnu.org?subject=subscribe> Errors-To: debbugs-submit-bounces <at> debbugs.gnu.org Sender: "Debbugs-submit" <debbugs-submit-bounces <at> debbugs.gnu.org> X-Spam-Score: -1.0 (-) Cecilio Pardo <cpardo@HIDDEN> writes: > + switch (keysym) > + { > + case GDK_KEY_Shift_L: > + case GDK_KEY_Shift_R: > + modifier = Qshift; > + break; > + case GDK_KEY_Control_L: > + case GDK_KEY_Control_R: > + modifier = Vx_ctrl_keysym; > + if (NILP (modifier)) > + modifier = Qctrl; > + break; > + case GDK_KEY_Alt_L: > + case GDK_KEY_Alt_R: > + modifier = Vx_meta_keysym; > + if (NILP (modifier)) > + modifier = Qalt; > + break; > + case GDK_KEY_Meta_L: > + case GDK_KEY_Meta_R: > + modifier = Vx_meta_keysym; > + if (NILP (modifier)) > + modifier = Qmeta; > + break; > + case GDK_KEY_Hyper_L: > + case GDK_KEY_Hyper_R: > + modifier = Vx_hyper_keysym; > + if (NILP (modifier)) > + modifier = Qhyper; > + break; > + case GDK_KEY_Super_L: > + case GDK_KEY_Super_R: > + modifier = Vx_super_keysym; > + if (NILP (modifier)) > + modifier = Qsuper; > + break; > + default: > + modifier = Qnil; > + } This is not the proper means of establishing the modifier bound to a key symbol in GTK, but I cannot immediately tell you what the alternative is. > + my_post_msg( &wmsg, hwnd, WM_EMACS_LOW_LEVEL_KEY, wParam, lParam ); > + } > + my_post_msg( &wmsg, hwnd, WM_EMACS_LOW_LEVEL_KEY, wParam, lParam ); > + } Stylistic issues. > +static void > +x_maybe_send_low_level_key_event (struct x_display_info *dpyinfo, > + const XEvent *xev) > +{ > + XKeyEvent xkey; > + bool is_press; > + KeySym keysym; > + Lisp_Object key, modifier; > + struct input_event ie; > + > + if (!Venable_low_level_key_events) > + return; > + > + switch (xev->type) > + { > + case KeyPress: > + is_press = true; > + xkey = xev->xkey; > + break; > + case KeyRelease: > + is_press = false; > + xkey = xev->xkey; > + break; > +#ifdef HAVE_XINPUT2 > + case GenericEvent: > + XIDeviceEvent *xiev = xev->xcookie.data; > + switch (xev->xgeneric.evtype) > + { > + case XI_KeyPress: > + is_press = true; > + break; > + case XI_KeyRelease: > + is_press = false; > + break; > + default: > + return; > + } > + > + xkey.serial = xiev->serial; > + xkey.send_event = xiev->send_event; > + xkey.display = xiev->display; > + xkey.window = xiev->event; > + xkey.root = xiev->root; > + xkey.subwindow = xiev->child; > + xkey.time = xiev->time; > + xkey.x = xiev->event_x; > + xkey.y = xiev->event_y; > + xkey.x_root = xiev->root_x; > + xkey.y_root = xiev->root_y; > + xkey.state = xiev->mods.effective; > + xkey.keycode = xiev->detail; > + xkey.same_screen = 1; > + break; > +#endif > + default: > + return; > + } > + > + struct frame *f = x_any_window_to_frame (dpyinfo, xkey.window); > + if (!f) > + return; > + > + XLookupString (&xkey, NULL, 0, &keysym, NULL); > + > + switch (keysym) > + { > + case XK_Shift_L: key = Qlshift; break; > + case XK_Shift_R: key = Qrshift; break; > + case XK_Control_L: key = Qlctrl; break; > + case XK_Control_R: key = Qrctrl; break; > + case XK_Alt_L: key = Qlalt; break; > + case XK_Alt_R: key = Qralt; break; > + default: > + key = Qnil; > + } This doesn't generate `ralt' events on my system, as that key produces the keysym ISO_Level3_Shift/ > + switch (keysym) > + { > + case XK_Shift_L: > + case XK_Shift_R: > + modifier = Qshift; > + break; > + case XK_Control_L: > + case XK_Control_R: > + modifier = Vx_ctrl_keysym; > + if (NILP (modifier)) > + modifier = Qctrl; > + break; > + case XK_Alt_L: > + case XK_Alt_R: > + modifier = Vx_meta_keysym; > + if (NILP (modifier)) > + modifier = Qalt; > + break; > + case XK_Meta_L: > + case XK_Meta_R: > + modifier = Vx_meta_keysym; > + if (NILP (modifier)) > + modifier = Qmeta; > + break; > + case XK_Hyper_L: > + case XK_Hyper_R: > + modifier = Vx_hyper_keysym; > + if (NILP (modifier)) > + modifier = Qhyper; > + break; > + case XK_Super_L: > + case XK_Super_R: > + modifier = Vx_super_keysym; > + if (NILP (modifier)) > + modifier = Qsuper; > + break; > + default: > + modifier = Qnil; > + } You are computing the modifier event to be generated incorrectly. You should search the modifier map (dpyinfo->modmap) for columns containing received keysyms, and compare modifier bits derived from the rows where they appear against meta_mod_mask, shift_lock_mask, alt_mod_mask, super_mod_mask, and hyper_mod_mask in the display structure, or CtrlMask and ShiftMask. > case KeyPress: > + x_maybe_send_low_level_key_event (dpyinfo, event); > x_display_set_last_user_time (dpyinfo, event->xkey.time, > event->xkey.send_event, > true); > @@ -20715,6 +20853,7 @@ handle_one_xevent (struct x_display_info *dpyinfo, > #endif > > case KeyRelease: > + x_maybe_send_low_level_key_event (dpyinfo, event); > #ifdef HAVE_X_I18N > /* Don't dispatch this event since XtDispatchEvent calls > XFilterEvent, and two calls in a row may freeze the > @@ -23970,6 +24109,8 @@ handle_one_xevent (struct x_display_info *dpyinfo, > struct xi_device_t *device, *source; > XKeyPressedEvent xkey; > > + x_maybe_send_low_level_key_event (dpyinfo, event); > + > coding = Qlatin_1; > > /* The code under this label is quite desultory. There > @@ -24586,6 +24727,8 @@ handle_one_xevent (struct x_display_info *dpyinfo, > #endif > > case XI_KeyRelease: > + x_maybe_send_low_level_key_event (dpyinfo, event); Would you rearrange the locations of calls to x_any_window_to_frame in handle_one_xevent so that you need not redundantly call the same function in x_maybe_send_low_level_key_event? Thanks for your interest in Emacs.
bug-gnu-emacs@HIDDEN
:bug#74423
; Package emacs
.
Full text available.Received: (at submit) by debbugs.gnu.org; 18 Nov 2024 20:35:56 +0000 From debbugs-submit-bounces <at> debbugs.gnu.org Mon Nov 18 15:35:56 2024 Received: from localhost ([127.0.0.1]:39370 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from <debbugs-submit-bounces <at> debbugs.gnu.org>) id 1tD8TS-0001Fn-Lk for submit <at> debbugs.gnu.org; Mon, 18 Nov 2024 15:35:56 -0500 Received: from lists.gnu.org ([209.51.188.17]:48072) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from <cpardo@HIDDEN>) id 1tD8TP-0001Fe-96 for submit <at> debbugs.gnu.org; Mon, 18 Nov 2024 15:35:52 -0500 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 <cpardo@HIDDEN>) id 1tD8TP-0000IX-2a for bug-gnu-emacs@HIDDEN; Mon, 18 Nov 2024 15:35:51 -0500 Received: from mail.imayhem.com ([82.223.54.191] helo=zealous-pike.82-223-54-191.plesk.page) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_128_GCM_SHA256:128) (Exim 4.90_1) (envelope-from <cpardo@HIDDEN>) id 1tD8TJ-0001EA-CS for bug-gnu-emacs@HIDDEN; Mon, 18 Nov 2024 15:35:50 -0500 Received: from [192.168.68.104] (111.red-88-21-7.staticip.rima-tde.net [88.21.7.111]) by zealous-pike.82-223-54-191.plesk.page (Postfix) with ESMTPSA id 43ACD800CD for <bug-gnu-emacs@HIDDEN>; Mon, 18 Nov 2024 20:35:41 +0000 (UTC) Authentication-Results: zealous-pike.82-223-54-191.plesk.page; spf=pass (sender IP is 88.21.7.111) smtp.mailfrom=cpardo@HIDDEN smtp.helo=[192.168.68.104] Received-SPF: pass (zealous-pike.82-223-54-191.plesk.page: connection is authenticated) Content-Type: multipart/mixed; boundary="------------NfVipp8PWcB7slQ6v5g6HUD0" Message-ID: <d5c72818-e907-43f5-853a-89ec01264157@HIDDEN> Date: Mon, 18 Nov 2024 21:35:40 +0100 MIME-Version: 1.0 User-Agent: Mozilla Thunderbird Subject: Low level key events To: bug-gnu-emacs@HIDDEN References: <fb50ec11-7aec-481e-8a3a-ecdcf22eb7c0@HIDDEN> <31bdc55d-8c13-4de0-9cef-bd6cc4fb033f@HIDDEN> <s1r8qtzsvbe.fsf@HIDDEN> Content-Language: es-ES From: Cecilio Pardo <cpardo@HIDDEN> In-Reply-To: <s1r8qtzsvbe.fsf@HIDDEN> Received-SPF: pass client-ip=82.223.54.191; envelope-from=cpardo@HIDDEN; helo=zealous-pike.82-223-54-191.plesk.page X-Spam_score_int: -18 X-Spam_score: -1.9 X-Spam_bar: - X-Spam_report: (-1.9 / 5.0 requ) BAYES_00=-1.9, RCVD_IN_VALIDITY_CERTIFIED_BLOCKED=0.001, RCVD_IN_VALIDITY_RPBL_BLOCKED=0.001, SPF_HELO_NONE=0.001, SPF_PASS=-0.001 autolearn=ham autolearn_force=no X-Spam_action: no action X-Spam-Score: -1.3 (-) X-Debbugs-Envelope-To: submit X-BeenThere: debbugs-submit <at> debbugs.gnu.org X-Mailman-Version: 2.1.18 Precedence: list List-Id: <debbugs-submit.debbugs.gnu.org> List-Unsubscribe: <https://debbugs.gnu.org/cgi-bin/mailman/options/debbugs-submit>, <mailto:debbugs-submit-request <at> debbugs.gnu.org?subject=unsubscribe> List-Archive: <https://debbugs.gnu.org/cgi-bin/mailman/private/debbugs-submit/> List-Post: <mailto:debbugs-submit <at> debbugs.gnu.org> List-Help: <mailto:debbugs-submit-request <at> debbugs.gnu.org?subject=help> List-Subscribe: <https://debbugs.gnu.org/cgi-bin/mailman/listinfo/debbugs-submit>, <mailto:debbugs-submit-request <at> debbugs.gnu.org?subject=subscribe> Errors-To: debbugs-submit-bounces <at> debbugs.gnu.org Sender: "Debbugs-submit" <debbugs-submit-bounces <at> debbugs.gnu.org> X-Spam-Score: -2.3 (--) This is a multi-part message in MIME format. --------------NfVipp8PWcB7slQ6v5g6HUD0 Content-Type: text/plain; charset=UTF-8; format=flowed Content-Transfer-Encoding: 7bit Here is a still incomplete patch for this, renamed from "physical keyboard events", following up to https://lists.gnu.org/archive/html/emacs-devel/2024-11/msg00085.html It provides events for press/release of keys, independently of the normal keyboard events. These events are bound int the special-event-map. Some lisp is included to implement detection of multiple tapping on keys, and running commands or simulating modifiers. Currently, only modifier keys are available, because other keys would send their own normal event. This could change when an use case for other keys appears. To provide events for 'logical' modifiers Ctrl, Meta, etc., now there is a new event low-level-modifier, in addition to low-level-key. If you press Shift_L, two events will be generated, one for 'shift as low-level-modifier, and one for 'lshift as low-level-key. The lisp part handles those events separately. I added a variable that enables/disables everything, enable-low-level-key-events. This are some of Po Lu's notes on the previous patch: > [...] Emacs must not depend on XKB for such a basic feature. Fixed. > Please find some means of generating such events by saving them into the > keyboard event buffer defined in handle_ome_xevent. As we may generate two events, that is not possible. > x_filter_events is not the proper location for this call. It is only > invoked to filter an event through the active GTK or X input method > context, and it is not invoked if Emacs is configured not to open input > method contexts, or they are unavailable by happenstance. Done. If XINPUT is enabled, the XI_KeyPress event used, over the gtk one. If not, the gtk event is used unless there is no input method. In this case KeyPress event is used. The pgtk version is not updated. --------------NfVipp8PWcB7slQ6v5g6HUD0 Content-Type: text/plain; charset=UTF-8; name="0001-Add-events-for-key-press-and-key-release-on-gui-syst.patch" Content-Disposition: attachment; filename*0="0001-Add-events-for-key-press-and-key-release-on-gui-syst.pa"; filename*1="tch" Content-Transfer-Encoding: base64 RnJvbSBkMjQwM2Q5ZmExNGI0OTgyNjNhYmIyNDIzMjRjMjE0NDFhNDI0NmFhIE1vbiBTZXAg MTcgMDA6MDA6MDAgMjAwMQpGcm9tOiBDZWNpbGlvIFBhcmRvIDxjcGFyZG9AaW1heWhlbS5j b20+CkRhdGU6IE1vbiwgMjggT2N0IDIwMjQgMjM6NTc6MzUgKzAxMDAKU3ViamVjdDogW1BB VENIXSBBZGQgZXZlbnRzIGZvciBrZXkgcHJlc3MgYW5kIGtleSByZWxlYXNlIG9uIGd1aSBz eXN0ZW1zLgoKQW5kIGRldGVjdGlvbiBvZiBkb3VibGUvdHJpcGxlIHRhcHMgb24gbW9kaWZp ZXIga2V5cy4KCiogbGlzcC9sb3ctbGV2ZWwta2V5LmVsIChsbGstdGFwLXRpbWVvdXQpOgoo bGxrLXRhcC1jb3VudCk6CihsbGstdGFwLWtleXMpOgoobGxrLWJpbmRpbmdzKToKKGxsay1t b2RpZmllci1iaW5kaW5ncyk6CihsbGstaW5pdCk6CihsbGstYmluZCk6CihsbGstbW9kaWZp ZXItYmluZCk6CihsbGstZXZlbnRzKToKKGxsay1tb2RpZmllci1ldmVudHMpOgoobGxtLWhh bmRsZSk6Ciogc3JjL2d0a3V0aWwuYyAoeGdfY3JlYXRlX2ZyYW1lX3dpZGdldHMpOgooeGdf bWF5YmVfc2VuZF9sb3dfbGV2ZWxfa2V5X2V2ZW50KToKKHhnX3dpZGdldF9rZXlfcHJlc3Nf ZXZlbnRfY2IpOgooeGdfd2lkZ2V0X2tleV9yZWxlYXNlX2V2ZW50X2NiKToKKiBzcmMveHRl cm0uYyAoeF9tYXliZV9zZW5kX3BoeXNpY2FsX2tleV9ldmVudCk6Cih4X2ZpbHRlcl9ldmVu dCk6CihoYW5kbGVfb25lX3hldmVudCk6CihzeW1zX29mX3h0ZXJtKToKLS0tCiBsaXNwL2xv dy1sZXZlbC1rZXkuZWwgfCAxNDEgKysrKysrKysrKysrKysrKysrKysrKysrKysrKysrKysr KysrKysrKysKIHNyYy9ndGt1dGlsLmMgICAgICAgICB8IDEzMyArKysrKysrKysrKysrKysr KysrKysrKysrKysrKysrKysrKysrKwogc3JjL2tleWJvYXJkLmMgICAgICAgIHwgIDM4ICsr KysrKysrKysrCiBzcmMvcGd0a3Rlcm0uYyAgICAgICAgfCAgMzcgKysrKysrKysrKysKIHNy Yy90ZXJtaG9va3MuaCAgICAgICB8ICAgMiArCiBzcmMvdzMyZm5zLmMgICAgICAgICAgfCAg MTEgKysrKwogc3JjL3czMnRlcm0uYyAgICAgICAgIHwgIDY5ICsrKysrKysrKysrKysrKysr KysrCiBzcmMvdzMydGVybS5oICAgICAgICAgfCAgIDMgKy0KIHNyYy94dGVybS5jICAgICAg ICAgICB8IDE0NCArKysrKysrKysrKysrKysrKysrKysrKysrKysrKysrKysrKysrKysrKysK IDkgZmlsZXMgY2hhbmdlZCwgNTc3IGluc2VydGlvbnMoKyksIDEgZGVsZXRpb24oLSkKIGNy ZWF0ZSBtb2RlIDEwMDY0NCBsaXNwL2xvdy1sZXZlbC1rZXkuZWwKCmRpZmYgLS1naXQgYS9s aXNwL2xvdy1sZXZlbC1rZXkuZWwgYi9saXNwL2xvdy1sZXZlbC1rZXkuZWwKbmV3IGZpbGUg bW9kZSAxMDA2NDQKaW5kZXggMDAwMDAwMDAwMDAuLjYzOWMwODJkYTE1Ci0tLSAvZGV2L251 bGwKKysrIGIvbGlzcC9sb3ctbGV2ZWwta2V5LmVsCkBAIC0wLDAgKzEsMTQxIEBACis7Ozsg LSotIGxleGljYWwtYmluZGluZzogdCAtKi0KKyhyZXF1aXJlICdjb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W5kIGxsay1ldmVudHMKKyAgICAgICAgICAgKG5vdCAo ZXF1YWwgKGNsLXRoaXJkIChjYXIgbGxrLWV2ZW50cykpIGtleSkpCisgICAgICAgICAgIChz ZXRxIGxsay1ldmVudHMgbmlsKSkKKyAgICAgIChwdXNoIGxhc3QtaW5wdXQtZXZlbnQgbGxr LWV2ZW50cykKKyAgICAgIDs7IE9ubHkgY2FyZSBhYm91dCBsYXN0IDJ4TiBldmVudHMKKyAg ICAgIChudGFrZSAoKiAyIG4pIGxsay1ldmVudHMpCisgICAgICA7OyBJZiB3ZSBoYXZlOgor ICAgICAgOzsgLSBFeGFjdGx5IDIgKiBuIGV2ZW50cy4KKyAgICAgIDs7IC0gZG93biwgdXAs IGRvd24sIHVwLCAuLi4KKyAgICAgIDs7IC0gbm90IHR3byBtdWNoIHRpbWUgYmV0d2VlbiBm aXJzdCBhbmQgbGFzdAorICAgICAgKGFuZCAoZXEgKCogMiBuKSAobGVuZ3RoIGxsay1ldmVu dHMpKQorICAgICAgICAgICAoY2wtZXZlcnkgJ2VxCisgICAgICAgICAgICAgICAgICAgICAo bnRha2UgKCogMiBuKQorICAgICAgICAgICAgICAgICAgICAgICAgICAgIChsaXN0IG5pbCB0 IG5pbCB0IG5pbCB0IG5pbCB0CisgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAg bmlsIHQgbmlsIHQgbmlsIHQgbmlsIHQpKQorICAgICAgICAgICAgICAgICAgICAgKG1hcGNh ciAnY2wtc2Vjb25kIGxsay1ldmVudHMpKQorICAgICAgICAgICAoPCAoLSAoY2wtZm91cnRo IChjbC1maXJzdCBsbGstZXZlbnRzKSkKKyAgICAgICAgICAgICAgICAgKGNsLWZvdXJ0aCAo Y2FyIChsYXN0IGxsay1ldmVudHMpKSkpCisgICAgICAgICAgICAgIHRpbWVvdXQpCisgICAg ICAgICAgIChwcm9nbgorICAgICAgICAgICAgIChzZXRxIGxsay1ldmVudHMgbmlsKQorICAg ICAgICAgICAgIGtleSkpKSkpCisKKworOzsgdGhpcyBmdW5jdGlvbiBpcyBhIGNvcHkgb2Yg bGxrLWRldGVjdC1uLXRhcCwgYnV0IGZvciBsbG0tZXZlbnRzCisoZGVmdW4gbGxtLWRldGVj dC1uLXRhcCAobiB0aW1lb3V0KQorICAobGV0ICgoa2V5IChjbC10aGlyZCBsYXN0LWlucHV0 LWV2ZW50KSkpCisgICAgKGlmIChub3QgKG1lbWJlciBrZXkgbGxrLXRhcC1rZXlzKSkKKyAg ICAgICAgKHNldHEgbGxtLWV2ZW50cyBuaWwpCisgICAgICAoYW5kIGxsbS1ldmVudHMKKyAg ICAgICAgICAgKG5vdCAoZXF1YWwgKGNsLXRoaXJkIChjYXIgbGxtLWV2ZW50cykpIGtleSkp CisgICAgICAgICAgIChzZXRxIGxsbS1ldmVudHMgbmlsKSkKKyAgICAgIChwdXNoIGxhc3Qt aW5wdXQtZXZlbnQgbGxtLWV2ZW50cykKKyAgICAgIChudGFrZSAoKiAyIG4pIGxsbS1ldmVu dHMpCisgICAgICAoYW5kIChlcSAoKiAyIG4pIChsZW5ndGggbGxtLWV2ZW50cykpCisgICAg ICAgICAgIChjbC1ldmVyeSAnZXEKKyAgICAgICAgICAgICAgICAgICAgIChudGFrZSAoKiAy IG4pCisgICAgICAgICAgICAgICAgICAgICAgICAgICAgKGxpc3QgbmlsIHQgbmlsIHQgbmls IHQgbmlsIHQKKyAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICBuaWwgdCBuaWwg dCBuaWwgdCBuaWwgdCkpCisgICAgICAgICAgICAgICAgICAgICAobWFwY2FyICdjbC1zZWNv bmQgbGxtLWV2ZW50cykpCisgICAgICAgICAgICg8ICgtIChjbC1mb3VydGggKGNsLWZpcnN0 IGxsbS1ldmVudHMpKQorICAgICAgICAgICAgICAgICAoY2wtZm91cnRoIChjYXIgKGxhc3Qg bGxtLWV2ZW50cykpKSkKKyAgICAgICAgICAgICAgdGltZW91dCkKKyAgICAgICAgICAgKHBy b2duCisgICAgICAgICAgICAgKHNldHEgbGxtLWV2ZW50cyBuaWwpCisgICAgICAgICAgICAg a2V5KSkpKSkKKworKGRlZnVuIGxsay1oYW5kbGUgKCkKKyAgKGludGVyYWN0aXZlKQorCisg IChsZXQgKCh0YXAta2V5IChsbGstZGV0ZWN0LW4tdGFwCisgICAgICAgICAgICAgICAgICBs bGstdGFwLWNvdW50CisgICAgICAgICAgICAgICAgICBsbGstdGFwLXRpbWVvdXQpKSkKKyAg ICAod2hlbiB0YXAta2V5CisgICAgICAobGV0ICgoZnVuYyAoY2wtdGhpcmQKKyAgICAgICAg ICAgICAgICAgICAoc2VxLWZpbmQKKyAgICAgICAgICAgICAgICAgICAgKGxhbWJkYSAoYikK KyAgICAgICAgICAgICAgICAgICAgICAoYW5kIChlcSAoY2wtZmlyc3QgYikgJ3RhcCkKKyAg ICAgICAgICAgICAgICAgICAgICAgICAgIChlcSAoY2wtc2Vjb25kIGIpIHRhcC1rZXkpKSkK KyAgICAgICAgICAgICAgICAgICAgbGxrLWJpbmRpbmdzKSkpKQorICAgICAgICAoY29uZAor ICAgICAgICAgKChjb21tYW5kcCBmdW5jKSAoY2FsbC1pbnRlcmFjdGl2ZWx5IGZ1bmMpKQor ICAgICAgICAgKChmdW5jdGlvbnAgZnVuYykgKGZ1bmNhbGwgZnVuYykpCisgICAgICAgICAo KGVxICdoeXBlciBmdW5jKQorICAgICAgICAgIChtZXNzYWdlICJILS4uLiIpCisgICAgICAg ICAgKGxldCAoKHIgKHJlYWQtZXZlbnQpKSkKKyAgICAgICAgICAgIChzZXRxIHVucmVhZC1j b21tYW5kLWV2ZW50cworICAgICAgICAgICAgICAgICAgKGxpc3QgKGV2ZW50LWFwcGx5LW1v ZGlmaWVyCisgICAgICAgICAgICAgICAgICAgICAgICAgciAnaHlwZXIgMjQgIkgtIikpKSkp KSkpKSkKKworKGRlZnVuIGxsbS1oYW5kbGUoKQorICAoaW50ZXJhY3RpdmUpCisKKyAgKGxl dCAoKHRhcC1rZXkgKGxsbS1kZXRlY3Qtbi10YXAKKyAgICAgICAgICAgICAgICAgIGxsay10 YXAtY291bnQKKyAgICAgICAgICAgICAgICAgIGxsay10YXAtdGltZW91dCkpKQorICAgICh3 aGVuIHRhcC1rZXkKKyAgICAgIChsZXQgKChmdW5jIChjbC10aGlyZAorICAgICAgICAgICAg ICAgICAgIChzZXEtZmluZAorICAgICAgICAgICAgICAgICAgICAobGFtYmRhIChiKQorICAg ICAgICAgICAgICAgICAgICAgIChhbmQgKGVxIChjbC1maXJzdCBiKSAndGFwKQorICAgICAg ICAgICAgICAgICAgICAgICAgICAgKGVxIChjbC1zZWNvbmQgYikgdGFwLWtleSkpKQorICAg ICAgICAgICAgICAgICAgICBsbG0tYmluZGluZ3MpKSkpCisgICAgICAgIChjb25kCisgICAg ICAgICAoKGNvbW1hbmRwIGZ1bmMpIChjYWxsLWludGVyYWN0aXZlbHkgZnVuYykpCisgICAg ICAgICAoKGZ1bmN0aW9ucCBmdW5jKSAoZnVuY2FsbCBmdW5jKSkKKyAgICAgICAgICgoZXEg J2h5cGVyIGZ1bmMpCisgICAgICAgICAgKG1lc3NhZ2UgIkgtLi4uIikKKyAgICAgICAgICAo bGV0ICgociAocmVhZC1ldmVudCkpKQorICAgICAgICAgICAgKHNldHEgdW5yZWFkLWNvbW1h bmQtZXZlbnRzCisgICAgICAgICAgICAgICAgICAobGlzdCAoZXZlbnQtYXBwbHktbW9kaWZp ZXIKKyAgICAgICAgICAgICAgICAgICAgICAgICByICdoeXBlciAyNCAiSC0iKSkpKSkpKSkp KQpkaWZmIC0tZ2l0IGEvc3JjL2d0a3V0aWwuYyBiL3NyYy9ndGt1dGlsLmMKaW5kZXggZDU3 NjI3ZjE1MmYuLjZjYTRlMzEzOTI5IDEwMDY0NAotLS0gYS9zcmMvZ3RrdXRpbC5jCisrKyBi L3NyYy9ndGt1dGlsLmMKQEAgLTk4LDYgKzk4LDcgQEAgR19ERUZJTkVfVFlQRSAoRW1hY3NN ZW51QmFyLCBlbWFjc19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GtiZF9idWZmZXJfc3RvcmVfZXZlbnQgKCZpbmV2KTsKIH0KIAorc3RhdGljIHZvaWQK K3hnX21heWJlX3NlbmRfbG93X2xldmVsX2tleV9ldmVudCAoc3RydWN0IGZyYW1lICpmLAor CQkJCSAgIEdka0V2ZW50ICp4ZXYpCit7CisgIEdka0V2ZW50S2V5IHhrZXkgPSB4ZXYtPmtl eTsKKyAgYm9vbCBpc19wcmVzczsKKyAgaW50IGtleXN5bTsKKyAgTGlzcF9PYmplY3Qga2V5 LCBtb2RpZmllcjsKKyAgdW5pb24gYnVmZmVyZWRfaW5wdXRfZXZlbnQgaW5ldjsKKworICBp ZiAoIVZlbmFibGVfbG93X2xldmVsX2tleV9ldmVudHMpCisgICAgcmV0dXJuOworICBzd2l0 Y2ggKHhldi0+dHlwZSkKKyAgICB7CisgICAgY2FzZSBHREtfS0VZX1BSRVNTOgorICAgICAg aXNfcHJlc3MgPSB0cnVlOworICAgICAgYnJlYWs7CisgICAgY2FzZSBHREtfS0VZX1JFTEVB U0U6CisgICAgICBpc19wcmVzcyA9IGZhbHNlOworICAgICAgYnJlYWs7CisgICAgZGVmYXVs dDoKKyAgICAgIHJldHVybjsKKyAgICB9CisKKyAga2V5c3ltID0geGtleS5rZXl2YWw7CisK KyAgc3dpdGNoIChrZXlzeW0pCisgICAgeworICAgIGNhc2UgR0RLX0tFWV9TaGlmdF9MOiBr ZXkgPSBRbHNoaWZ0OyBicmVhazsKKyAgICBjYXNlIEdES19LRVlfU2hpZnRfUjoga2V5ID0g UXJzaGlmdDsgYnJlYWs7CisgICAgY2FzZSBHREtfS0VZX0NvbnRyb2xfTDoga2V5ID0gUWxj dHJsOyBicmVhazsKKyAgICBjYXNlIEdES19LRVlfQ29udHJvbF9SOiBrZXkgPSBRcmN0cmw7 IGJyZWFrOworICAgIGNhc2UgR0RLX0tFWV9BbHRfTDoga2V5ID0gUWxhbHQ7IGJyZWFrOwor ICAgIGNhc2UgR0RLX0tFWV9BbHRfUjoga2V5ID0gUXJhbHQ7IGJyZWFrOworICAgIGRlZmF1 bHQ6CisgICAgICBrZXkgPSBRbmlsOworICAgIH0KKworICAgc3dpdGNoIChrZXlzeW0pCisg ICAgeworICAgIGNhc2UgR0RLX0tFWV9TaGlmdF9MOgorICAgIGNhc2UgR0RLX0tFWV9TaGlm dF9SOgorICAgICAgbW9kaWZpZXIgPSBRc2hpZnQ7CisgICAgICBicmVhazsKKyAgICBjYXNl IEdES19LRVlfQ29udHJvbF9MOgorICAgIGNhc2UgR0RLX0tFWV9Db250cm9sX1I6CisgICAg ICBtb2RpZmllciA9IFZ4X2N0cmxfa2V5c3ltOworICAgICAgaWYgKE5JTFAgKG1vZGlmaWVy KSkKKwltb2RpZmllciA9IFFjdHJsOworICAgICAgYnJlYWs7CisgICAgY2FzZSBHREtfS0VZ X0FsdF9MOgorICAgIGNhc2UgR0RLX0tFWV9BbHRfUjoKKyAgICAgIG1vZGlmaWVyID0gVnhf bWV0YV9rZXlzeW07CisgICAgICBpZiAoTklMUCAobW9kaWZpZXIpKQorCW1vZGlmaWVyID0g UWFsdDsKKyAgICAgIGJyZWFrOworICAgIGNhc2UgR0RLX0tFWV9NZXRhX0w6CisgICAgY2Fz ZSBHREtfS0VZX01ldGFfUjoKKyAgICAgIG1vZGlmaWVyID0gVnhfbWV0YV9rZXlzeW07Cisg ICAgICBpZiAoTklMUCAobW9kaWZpZXIpKQorCW1vZGlmaWVyID0gUW1ldGE7CisgICAgICBi cmVhazsKKyAgICBjYXNlIEdES19LRVlfSHlwZXJfTDoKKyAgICBjYXNlIEdES19LRVlfSHlw ZXJfUjoKKyAgICAgIG1vZGlmaWVyID0gVnhfaHlwZXJfa2V5c3ltOworICAgICAgaWYgKE5J TFAgKG1vZGlmaWVyKSkKKwltb2RpZmllciA9IFFoeXBlcjsKKyAgICAgIGJyZWFrOworICAg IGNhc2UgR0RLX0tFWV9TdXBlcl9MOgorICAgIGNhc2UgR0RLX0tFWV9TdXBlcl9SOgorICAg ICAgbW9kaWZpZXIgPSBWeF9zdXBlcl9rZXlzeW07CisgICAgICBpZiAoTklMUCAobW9kaWZp ZXIpKQorCW1vZGlmaWVyID0gUXN1cGVyOworICAgICAgYnJlYWs7CisgICAgZGVmYXVsdDoK KyAgICAgIG1vZGlmaWVyID0gUW5pbDsKKyAgICB9CisKKyAgaWYgKCFOSUxQIChrZXkpKQor ICAgIHsKKyAgICAgIEVWRU5UX0lOSVQgKGluZXYuaWUpOworICAgICAgWFNFVEZSQU1FIChp bmV2LmllLmZyYW1lX29yX3dpbmRvdywgZik7CisgICAgICBpbmV2LmllLmtpbmQgPSBMT1df TEVWRUxfS0VZX0VWRU5UOworICAgICAgaW5ldi5pZS50aW1lc3RhbXAgPSB4a2V5LnRpbWU7 CisgICAgICBpbmV2LmllLmFyZyA9IGxpc3QyIChpc19wcmVzcyA/IFF0IDogUW5pbCwga2V5 KTsKKyAgICAgIGtiZF9idWZmZXJfc3RvcmVfYnVmZmVyZWRfZXZlbnQgKCZpbmV2LCAmeGdf cGVuZGluZ19xdWl0X2V2ZW50KTsKKyAgICB9CisKKyAgaWYgKCFOSUxQIChtb2RpZmllcikp CisgICAgeworICAgICAgRVZFTlRfSU5JVCAoaW5ldi5pZSk7CisgICAgICBYU0VURlJBTUUg KGluZXYuaWUuZnJhbWVfb3Jfd2luZG93LCBmKTsKKyAgICAgIGluZXYuaWUua2luZCA9IExP V19MRVZFTF9NT0RJRklFUl9LRVlfRVZFTlQ7CisgICAgICBpbmV2LmllLnRpbWVzdGFtcCA9 IHhrZXkudGltZTsKKyAgICAgIGluZXYuaWUuYXJnID0gbGlzdDIgKGlzX3ByZXNzID8gUXQg OiBRbmlsLCBtb2RpZmllcik7CisgICAgICBrYmRfYnVmZmVyX3N0b3JlX2J1ZmZlcmVkX2V2 ZW50ICgmaW5ldiwgJnhnX3BlbmRpbmdfcXVpdF9ldmVudCk7CisgICAgfQorfQorCiBzdGF0 aWMgYm9vbAogeGdfd2lkZ2V0X2tleV9wcmVzc19ldmV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7CisgICAgICB4a2V5ID0geGV2LT54a2V5OworICAgICAg YnJlYWs7CisgICAgY2FzZSBLZXlSZWxlYXNlOgorICAgICAgaXNfcHJlc3MgPSBmYWxzZTsK KyAgICAgIHhrZXkgPSB4ZXYtPnhrZXk7CisgICAgICBicmVhazsKKyNpZmRlZiBIQVZFX1hJ TlBVVDIKKyAgICBjYXNlIEdlbmVyaWNFdmVudDoKKyAgICAgIFhJRGV2aWNlRXZlbnQgKnhp ZXYgPSB4ZXYtPnhjb29raWUuZGF0YTsKKyAgICAgIHN3aXRjaCAoeGV2LT54Z2VuZXJpYy5l dnR5cGUpCisJeworCWNhc2UgWElfS2V5UHJlc3M6CisJICBpc19wcmVzcyA9IHRydWU7CisJ ICBicmVhazsKKwljYXNlIFhJX0tleVJlbGVhc2U6CisJICBpc19wcmVzcyA9IGZhbHNlOwor CSAgYnJlYWs7CisJZGVmYXVsdDoKKwkgIHJldHVybjsKKwl9CisKKyAgICAgIHhrZXkuc2Vy aWFsID0geGlldi0+c2VyaWFsOworICAgICAgeGtleS5zZW5kX2V2ZW50ID0geGlldi0+c2Vu ZF9ldmVudDsKKyAgICAgIHhrZXkuZGlzcGxheSA9IHhpZXYtPmRpc3BsYXk7CisgICAgICB4 a2V5LndpbmRvdyA9IHhpZXYtPmV2ZW50OworICAgICAgeGtleS5yb290ID0geGlldi0+cm9v dDsKKyAgICAgIHhrZXkuc3Vid2luZG93ID0geGlldi0+Y2hpbGQ7CisgICAgICB4a2V5LnRp bWUgPSB4aWV2LT50aW1lOworICAgICAgeGtleS54ID0geGlldi0+ZXZlbnRfeDsKKyAgICAg IHhrZXkueSA9IHhpZXYtPmV2ZW50X3k7CisgICAgICB4a2V5Lnhfcm9vdCA9IHhpZXYtPnJv b3RfeDsKKyAgICAgIHhrZXkueV9yb290ID0geGlldi0+cm9vdF95OworICAgICAgeGtleS5z dGF0ZSA9IHhpZXYtPm1vZHMuZWZmZWN0aXZlOworICAgICAgeGtleS5rZXljb2RlID0geGll di0+ZGV0YWlsOworICAgICAgeGtleS5zYW1lX3NjcmVlbiA9IDE7CisgICAgICBicmVhazsK KyNlbmRpZgorICAgIGRlZmF1bHQ6CisgICAgICByZXR1cm47CisgICAgfQorCisgIHN0cnVj dCBmcmFtZSAqZiA9IHhfYW55X3dpbmRvd190b19mcmFtZSAoZHB5aW5mbywgeGtleS53aW5k b3cpOworICBpZiAoIWYpCisgICAgcmV0dXJuOworCisgIFhMb29rdXBTdHJpbmcgKCZ4a2V5 LCBOVUxMLCAwLCAma2V5c3ltLCBOVUxMKTsKKworICBzd2l0Y2ggKGtleXN5bSkKKyAgICB7 CisgICAgY2FzZSBYS19TaGlmdF9MOiBrZXkgPSBRbHNoaWZ0OyBicmVhazsKKyAgICBjYXNl IFhLX1NoaWZ0X1I6IGtleSA9IFFyc2hpZnQ7IGJyZWFrOworICAgIGNhc2UgWEtfQ29udHJv bF9MOiBrZXkgPSBRbGN0cmw7IGJyZWFrOworICAgIGNhc2UgWEtfQ29udHJvbF9SOiBrZXkg PSBRcmN0cmw7IGJyZWFrOworICAgIGNhc2UgWEtfQWx0X0w6IGtleSA9IFFsYWx0OyBicmVh azsKKyAgICBjYXNlIFhLX0FsdF9SOiBrZXkgPSBRcmFsdDsgYnJlYWs7CisgICAgZGVmYXVs dDoKKyAgICAgIGtleSA9IFFuaWw7CisgICAgfQorCisgICBzd2l0Y2ggKGtleXN5bSkKKyAg ICB7CisgICAgY2FzZSBYS19TaGlmdF9MOgorICAgIGNhc2UgWEtfU2hpZnRfUjoKKyAgICAg IG1vZGlmaWVyID0gUXNoaWZ0OworICAgICAgYnJlYWs7CisgICAgY2FzZSBYS19Db250cm9s X0w6CisgICAgY2FzZSBYS19Db250cm9sX1I6CisgICAgICBtb2RpZmllciA9IFZ4X2N0cmxf a2V5c3ltOworICAgICAgaWYgKE5JTFAgKG1vZGlmaWVyKSkKKwltb2RpZmllciA9IFFjdHJs OworICAgICAgYnJlYWs7CisgICAgY2FzZSBYS19BbHRfTDoKKyAgICBjYXNlIFhLX0FsdF9S OgorICAgICAgbW9kaWZpZXIgPSBWeF9tZXRhX2tleXN5bTsKKyAgICAgIGlmIChOSUxQICht b2RpZmllcikpCisJbW9kaWZpZXIgPSBRYWx0OworICAgICAgYnJlYWs7CisgICAgY2FzZSBY S19NZXRhX0w6CisgICAgY2FzZSBYS19NZXRhX1I6CisgICAgICBtb2RpZmllciA9IFZ4X21l dGFfa2V5c3ltOworICAgICAgaWYgKE5JTFAgKG1vZGlmaWVyKSkKKwltb2RpZmllciA9IFFt ZXRhOworICAgICAgYnJlYWs7CisgICAgY2FzZSBYS19IeXBlcl9MOgorICAgIGNhc2UgWEtf SHlwZXJfUjoKKyAgICAgIG1vZGlmaWVyID0gVnhfaHlwZXJfa2V5c3ltOworICAgICAgaWYg KE5JTFAgKG1vZGlmaWVyKSkKKwltb2RpZmllciA9IFFoeXBlcjsKKyAgICAgIGJyZWFrOwor ICAgIGNhc2UgWEtfU3VwZXJfTDoKKyAgICBjYXNlIFhLX1N1cGVyX1I6CisgICAgICBtb2Rp ZmllciA9IFZ4X3N1cGVyX2tleXN5bTsKKyAgICAgIGlmIChOSUxQIChtb2RpZmllcikpCisJ bW9kaWZpZXIgPSBRc3VwZXI7CisgICAgICBicmVhazsKKyAgICBkZWZhdWx0OgorICAgICAg bW9kaWZpZXIgPSBRbmlsOworICAgIH0KKworICBpZiAoIU5JTFAgKGtleSkpCisgICAgewor ICAgICAgRVZFTlRfSU5JVCAoaWUpOworICAgICAgWFNFVEZSQU1FIChpZS5mcmFtZV9vcl93 aW5kb3csIGYpOworICAgICAgaWUua2luZCA9IExPV19MRVZFTF9LRVlfRVZFTlQ7CisgICAg ICBpZS50aW1lc3RhbXAgPSB4a2V5LnRpbWU7CisgICAgICBpZS5hcmcgPSBsaXN0MiAoaXNf cHJlc3MgPyBRdCA6IFFuaWwsIGtleSk7CisgICAgICBrYmRfYnVmZmVyX3N0b3JlX2V2ZW50 ICgmaWUpOworICAgIH0KKworICBpZiAoI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a2l0X3Njcm9sbF9iYXJz ID0gUW5pbDsKICNlbmRpZgogCisgIERFRlNZTSAoUXNoaWZ0LCAic2hpZnQiKTsKICAgREVG U1lNIChRbW9kaWZpZXJfdmFsdWUsICJtb2RpZmllci12YWx1ZSIpOwogICBERUZTWU0gKFFj dHJsLCAiY3RybCIpOwogICBGcHV0IChRY3RybCwgUW1vZGlmaWVyX3ZhbHVlLCBtYWtlX2Zp eG51bSAoY3RybF9tb2RpZmllcikpOwotLSAKMi4zNS4xLndpbmRvd3MuMgoK --------------NfVipp8PWcB7slQ6v5g6HUD0--
Cecilio Pardo <cpardo@HIDDEN>
:bug-gnu-emacs@HIDDEN
.
Full text available.bug-gnu-emacs@HIDDEN
:bug#74423
; Package emacs
.
Full text available.
GNU bug tracking system
Copyright (C) 1999 Darren O. Benham,
1997 nCipher Corporation Ltd,
1994-97 Ian Jackson.