help-gnu-emacs
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: simple editor required


From: Paul Edwards
Subject: Re: simple editor required
Date: Fri, 20 Jun 2003 10:13:36 GMT

"Kai Großjohann" <kai.grossjohann@gmx.net> wrote in message 
84vfv2ulf7.fsf@lucy.is.informatik.uni-duisburg.de">news:84vfv2ulf7.fsf@lucy.is.informatik.uni-duisburg.de...
> "Paul Edwards" <kerravon@nosppaam.w3.to> writes:
>
> > indent-line-function's value is
> > indent-relative-maybe
> > Local in buffer .emacs; global value is
> > indent-to-left-margin
>
> Okay, so indent-relative-maybe has the effect at the beginning of the
> file.  Put point at the beginning of the buffer and invoke M-x
> indent-relative-maybe RET, you'll see where the RET behavior comes
> from.
>
> It's now clear that you want a function to use as the value of
> indent-line-function that works like indent-relative-maybe in some
> cases but not in others.
>
> What should happen in which cases?

Ok, the problem as I described is more generic than that.
After having used it for more I found that the following:

    aaaa
    bbbb

cccc

If I am at the beginning of the "cccc" line and I hit enter,
emacs is inspired to indent cccc to be under bbbb.  I don't
want that, I want cccc to stay where it is.  If I wanted cccc
to be indented I would do something, e.g. press tab or hit
spaces.

I expect that in the above, if I am at the end of aaaa and hit
enter, then a blank line is inserted and I am positioned under
the first "a".  This already happens.

As I continue to type and hit enter, I expect the cursor to
stay at that same indentiation level.  However, if I break
the sequence of non-blank lines, by leaving a blank line,
then I don't mind emacs giving up and deciding to leave me
at the left hand side until I've finished entering blank lines,
and then the obligation being on me to press spaces to start
the indentation sequence again.

If emacs was super smart and let me hit enter without
changing the indent level, so long as I didn't do anything
strange, such as a cursor movement, then that would be
great.  But if it doesn't have that feature, that's fine too.

Micro-emacs works as I described above, there are no
surprises that I am aware of.

BFN.  Paul.




reply via email to

[Prev in Thread] Current Thread [Next in Thread]