From mboxrd@z Thu Jan 1 00:00:00 1970 Path: main.gmane.org!not-for-mail From: kai.grossjohann@gmx.net (=?iso-8859-1?q?Kai_Gro=DFjohann?=) Newsgroups: gmane.emacs.help Subject: Re: simple editor required Date: Tue, 24 Jun 2003 17:25:49 +0200 Organization: University of Duisburg, Germany Sender: help-gnu-emacs-bounces+gnu-help-gnu-emacs=m.gmane.org@gnu.org Message-ID: <84fzlzsdj6.fsf@lucy.is.informatik.uni-duisburg.de> References: <841xxzto54.fsf@lucy.is.informatik.uni-duisburg.de> <5lu1aqcev2.fsf@rum.cs.yale.edu> <84n0git5vn.fsf@lucy.is.informatik.uni-duisburg.de> <844r2opsuy.fsf@lucy.is.informatik.uni-duisburg.de> <84r85ry9ft.fsf@lucy.is.informatik.uni-duisburg.de> <84vfv2ulf7.fsf@lucy.is.informatik.uni-duisburg.de> <84wufgke19.fsf@lucy.is.informatik.uni-duisburg.de> <5ly8zw7hah.fsf@rum.cs.yale.edu> <7TAJa.738$eG1.8604@news-server.bigpond.net.au> <5ln0g87dki.fsf@rum.cs.yale.edu> <848yrsgd4s.fsf@lucy.is.informatik.uni-duisburg.de> NNTP-Posting-Host: main.gmane.org Mime-Version: 1.0 Content-Type: text/plain; charset=iso-8859-1 Content-Transfer-Encoding: 8bit X-Trace: main.gmane.org 1056469930 954 80.91.224.249 (24 Jun 2003 15:52:10 GMT) X-Complaints-To: usenet@main.gmane.org NNTP-Posting-Date: Tue, 24 Jun 2003 15:52:10 +0000 (UTC) Original-X-From: help-gnu-emacs-bounces+gnu-help-gnu-emacs=m.gmane.org@gnu.org Tue Jun 24 17:52:09 2003 Return-path: Original-Received: from monty-python.gnu.org ([199.232.76.173]) by main.gmane.org with esmtp (Exim 3.35 #1 (Debian)) id 19Uq2T-0008QG-00 for ; Tue, 24 Jun 2003 17:48:57 +0200 Original-Received: from localhost ([127.0.0.1] helo=monty-python.gnu.org) by monty-python.gnu.org with esmtp (Exim 4.20) id 19UpkZ-0003ye-Tz for gnu-help-gnu-emacs@m.gmane.org; Tue, 24 Jun 2003 11:30:27 -0400 Original-Path: shelby.stanford.edu!newsfeed.stanford.edu!logbridge.uoregon.edu!fu-berlin.de!uni-berlin.de!lucy.is.informatik.uni-duisburg.DE!not-for-mail Original-Newsgroups: gnu.emacs.help Original-Lines: 77 Original-NNTP-Posting-Host: lucy.is.informatik.uni-duisburg.de (134.91.35.216) Original-X-Trace: fu-berlin.de 1056468390 27588218 134.91.35.216 (16 [73968]) Mail-Copies-To: never User-Agent: Gnus/5.1003 (Gnus v5.10.3) Emacs/21.3.50 (gnu/linux) Cancel-Lock: sha1:x8YO0QlaUWh9giiBiSlbOKjcRf4= Original-Xref: shelby.stanford.edu gnu.emacs.help:114692 Original-To: help-gnu-emacs@gnu.org X-BeenThere: help-gnu-emacs@gnu.org X-Mailman-Version: 2.1b5 Precedence: list List-Id: Users list for the GNU Emacs text editor List-Help: List-Post: List-Subscribe: , List-Archive: List-Unsubscribe: , Errors-To: help-gnu-emacs-bounces+gnu-help-gnu-emacs=m.gmane.org@gnu.org Xref: main.gmane.org gmane.emacs.help:11184 X-Report-Spam: http://spam.gmane.org/gmane.emacs.help:11184 "Paul Edwards" writes: > "Kai Großjohann" wrote in message news:848yrsgd4s.fsf@lucy.is.informatik.uni-duisburg.de... >> "Paul Edwards" writes: >> >> > It is. The "maybe" means it doesn't always indent. And it >> > shouldn't, when it is quite obvious the user already has text >> > on that line, and doesn't need it indented. If they had wanted >> > it indented, they would have pressed tab, not enter. >> >> Huh? I find it really convenient that I can just hit TAB (my binding >> for indent-relative) at the beginning of a line to increase its >> indentation. > > But that's what I just said. You'd press TAB, not enter. > TAB is logical, enter is not. No-one expects enter, at > the beginning of a line, to go to a newline and indent > the existing text. enter doesn't do that sort of thing. It > does start a newline, beginning under the previous one > though. That is logical and reasonable. But the fact that RET does newline and then does like TAB is your own customization! So you can't blame Emacs that it is doing what you told it to do. That said, I understand that the behavior of RET that you see in text-mode is not the best behavior. Clearly it should be changed. >> > Indentation is meant to apply to a NEW line, not an existing >> > line. It's meant to put blanks there ready for you to optionally >> > start typing real characters, and then delete them later if they >> > are not already there. >> >> I use it for existing lines, too. > > You don't hit enter at the beginning of a line of text, and expect > it to insert a newline and indent the current text. Actually, I've never minded until now. But I see how it would be strange in text mode. But in text mode, indentation is not done very often. I have told Emacs that RET invokes newline-and-indent in programming modes (C, Java, Perl, ...) whereas it does just newline in other modes, like text. [time passes] Oh, now I remember that I sent a bug report about newline-and-indent in text mode, some years back. Whee. Yeah. I guess Emacs just doesn't like you to use newline-and-indent in text-like modes :-) FWIW, I get by with just newline quite nicely. For the kind of text I write, indentation is not often required. >> > It is not meant to trash existing lines! Nor is it meant to get >> > so confused on the first line, that it just indents 8 spaces, even >> > when my tab setting is 4, and there's not even a prior line to >> > inspire it to do something that silly. >> >> That might be a misconfiguration on your part. (Not that I blame you; >> the subject is complex.) indent-relative looks at tab-stop-list and >> configuring tab-width is not going to have the effect you might >> expect. (tab-width refers to how tab characters in the text are >> displayed, but the TAB key does not always insert tab characters.) > > So it sometimes (ie at beginning of file) looks at tab-stop-list, > and everywhere else it looks at the indentation of the previous > line. Seems very strange to me. Hm. I was going to answer that indent-relative does that, but in fact indent-relative-maybe also has this strange behavior in the first line of the file. I think that might be a bug. Note that indent-relative goes by tab-stop-list after the end of the previous line, whereas indent-relative-maybe does not do that. -- This line is not blank.