Class KittyGraphicsSupportDetector
Detects whether the active terminal supports the Kitty graphics protocol by inspecting well-known environment variables set by Kitty-compatible terminals.
public class KittyGraphicsSupportDetector
- Inheritance
-
KittyGraphicsSupportDetector
- Inherited Members
Remarks
Detection checks the following environment variables in order:
KITTY_WINDOW_ID— set by the Kitty terminal emulator.TERM_PROGRAMequal tokittyorghostty.
When support is confirmed, the detector attempts to derive the pixel-per-cell Resolution via ANSI window-size queries (the same fallback used by SixelSupportDetector).
Constructors
- KittyGraphicsSupportDetector()
Creates a new instance of the KittyGraphicsSupportDetector class.
- KittyGraphicsSupportDetector(IDriver)
Creates a new instance of the KittyGraphicsSupportDetector class bound to the specified driver (used for resolution queries).
Methods
- Detect(Action<KittyGraphicsSupportResult>)
Detects Kitty graphics protocol support and invokes
resultCallbackwith the result. When support is detected the detector also attempts to resolve Resolution via ANSI queries; if those are unavailable the default 10×20 resolution is used.