Synchronize a timer with textclock refresh in AwesomeWM

117 Views Asked by At

I try to synchronize a cairo surface's update with my textclock refresh.

Is it possible to hook a gears.timer to textclock's one? or should I create a textbox and use the same gears.timer to update both?

1

There are 1 best solutions below

0
Emmanuel Lepage Vallee On BEST ANSWER

By default, not without using private APIs, which is not recommended (mytextclock._timer).

However, a better alternative is to create a timer, then create your own textclock using a wibox.widget.textbox when it timeouts. It can be done in 1 line using os.date