From mboxrd@z Thu Jan 1 00:00:00 1970 Path: news.gmane.io!.POSTED.blaine.gmane.org!not-for-mail From: Susam Pal Newsgroups: gmane.emacs.devel Subject: Re: [NonGNU ELPA] New package: devil Date: Thu, 11 May 2023 11:09:37 +0100 Message-ID: References: <87ttwjbfqq.fsf@gmail.com> <83y1lv5qe9.fsf@gnu.org> <87lehv2wd9.fsf@posteo.net> <87zg6bw91n.fsf@posteo.net> <83o7mr5jnj.fsf@gnu.org> <87sfc3w7sm.fsf@posteo.net> Mime-Version: 1.0 Content-Type: text/plain; charset="UTF-8" Injection-Info: ciao.gmane.io; posting-host="blaine.gmane.org:116.202.254.214"; logging-data="20294"; mail-complaints-to="usenet@ciao.gmane.io" Cc: Philip Kaludercic , emacs-devel@gnu.org To: Ruijie Yu Original-X-From: emacs-devel-bounces+ged-emacs-devel=m.gmane-mx.org@gnu.org Thu May 11 12:10:53 2023 Return-path: Envelope-to: ged-emacs-devel@m.gmane-mx.org Original-Received: from lists.gnu.org ([209.51.188.17]) by ciao.gmane.io with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.92) (envelope-from ) id 1px3G9-00054E-11 for ged-emacs-devel@m.gmane-mx.org; Thu, 11 May 2023 12:10:53 +0200 Original-Received: from localhost ([::1] helo=lists1p.gnu.org) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1px3Fe-00084H-4x; Thu, 11 May 2023 06:10:22 -0400 Original-Received: from eggs.gnu.org ([2001:470:142:3::10]) by lists.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1px3FZ-00082N-Aq for emacs-devel@gnu.org; Thu, 11 May 2023 06:10:18 -0400 Original-Received: from mail-yw1-x1133.google.com ([2607:f8b0:4864:20::1133]) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_128_GCM_SHA256:128) (Exim 4.90_1) (envelope-from ) id 1px3FW-00022G-VU for emacs-devel@gnu.org; Thu, 11 May 2023 06:10:17 -0400 Original-Received: by mail-yw1-x1133.google.com with SMTP id 00721157ae682-55b7630a736so126326137b3.1 for ; Thu, 11 May 2023 03:10:14 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20221208; t=1683799813; x=1686391813; h=cc:to:subject:message-id:date:from:in-reply-to:references :mime-version:from:to:cc:subject:date:message-id:reply-to; bh=0fuPVyaphpVzCVlp33FZabvkOrZw99IKbYYIjo95qyQ=; b=Zrr1bMMtHd51oOGBQ3KfMvkdjL4nCWEnLnxW6A6B57Jo49Lr1YbDbku6k8Gtny/vDL FX+G8nSRaaNhFFgVrCn9noekV7ZdUt12RoVTptlyTJlczGSsJCXcYnCwC4V4krZ7pSKw DuQtJafNcQzHgJc82nojHjb7khFGExTYqLWlxtfVc1B83DPY3VMaVrDSqytEzFAcqnXh 8sZasY6X2ypAVUTKSK4pUCN0thEd4IGvEYbdZM9re0yv301nppE76Ksd+Rm3hj57HnQ/ mgs+W1fNL1SjTh7yoYyEO9bcY8elcAgWXhXO/lNgUuvDrzRBHHpHU4a8WRE38I0w8Ld/ s68w== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20221208; t=1683799813; x=1686391813; h=cc:to:subject:message-id:date:from:in-reply-to:references :mime-version:x-gm-message-state:from:to:cc:subject:date:message-id :reply-to; bh=0fuPVyaphpVzCVlp33FZabvkOrZw99IKbYYIjo95qyQ=; b=NTHTJHAVNPjemATQFOsLnHRaxwBSMgvyWWr3AxXPf/Qpvl8ojcvwHMlFEWfHL7R4ai hy9RYsd+PeT4f93rPvPyR+q480o2Mu6WnOR5VdssAHx/wVGP5RL8PW82HQ9Ez0GnCvcX Eo0pmq6V2+A8J3vuEGFwZW1zhlD5lqoGoyJZ+i04ASHqbA0rNgjr3N1HQ/m53K9+MOFa Obu10+wA+Un+cP762+1CtBXjLsAqYeiX7xtN9Y1EblYUTUxuEDHdYeq1ghqt/D/PfBnX RTuUfikER5IFT/9W7R/YQOmVKkHGkTxUhYZ2KbuODxxLxrDZMR0A+iOQ/Rw+XhZDOA5W nviw== X-Gm-Message-State: AC+VfDzsAtXgroAZCyivy1GfJvoPOK8v+becEac7tnpCbq4LgPPlprFo 6XfRWrN6JDbi0rWmQeHaxTxvf8wvVH9gVIfXh6I= X-Google-Smtp-Source: ACHHUZ4ApgqAZhVGwQKagWZYLxD1RCjms7D1nNLf/5BbiA0e+AlbxJElr83Wab/dZS3gCf8bIJYvKAWXpYV4VcXHI6Y= X-Received: by 2002:a81:4fd6:0:b0:55a:5a38:46e4 with SMTP id d205-20020a814fd6000000b0055a5a3846e4mr19952007ywb.47.1683799813447; Thu, 11 May 2023 03:10:13 -0700 (PDT) In-Reply-To: Received-SPF: pass client-ip=2607:f8b0:4864:20::1133; envelope-from=susam.pal@gmail.com; helo=mail-yw1-x1133.google.com X-Spam_score_int: -20 X-Spam_score: -2.1 X-Spam_bar: -- X-Spam_report: (-2.1 / 5.0 requ) BAYES_00=-1.9, DKIM_SIGNED=0.1, DKIM_VALID=-0.1, DKIM_VALID_AU=-0.1, DKIM_VALID_EF=-0.1, FREEMAIL_FROM=0.001, RCVD_IN_DNSWL_NONE=-0.0001, SPF_HELO_NONE=0.001, SPF_PASS=-0.001, T_SCC_BODY_TEXT_LINE=-0.01 autolearn=ham autolearn_force=no X-Spam_action: no action X-BeenThere: emacs-devel@gnu.org X-Mailman-Version: 2.1.29 Precedence: list List-Id: "Emacs development discussions." List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: emacs-devel-bounces+ged-emacs-devel=m.gmane-mx.org@gnu.org Original-Sender: emacs-devel-bounces+ged-emacs-devel=m.gmane-mx.org@gnu.org Xref: news.gmane.io gmane.emacs.devel:306053 Archived-At: Ruijie Yu wrote: > > > Susam Pal writes: > > >> > "Minor mode for reading and translating key sequences." > >> ^ > >> is this redundant? hard to translate without reading. > >> > >> That sounds very generic, is the package capable of doing that for any > >> kind of key translation. > > > > Thanks for the feedback. In that case, > > > > "Minor mode for translating key sequences." > > Can your package translate more than just modifier keys like control or > meta? Like translate key sequence "j k" into something else? > > If the answer is no, then maybe you should clarify that in the > description. Yes, this is possible. Although the defaults cater to how I and some other users use this package, i.e., converting comma-prefixed key sequences with modifier-based key sequences, the key sequence translation logic does not make any assumption about modifier keys. For example, one could configure the following key translations: (setq devil-key "j") (require 'devil) (global-devil-mode) (setq devil-logging t) (setq devil-translations '(("%k k" . "RET") ("%k l" . "") ("%k m" . "C-M-"))) Assuming vanilla Emacs key bindings have not been altered, now typing "j j" results in a newline. Typing "j l" opens the menu bar. Similarly, typing "j m s" results in regexp i-search. Regards, Susam