Quantcast
Channel: Visual Studio Integrate forum
Viewing all articles
Browse latest Browse all 4410

How to extend the default auto-formatting behavior for a builtin language

$
0
0

I'd like to change the behavior of the default C++ auto-formatter.  Simple examples of things I'd like to do include:

* Context-sensitive indenting, so that different lines are indented differently depending on their context

* Automatically remove trailing whitespace from lines

All of this should happen as the user types.  I'm not particularly picky about what version of VS the extension would have to work with, so even if, for example, this would only be possible with 2013, I'd be ok with that.

I've been reading through the documentation so far, and the first thing that came to mind was extending the builtin C++ language service.  However, reading through the forums, it seems this isn't supported (has this changed in more recent versions of VS, up to and including 2013?)

But it seems like there must be a way, as I see other extensions that have done various similar things, such as VisualAssistX and/or VsVim.  

Does anyone have any suggestions for how I might approach this problem?


Viewing all articles
Browse latest Browse all 4410

Trending Articles



<script src="https://jsc.adskeeper.com/r/s/rssing.com.1596347.js" async> </script>