5#ifndef FTXUI_DOM_SELECTION_HPP
6#define FTXUI_DOM_SELECTION_HPP
20 Selection(
int start_x,
int start_y,
int end_x,
int end_y);
28 void AddPart(
const std::string&
part,
int y,
int left,
int right);
29 std::string
GetParts() {
return parts_.str(); }
34 const int start_x_ = 0;
35 const int start_y_ = 0;
40 const bool empty_ =
true;
41 std::stringstream parts_;
Represent a selection in the terminal.
const Box & GetBox() const
Get the box of the selection.
void AddPart(const std::string &part, int y, int left, int right)
Selection SaturateVertical(Box box)
Saturate the selection to be inside the box. This is called by vbox to propagate the selection to its...
Selection()
Create an empty selection.
Selection SaturateHorizontal(Box box)
Saturate the selection to be inside the box. This is called by hbox to propagate the selection to its...
std::shared_ptr< T > Make(Args &&... args)