fix AIconLabel spacing between image and label

This commit is contained in:
Dordovel 2022-12-05 10:02:38 +03:00
parent f4afa59861
commit 3cbcef61cf
1 changed files with 2 additions and 1 deletions

View File

@ -27,6 +27,7 @@ const static int LEFT_MOUSE_BUTTON_CODE = 1;
namespace waybar::modules { namespace waybar::modules {
User::User(const std::string& id, const Json::Value& config) User::User(const std::string& id, const Json::Value& config)
: AIconLabel(config, "user", id, "{user} {work_H}:{work_M}", 60, false, true, true) { : AIconLabel(config, "user", id, "{user} {work_H}:{work_M}", 60, false, true, true) {
AIconLabel::box_.set_spacing(0);
if (AIconLabel::iconEnabled()) { if (AIconLabel::iconEnabled()) {
this->init_avatar(AIconLabel::config_); this->init_avatar(AIconLabel::config_);
} }
@ -137,6 +138,6 @@ auto User::update() -> void {
fmt::arg("work_S", fmt::format("{:%S}", workSystemTimeSeconds)), fmt::arg("work_S", fmt::format("{:%S}", workSystemTimeSeconds)),
fmt::arg("user", systemUser)); fmt::arg("user", systemUser));
ALabel::label_.set_markup(label); ALabel::label_.set_markup(label);
ALabel::update(); AIconLabel::update();
} }
}; // namespace waybar::modules }; // namespace waybar::modules