Ardimedia.VsExtensions.Common 1.1.0

dotnet add package Ardimedia.VsExtensions.Common --version 1.1.0
                    
NuGet\Install-Package Ardimedia.VsExtensions.Common -Version 1.1.0
                    
This command is intended to be used within the Package Manager Console in Visual Studio, as it uses the NuGet module's version of Install-Package.
<PackageReference Include="Ardimedia.VsExtensions.Common" Version="1.1.0" />
                    
For projects that support PackageReference, copy this XML node into the project file to reference the package.
<PackageVersion Include="Ardimedia.VsExtensions.Common" Version="1.1.0" />
                    
Directory.Packages.props
<PackageReference Include="Ardimedia.VsExtensions.Common" />
                    
Project file
For projects that support Central Package Management (CPM), copy this XML node into the solution Directory.Packages.props file to version the package.
paket add Ardimedia.VsExtensions.Common --version 1.1.0
                    
#r "nuget: Ardimedia.VsExtensions.Common, 1.1.0"
                    
#r directive can be used in F# Interactive and Polyglot Notebooks. Copy this into the interactive tool or source code of the script to reference the package.
#:package Ardimedia.VsExtensions.Common@1.1.0
                    
#:package directive can be used in C# file-based apps starting in .NET 10 preview 4. Copy this into a .cs file before any lines of code to reference the package.
#addin nuget:?package=Ardimedia.VsExtensions.Common&version=1.1.0
                    
Install as a Cake Addin
#tool nuget:?package=Ardimedia.VsExtensions.Common&version=1.1.0
                    
Install as a Cake Tool

Ardimedia.VsExtensions.Common

NuGet

Shared infrastructure for Ardimedia Visual Studio extensions built on the VisualStudio.Extensibility SDK (out-of-process).

NuGet: https://www.nuget.org/packages/Ardimedia.VsExtensions.Common

What's Included

VS Theme Resources (XAML)

Pre-built control styles that adapt to VS Light, Dark, Blue, and High Contrast themes:

  • Themed Button -- default button with hover/press states
  • ChromelessButton -- borderless button for tabs and inline actions
  • Themed ComboBox -- full template with dropdown arrow and popup
  • Themed ComboBoxItem -- hover highlight in dropdown
  • Themed TextBox -- text input with caret color
  • SelectableText -- read-only text that supports copy (looks like TextBlock)

ToolWindowViewModelBase (C#)

Base ViewModel class for tool windows with:

  • Solution monitoring -- detects solution open/close/switch with two-pass debounce (waits for all projects to load)
  • IsScanning state -- with AnalyseButtonVisibility / CancelButtonVisibility for separate Analyse and Cancel buttons
  • CancellationToken management -- _scanCts pattern for cancellable scans
  • Virtual hooks -- OnSolutionOpenedAsync(), OnSolutionClosed(), OnIsScanningChanged()

OutputChannelLogger (C#)

Fire-and-forget wrapper for VS Output Window:

  • Lazy channel creation
  • WriteLine(string message) -- writes to a dedicated output channel

Installation

dotnet add package Ardimedia.VsExtensions.Common

Usage

XAML Themes

In your tool window XAML, reference the theme resources:

<DataTemplate xmlns="http://schemas.microsoft.com/winfx/2006/xaml/presentation">
    <Grid>
        <Grid.Resources>
            <ResourceDictionary>
                <ResourceDictionary.MergedDictionaries>
                    <ResourceDictionary Source="...path.../VsThemeResources.xaml" />
                </ResourceDictionary.MergedDictionaries>
            </ResourceDictionary>
        </Grid.Resources>
        
    </Grid>
</DataTemplate>

ViewModel Base Class

[DataContract]
public class MyToolWindowViewModel : ToolWindowViewModelBase
{
    public MyToolWindowViewModel(VisualStudioExtensibility extensibility)
        : base(extensibility) { }

    protected override async Task OnSolutionOpenedAsync(CancellationToken ct)
    {
        // Your scan logic here
    }

    protected override void OnSolutionClosed()
    {
        // Clear your data here
    }
}

Output Logger

var logger = new OutputChannelLogger(extensibility, "My Extension");
logger.WriteLine("Scan started...");

Requirements

  • .NET 10
  • Microsoft.VisualStudio.Extensibility.Sdk 17.14+
  • Visual Studio 2022 17.14+ or Visual Studio 2026

License

MIT

Product Compatible and additional computed target framework versions.
.NET net10.0 is compatible.  net10.0-android was computed.  net10.0-browser was computed.  net10.0-ios was computed.  net10.0-maccatalyst was computed.  net10.0-macos was computed.  net10.0-tvos was computed.  net10.0-windows was computed. 
Compatible target framework(s)
Included target framework(s) (in package)
Learn more about Target Frameworks and .NET Standard.

NuGet packages

This package is not used by any NuGet packages.

GitHub repositories

This package is not used by any popular GitHub repositories.

Version Downloads Last Updated
1.1.0 167 4/3/2026
1.0.8 155 4/3/2026
1.0.7 108 4/3/2026
1.0.6 130 3/29/2026
1.0.5 109 3/29/2026
1.0.0 106 3/29/2026