From mboxrd@z Thu Jan 1 00:00:00 1970 Path: news.gmane.org!.POSTED.blaine.gmane.org!not-for-mail From: Karl Fogel Newsgroups: gmane.emacs.devel Subject: Re: Should `revert-buffer' preserve text-scaling by default? Date: Mon, 02 Dec 2019 18:36:28 -0600 Message-ID: <87o8wqjldf.fsf@red-bean.com> References: <87fti6toq7.fsf@red-bean.com> <83pnhao1re.fsf@gnu.org> <8736e6tm51.fsf@red-bean.com> <83imn1omkf.fsf@gnu.org> <87d0d8xxzu.fsf@red-bean.com> <8736e3scxq.fsf@red-bean.com> <83o8wqln5f.fsf@gnu.org> <87pnh6ve5v.fsf@red-bean.com> <83eexmlj34.fsf@gnu.org> <87fti2s6nu.fsf@red-bean.com> Reply-To: Karl Fogel Mime-Version: 1.0 Content-Type: text/plain Injection-Info: blaine.gmane.org; posting-host="blaine.gmane.org:195.159.176.226"; logging-data="216514"; mail-complaints-to="usenet@blaine.gmane.org" User-Agent: Gnus/5.13 (Gnus v5.13) Emacs/27.0.50 (gnu/linux) Cc: Eli Zaretskii , emacs-devel@gnu.org To: Stefan Monnier Original-X-From: emacs-devel-bounces+ged-emacs-devel=m.gmane.org@gnu.org Tue Dec 03 01:36:47 2019 Return-path: Envelope-to: ged-emacs-devel@m.gmane.org Original-Received: from lists.gnu.org ([209.51.188.17]) by blaine.gmane.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.89) (envelope-from ) id 1ibwBI-000u7h-H5 for ged-emacs-devel@m.gmane.org; Tue, 03 Dec 2019 01:36:44 +0100 Original-Received: from localhost ([::1]:46176 helo=lists1p.gnu.org) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1ibwBG-0007nC-Tq for ged-emacs-devel@m.gmane.org; Mon, 02 Dec 2019 19:36:42 -0500 Original-Received: from eggs.gnu.org ([2001:470:142:3::10]:37876) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1ibwB9-0007mk-Jx for emacs-devel@gnu.org; Mon, 02 Dec 2019 19:36:36 -0500 Original-Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1ibwB8-0002cI-7Z for emacs-devel@gnu.org; Mon, 02 Dec 2019 19:36:35 -0500 Original-Received: from mail-yb1-xb2c.google.com ([2607:f8b0:4864:20::b2c]:38186) by eggs.gnu.org with esmtps (TLS1.0:RSA_AES_128_CBC_SHA1:16) (Exim 4.71) (envelope-from ) id 1ibwB7-0002Yo-Qp; Mon, 02 Dec 2019 19:36:34 -0500 Original-Received: by mail-yb1-xb2c.google.com with SMTP id l129so846135ybf.5; Mon, 02 Dec 2019 16:36:32 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20161025; h=sender:from:to:cc:subject:references:reply-to:date:in-reply-to :message-id:user-agent:mime-version; bh=3cUBPyMeQ2JfGUl8mPGX28FuIxGuDcK9TtmFASsrthA=; b=ax0aySCr3Np0IH7gaVdKhUd4hCWQP7u6okBWLZQdCH+xpnKjqPd6AKpJDv9CB6gBI6 S8eZOOMZksSL5GsndG65dFfWT3ilHcIksv20eT+MOKAuDRDal2LuPn+b9EJc+DMb5RN6 T1px0+yq7vzjZKmzmTbyl0J5Zo5GZAT0fw511ORG5jl/JNRGD1mQMcyB6Wzd+2a6j004 xi/jxI+OV+9qHGNBca3YSYpY4+8VXzuz+2qBc9ojFfjbO9ckzNFW3FDr5uFuoi/kq/5F cF5kMJSANCRXntL5pwlvtzXWIU8J48JD4AWQRjYfIG4UAM6apUTRJLtPLAfOHIpkUett 65Lg== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:sender:from:to:cc:subject:references:reply-to :date:in-reply-to:message-id:user-agent:mime-version; bh=3cUBPyMeQ2JfGUl8mPGX28FuIxGuDcK9TtmFASsrthA=; b=qUCC2grIbGaLQVZk1RW9xgnWY+sPpPRon7fpAe76u8+6Oh5fos0XKf5T0bB9KohY9K iH32Oqye5TMrpIVCvw//P7bcn9JjwLCxbMMs7RrI5Jo6cthu9+unA4o7JsWPAsjHJCY2 YrD2fanPnVeN0NFLGmLGbpaGhtwf4N+XItHRjplamGt/Q1EJuDR02WKVxvvmY8owrH9C 8fA8H02Yc1ZabUuTrnF0qoZNdyvKToNtxStYxOqcJ6GyBdeUHeoRPAWONM8w8GEyVCxq pPsqkL+2c1f+Sz9/hhbUJOT7yVSsJP4nyoyqO0o8Dlig9782Q1gdYumTBgJ8mXE3RAMa to4g== X-Gm-Message-State: APjAAAVJgnfK184X2wPsPzc8RJKiyZJ7lMmh9WCDH/jkBKfpIWNQmiA6 sFo88qi3NoZ/VxlG0t+1n1w/GahJ X-Google-Smtp-Source: APXvYqyslq5e46/YRLbz7DyfQAiquSTEiP7WnSlb3AnCaqGkAIr/fdq0z71zeiGTM7BNfCZQ8tFazQ== X-Received: by 2002:a25:aae4:: with SMTP id t91mr2095076ybi.22.1575333390864; Mon, 02 Dec 2019 16:36:30 -0800 (PST) Original-Received: from kwork (c-67-173-70-191.hsd1.il.comcast.net. [67.173.70.191]) by smtp.gmail.com with ESMTPSA id 189sm648950ywx.45.2019.12.02.16.36.29 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Mon, 02 Dec 2019 16:36:30 -0800 (PST) In-Reply-To: (Stefan Monnier's message of "Mon, 02 Dec 2019 17:49:13 -0500") X-detected-operating-system: by eggs.gnu.org: Genre and OS details not recognized. X-Received-From: 2607:f8b0:4864:20::b2c 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.org@gnu.org Original-Sender: "Emacs-devel" Xref: news.gmane.org gmane.emacs.devel:243028 Archived-At: On 02 Dec 2019, Stefan Monnier wrote: >It will let people try it out, so we get experience. We could also >change its value tentatively in Emacs's `master` after we cut the >emacs-27 branch, so we have time to hear complaints/bugreports in order >to decide if we want to change it officially in Emacs-28. Ah, that makes sense. I didn't think of the possibility of changing it in 'master' once the release branch is cut. That answers the question I asked Eli: how does this two-step process help us? You've explained how it does. >There's still a UI question, tho. There are (at least) 3 operations we >want to bind to the same command: > > A- revert buffer content > B- revert to auto-save file > C- revert and reset modes > >Currently C is the default and B is obtained via C-u. With the bool var >suggested, we could have A by default but would C-u give you C or B? >In that case would we still give access to the other somehow? > >[ And of course, there's option D which is "revert to auto-save file bur > without resetting modes". ] Well, I was thinking we wouldn't change the current C-u behavior. We'd just add a new defcustom, `revert-buffer-reset-modes', defaulting to `t' for now. If someone wants to change the mode-resetting behavior, they just change that variable. This is not as easily interactive as a prefix arg would be, but I'm not sure we need such convenience here (unless we believe that people are likely to change their preference from call to call, but I suspect that's a rare case). I'm not going into detail here about how `revert-buffer-reset-modes' would interact with the `preserve-modes' parameter; that implementation question is easy to resolve. I'm just proposing the following user-visible behavior: 1) C-u continues to control revert-to-auto-save-file 2) New defcustom `revert-buffer-reset-modes', defaulting to `t' Thoughts? Best regards, -Karl