#include "UI.h" #include "cpuload.h" #include #include #include #include void UI::draw() { std::vector cpuloads = get_cpu_loads(); std::cout << std::endl; std::cout << "- -- BPM +" << std::endl; std::cout << "Mode: Click __/__ (Clock Internal)" << std::endl; std::cout << "Status:" << std::endl; std::cout << " Alive/not alive" << std::endl; std::cout << " CPU:"; for (auto& i: cpuloads) { std::cout << fmt::format(" {:2}%", i); } int max = *std::max_element(cpuloads.begin(), cpuloads.end()); std::cout << fmt::format(", max. {:2}%", max) << std::endl; std::cout << " Notes/Channels: -- -- -- ... (Choose)" << std::endl; std::cout << " Timestamp: ------" << std::endl; std::cout << " Active sensing: ---" << std::endl; std::cout << " Clock: ____" << std::endl; std::cout << " Click: ____" << std::endl; }