mirror of
https://github.com/polybar/polybar.git
synced 2024-11-11 13:50:56 -05:00
973b1fa3d3
Closes #1331 Closes #1342 Fixes #2673
28 lines
571 B
C++
28 lines
571 B
C++
#pragma once
|
|
|
|
#include "modules/meta/static_module.hpp"
|
|
|
|
POLYBAR_NS
|
|
|
|
namespace modules {
|
|
class text_module : public static_module<text_module> {
|
|
public:
|
|
explicit text_module(const bar_settings&, string);
|
|
|
|
void update() {}
|
|
string get_format() const;
|
|
string get_output();
|
|
bool build(builder* builder, const string& tag) const;
|
|
|
|
static constexpr auto TYPE = "custom/text";
|
|
|
|
private:
|
|
static constexpr const char* TAG_LABEL{"<label>"};
|
|
|
|
label_t m_label;
|
|
|
|
string m_format{DEFAULT_FORMAT};
|
|
};
|
|
} // namespace modules
|
|
|
|
POLYBAR_NS_END
|