Skip to content

Hex1bTerminalGraphicsOptions ​

Namespace: Hex1b

Assembly: Hex1b.dll

Configures resource limits for graphics retained and processed by a .

csharp
public sealed class Hex1bTerminalGraphicsOptions

Inheritance ​

Object → Hex1bTerminalGraphicsOptions

Properties ​

MaximumHistoryPlacements ​

Gets or sets the maximum number of image placement fragments retained in scrollback history. The default is 4,096.

Returns: Int32

csharp
public int MaximumHistoryPlacements { get; set; }

MaximumImagesPerScreen ​

Gets or sets the maximum number of distinct images retained by one screen. The default is 1,024.

Returns: Int32

csharp
public int MaximumImagesPerScreen { get; set; }

MaximumPlacementsPerScreen ​

Gets or sets the maximum number of live image placements retained by one screen. The default is 4,096.

Returns: Int32

csharp
public int MaximumPlacementsPerScreen { get; set; }

MaximumRasterOperationsPerImage ​

Gets or sets the maximum number of pixel-write operations performed while rasterizing one graphic. The default is 67,108,864 operations.

Returns: Int64

csharp
public long MaximumRasterOperationsPerImage { get; set; }

MaximumRasterPixelsPerImage ​

Gets or sets the maximum logical pixel area rasterized for one graphic. The default is 16,777,216 pixels.

Returns: Int64

csharp
public long MaximumRasterPixelsPerImage { get; set; }

MaximumRetainedBytesPerScreen ​

Gets or sets the maximum aggregate encoded and decoded image data retained by one screen. The default is 335,544,320 bytes.

Returns: Int64

csharp
public long MaximumRetainedBytesPerScreen { get; set; }

MaximumRetainedInputBytesPerImage ​

Gets or sets the maximum number of source input bytes retained for one graphic. The default is 1 MiB.

Returns: Int32

csharp
public int MaximumRetainedInputBytesPerImage { get; set; }

MaximumRetainedLogicalPixelsPerScreen ​

Gets or sets the maximum aggregate logical pixel area retained by distinct images on one screen. The default is 67,108,864 pixels.

Returns: Int64

csharp
public long MaximumRetainedLogicalPixelsPerScreen { get; set; }

Remarks ​

These limits are protocol-neutral. A graphics protocol uses the limits that apply to its representation; unsupported concepts are ignored rather than translated between protocols.

Per-image limits bound the work accepted from one graphic. Per-screen limits bound the live terminal state independently for the main and alternate screens. Snapshot owners may extend the lifetime of resources after the live terminal has evicted them.

Examples ​

csharp
await using var terminal = Hex1bTerminal.CreateBuilder()
    .WithPtyProcess("bash")
    .WithGraphics(options =>
    {
        options.MaximumRetainedBytesPerScreen = 64L * 1024 * 1024;
        options.MaximumImagesPerScreen = 256;
    })
    .Build();

await terminal.RunAsync();

Released under the MIT License.