RFC: Add keyboard backlight brightness handling to power-manager

Steve Dodier-Lazaro sidnioulz at gmail.com
Thu Mar 27 03:25:08 CET 2014


I think xfpm is the right place since it already talks to the daemon you
need, afaik.

I'm not sure if it makes sense to have a UI/settings for this, because I've
never had a bright keyboard. I would say that if the user wants to toggle
keyboard lights (any use case?), it should be in the keyboard settings as a
toggle and one could even make a CLI for that so it can be bound to a key
(CLI is not too intrusive as well since it avoids UI clutter for lay users).

However, if you're concerned about automatically turning off the keyboard
for power saving (or to make the PC dark when it's just used to play music
at night, which is my personal use case for turning off the monitor) then
it has to do with power manager. Because this use case seems more likely to
draw attention to me, I would locate a UI within xfpm (that would allow
sliding the brightness -- lay users may fail to understand keyboard
shortcuts or there might be driver issues with them too, and that gives you
a nice way to also turn off the brightness permanently without extra UI
widgets -- and that would allow automatic toggling when the user's inactive
just like the screen does), and I would then add a link in the keyboard
settings to the xfpm UI to avoid duplication.

There are of course a large number of alternative designs (some of which
should be better than this 20-seconds attempt)... only depends how
seriously you want to consider the question :)


2014-03-27 2:04 GMT+00:00 Carl Simonson <simonsonc at gmail.com>:

> Steve,
>
> Those are good ideas.
>
> All that I have changed so far is changing the brightness when keyboard
> buttons are pressed. There are no settings saved, or user interfaces to
> control the level.
>
> Since I hadn't really considered the UI to begin with, would there be a
> better place for this code? It seemed like a natural place since that where
> the display brightness changer is.
>
> Carl Simonson
> simonsonc at gmail.com
>
>
> On Wed, Mar 26, 2014 at 8:36 PM, Steve Dodier-Lazaro <sidnioulz at gmail.com>wrote:
>
>> Hi,
>>
>> Whilst to me the location of the backend matters little, shouldn't one
>> expect that users will look for keyboard brightness settings in the
>> keyboard settings? I had a quick glance at your code (can't build/test
>> stuff on the lappy right now) and it seems to me that you're using only the
>> xfpm settings UI. What about a patch against keyboard-settings with a
>> clickable link that'd open the xfpm settings (and appear only if xfpm is
>> running/runnable)?
>>
>>
>> 2014-03-26 22:14 GMT+00:00 Carl Simonson <simonsonc at gmail.com>:
>>
>>>  All,
>>>
>>> I have been working on a way to have xfce4-power-manager handle keyboard
>>> backlight brightness buttons. Some things it does:
>>>
>>> * It will listen to keyboard brightness up/down keys from your keyboard
>>> * It displays a libnotify popup showing the brightness level (a la
>>> sound/display brightness)
>>> * Changes brightness by sending D-Bus messages to UPower
>>>
>>> Please have a look and see if it seems like something that should be
>>> included into mainline. You can check my kdb-backlight branch in github at:
>>>
>>>     https://github.com/simonsonc/xfce4-power-manager/tree/kbd-backlight
>>>
>>> Thanks,
>>>
>>> Carl Simonson
>>> simonsonc at gmail.com
>>>
>>> _______________________________________________
>>> Xfce4-dev mailing list
>>> Xfce4-dev at xfce.org
>>> https://mail.xfce.org/mailman/listinfo/xfce4-dev
>>>
>>
>>
>>
>> --
>> Steve Dodier-Lazaro
>> PhD Student in Information Security
>> University College London
>> Free Software Developer
>> OpenPGP : 1B6B1670
>>
>> _______________________________________________
>> Xfce4-dev mailing list
>> Xfce4-dev at xfce.org
>> https://mail.xfce.org/mailman/listinfo/xfce4-dev
>>
>
>
> _______________________________________________
> Xfce4-dev mailing list
> Xfce4-dev at xfce.org
> https://mail.xfce.org/mailman/listinfo/xfce4-dev
>



-- 
Steve Dodier-Lazaro
PhD Student in Information Security
University College London
Free Software Developer
OpenPGP : 1B6B1670
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://mail.xfce.org/pipermail/xfce4-dev/attachments/20140327/5d5521b3/attachment.html>


More information about the Xfce4-dev mailing list