xlnt
Public Member Functions | List of all members
xlnt::selection Class Reference

The selected area of a worksheet. More...

#include <selection.hpp>

Public Member Functions

 selection ()=default
 default ctor More...
 
 selection (pane_corner quadrant, cell_reference active_cell)
 ctor when no range selected sqref == active_cell More...
 
 selection (pane_corner quadrant, cell_reference active_cell, range_reference selected)
 ctor with selected range sqref must contain active_cell More...
 
bool has_active_cell () const
 Returns true if this selection has a defined active cell. More...
 
cell_reference active_cell () const
 Returns the cell reference of the active cell. More...
 
void active_cell (const cell_reference &ref)
 Sets the active cell to that pointed to by ref. More...
 
bool has_sqref () const
 Returns true if this selection has a defined sqref. More...
 
range_reference sqref () const
 Returns the range encompassed by this selection. More...
 
void sqref (const range_reference &ref)
 Sets the range encompassed by this selection. More...
 
void sqref (const std::string &ref)
 Sets the range encompassed by this selection. More...
 
pane_corner pane () const
 Returns the sheet quadrant of this selection. More...
 
void pane (pane_corner corner)
 Sets the sheet quadrant of this selection to corner. More...
 
bool operator== (const selection &rhs) const
 Returns true if this selection is equal to rhs based on its active cell, sqref, and pane. More...
 

Detailed Description

The selected area of a worksheet.

Constructor & Destructor Documentation

◆ selection() [1/3]

xlnt::selection::selection ( )
explicitdefault

default ctor

◆ selection() [2/3]

xlnt::selection::selection ( pane_corner  quadrant,
cell_reference  active_cell 
)
inlineexplicit

ctor when no range selected sqref == active_cell

◆ selection() [3/3]

xlnt::selection::selection ( pane_corner  quadrant,
cell_reference  active_cell,
range_reference  selected 
)
inlineexplicit

ctor with selected range sqref must contain active_cell

Member Function Documentation

◆ active_cell() [1/2]

cell_reference xlnt::selection::active_cell ( ) const
inline

Returns the cell reference of the active cell.

◆ active_cell() [2/2]

void xlnt::selection::active_cell ( const cell_reference ref)
inline

Sets the active cell to that pointed to by ref.

◆ has_active_cell()

bool xlnt::selection::has_active_cell ( ) const
inline

Returns true if this selection has a defined active cell.

◆ has_sqref()

bool xlnt::selection::has_sqref ( ) const
inline

Returns true if this selection has a defined sqref.

◆ operator==()

bool xlnt::selection::operator== ( const selection rhs) const
inline

Returns true if this selection is equal to rhs based on its active cell, sqref, and pane.

◆ pane() [1/2]

pane_corner xlnt::selection::pane ( ) const
inline

Returns the sheet quadrant of this selection.

◆ pane() [2/2]

void xlnt::selection::pane ( pane_corner  corner)
inline

Sets the sheet quadrant of this selection to corner.

◆ sqref() [1/3]

range_reference xlnt::selection::sqref ( ) const
inline

Returns the range encompassed by this selection.

◆ sqref() [2/3]

void xlnt::selection::sqref ( const range_reference ref)
inline

Sets the range encompassed by this selection.

◆ sqref() [3/3]

void xlnt::selection::sqref ( const std::string &  ref)
inline

Sets the range encompassed by this selection.


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