Hello there again! This is a somewhat manual cherry-pick request on part of the next branch.
Available at: [email protected]:obvious.git next Andrei 'Garoth' Thorp (2): [d2aa9c2] Lib: hooks lib w/ awful timer wrapper functions [aead25c] Lib/Util: Added bold & colour functions So this adds some interesting stuff to Obvious. The main big conceptual addition is the Obvious "lib" -- the idea here is to provide an extension to awful for use with Obvious. The plan would be to put stuff like mpd backends (one is in the works in another branch), /proc parsing backends, and utilities in there. So far, I've implemented some maybe exciting stuff: * The basic file structure for the lib * lib/hooks/timer: This is an extension of awful.hooks.timer. It has some extra features: (Thanks to anrxc for some ideas.) * Each timer register takes a regular speed, a slow speed, the fn, and a description. * You can access the data for registered functions at any point, or change it. This should be interesting for changing the speeds on stuff that was registered by widgets and not by the user directly (hopefully). The description aids in identifying which timer goes with what if you're trying to do this. * You can tell a registered function (or all functions at once!) to change speed to slow or regular. This may be useful for a "low usage" kind of setup where you want your widgets running, but not so quickly because you're on battery or something. Maybe you just feel like slow-motion :) * You can pause/unpause any function (or all at once). When they are resumed, they remember which speed they were at before being paused. This is great for that "I'm on battery, suspend my widgets" moment. * Check whether a function is registered. Useful for some dynamic stuff. * lib/util: A basic set of utilities. So far, this just has simple bold + colour functions that someone may want to improve at some point. They're just wrappers for the pango markup. There is another patch in next that I don't think is quite ready for merge. It's a port of my popup run prompt to this. It works, but slow-mo isn't quite in. Don't grab that :) Hopefully some people are as excited about this timer stuff as I am, haha. Maybe I'm just crazy though. Cheers. -- Andrei Thorp, Developer: Xandros Corp. (http://www.xandros.com) -- To unsubscribe, send mail to [email protected].
