1

Topic: Using viemu when editing stylesheets (Visual Studio 2013/2015)

I've had this problem for a number of years and can't seem to find a solution. When editing stylesheets a lot of the normal movement and commands don't work as expected inside Visual Studio.

It's hard to pin down what is going on. Pressing / to search allows you to start searching, but then you can't press n to go to the next result, it just keeps appending n to the search string. Pressing another character to start editing or moving when the search term is found doesn't work and usually drops you back to where you were in the file before searching.

Various places you cannot exit from edit mode, and sometimes you get dropped into edit mode without wanting to.

This only happens in CSS files as far as I can tell. Everything else works fine.

2

Re: Using viemu when editing stylesheets (Visual Studio 2013/2015)

I'm experiencing a similar problem. When I edit standard C# files (.cs), ViEmu works fine. But when I edit C#-based Razor files (.cshtml), ViEmu sometimes thinks it is in insert mode instead of command mode.

For example, I just tried to yank some lines in a section of HTML code with a vi mark at the end. Normally I would type "ay'm, or something like that. When I do this, the single-quote from the 'm portion gets inserted into the page content.

There are other similar situations where typing a Vi command will suddenly trigger IntelliSense for whatever is under the cursor. For example, if the cursor is on an opening <div> tag and I start to type 5yy to yank five lines, the 5 will cause the IntelliSense for <div> to appear. But other commands, like the standard movement commands, work just fine. Insert mode has no problem, and nothing like this ever happens in .cs files.

I'm using VS2015 with the latest ViEmu 3.6.

3

Re: Using viemu when editing stylesheets (Visual Studio 2013/2015)

See my notes on this issue: http://www.viemu.com/forum/viewtopic.php?id=5325

I got pretty good results by uninstalling the Web Essentials extension from Visual Studio. This works for me because I am not a web dev and rarely work on web projects but was always annoyed when I did. There are still times that I have to use Ctrl+S instead of :w to save a .cshtml file, but it is much more rare. Style sheets work beautifully again too.

4

Re: Using viemu when editing stylesheets (Visual Studio 2013/2015)

Oh yeah, one thing that still doesn't work for me is visual block selection. It simply doesn't work in .cshtml and .css files.

5

Re: Using viemu when editing stylesheets (Visual Studio 2013/2015)

I don't have Web Essentials installed, so it must be something else that is conflicting with ViEmu.