jed-users mailing list

[2013 Date Index] [2013 Thread Index] [Other years]
[Thread Prev] [Thread Next]      [Date Prev] [Date Next]

Re: [Jed-users-l] Request for a couple of adjustments to python-mode


Hi Roey,

> 1.  Making a new line on an indented paragraph
>     without changing the indentation level.

Maybe I did not understand how you would like jed to behave in detail
(With which buffer content and cursor position do you want to achieve
what when hitting Enter?), but I could think of a function other than
newline_and_indent (which is bound to Enter by default):

  define newline_and_indent_prev_line()
  {
    push_spot();
    bol();
    if(left(1))
      call("newline_and_indent");
    else
      newline();
    pop_spot();
  }

If that's what you want (try by binding it to maybe Alt + Enter:

  setkey("newline_and_indent_prev_line", "\e^M");

), and if you can define in which situations you want to have the one
or the other behaviour, one can certainly also code these conditions
in S-Lang and switch between newline_and_indent and
newline_and_indent_prev_line from another function that you'd finally
bind to ^M.

Cheers,

Manfred  (sorry, no experience in Python yet... ;-))


> If I run 'jed' on an empty file, without choosing a mode, it
> preserves the indentation level of a line after I hit Enter. However,
> if I hit enter in the whitespace before the start of the line, then
> the indentation level of the line falls back to zero.  How can I set 
> this to not do that?

_______________________________________________
Jed-users-l mailing list
Jed-users-l@xxxxxxxx
http://mailman.jtan.com/mailman/listinfo/jed-users-l


[2013 date index] [2013 thread index]
[Thread Prev] [Thread Next]      [Date Prev] [Date Next]