30 Days with IntelliJ IDEA. Editor Basics

As you remember last week we announced the plans to publish articles from the 30-day guide on getting started with IntelliJ IDEA. The first article was about the user interface. Today we would like to share with you one more article about the editor basics in IntelliJ IDEA.

Structural selection. A definite must-know

Did you know that IntelliJ IDEA provides an alternative way to select code? Structural selection allows you to select expressions based on grammar. By pressing Ctrl + W (Cmd + W for Mac) you keep expanding your selection (starting from the caret). And vice versa, you can shrink it by pressing Shift + Ctrl + W (Shift + Cmd + W for Mac).

Column selection

There are many users used to the column selection mode. Not everyone knows that this feature is available in IntelliJ IDEA. Column selection with mouse is available when you hold Alt. If you decide to use column selection by default, you can enable it via Edit → Column Selection Mode.

The complete article can be found here.

Stay tuned for more articles soon, and develop with Pleasure!

About Andrey Cheptsov

Andrey Cheptsov is IntelliJ IDEA product marketing manager at JetBrains. He's passionate about productivity, programming languages and tools.
This entry was posted in Tips & Tricks and tagged , . Bookmark the permalink.

12 Responses to 30 Days with IntelliJ IDEA. Editor Basics

  1. Steffen says:

    Structural Selection sounds and looks awesome!
    However, on my Mac Installation of IDEA, Cmd-W is mapped to “Close active editor”.
    Also I am not able to find something like “structural selection” or “expand selection” in the keymap.

    Any idea how I might achieve this functionality?

    Thx

  2. Ramiro Araujo says:

    @Steffen, in the keymap search for “Select Word at Caret” and “Unselect Word at Caret”

  3. hiessu says:

    keymaps select intellij IDEA, search “select word at Caret”

  4. Mike says:

    @Steffen the name of this in the keymap is “Select word at caret”. The article lists the shortcut on a Mac as shift-cmd-w.

  5. Mike says:

    I am a long time IntelliJ user and I didn’t know about “Show method separators” or that you could get column selection by holding down the alt key. I knew you could turn on column selection but didn’t know about the one-time usage of it with alt. Nice!

  6. Mark says:

    The OS X 10.5+ keymap has ‘Select word at caret’ set to Option+Arrow Up by default.

    On the subject of keymaps: why isn’t the 10.5+ keymap default on OS X? The first time I used IntelliJ IDEA on my Mac I got scared off by the keymap, which goes against anything a regular OS X user would expect. The 10.5+ keymap is a lot better, but still has some annoyances (particularly using hard to reach keys and using combinations that conflict with OS X internal shortcuts).

  7. Matt B says:

    Steffen, you might have your keymap set to “Mac OS X 10.5+”, whereas the Cmd-W mapping is for the “Mac OS X” keymap – the naming is a bit confusing (as the latter seems to be what most documentation refers to by default, yet the name of the former seems like it would be the default going forward).

  8. przemeko says:

    Navigate between opened tabs via Ctrl + Arrows. Shouldn’r be Alt +Arrows for default keymap ?

  9. Steffen says:

    Thanks guys, yes may be my fault in that I have some kind of modified “Mac OSX 10.5+” Keymap here.

    Looking for ‘Select word at caret’ did the trick. Mapped it to Option-Arrow Up (Likewise ‘Unselect word at caret’ => Option+Arrow Down) – Nice!

  10. Andrey Cheptsov says:

    @przemeko, you are right! sorry, fixed)

  11. Colin Kershaw says:

    Tip: Column Selection is handy for typing/pasting into columns too – it’s useful for more than only selecting text.

  12. Steve Cecutti says:

    These tutorials are great. Having been a recent eclipse user, I tried Intellij 1 month before my MyEclipse subscription expired. I purchased IntelliJ within 2 weeks since I felt it made that much sense. And these tutorial sessions show me how much more I still have yet to learn about IntelliJ. Keep them coming please!

Leave a Reply

Your email address will not be published. Required fields are marked *

You may use these HTML tags and attributes: <a href="" title=""> <abbr title=""> <acronym title=""> <b> <blockquote cite=""> <cite> <code class="" title="" data-url=""> <del datetime=""> <em> <i> <q cite=""> <strike> <strong> <pre class="" title="" data-url=""> <span class="" title="" data-url="">