Menu

#323 Macro Toggle_Auto_Indent.bsh

closed-rejected
nobody
general (64)
5
2011-12-05
2010-03-06
No

The question for toggling the auto indent behavior has been asked repeatedly (last time see tracker item #2962106). Though it's well documented that this is only a matter of assigning shortcuts (which is brilliant consistent BTW), it's possibly not very intuitive. I guess many users don't think of ENTER as a key that can be assigned to an arbitrary action. Also, if You want toggle auto indent often, re-assigning shortcuts is inconvenient.

Attached is a beanshell macro that toggles the auto indent feature by alternatively assigning the ENTER key to "insert-newline-indent" or "insert-newline" action. By default, the assignments are made temporarily, which means for the current jEdit session only.

Discussion

  • Robert Schwenn

    Robert Schwenn - 2010-03-06

    Beanshell script that toggles the auto indent feature

     
  • Robert Schwenn

    Robert Schwenn - 2011-12-04

    I guess, this is not the way we want to address this issue officially.

     
  • Robert Schwenn

    Robert Schwenn - 2011-12-04
    • status: open --> pending-remind
     
  • Jarek Czekalski

    Jarek Czekalski - 2011-12-05

    Robert, daily built jedit has switchable indentation: none, simple, full. I think your macro is no longer necessary and you may close.

     
  • Robert Schwenn

    Robert Schwenn - 2011-12-05
    • status: pending-remind --> closed-rejected
     
  • Robert Schwenn

    Robert Schwenn - 2011-12-05

    OK.

    BTW: I remember a time when SF "Pending" status has had some automatic functionality. This doesn't seem to work at all...

     

Log in to post a comment.