4 * i3 - an improved dynamic tiling window manager
6 * © 2009-2010 Michael Stapelberg and contributors
8 * See file LICENSE for license information.
17 /** ##__VA_ARGS__ means: leave out __VA_ARGS__ completely if it is empty, that
18 is, delete the preceding comma */
19 #define LOG(fmt, ...) verboselog(fmt, ##__VA_ARGS__)
20 #define ELOG(fmt, ...) errorlog("ERROR: " fmt, ##__VA_ARGS__)
21 #define DLOG(fmt, ...) debuglog(LOGLEVEL, "%s:%s:%d - " fmt, __FILE__, __FUNCTION__, __LINE__, ##__VA_ARGS__)
23 extern char *loglevels[];
26 * Enables the given loglevel.
29 void add_loglevel(const char *level);
32 * Set verbosity of i3. If verbose is set to true, informative messages will
33 * be printed to stdout. If verbose is set to false, only errors will be
37 void set_verbosity(bool _verbose);
40 * Logs the given message to stdout while prefixing the current time to it,
41 * but only if the corresponding debug loglevel was activated.
44 void debuglog(int lev, char *fmt, ...);
47 * Logs the given message to stdout while prefixing the current time to it.
50 void errorlog(char *fmt, ...);
53 * Logs the given message to stdout while prefixing the current time to it,
54 * but only if verbose mode is activated.
57 void verboselog(char *fmt, ...);
60 * Logs the given message to stdout while prefixing the current time to it.
61 * This is to be called by LOG() which includes filename/linenumber
64 void slog(char *fmt, va_list args);