Commit graph

893 commits

Author SHA1 Message Date
Daniel Eklöf
ce68bdb59d exposable: add a 'width' member, set (at latest) in begin_expose() 2018-12-26 16:37:11 +01:00
Daniel Eklöf
a745436ee2 decoration: stack: stacks multiple decorations on top of each other 2018-12-26 15:59:48 +01:00
Daniel Eklöf
09cd27b688 decoration/underline: draws a line at the bottom of the particle 2018-12-26 15:59:16 +01:00
Daniel Eklöf
1c9a908a8f particle/string: draw decoration, if available 2018-12-26 15:31:49 +01:00
Daniel Eklöf
0e3dd72313 yml: bump anchor vector size 2018-12-26 15:31:37 +01:00
Daniel Eklöf
0094cc1269 config: load decorations. All particles may have one 2018-12-26 15:31:16 +01:00
Daniel Eklöf
0284f5ac85 decoration: configurable graphical effects, added to a particle 2018-12-26 15:30:47 +01:00
Daniel Eklöf
052513c736 particle/ramp: don't use floating point arithmetic 2018-12-26 12:44:26 +01:00
Daniel Eklöf
1929099ca4 module/backlight: new module 2018-12-26 12:44:17 +01:00
Daniel Eklöf
5306ebd4ed bar: call refresh() after all modules have been loaded
This also means that modules do *not* have to call bar->refresh() just
before/after calling module_signal_ready().

As long as the module's initial state has been correctly/completely
set up before it calls module_signal_ready(), the module *only* has to
call bar->refresh() when it's state changes.
2018-12-26 11:48:09 +01:00
Daniel Eklöf
3af0280304 module/xwindow: replace assert with real error check 2018-12-26 11:44:21 +01:00
Daniel Eklöf
6d75fe64ef module/xkb: signal module-ready when failing early 2018-12-26 11:42:42 +01:00
Daniel Eklöf
b2121070f8 module/i3: replace asserts with real error checks 2018-12-26 11:31:28 +01:00
Daniel Eklöf
30332670aa module/battery: convert asserts to real error checks 2018-12-25 12:25:24 +01:00
Daniel Eklöf
d81547066d module/battery: log error message on failure during initialization 2018-12-19 21:12:42 +01:00
Daniel Eklöf
3bc4bd56a9 tag: tag_new_string(): allow NULL values (treat as empty string) 2018-12-19 21:01:36 +01:00
Daniel Eklöf
7f2c0681a7 log: add LOG_ERRNO()
Works like LOG_ERR(), but appends a string representation of the
current errno value to the log message string.
2018-12-19 21:01:01 +01:00
Daniel Eklöf
8897e480c5 log: rename log_class() -> log_msg() 2018-12-19 20:56:26 +01:00
Daniel Eklöf
7e95862e12 module/battery: error handling during initialization 2018-12-19 20:54:36 +01:00
Daniel Eklöf
ffaec546f5 module/xwindow: use lock from generic module 2018-12-19 20:35:43 +01:00
Daniel Eklöf
60b72cc55a module/xkb: delay ready signal, until we've actually initialized 2018-12-19 20:29:58 +01:00
Daniel Eklöf
661cabfb69 module/i3: use lock provided by generic module 2018-12-19 20:26:15 +01:00
Daniel Eklöf
2c7362fefa module/battery: no need to lock before we've signaled ready 2018-12-19 20:24:36 +01:00
Daniel Eklöf
3413232ed6 module: add new function module_signal_ready() 2018-12-19 20:23:53 +01:00
Daniel Eklöf
a3eb7ebc08 bar: wait for all modules to have started up before continuing
After starting all the module threads, wait for all modules to have
signalled "ready" before continuing.

This will allow modules to do initial setup, and knowing that
content() will *not* be called until they've signalled "ready".
2018-12-19 19:41:25 +01:00
Daniel Eklöf
7f0f096ba4 module: begin_expose() and content() take a non-const module pointer 2018-12-19 19:03:19 +01:00
Daniel Eklöf
b579f97db7 module/xwindow: use module common constructor/destructor 2018-12-19 19:00:29 +01:00
Daniel Eklöf
f8cb3acc35 module/xkb: use module common constructor/destructor 2018-12-19 18:59:33 +01:00
Daniel Eklöf
20cb0f0de7 module/label: use module common constructor/destructor 2018-12-19 18:58:10 +01:00
Daniel Eklöf
536db672b4 module/i3: use module common constructor/destructor 2018-12-19 18:57:19 +01:00
Daniel Eklöf
16553a7216 module/battery: acquire lock when reading/writing state 2018-12-18 20:24:30 +01:00
Daniel Eklöf
d279b585db module/battery: read all data into local variables first
This minimizes the time we'll have to hold the lock (once we lock).
2018-12-18 20:23:19 +01:00
Daniel Eklöf
f253bbebd2 module/battery: we're scanning into a signed long 2018-12-18 20:22:48 +01:00
Daniel Eklöf
76995ddcd5 module/battery: use module common constructor and default destructor 2018-12-18 20:22:30 +01:00
Daniel Eklöf
72624af1fa clock: use module common constructor and destructor 2018-12-18 20:13:04 +01:00
Daniel Eklöf
edc418b22d module: provide a "common" constructor and destructor
Also, provide a lock for module to use (to ensure run() and content()
doesn't step on each other's toes).
2018-12-18 20:12:04 +01:00
Daniel Eklöf
3618b863ff module/i3: lower case initial letter in log message 2018-12-18 20:00:03 +01:00
Daniel Eklöf
0f5d626177 config: list has a default right-spacing of 2 2018-12-18 19:52:36 +01:00
Daniel Eklöf
6db41b7803 module/xkb: initialize layouts to zero
Fixes a crash when content() is called before we've initialized the
layouts.
2018-12-18 19:49:05 +01:00
Daniel Eklöf
47f5c5d655 log: dim module name / file name + line number 2018-12-18 19:46:13 +01:00
Daniel Eklöf
b3a3990347 bar: log *which* event that is unimplemented 2018-12-18 19:42:47 +01:00
Daniel Eklöf
7cc1fa9cef log.c: align module name 2018-12-18 19:41:08 +01:00
Daniel Eklöf
5e80cf2204 log: only enable debug logging if LOG_ENABLE_DBG has been set to 1 2018-12-18 19:41:05 +01:00
Daniel Eklöf
a588c78e57 particle/ramp: use log framework 2018-12-18 19:37:37 +01:00
Daniel Eklöf
1c708975eb module/xkb: use log framework 2018-12-18 19:37:30 +01:00
Daniel Eklöf
1fa5baf8b7 module/i3: use log framework 2018-12-18 19:37:22 +01:00
Daniel Eklöf
2fdd419600 module/battery: use log framework 2018-12-18 19:37:10 +01:00
Daniel Eklöf
452669d6de bar: lower case initial letter in log message 2018-12-18 19:37:03 +01:00
Daniel Eklöf
817ce49e3b bar: use log framework 2018-12-18 19:24:26 +01:00
Daniel Eklöf
8ae89820db bar: use log framework 2018-12-17 20:29:25 +01:00