Table of Contents

Class TableSelection

Namespace
Terminal.Gui.Views
Assembly
Terminal.Gui.dll

Represents the complete selection state of a TableView: the cursor position and all extended selection regions. Used as the T in IValue<TValue>.

public class TableSelection : IEquatable<TableSelection>
Inheritance
TableSelection
Implements
Inherited Members

Remarks

A null TableSelection (as the value of Value) means "no selection" — either no Table is assigned or the selection was explicitly cleared.

A non-null TableSelection always has a non-null SelectedCell.

Constructors

TableSelection(Point)

Creates a cursor-only TableSelection with no extended regions.

TableSelection(Point, IReadOnlyList<TableSelectionRegion>?)

Creates a new TableSelection with the specified cursor and regions.

Properties

Regions

All extended selection regions. May be empty if only the cursor cell is selected.

SelectedCell

The selected cell used for navigation. Always non-null on a non-null TableSelection.

Methods

Contains(int, int)

Returns true if the given cell is within any of the Regions.

Equals(object?)
Equals(TableSelection?)
GetHashCode()