#pragma once #include #include #include #include "Database.h" #include "Status.h" #include "Views.h" struct DisplaySettings { bool showTasks = true; // auto-print the task table after each change bool showAccounts = true; // auto-print the account table after each change std::set hiddenTaskLevels; std::set hiddenAccountLevels; }; // Renders the task and account panels as text tables, from the computed views // (see Views.h), honouring the hidden levels in the settings. class Display { public: explicit Display(const Database& db); DisplaySettings& settings(); const DisplaySettings& settings() const; std::string renderTasks(std::time_t now) const; std::string renderAccounts(std::time_t now) const; private: const Database& db_; DisplaySettings settings_; };