Nullean.TerminalImages 0.2.2

dotnet add package Nullean.TerminalImages --version 0.2.2
                    
NuGet\Install-Package Nullean.TerminalImages -Version 0.2.2
                    
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="Nullean.TerminalImages" Version="0.2.2" />
                    
For projects that support PackageReference, copy this XML node into the project file to reference the package.
<PackageVersion Include="Nullean.TerminalImages" Version="0.2.2" />
                    
Directory.Packages.props
<PackageReference Include="Nullean.TerminalImages" />
                    
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 Nullean.TerminalImages --version 0.2.2
                    
#r "nuget: Nullean.TerminalImages, 0.2.2"
                    
#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 Nullean.TerminalImages@0.2.2
                    
#: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=Nullean.TerminalImages&version=0.2.2
                    
Install as a Cake Addin
#tool nuget:?package=Nullean.TerminalImages&version=0.2.2
                    
Install as a Cake Tool

Nullean.TerminalImages

terminal-images_

Show images in the terminal with the Kitty, iTerm2 and Sixel protocols, with protocol detection and a half-block fallback. No dependencies, NativeAOT-safe.

NuGet

Install

dotnet add package Nullean.TerminalImages

Quick start

using Nullean.TerminalImages;
using Nullean.TerminalImages.Detection;

// Reads the environment, then asks the terminal once (macOS/Linux): Kitty, iTerm2, Sixel or half blocks?
var capabilities = await TerminalImageDetector.DetectAsync();

var renderer = new TerminalImageRenderer(capabilities, new TerminalImageRenderOptions { MaxColumns = 60, MaxRows = 20 });
if (!renderer.RenderPng(File.ReadAllBytes("sunset.png"), Console.Out))
	Console.WriteLine("(this terminal cannot show images)");

examples/sunset.png drawn with the Sixel protocol, and with the half-block fallback

  • Zero dependencies. The PNG codec, resampler and all four encoders are managed code: no SkiaSharp, no ImageSharp, no native assets.
  • Detection that does not hang. It reads the environment first, then asks the terminal once with a batch of queries that always ends with a Device Attributes request, which every terminal answers.
  • Only PNG is decoded; for other formats build an RgbaImage from RGBA bytes yourself.
  • Redirected output detects as None and nothing is written; force a protocol with TerminalImageDetectionOptions.Protocol to write escape sequences into a file anyway.
  • NULLEAN_TERMINAL_IMAGES=kitty|iterm2|sixel|blocks|none|auto overrides detection without code, and capabilities.Diagnostics says why detection chose what it did.
  • Detection sees through tmux and wraps output in its passthrough; tmux itself must have allow-passthrough on.
  • For Spectre.Console, Terminal.Gui or XenoAtom.Terminal use the Nullean.TerminalImages.<Host> package.

Learn more

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.
  • net10.0

    • No dependencies.

NuGet packages (4)

Showing the top 4 NuGet packages that depend on Nullean.TerminalImages:

Package Downloads
Nullean.Snapshots.Browser.Console

Runs a suite of journeys from the console with streamed results, grouped skips and readable failures, for snap journey run and for any tool that wants the same output.

Nullean.TerminalImages.XenoAtom

Show images in XenoAtom.Terminal with the Kitty, iTerm2 or Sixel protocol, with half blocks as the fallback. Independent of XenoAtom.Terminal.Graphics and SkiaSharp.

Nullean.TerminalImages.Spectre

Show images in Spectre.Console with the Kitty, iTerm2 or Sixel protocol, falling back to half blocks drawn with Spectre's own colours.

Nullean.TerminalImages.TerminalGui

Show images in Terminal.Gui v2: a view that feeds Terminal.Gui's Sixel and Kitty pipeline, a half-block fallback, and detection that Terminal.Gui's own handshake cannot do (probing, SSH, tmux).

GitHub repositories

This package is not used by any popular GitHub repositories.

Version Downloads Last Updated
0.2.2 0 11/12/2026
0.2.1 49 11/11/2026
0.1.0 690 11/10/2026