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: Thu, 09 Jun 2022 19:40:05 +0000 Message-ID: References: <2nP2PN2t_BuoLFcCV1LCJLjRsU6YkW6e-VeBbRcMl2zR4tfPLI9rg26bBYSjJIhOkCKntjKW0XfBXVpaHYoXIrE7Lm4Zh-4Pzy0b1mCwdpc=@protonmail.com> <877d5pljnr.fsf@gnu.org> 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="3016"; mail-complaints-to="usenet@ciao.gmane.io" Cc: Yuri Khan , help-gnu-emacs@gnu.org To: Tassilo Horn Original-X-From: help-gnu-emacs-bounces+geh-help-gnu-emacs=m.gmane-mx.org@gnu.org Thu Jun 09 21:41:53 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 1nzO2T-0000Yp-Ax for geh-help-gnu-emacs@m.gmane-mx.org; Thu, 09 Jun 2022 21:41:53 +0200 Original-Received: from localhost ([::1]:33786 helo=lists1p.gnu.org) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1nzO2S-0003Vk-12 for geh-help-gnu-emacs@m.gmane-mx.org; Thu, 09 Jun 2022 15:41:52 -0400 Original-Received: from eggs.gnu.org ([2001:470:142:3::10]:57536) by lists.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1nzO10-0003Ta-Dl for help-gnu-emacs@gnu.org; Thu, 09 Jun 2022 15:40:22 -0400 Original-Received: from mail-4325.protonmail.ch ([185.70.43.25]:45933) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1nzO0u-0000CI-Jc for help-gnu-emacs@gnu.org; Thu, 09 Jun 2022 15:40:21 -0400 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=protonmail.com; s=protonmail3; t=1654803613; x=1655062813; bh=8wRd2yJfKq5M9PCWDa78+Nv3X4yK8fc5wnbR4gwMSq4=; 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=dSOui8x7G11INGFLDJeZwEi1+kQP5IcZI+rI04435GdzHxLODl4VZNalvdVlDrmWk 1rkFNMDw5KqdAoxSzlrBbJAizpHdKH8wb6k1EXHU0qYdxasHFfqessifR6GXX7EJ20 iiLmMgB8eykYq3Zi7/RTJ8X8lor6kAsBefX1vH424TCGOhMD7Lkd3SIRLwEHsS/eVv vNrlwPW8N/KyaodqIqhPcvLJreFL1XnlGp9v7FXml+3HcNB4TYcA6NPEmSNutUWKb5 ic2FzfVTyCwbCZCKV5YYQY+bP5LYyTmSIoicu9ctOFy4/yP2Z36YcL28Bk9wAjtaw9 uVEA7q7c1t7GQ== In-Reply-To: <877d5pljnr.fsf@gnu.org> Feedback-ID: 43053548:user:proton Received-SPF: pass client-ip=185.70.43.25; envelope-from=goncholden@protonmail.com; helo=mail-4325.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, 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:137575 Archived-At: ------- Original Message ------- On Friday, June 10th, 2022 at 7:24 AM, Tassilo Horn wrote: > goncholden goncholden@protonmail.com writes: > > > > > ((c++-mode > > > > (indent-tabs-mode . t) > > > > (c-mode > > > > (indent-tabs-mode . t))) > > > > Suppose I have a file with tabs, would the change show the tabs as > > spaces? I would rather have the file show as it is. If there are > > tabs in the file, would (setq-default indent-tabs-mode nil) show them > > as spaces? > > > It doesn't affect how tabs/spaces are displayed. It just defines if > emacs' indentation commands may insert tabs. Even with indent-tabs-mode > set to nil, you can still manually insert a TAB using C-q TAB. > > If you want to convert a file from/to tabs, you can use the commands > tabify and untabify. > > Bye, > Tassilo Makes sense but I find it somewhat complicated. It works well if I press return and get indentation with spaces. But if so= meone presses the tab key, why does it not accept that tab? I would like to be able to introduce a tab with the tab key but indent with= spaces.