The Extend Selection command allows you to successively select expanding logical blocks of code so that you can easily select any expression in the code by placing the caret somewhere inside it and pressing CtrlAlt0→ a few times. The command is also available in the main menu: ReSharper | Edit | Extend Selection.
tip
ReSharper also provides the Go to containing declarationCtrl0[ command that helps you instantly select the current member where your caret is or the whole type.
Shrink Selection does exactly the opposite. Press CtrlAlt0← or choose ReSharper | Edit | Shrink Selection in the main menu to apply this command.
With CamelHumps (the Use CamelHumps checkbox on the Environment | Editor | Behavior page of ReSharper options), the Extend/Shrink selection commands work in a slightly different way.
If the CamelHumps is enabled, the Extend/Shrink Selection commands take into account parts of compound names. Suppose you have placed the caret in the middle of a compound name with several parts that begin with uppercase letters:
With CamelHumps, pressing CtrlAlt0→ for the first time selects the current part of the word:
Only after pressing this keystroke for the second time ReSharper selects the whole word:
All subsequent presses are processed as usual.
This feature is supported in the following languages and technologies:
The instructions and examples given here address the use of the feature in C#. For more information about other languages, refer to corresponding topics in the Languages and frameworks section.
Our website uses some cookies and records your IP address for the purposes of accessibility, security, and managing your access to the telecommunication network. You can disable data collection and cookies by changing your browser settings, but it may affect how this website functions. Learn more.
With your consent, JetBrains may also use cookies and your IP address to collect individual statistics and provide you with personalized offers and ads subject to the Privacy Notice and the Terms of Use. JetBrains may use third-party services for this purpose. You can adjust or withdraw your consent at any time by visiting the Opt-Out page.