From mboxrd@z Thu Jan 1 00:00:00 1970 Path: news.gmane.io!.POSTED.blaine.gmane.org!not-for-mail From: Fu Yuan Newsgroups: gmane.emacs.devel Subject: Re: Repeat undo-only is not working Date: Mon, 23 Aug 2021 06:52:51 -0700 Message-ID: <949B151B-7E8D-47D9-8BD9-DA69EA74AC98@gmail.com> References: <20210823131240.rxfepbz4q2buo733@Ergus> Mime-Version: 1.0 (1.0) Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: quoted-printable Injection-Info: ciao.gmane.io; posting-host="blaine.gmane.org:116.202.254.214"; logging-data="28182"; mail-complaints-to="usenet@ciao.gmane.io" Cc: emacs-devel , Juri Linkov To: Ergus Original-X-From: emacs-devel-bounces+ged-emacs-devel=m.gmane-mx.org@gnu.org Mon Aug 23 15:54:28 2021 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 1mIAPE-00075v-Ks for ged-emacs-devel@m.gmane-mx.org; Mon, 23 Aug 2021 15:54:28 +0200 Original-Received: from localhost ([::1]:58952 helo=lists1p.gnu.org) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1mIAPD-0007jy-2h for ged-emacs-devel@m.gmane-mx.org; Mon, 23 Aug 2021 09:54:27 -0400 Original-Received: from eggs.gnu.org ([2001:470:142:3::10]:35750) by lists.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1mIANk-0006UY-Bz for emacs-devel@gnu.org; Mon, 23 Aug 2021 09:52:56 -0400 Original-Received: from mail-pj1-x102d.google.com ([2607:f8b0:4864:20::102d]:34663) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_128_GCM_SHA256:128) (Exim 4.90_1) (envelope-from ) id 1mIANh-0008R6-Ru for emacs-devel@gnu.org; Mon, 23 Aug 2021 09:52:56 -0400 Original-Received: by mail-pj1-x102d.google.com with SMTP id ot2-20020a17090b3b4200b0019127f8ed87so13670pjb.1 for ; Mon, 23 Aug 2021 06:52:53 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20161025; h=content-transfer-encoding:from:mime-version:subject:date:message-id :references:cc:in-reply-to:to; bh=BG8c9YHkX60qQ1gbrpcwAiHvOmH4GxME42CJF4eb6hE=; b=O9kK1BTcgEszsgYiAiirYuDO0hy+Ms4MJd5CtqTi0iBfAuPxhF4PZGjlZC5bb+7jRt 5qvN239uCpXerWi0D+YC/bOXe/zqr1viAj3yGxaVxqBOFjiFg0vkOSHRXy/tBOOLvoFh rsw1pV1gM6VL6vSDfcc5LfZ+Gronu2pYjQde+sfm/LufR2/BrVA8aAUEe0guvUAkZi5m m3KcFnKzS4wUVmloF9o5/UALFVl3icDaeO9E+omTgweWTKJ+g0sJ5OxfAyJ5ahmFjR5N 561oaWgPCMXikT660kSGBHGp4TXXT4MYKFU94zewATP9pP3R0u0xbL2J7YBD+ctmJYf0 HQiw== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:content-transfer-encoding:from:mime-version :subject:date:message-id:references:cc:in-reply-to:to; bh=BG8c9YHkX60qQ1gbrpcwAiHvOmH4GxME42CJF4eb6hE=; b=htuk3p5rnJ8dmUsciu0vB57L240qNLLlzgicVNHMUrNc89kDZkZYxGlVHoaEnadtPe Ch6mXcxOqPPgaA0Tr0iqMVCEzjOwuI59CLAxhVWZYWQwdK4jidTxHIW44v5U6hlm06F6 X+vTB6Dce1vSZDEI/swZBkN2fXOnTQI3RazcGZm5fsWaZHOL5QfgM8T6G+4JjtcChWYL vUQ40JoAUQuAMI4tuz8W/TuSicX0U29vdVFb+LcpHHDPwe+q6kpih8AoAsHpIYkN/R95 9YQFGRQ+2HaKYiSZhJnmI2htu53iB2ksLz6Rz6jZlfDizEGAMvr6vt0fO38KwCJekbVh Lqog== X-Gm-Message-State: AOAM530bPtAu+9QYmpYdcp8WRJ7De6g4dgmKbbr09ds1X/Njrdadfq3E xFkTvg0IaEp+q9jTCvcaixA= X-Google-Smtp-Source: ABdhPJzbV1qb+6DCzqosMMjXmqEGsVGQGSXMFpfivvfmv54fltXkklG2T0qJxUf1l6t0F/cKKHvQkA== X-Received: by 2002:a17:90a:6282:: with SMTP id d2mr8410410pjj.189.1629726772536; Mon, 23 Aug 2021 06:52:52 -0700 (PDT) Original-Received: from [10.11.16.201] (wsip-70-166-26-37.sd.sd.cox.net. [70.166.26.37]) by smtp.gmail.com with ESMTPSA id pc11sm19399300pjb.17.2021.08.23.06.52.52 (version=TLS1_3 cipher=TLS_AES_128_GCM_SHA256 bits=128/128); Mon, 23 Aug 2021 06:52:52 -0700 (PDT) In-Reply-To: <20210823131240.rxfepbz4q2buo733@Ergus> X-Mailer: iPhone Mail (17H35) Received-SPF: pass client-ip=2607:f8b0:4864:20::102d; envelope-from=casouri@gmail.com; helo=mail-pj1-x102d.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 autolearn=ham autolearn_force=no X-Spam_action: no action X-BeenThere: emacs-devel@gnu.org X-Mailman-Version: 2.1.23 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" Xref: news.gmane.io gmane.emacs.devel:272874 Archived-At: > =E5=9C=A8 2021=E5=B9=B48=E6=9C=8823=E6=97=A5=EF=BC=8C=E4=B8=8A=E5=8D=886:1= 7=EF=BC=8CErgus =E5=86=99=E9=81=93=EF=BC=9A >=20 > =EF=BB=BFHi Juri: >=20 > I have this config: >=20 > ``` > (global-set-key (kbd "C-/") #'undo-only) > (global-set-key (kbd "C-M-/") #'undo-redo) >=20 > (with-eval-after-load 'repeat > (defvar undo-redo-repeat-map > (let ((map (make-sparse-keymap))) > (define-key map "/" #'undo-only) > (define-key map "M-/" #'undo-redo) > (define-key map "U" #'undo) > map) > "Keymap to repeat undo-redo key sequences. Used in `repeat-mode'.") > (put 'undo-only 'repeat-map 'undo-redo-repeat-map) > (put 'undo-redo 'repeat-map 'undo-redo-repeat-map) > (put 'undo 'repeat-map 'undo-redo-repeat-map)) > ``` >=20 > And for some reason the repeat map does not activates with "undo-only" > (it doesn't even shows the message in the minibuffer) but with "undo" > and "undo-redo" it works as expected. Is there anything special in > "undo-only" that disables repeat-mode? >=20 Maybe because undo-only sets this-command to undo? Yuan=