Being able to navigate based on camel casing (pascal casing) is fantastic. I used VS for 3 years at my job before finding this extension. Those 3 years need not have been the horror that they were, had I only known about this extension sooner. Thankfully, my torture has ended.
This makes life so much easier and makes me hate using any text editor that doesn't have this feature.
One minor complaint I have is that when I am formatting things to look nice or maybe copy/pasting I often run into an issue where this doesn't play nice with spaces.
for instance if I have string audience, string sponsors, string building
and I want to get rid of the extra spaces behind string building by putting the cursor at |string building and hitting ctrl+backspace (I just replaced all of the ctrl functions with yours) it will erase the comma in front of sponsors. As in
from string audience, string sponsors, string building
to string audience, string sponsorsstring building
rather than string audience, string sponsors,string building
It also has issues with navigating and deleting past line breaks in a similar way
It would be nice if whitespace was treated differently from other non-letter/non-number characters
I think the thing to do here is add a setting to make the navigation either treat symbols as whitespace (as it's doing now) or as text (which is more like how word navigation works in VStudio). I need to figure out how to add settings to the extension (see also the previous question). Stay tuned...
Actually, as I've played with this, I am seeing that the SubWordDeleteToStart is behaving the same way that WordDeleteToStart behaves for this situation. The comma is considered a word (or sub-word), so hitting Ctrl-Backspace with spaces to the left will consume the spaces and the closest sub-word, and that's exactly what happens. Changing the behavior to leave the sub-word gets really confusing.
If the start text was "building, string" and the text carat was on the s in string, doing the SubWordDeleteToStart operation should delete the text that's selected when doing a SubWordPreviousExtend operation, which is the whitespace and the comma, leaving "buildingstring".
Similarly, if the start text was "building string" and the text carat was on the s in string, then SubWordDeleteToStart should delete the whitespace and the previous sub-word, the same as would be selected by SubWordPreviousExtend, leaving "string".
I could add a setting that treats whitespace like a word, so the SubWordPrevious operations stop at the end of the previous word instead of the beginning of the previous word, and the SubWordNext operations would stop at the beginning of whitespace instead of continuing on to the beginning of the next word. That would be a little strange, because moving through text like "this is a list of words" would have stops like this: "this| |is| |a| |list| |of| |words|" which would take twice as many steps as it does now with stops like this: "this |is |a |list |of |words", so each SubWordNext/SubWordPrevious operation takes you to the beginning of the next/previous word.
Does that make sense? Would you want to have such a setting?
Hey, awesome extension!
Is it possible to add functionality to delete subwords, something like Delete(Previous|Next)Subword, so it's possible to map Ctrl+(Backspace|Delete) to them and delete just the subword instead of the whole word?
Hi, great extension. I had Duplicate Selection as a Macro in VS2008, but since there are no macros in VS2012...
So far it's working great, but I think I've found a little glitch. Imagine I have the following code:
with the selection spanning from "5" to the end of the next line. If I duplicate the selection, I get:
which is correct. But the selected text goes from the "e" in the second line to the end of the third line. I would expect it to go from the 5 in the second line to the end of the third line (basically, the same text as was originally selected).
11/06/2015 06:01:51 - Searching for applicable products...
11/06/2015 06:01:51 - Found installed product - Microsoft Visual Studio Express 2013 for Windows Desktop
11/06/2015 06:01:51 - Found installed product - Global Location
11/06/2015 06:01:51 - VSIXInstaller.NoApplicableSKUsException: This extension is not installable on any currently installed products.
I have only Visual Studio 2012 installed, and subword navigation works for me. When I set up the shortcut, I had to select Text Editor (instead of Global) for where to use the shortcut.
I don't have 2013 installed.
(Also, just to help those googling for this extension, I couldn't find this using keywords like CamelCase, camel case, pascalCase or pascal case, so hopefully including them in my comment here will help people find this subword navigation utility.)
I noticed a difference between moving left or right on underscored lines.
Moving right skips over underscore.
Moving left considers the underscores a subword.
I would prefer the underscores to be skipped as it is moving right for left as well. Regardless is this intentional? Great features by the way. Thanks.
Probably would have been better to start a new discussion rather than reply to this one.
It looks like my assumptions were incorrect about creating an extension that will work on multiple versions of Visual Studio. It looks like right now the extension will work on VS2012 but only if you also have VS2013 installed. I will continue to look into this and see if I can get it to work with individual versions of Visual Studio.
Tom_HH posted a reply in a different discussion about VSTricks no longer working on Visual Studio 2012.
I've just re-built v1.5 and uploaded it. This one should work correctly in Visual Studio 2012 and Visual Studio 2013. Getting an extension to work with multiple versions of Visual Studio is pretty tricky. I had to drop support for Visual Studio 2010 because I no longer have that version installed on my dev machine. If anyone really wants this to work on 2010 again, let me know and I'll see what I can do.
Hi. Thanks for the interest in my little VS extension. I am willing to open source this, but I'll need to work with my employer before I can put the code out there. If that gets a thumbs-up then I'll change the extension description to include information about accessing the open source project.