Question

I would like to create an extension for visual studio in which some UI behaviors are overridden. I have found many examples of adding UI components to VS, but none where they change them. A very good example of what I want to do is make it so that each tab takes up exactly 50 pixels in width (at the top of the editor window group). Is this possible? If so, what would be a good resource for me?

Was it helpful?

Solution

For your specific example, the Document Tab Well extension inside the Productivity Power Tools pack lets you set minimum and maximum widths for the editor tabs, so you could force it to 50 pixels if you want.

In general, there is no uniform way you can override or replace UI components in Visual Studio. A few components were designed to be easily replaced, while some components cannot be replaced, but many aren't replacable. The general problem with replacing components is it fails the "what if two extensions want to do it test", because it's not clear which replacement wins. Thus most extension points are add-only.

My advice: if you want to replace a specific component, ask a separate question on Stack Overflow and hopefully somebody can chime in on how to customize that particular component.

Licensed under: CC-BY-SA with attribution
Not affiliated with StackOverflow
scroll top