From a570e494bca43c30d7ec91d293051c0c818509b5 Mon Sep 17 00:00:00 2001 From: HampusM Date: Thu, 23 Jun 2022 17:05:43 +0200 Subject: feat: add statusline mode styling --- src/game/status_manager.cpp | 10 +++++----- 1 file changed, 5 insertions(+), 5 deletions(-) (limited to 'src/game/status_manager.cpp') diff --git a/src/game/status_manager.cpp b/src/game/status_manager.cpp index 36add4c..e4838cc 100644 --- a/src/game/status_manager.cpp +++ b/src/game/status_manager.cpp @@ -13,23 +13,23 @@ void StatusManager::set_section_title( const StatusLineSection §ion, const std::string_view &title) noexcept { - if (_title_lengths.contains(section)) + if (_section_title_lengths.contains(section)) { fmt::print(stderr, "Error: can't set statusbar section title more than once"); return; } - _statusline->set_status(section, title); + _statusline->set_section_status(section, title); - _title_lengths[section] = static_cast(title.length()); + _section_title_lengths[section] = static_cast(title.length()); } void StatusManager::set_section_body( const StatusLineSection §ion, const std::string_view &body) noexcept { - auto section_title_length = _title_lengths[section]; + auto section_title_length = _section_title_lengths[section]; - _statusline->set_status(section, body, section_title_length + 1); + _statusline->set_section_status(section, body, section_title_length + 1); } -- cgit v1.2.3-18-g5258