Skip to content

Coordinate

A class to store a coordinate, used by the DataTable.

Coordinate class

Bases: NamedTuple

An object representing a row/column coordinate within a grid.

column instance-attribute

column: int

The column of the coordinate within a grid.

row instance-attribute

row: int

The row of the coordinate within a grid.

down method

def down(self):

Get the coordinate below.

Returns
Type Description
Coordinate

The coordinate below.

left method

def left(self):

Get the coordinate to the left.

Returns
Type Description
Coordinate

The coordinate to the left.

right method

def right(self):

Get the coordinate to the right.

Returns
Type Description
Coordinate

The coordinate to the right.

up method

def up(self):

Get the coordinate above.

Returns
Type Description
Coordinate

The coordinate above.