From mboxrd@z Thu Jan 1 00:00:00 1970 Path: news.gmane.io!.POSTED.blaine.gmane.org!not-for-mail From: Thibaut Verron Newsgroups: gmane.emacs.help Subject: Re: indentation Date: Tue, 27 Apr 2021 20:43:42 +0200 Message-ID: <100082ce-c6a4-1923-fc89-1d466183afc8@gmail.com> References: <20210427090348.67C9B5D0@centrum.cz> <87v9889okp.fsf@posteo.net> <20210427174546.532D380B@centrum.cz> <8735vb3e60.fsf@yandex.com> Mime-Version: 1.0 Content-Type: text/plain; charset=utf-8; format=flowed Content-Transfer-Encoding: 7bit Injection-Info: ciao.gmane.io; posting-host="blaine.gmane.org:116.202.254.214"; logging-data="11916"; mail-complaints-to="usenet@ciao.gmane.io" User-Agent: Mozilla/5.0 (X11; Linux x86_64; rv:78.0) Gecko/20100101 Thunderbird/78.7.1 Cc: Philip Kaludercic , help-gnu-emacs@gnu.org To: Colin Baxter , ptlo@centrum.cz Original-X-From: help-gnu-emacs-bounces+geh-help-gnu-emacs=m.gmane-mx.org@gnu.org Tue Apr 27 20:45:20 2021 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 1lbShz-0002om-V6 for geh-help-gnu-emacs@m.gmane-mx.org; Tue, 27 Apr 2021 20:45:19 +0200 Original-Received: from localhost ([::1]:32834 helo=lists1p.gnu.org) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1lbShy-0007mb-Tk for geh-help-gnu-emacs@m.gmane-mx.org; Tue, 27 Apr 2021 14:45:18 -0400 Original-Received: from eggs.gnu.org ([2001:470:142:3::10]:33670) by lists.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1lbSgc-0007kw-4h for help-gnu-emacs@gnu.org; Tue, 27 Apr 2021 14:43:54 -0400 Original-Received: from mail-ej1-x632.google.com ([2a00:1450:4864:20::632]:41633) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_128_GCM_SHA256:128) (Exim 4.90_1) (envelope-from ) id 1lbSga-0007ie-CK for help-gnu-emacs@gnu.org; Tue, 27 Apr 2021 14:43:53 -0400 Original-Received: by mail-ej1-x632.google.com with SMTP id zg3so9325164ejb.8 for ; Tue, 27 Apr 2021 11:43:45 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20161025; h=subject:to:cc:references:from:message-id:date:user-agent :mime-version:in-reply-to:content-transfer-encoding:content-language; bh=qzgaSFo3SsprIqOwPhhVEZ55e6mrBZ917iS3lEznLkQ=; b=sRnk56puflbK8QlY9DrxNb1nw2yKr2nW6ZAyPUhOTz45+un/yO55D4vNe8uILUDmoS sPp4l10VUYS4mVKJhjLLLldxG5JXcu8d0smAKKooGYHWC1Q45x/dzd6Xp3TLv06vrCHv JT3Izn8JQDxhw4ZbkWl4WVsAY8pCqTZ0m2GPgmsoGbinqDpUZHV7sCBhDnusVhUj2VnO byzUqrDr4mFukODXKNZCa13o9jOYV4hUf3K4yWSVBzq3r1AClB8F6pihKv1nortXuNoQ vZG/saUm+cRqzesaeSrvTN3GYIhvLOhWzbqQABEUoiN/3URgo9oNHHZMbblA+mc3McNw hzrw== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:subject:to:cc:references:from:message-id:date :user-agent:mime-version:in-reply-to:content-transfer-encoding :content-language; bh=qzgaSFo3SsprIqOwPhhVEZ55e6mrBZ917iS3lEznLkQ=; b=DzWZo6mJxvI1TlcaNAyfJRtCG/CKB9524kYDgkmYqETt9AmV7iqDZjSGta3JjAT5MY LK2nGlNZ9IXnwtLV4DVlns7zhlvs8zP98H44KDL5xDEWD8IIRkZGUAMlWiyJZsc0dlES 3yGphI4deCNLzUoKYRd2+ypC5RrNZLx/gizQLIw0/OuKe+hibZw3LvUpGvs0VWyniXqb CfsKdUapADFVuQzG2cV/bZ1B6hSRbA4sediztcLTOCsgaN4r6txuGROhMjUd1IXQaDqp CIeQYMkAkLDMRP+5sdoY7lVJNQyoli6PZQgXozQQ3oY3JykS/c0tR586bdvvbMyB0Vwl l1+A== X-Gm-Message-State: AOAM532TUDOXCv43xpd5SdPjqskC55X7zyoW7IvVarRI8fgMw5YL9roL gUIR1FAm2jvCvr/69IhT+2XkBrsiq7EUOtTOenE= X-Google-Smtp-Source: ABdhPJz/7uj5DqlTiWb+bt2aGTpCE8ZGgFCYu4QsXUhpyjaSaY9NvhMymn1REeQnVhbEvfWRtWgy6w== X-Received: by 2002:a17:906:18e1:: with SMTP id e1mr24866344ejf.341.1619549024112; Tue, 27 Apr 2021 11:43:44 -0700 (PDT) Original-Received: from [192.168.2.103] (dslb-088-066-248-118.088.066.pools.vodafone-ip.de. [88.66.248.118]) by smtp.googlemail.com with ESMTPSA id i8sm3002819edu.64.2021.04.27.11.43.43 (version=TLS1_3 cipher=TLS_AES_128_GCM_SHA256 bits=128/128); Tue, 27 Apr 2021 11:43:43 -0700 (PDT) In-Reply-To: <8735vb3e60.fsf@yandex.com> Content-Language: en-US Received-SPF: pass client-ip=2a00:1450:4864:20::632; envelope-from=thibaut.verron@gmail.com; helo=mail-ej1-x632.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, NICE_REPLY_A=-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: help-gnu-emacs@gnu.org X-Mailman-Version: 2.1.23 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:129173 Archived-At: On 4/27/21 6:06 PM, Colin Baxter wrote: >>>>>> writes: > > Philip, this is it! I disabled the electric-indent-mode and emacs > > is again sane. I didn't find this option before, looking in the > > customization groups from the menu. > > In F-90 I switch off electric-indent-mode via a .dir-locals.el, viz > > #+begin_src elisp > ((nil . ((f90-if-indent . 4) > (f90-do-indent . 4) > (f90-program-indent . 4) > (f90-associate-indent . 4) > (f90-critical-indent . 4) > (f90-type-indent . 4) > (eval add-hook 'f90-mode-hook > (lambda () (electric-indent-local-mode -1)))))) > #+end_src Do you use a .dir-locals because you sometimes want to use electric-indent-mode in fortran? If yes, I don't think this will do what you want, as the eval form will modify the global value of the hook. However, if all you want is to never have electric-indent-mode in fortran, you can just have the add-hook form in your .emacs.