Vsvim: Visual Studio 2019 "Use Editor Command Margin" bug

Created on 23 Jan 2019  Â·  13Comments  Â·  Source: VsVim/VsVim

In VS2019:

If "Use Editor Command Margin" is set to false, the text you type after pressing : does not show up in the visual studio's status bar at the bottom. When set to true, text appears as expected in the white line.

I've checked, and this bug does not exist in VS2017

need more data

Most helpful comment

For this particular case I see it now. I have a suspicion that something from within VS itself posts another update to the status bar so fast that the one from VsVim never gets a chance to be shown (status bar starts flickering a bit during this command for me).
I'll take a look into this when I have time, I hoped to finish some stuff for VsVim last weekends but didn't get time to do it, after I finish - I'll look into your problem.

All 13 comments

Hi @radutomy , are you using preview 1.0/1.1 or preview 2.0? What other plugins do you have?
Could you please try a new exp instance of VS with only VsVim installed?

I have both VS2019 Preview 1.1 and VS2019 Preview 2.0 installed on different PCs and I just tested your scenario, in both cases I do see the text in the status bar as I type commands so the problem seems to be from some interaction with some settings/plugins and to localize it we might need more info.

Using vs2019 preview 2.0

  1. I've started a new exp instance and installed VsVim from the marketplace (you can see all the other plugins in pic 1)
  2. Created a new .NET Core project.
  3. Typed :18,22t.
    The text is displayed in the white strip and the command copied lines 18-22 as expected. (see pic 2)
  4. Changed "Use Editor Command Margin" to false. Typed :18,22t.
    The command copied lines 18-22 as expected, but the text was NOT displayed in the bottom status bar, it still displays Ready - see pic 3

The VsVim settings I'm using are all pretty much default (see pic 4).

vs1
vs2
vs3
vs4

For this particular case I see it now. I have a suspicion that something from within VS itself posts another update to the status bar so fast that the one from VsVim never gets a chance to be shown (status bar starts flickering a bit during this command for me).
I'll take a look into this when I have time, I hoped to finish some stuff for VsVim last weekends but didn't get time to do it, after I finish - I'll look into your problem.

same here.
I can confirm this bug.
Preview 4.4.

@radutomy @xarthurx

I just tried on the latest build and did not see this behavior. Everything seems to be working smoothly.

It is possible though another extension is just overriding the text VsVim adds here. The status bar is a shared resource and there is no way to stop others from adding text. VsVim actually sets up a timer so it can refresh the text there regularly in case there are other updates.

What all other extensions do you have installed?

@jaredpar
I just updated to the released version of VS2019, and disabled all the extensions except vsvim.
The issue still exists...

For the plugins, I only used AceJump and several for making comments more clear.
But since I disabled all the extension and the issue is still there, not sure if this is really an issue caused by other plugins.

So I also tried on another machine with VS2019 newly installed and only
install the extension of vsvim.
The issue still exists....

On Mon, 8 Apr 2019 at 05:06, Jared Parsons notifications@github.com wrote:

@radutomy https://github.com/radutomy @xarthurx
https://github.com/xarthurx

I just tried on the latest build and did not see this behavior. Everything
seems to be working smoothly.

It is possible though another extension is just overriding the text VsVim
adds here. The status bar is a shared resource and there is no way to stop
others from adding text. VsVim actually sets up a timer so it can refresh
the text there regularly in case there are other updates.

What all other extensions do you have installed?

—
You are receiving this because you were mentioned.
Reply to this email directly, view it on GitHub
https://github.com/jaredpar/VsVim/issues/2457#issuecomment-480667735,
or mute the thread
https://github.com/notifications/unsubscribe-auth/AB1TVljo7wIYeJA9Q6jmkqgaG2J2lua7ks5verJDgaJpZM4aPXJI
.

--
MA Zhao

"SAVE PAPER - PLEASE THINK BEFORE YOU PRINT!"

The issue still persists, even with the latest update of VS2019.
@jaredpar I'm not using any extensions (see first print screen above). At the time of writing this post, VS2019 was freshly installed, with everything default.

Hi.
I have confirmed that the same problem occurs in the following environment.

Visual Studio 2019 pro 16.0.1
VsVim 2.6.0

However, no problem occurred with the following link "VsVim 2.7.1324".
http://vsixgallery.com/extension/VsVim.Microsoft.e214908b-0458-4ae2-a583-4310f29687c3/

@xarthurx and @radutomy, are you using VsVim 2.6.0?
If so, installing the latest version may help.

I think this may be the same problem here.
gt and gT not working in VS2019

@ricksladkey, it seems that something you are worried about is happening.

@TKumadaki
I can confirm that VsVim 2.7.1324 works.
Thank you for pointing out the issue.

The sources of VsVim 2.7 and 2.6 were compared.
In 2.7, support for Visual Studio 2012, 2013 has been discontinued.
Some versions of Visual Studio SDK have been updated from 11.0.0.0 to 14.0.0.0.
Version 2.7 adds a Vs2019 project.
@jaredpar @ricksladkey
I think you know.
But I wrote just in case.

As there is no Vs2019 project in version 2.6, ISharedServiceFactory can not be acquired correctly.
The timer event of StatusBarAdapter gets the VimBuffer with focus.
This is obtained using VsVimHost.TryGetFocusedTextView.
However, the following part of this method does not work correctly.

var activeWindowFrame = result.Value.FirstOrDefault(_sharedService.IsActiveWindowFrame);

It seems that the timer event does not work properly by this.

As @TKumadaki pointed out, this is caused by using the published 2.6.0 version of VsVim which claims that it supports VS2019, but which does not in fact support any Visual Studio APIs that are accessed through VsVim's version-specific assemblies. This deficiency was fixed in PR #2447 and so will be included in 2.7.0 when it is released.

Was this page helpful?
0 / 5 - 0 ratings

Related issues

DanielKeogh picture DanielKeogh  Â·  3Comments

ogirginc picture ogirginc  Â·  6Comments

iamkarlson picture iamkarlson  Â·  7Comments

deevus picture deevus  Â·  4Comments

academician picture academician  Â·  3Comments