Usually in Visual Studio Code, if I want to delete or modify a certain word from my file, I can highlight one of the words and then continuously press CTRL+D to highlight the rest of that same word in the file. But, in CLion, I am unable to find the equivalent shortcut.
I've Googled and searched here on StackOverflow but no luck. Maybe this shortcut doesn't exist in CLion? Can anyone confirm?
EDIT: It's also known as "Select next occurence" in other JetBrains products.
EDIT: The answer is ALT+J
it is alt+j in all of jetbrains products
So I just want to hit on a couple of options that you have, because I work with both CLion & VSCode as well, and needed the same exact keybinding in CLion.
Unfortunately, it appears that no one cares about standardizing semantics when it comes to editor functionality/features, and keybindings. It can make moving from one editor to the next difficult, and flat out something many people just would rather not have to do.
Please Note:
_I am no expert on JetBrains IDE's, I am somewhat of an expert with VSCode though. I say this because, IDK how much JetBrains IDE's vary from one to the next, however, from having CLion, IntelliJ, and Access to Ryder I can tell you that in the standard IDE's the keymappings seem near Identical, but in Ryder, the keybindings are totally different.
| DEV ENVIRONMENT | BOUND-KEYS (dev env's default) | SEMANTICS |
|---|---|---|
| CLion | ALT+J | "Add Selection for Next Occurrence" |
| Visual Studio Code | CTRL+D | "editor.action.addSelectionToNextFindMatch" |
| Visual Studio 2022 (IDE) | SHIFT+ALT+. | "Edit.insertNextMatchingCaret" |
the The correct semantics for referring to the functionality you seek in CLion is contingent on the environment that its being implemented in. The following demonstrates how to correctly reference it in both JetBrains & Visual Studio Environments:
Add Selection To Next Find Match Ctrl+D editor.action.addSelectionToNextFindMatch
Once you know the semantics of the functionality that you want to customize, you no longer have to resort to using any editors default key mapping. You asked about, CLion, so I will demonstrate, in an image (or screenshot) below, how you can change the keybinding to be anything you want it to be.

- Starting from the text editor, find the word 'FILE' on the 'MENUBAR' located at the very top of your screen.
- Click on 'FILE' to drop open the 'FILE MENU'.
- Scan through the __FILE MENU'_s ITEMS, until you see the selectable ITEM named 'SETTINGS' (it will have a wrench icon next to it). 4 Select 'SETTINGS' by left-clicking it, and you'll open the 'SETTINGS MENU' open.
- Another 'LIST' will appear on the left side. There will be 'BOLD ITEMS' and regular weighted SUB ITEMS. Find the 'BOLD ITEM' that reads 'KEYMAP'.
- Select 'KEYMAP'.
The image above shows the view in my IDE of the keymap menu. You can see a red arrow, as well as a green arrow, in the image.
The green arrow shows where you can change the entire Keymap, as you can see in the image, mine is set to VSCode, and as far as I can tell, every keybinding is the same as in VSCode. You do have to download the VSCode keymap plugin though.
The red arrow shows where the "Bound Keys" are listed. Right click on the keybinding and you'll see a menu that reads
"it may also have options for removing keybindings and mouse shortcuts, it all depends on how the keybinding you click on is configured"
To set the keybinding select Add Keyboard shortcut, and set it to what ever you want.
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With