Table of Contents

Class RenderZone

Namespace
CLI.CliniCore.Service.Editor
Assembly
CLI.CliniCore.dll

Represents a rectangular rendering zone within the console interface. Manages dirty state tracking and provides coordinate boundaries for partial screen updates.

public class RenderZone
Inheritance
RenderZone
Inherited Members

Constructors

RenderZone(string, Region, int)

Creates a new render zone with the specified identifier and bounds

public RenderZone(string zoneId, Region bounds, int renderPriority = 100)

Parameters

zoneId string

Unique identifier for this zone

bounds Region

Initial spatial boundaries

renderPriority int

Render order priority (default: 100)

Properties

Bounds

The spatial boundaries of this render zone in console coordinates

public Region Bounds { get; set; }

Property Value

Region

HasLayoutDependencies

Whether this zone's content depends on other zones' layouts

public bool HasLayoutDependencies { get; set; }

Property Value

bool

IsDirty

Indicates whether this zone needs to be redrawn on the next render cycle

public bool IsDirty { get; set; }

Property Value

bool

LastUpdate

Timestamp of the last successful render operation for this zone

public DateTime LastUpdate { get; }

Property Value

DateTime

RenderPriority

Priority level for rendering order (lower numbers render first)

public int RenderPriority { get; set; }

Property Value

int

ZoneId

Unique identifier for this zone within the renderer

public string ZoneId { get; }

Property Value

string

Methods

GetIntersection(RenderZone)

Calculates the area of intersection with another zone

public Region? GetIntersection(RenderZone other)

Parameters

other RenderZone

The zone to calculate intersection with

Returns

Region

The intersecting region, or null if no intersection

IntersectsWith(RenderZone)

Checks if this zone intersects with another zone's boundaries

public bool IntersectsWith(RenderZone other)

Parameters

other RenderZone

The zone to check intersection with

Returns

bool

True if the zones overlap spatially

Invalidate()

Marks this zone as needing a redraw

public void Invalidate()

MarkRendered()

Marks this zone as clean and updates the last render timestamp

public void MarkRendered()

ToString()

Returns a string that represents the current object.

public override string ToString()

Returns

string

A string that represents the current object.

UpdateBounds(Region)

Updates the zone boundaries and invalidates if they changed

public void UpdateBounds(Region newBounds)

Parameters

newBounds Region

The new spatial boundaries