File: AAppIconLabel.hpp

package info (click to toggle)
waybar 0.15.0-1
  • links: PTS, VCS
  • area: main
  • in suites: forky, sid
  • size: 2,464 kB
  • sloc: cpp: 25,331; xml: 742; python: 146; ansic: 77; makefile: 29
file content (27 lines) | stat: -rw-r--r-- 775 bytes parent folder | download
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
#pragma once

#include <gtkmm/box.h>
#include <gtkmm/image.h>

#include "AIconLabel.hpp"

namespace waybar {

class AAppIconLabel : public AIconLabel {
 public:
  AAppIconLabel(const Json::Value& config, const std::string& name, const std::string& id,
                const std::string& format, uint16_t interval = 0, bool ellipsize = false,
                bool enable_click = false, bool enable_scroll = false);
  virtual ~AAppIconLabel() = default;
  auto update() -> void override;

 protected:
  void updateAppIconName(const std::string& app_identifier,
                         const std::string& alternative_app_identifier);
  void updateAppIcon();
  unsigned app_icon_size_{24};
  bool update_app_icon_{true};
  std::string app_icon_name_;
};

}  // namespace waybar