I have made a new Visual Studio extension with a tool window as described by Microsoft here https://learn.microsoft.com/en-us/visualstudio/extensibility/creating-an-extension-with-a-tool-window?view=vs-2019
This generates multiple files, including a XAML definition for the tool window.
I want to add a toolbar to the tool window, so I could define it in XAML and connect the buttons up to some command objects in my view model. This is attactive, because I am already familiar with how to do it.
However, on another page, https://learn.microsoft.com/en-us/visualstudio/extensibility/adding-a-tool-window?view=vs-2019 Microsoft describe how to add a toolbar using a Visual Studio Command Table (.Vsct) File.
At first glance, it looks quite complex and I don't think I need it.
The description does say
By adding a toolbar in the following manner, you guarantee that its gradients and colors are consistent with the rest of the IDE.
Apart form that, what would be the advantage of using the VSCT method?
With the VSCT method user will be able to edit the toolbar and assign keyboard shortcuts to its commands. And don't underestimate the need to style the XAML toolbar for different VS themes.
Personally, I use both methods depending on need to expose commands for standard VS customization.