Files
FTXUI/examples/component/slider.cpp

17 lines
549 B
C++
Raw Normal View History

2021-05-09 20:32:27 +02:00
#include "ftxui/component/captured_mouse.hpp" // for ftxui
#include "ftxui/component/component.hpp" // for Slider
2021-05-01 20:40:35 +02:00
#include "ftxui/component/screen_interactive.hpp" // for ScreenInteractive
2021-04-29 00:18:58 +02:00
using namespace ftxui;
int main() {
2021-04-29 00:18:58 +02:00
auto screen = ScreenInteractive::TerminalOutput();
2021-05-09 20:32:27 +02:00
int value = 50;
auto slider = Slider("Value:", &value, 0, 100, 1);
2021-05-09 20:32:27 +02:00
screen.Loop(slider);
2021-04-29 00:18:58 +02:00
}
// Copyright 2020 Arthur Sonzogni. All rights reserved.
// Use of this source code is governed by the MIT license that can be found in
// the LICENSE file.