#pragma once #include "common.hpp" #include "components/eventloop.hpp" #include "utils/functional.hpp" POLYBAR_NS // fwd decl {{{ enum class mousebtn : uint8_t; enum class syntaxtag : uint8_t; enum class alignment : uint8_t; enum class attribute : uint8_t; // }}} /** * @TODO: Allow multiple signal handlers * @TODO: Encapsulate signals */ namespace g_signals { /** * Helper used to create no-op "callbacks" */ template static callback noop = [](T...) {}; /** * Signals used to communicate with the event loop */ namespace event { extern callback enqueue; extern callback enqueue_delayed; } /** * Signals used to communicate with the bar window */ namespace bar { extern callback action_click; extern callback visibility_change; } /** * Signals used to communicate with the input parser */ namespace parser { extern callback background_change; extern callback foreground_change; extern callback underline_change; extern callback overline_change; extern callback alignment_change; extern callback attribute_set; extern callback attribute_unset; extern callback attribute_toggle; extern callback font_change; extern callback pixel_offset; extern callback action_block_open; extern callback action_block_close; extern callback ascii_text_write; extern callback unicode_text_write; extern callback string_write; } /** * Signals used to communicate with the tray manager */ namespace tray { extern callback report_slotcount; } } POLYBAR_NS_END