cpp-terminal 1.0.0
Small C++ library for writing multiplatform terminal applications
Loading...
Searching...
No Matches
Term::Screen Class Reference

#include <cpp-terminal/screen.hpp>

Public Member Functions

 Screen ()=default
 
 Screen (const Size &size)
 
const Rowsrows () const noexcept
 
const Columnscolumns () const noexcept
 
bool empty () const
 
bool operator== (const Term::Screen &screen) const
 
bool operator!= (const Term::Screen &screen) const
 

Private Attributes

Size m_size
 

Detailed Description

Definition at line 19 of file screen.hpp.

Constructor & Destructor Documentation

◆ Screen() [1/2]

Term::Screen::Screen ( )
default

◆ Screen() [2/2]

Term::Screen::Screen ( const Size & size)
explicit

Definition at line 12 of file screen.cpp.

12: m_size(size) {}
Size m_size
Definition screen.hpp:31

Member Function Documentation

◆ columns()

const Term::Columns & Term::Screen::columns ( ) const
noexcept

Definition at line 16 of file screen.cpp.

16{ return m_size.columns(); }
const Columns & columns() const noexcept
Definition size.hpp:48

◆ empty()

bool Term::Screen::empty ( ) const

Definition at line 18 of file screen.cpp.

18{ return (0 == m_size.rows()) && (0 == m_size.columns()); }
const Rows & rows() const noexcept
Definition size.hpp:47

◆ operator!=()

bool Term::Screen::operator!= ( const Term::Screen & screen) const

Definition at line 34 of file screen.cpp.

34{ return !(*this == screen); }

◆ operator==()

bool Term::Screen::operator== ( const Term::Screen & screen) const

Definition at line 32 of file screen.cpp.

32{ return (this->rows() == screen.rows()) && (this->columns() == screen.columns()); }
const Columns & columns() const noexcept
Definition screen.cpp:16
const Rows & rows() const noexcept
Definition screen.cpp:14

◆ rows()

const Term::Rows & Term::Screen::rows ( ) const
noexcept

Definition at line 14 of file screen.cpp.

14{ return m_size.rows(); }

Member Data Documentation

◆ m_size

Size Term::Screen::m_size
private

Definition at line 31 of file screen.hpp.


The documentation for this class was generated from the following files: