From mboxrd@z Thu Jan 1 00:00:00 1970 Path: news.gmane.io!.POSTED.blaine.gmane.org!not-for-mail From: goncholden Newsgroups: gmane.emacs.help Subject: Re: Spaces rather than tabs by a major mode hook Date: Mon, 13 Jun 2022 12:12:26 +0000 Message-ID: <0GdLwEMPL28eEn2frQnxlC6VwEoodCkwB0weQbFslsdYOR2NEGhXCJVUb3z1Ngpb5662Y1oH7BDNKQ9mX0c3mnkk-PNwV1m7c7_njqTxXwM=@protonmail.com> References: <83leu3y0hs.fsf@gnu.org> <83h74rxze0.fsf@gnu.org> <83bkuzxvur.fsf@gnu.org> <90592a81-c690-34c9-ddd5-619c9cb76ce7@easy-emacs.de> Reply-To: goncholden Mime-Version: 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="28825"; mail-complaints-to="usenet@ciao.gmane.io" Cc: help-gnu-emacs@gnu.org To: =?utf-8?Q?Andreas_R=C3=B6hler?= Original-X-From: help-gnu-emacs-bounces+geh-help-gnu-emacs=m.gmane-mx.org@gnu.org Mon Jun 13 14:20:10 2022 Return-path: Envelope-to: geh-help-gnu-emacs@m.gmane-mx.org Original-Received: from lists.gnu.org ([209.51.188.17]) by ciao.gmane.io with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.92) (envelope-from ) id 1o0j3C-0007JC-1M for geh-help-gnu-emacs@m.gmane-mx.org; Mon, 13 Jun 2022 14:20:10 +0200 Original-Received: from localhost ([::1]:40532 helo=lists1p.gnu.org) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1o0j3A-00067I-Nb for geh-help-gnu-emacs@m.gmane-mx.org; Mon, 13 Jun 2022 08:20:08 -0400 Original-Received: from eggs.gnu.org ([2001:470:142:3::10]:43512) by lists.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1o0ivv-0000Xk-CO for help-gnu-emacs@gnu.org; Mon, 13 Jun 2022 08:12:39 -0400 Original-Received: from mail-4318.protonmail.ch ([185.70.43.18]:46485) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1o0ivt-0007pC-0v for help-gnu-emacs@gnu.org; Mon, 13 Jun 2022 08:12:38 -0400 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=protonmail.com; s=protonmail3; t=1655122354; x=1655381554; bh=mlNVIYQdG31c8pifdBZDG3kGaxfgT1CinyArFUx3/NA=; h=Date:To:From:Cc:Reply-To:Subject:Message-ID:In-Reply-To: References:Feedback-ID:From:To:Cc:Date:Subject:Reply-To: Feedback-ID:Message-ID; b=JDzz+vcojs2boXqkgyLDzC6W50d5vsL1F2YoKglgrE/M+zdyPR3Zzj6SYwn0QUYY3 NCpAEOUk3Tc6P5ZvsarqvHsh7/ecK4DzZ5pthFVTOBamvuZ2EoRKppjjcE/mx0BLm8 BSueCXEeuoQsn+gMnumF0gd13GqSriKrk15ODojuXrlnhGPqYx0fpVpiPcHfggrbAy SeLauIHY6dGxEG+VrgncSVBuPnNo9IH8HfdkBHYl+Fpkcl7KVlJglI5XGRUqhXzI5y ajualO6D2wNIIwQ/QazbyqtAxbvk6WmMWGaL09lzL5uzCJDlFtolZ8u0/22iIk0QPn adlMPBcSYn2Ig== In-Reply-To: <90592a81-c690-34c9-ddd5-619c9cb76ce7@easy-emacs.de> Feedback-ID: 43053548:user:proton Received-SPF: pass client-ip=185.70.43.18; envelope-from=goncholden@protonmail.com; helo=mail-4318.protonmail.ch 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_MSPIKE_H2=-0.001, SPF_HELO_PASS=-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: help-gnu-emacs@gnu.org X-Mailman-Version: 2.1.29 Precedence: list List-Id: Users list for the GNU Emacs text editor List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: help-gnu-emacs-bounces+geh-help-gnu-emacs=m.gmane-mx.org@gnu.org Original-Sender: "help-gnu-emacs" Xref: news.gmane.io gmane.emacs.help:137787 Archived-At: ------- Original Message ------- On Monday, June 13th, 2022 at 11:55 PM, Andreas R=C3=B6hler wrote: > Am 11.06.22 um 22:02 schrieb goncholden: > > > ------- Original Message ------- > > On Saturday, June 11th, 2022 at 11:50 PM, Eli Zaretskiieliz@gnu.org wro= te: > > > > > > Date: Sat, 11 Jun 2022 11:15:59 +0000 > > > > From: goncholdengoncholden@protonmail.com > > > > Cc:help-gnu-emacs@gnu.org > > > > > > > > > Emacs doesn't impose any style. By "style" I meant how many colum= ns > > > > > should each construct be indented. In Emacs, you can set all the > > > > > parameters of the style one by one via the menu I mentioned, and = you > > > > > can do that according to the style used by whoever wrote these fi= les. > > > > > Then you save your customizations, and Emacs will henceforth > > > > > automatically indent according to the style you defined by your > > > > > customizations. > > > > > Let me rephrase again. Emacs imposes indentation rules by requiri= ng said customisations. > > > > > > Emacs requires you to customize, once, the indentation so that it > > > could thereafter help you by indenting everything automatically to > > > suit the indentation style. That's a win by any measure. > > > That the problem you are taking ages to understand. "Emacs requires y= ou to customize", the origin of the problem. > > > > > > The question about how many columns should each construct be indent= ed, has no answer. > > > > > > It should be possible to answer that question by just examining the > > > file you posted. > > > No, because there are thousands of files. That was just an example to= show how emacs takes over the file, disallowing tabs and certain formattin= g because it assumes that fortran files have a single style. Not true. > > > > > Alternatively, you could just reindent the entire file according to > > > the defaults, like this: > > > > > > C-x h > > > C-M-\ > > > > > > and then keep making changes without any customizations. > > > That would destroy the possibilities of easily detecting code changes= . Only want emacs to recognise that one cannot impose a style on legacy cod= e. It should be able to go along with no style. > > > > The mantra that things can always be customised implies observance to a= single formatting scheme. Legacy code does not even subscribe to that. The= y only had simple editors. If I introduce tabs with > > "C-q TAB", all those tabs get removed by emacs as soon as one presses r= eturn at the end of the line. > > > > Emacs is acting like a dictator. > > > Hmm, seems you stumbled over a mistake. That's what I call > "electric-indent-mode turned on by default". > > While freedom obviously doesn't prevent mistakes, --given also the > possibility I'm wrong in this judgement--, you hardly find a tool such > easily to tweak along your wishes like Emacs. > > So, don't give up. Right. Thus the insistence rather than taking the advice of choosing a dif= ferent editor. Managed to find what has to be done. Thank you.