Visual Studio's brake lines in Rider - visual-studio

in Visual studio when i hit enter from ternary expression ?? in constructor i get lines break like this:
But Rider doing breaking for ternaries like this:
How to set up braking lines in Rider for ternaries like it works in Visual Studio?

I think you can't configure in the same way as VS. The wrapping of the ternary lines indents with the default Indent size (by default is set to 4). So in other word it's a fixed size and not "dynamic" like it's for VS int that situation. Maybe it's a feature you could request at JetBrains Rider Support page.

Related

emmet conflicting with snippets visual studio 2013

Every time I type an emmet string and press tab visual studio replaces it with just the main element. Then i realized it was preferning the the snippet that it was auto suggesting. Is there a way around this or fix it? I am using Visual Studio 2013 Community edition on windows 7 64bit if that makes any difference
I found the problem, I was using another plugin called Viasafora that colors braces and makes it easier to to see your indentations it had a default option for showing completions ans you type. I had to go turn it off.

Code editing in Visual Studio like it is in Aptana Studio

Is there any plugins to Visual Studio that enables you to have the wonderful type-style you get in Aptana Studio, ie:
Auto brace completion
Auto indentation of braces (and other characters) whenever 'enter' is pressed inside the braces, like so:
Before enter:
{*}
After enter:
{
*
}
Is it possible to make this work in Visual Studio (via plugin or otherwise)?
You can use, for instance, Resharper, http://www.jetbrains.com/resharper, which is a pay-for plugin for code style, code refactoring and formatting. Rather advanced.
There's also Visual Assist X, http://www.wholetomato.com/, as well as JustCode, http://www.telerik.com/products/justcode.aspx and a whole lot more. Several products available, most of them for money, most of them good. =)
Check Productivity Power Tools. It has plenty of nice stuff:
Auto Brace Completion
Quick Find
Enhanced Scrollbar
Searchable Add Reference Dialog
and others.

I don't want spaces when I tab in visual studio 2010

Whenever I add a tab in VS 2010, it puts spaces instead. I know you could fix this problem by going in the VS 2008 options, but I can't figure out how to fix this in VS 2010.
Tools > Options > Text Editor > All Languages > Tabs > enable "Keep Tabs".
You can also adjust this setting on a per-language basis.
Regarding the first anwser ...
"Keep Tabs" will only work until you start using linq queries.
When visual studio formats linq queries adds some spaces for paddind.
There are no built-in support in vs2010 for strict indentation using tabs.

Highlight all occurrences of a selected object with ReSharper

I was used to use RockScroll (or MetalScroll), but when I started to use ReSharper my RockScroll start to show some bugs. Well, this is scope to another discussion https://stackoverflow.com/questions/1089493/is-rockscroll-compatible-with-resharper.
But my problem is related, because now without MetalScroll I can't highlight all occurrences, what I consider very useful in many situations.
Someone have another plugin for VS2010 or for ReSharper that do the same or better?
I think you are looking for "Highlight usages in file" This can be access via Shift+Alt+F11 or Ctrl+Shift+F7 depending if you are using VS key bindings or InteliJ bindings. Use either Ctrl+Alt+Up/Down or Ctrl+Alt+PageUp/PageDown to go to next and previous highlights.
You can also use the Ctrl+Alt+G combo to bring up a menu of what to jump to. This can be used to move the cursor to the next occurrence.
You should try Productivity Power Tools for Visual Studio 2010. There are other versions, at least one for Visual Studio 2013 and another one for Visual Studio 2015.
It plays nicely with ReSharper and has this selected text matches highlighting both in the editor and the scrollbars among many other features.
Try the visual studio extension RockMargin which highlight the occurrences on double click (like most IDEs). Works fine with VS 2015 and ReSharper.

Highlight all references to X?

The Eclipse IDE has a neat little feature that I really miss in Visual Studio.
If I place the cursor on a variable or method name, the IDE will automatically highlight all references to it in the current document within the relevant scope.
I can't seem to find an option to turn on similar behaviour in VS2008 or Resharper 4. I know VS has a Find Usages function, but I'd like to do it automatically on the fly.
Does anyone know of a free addin which will add this functionality?
If you're using ReSharper, you can highlight the usages in the file with Shift-Alt-F11. Place your cursor on the variable you want to find usages of, and press the Shift-Alt-F11 combination.
There is an add-in for Visual Studio that will do something similar called RockScroll.
When you double click on something, it will highlight all occurrences of the item you double clicked. It also changes the vertical scrollbar to a "syntax highlighted thumbnail view" showing an overview of where the item occurs in the file.
I know you mentioned ReSharper, but CodeRush has a nice references window that you can dock and let it search for things on-the-fly or on demand. As a bonus, you can select each usage and it will show you the context surrounding the usage. It also works for methods.
I mentioned CodeRush since they have an express edition, which looks like it includes that feature, but I haven't tried that edition.
Visual Studio 2010 has sorta implemented this, but the feature is somewhat lacking. There is a non-configurable delay between placing the cursor and highlighting.
The RockScroll Addin is not available for Visual Studio 2010 and above.
As a replacement, the free "Highlight all occurrences of selected word" plugin will highlight all occurences of the selected string after a doubleclick. There is no delay as with the native vs2010 highlighter.
It is string-based, which means it works inside comments and string literals.
Microsoft published a tool that sort of does what you want.
Some of my favourite features:
Enhanced Scrollbar
Auto Brace Completion
Ctrl + Click Go To Definition
Open Containing Folder
and the list goes on.
For Visual Studio 2010 and for Visual Studio 2012

Resources