From 83992d29a063361ed89e41f100d8ddbbd5456e27 Mon Sep 17 00:00:00 2001 From: Lukas Fink Date: Tue, 17 Sep 2024 00:39:33 +0200 Subject: [PATCH] Fix formatting --- src/modules/custom.cpp | 10 +++------- 1 file changed, 3 insertions(+), 7 deletions(-) diff --git a/src/modules/custom.cpp b/src/modules/custom.cpp index bc5df76f..90c54128 100644 --- a/src/modules/custom.cpp +++ b/src/modules/custom.cpp @@ -159,9 +159,7 @@ auto waybar::modules::Custom::update() -> void { parseOutputRaw(); } - auto str = fmt::format(fmt::runtime(format_), - fmt::arg("text", text_), - fmt::arg("alt", alt_), + auto str = fmt::format(fmt::runtime(format_), fmt::arg("text", text_), fmt::arg("alt", alt_), fmt::arg("icon", getIcon(percentage_, alt_)), fmt::arg("percentage", percentage_)); if ((config_["hide-empty-text"].asBool() && text_.empty()) || str.empty()) { @@ -171,10 +169,8 @@ auto waybar::modules::Custom::update() -> void { if (tooltipEnabled()) { if (tooltip_format_enabled_) { auto tooltip = config_["tooltip-format"].asString(); - tooltip = fmt::format(fmt::runtime(tooltip), - fmt::arg("text", text_), - fmt::arg("alt", alt_), - fmt::arg("icon", getIcon(percentage_, alt_)), + tooltip = fmt::format(fmt::runtime(tooltip), fmt::arg("text", text_), + fmt::arg("alt", alt_), fmt::arg("icon", getIcon(percentage_, alt_)), fmt::arg("percentage", percentage_)); label_.set_tooltip_markup(tooltip); } else if (text_ == tooltip_) {