mirror of
https://github.com/ArthurSonzogni/FTXUI.git
synced 2025-10-01 17:29:07 +08:00
Update tutorial.md
This commit is contained in:
@@ -20,6 +20,9 @@ class CheckBox : public Component {
|
||||
std::wstring checked = L"☑ ";
|
||||
std::wstring unchecked = L"☐ ";
|
||||
|
||||
Decorator focused_style = inverted;
|
||||
Decorator unfocused_style = nothing;
|
||||
|
||||
// State update callback.
|
||||
std::function<void()> on_change = [](){};
|
||||
|
||||
|
@@ -12,6 +12,7 @@ class ScreenInteractive : public Screen {
|
||||
public:
|
||||
static ScreenInteractive FixedSize(size_t dimx, size_t dimy);
|
||||
static ScreenInteractive Fullscreen();
|
||||
static ScreenInteractive FitComponent();
|
||||
static ScreenInteractive TerminalOutput();
|
||||
|
||||
~ScreenInteractive();
|
||||
@@ -23,9 +24,10 @@ class ScreenInteractive : public Screen {
|
||||
bool quit_ = false;
|
||||
|
||||
enum class Dimension {
|
||||
FitComponent,
|
||||
Fixed,
|
||||
TerminalOutput,
|
||||
Fullscreen,
|
||||
TerminalOutput,
|
||||
};
|
||||
Dimension dimension_ = Dimension::Fixed;
|
||||
ScreenInteractive(size_t dimx, size_t dimy, Dimension dimension);
|
||||
|
@@ -50,6 +50,8 @@ class Screen {
|
||||
// Fill with space.
|
||||
void Clear();
|
||||
|
||||
void ApplyShader();
|
||||
|
||||
protected:
|
||||
size_t dimx_;
|
||||
size_t dimy_;
|
||||
|
Reference in New Issue
Block a user