Geometry
The dimensions of a terminal-backed Console.
Returned by geometry().
rows and cols are independently nil: a console may know one dimension
without the other. The host console (term.console) always returns a
Geometry, never nil itself.
Subclassing
Geometry is the interface; reading rows or cols on a bare instance
raises UnsupportedError. A Do console that
implements geometry() subclasses this to describe itself:
class FixedGeometry: term.Geometry
pub field rows
pub field cols
def (init) self rows cols
term.Geometry.(init) $self
self.rows = rows
self.cols = cols
Constructor
Geometry()
Initializes the base. A subclass calls this from its own (init).