Is there a feature to intelligently close current line and open new line?

I have a macro to open line below (opposite of ctl-Enter). Is there a R#r
feature to do this? Something intelligent that would at least add ';' if
needed... maybe close ')', '}', ']', etc.?

If not I'll add the request.

/jhd


4 comments
Comment actions Permalink

John,

just out of curiosity, what the difference between you macro and simple
Enter keystroke?
Sorry if I'm missing something.

"John Dhom" <a@b.c> wrote in message news:cb9juo$urq$1@is.intellij.net...

I have a macro to open line below (opposite of ctl-Enter). Is there a R#r
feature to do this? Something intelligent that would at least add ';' if
needed... maybe close ')', '}', ']', etc.?

>

If not I'll add the request.

>

/jhd

>
>


0
Comment actions Permalink

The macro works from anywhere in the current line of code. Think of it as
goto end of line + Enter.

Used to bind it to alt-Enter... since open line above is ctl-Enter... til I
started using some add-in that stole my binding... hehe.

Not sure how smart R#r can be in this case(s). Minimally R#r could ensure
ending ';' and open new line below.

Do you not use something like this? Or do you take your hand(s) off the home
row to do END, ENTER or something?

/jhd

"Dmitry Shaporenkov (JetBrains)" <dsha@jetbrains.com> wrote in message
news:cb9kj7$a95$1@is.intellij.net...

John,

>

just out of curiosity, what the difference between you macro and simple
Enter keystroke?
Sorry if I'm missing something.

>

"John Dhom" <a@b.c> wrote in message news:cb9juo$urq$1@is.intellij.net...

I have a macro to open line below (opposite of ctl-Enter). Is there a

R#r

feature to do this? Something intelligent that would at least add ';' if
needed... maybe close ')', '}', ']', etc.?

>

If not I'll add the request.

>

/jhd

>
>

>
>


0
Comment actions Permalink

Not sure how smart R#r can be in this case(s).
Minimally R#r could ensure
ending ';' and open new line below.

Do you not use something like this? Or do you take
your hand(s) off the home
row to do END, ENTER or something?


There is something like this in IDEA, say
System.out.println("hello"(22
And it completes "));"

In IDEA I used to bind it to enter, and just ctrl+enter as real enter.

Sincerely

Jens Peter Grosen

0
Comment actions Permalink

music to my ears ;)

/jhd

"Jens Peter Grosen" <no_mail@jetbrains.com> wrote in message
news:16894132.1087966561825.JavaMail.itn@is.intellij.net...

Not sure how smart R#r can be in this case(s).
Minimally R#r could ensure
ending ';' and open new line below.

>

Do you not use something like this? Or do you take
your hand(s) off the home
row to do END, ENTER or something?

>

>

There is something like this in IDEA, say
System.out.println("hello"(22
And it completes "));"

>

In IDEA I used to bind it to enter, and just ctrl+enter as real enter.

>

Sincerely

>

Jens Peter Grosen

>


0

Please sign in to leave a comment.