Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Doesn't work with MATE #16

Open
fhucho opened this issue Jul 6, 2012 · 12 comments
Open

Doesn't work with MATE #16

fhucho opened this issue Jul 6, 2012 · 12 comments

Comments

@fhucho
Copy link

fhucho commented Jul 6, 2012

I'm using Arch Linux with MATE desktop environment (Gnome 2 fork). When I launch lightum, it writes this out:

Error org.freedesktop.DBus.Error.ServiceUnknown: The name org.gnome.SettingsDaemon was not provided by any .service files
Error org.freedesktop.DBus.Error.ServiceUnknown: The name org.gnome.SettingsDaemon was not provided by any .service files
Error org.freedesktop.DBus.Error.ServiceUnknown: The name org.kde.Solid.PowerManagement was not provided by any .service files
Can't manage screen backlight on this system.
Please disable backlight with config option 'workmode='1' or command line switch '-w 1'.
If you believe this is an error, open a bug report: https://github.com/poliva/lightum/issues

@poliva
Copy link
Owner

poliva commented Jul 7, 2012

Hello,

In file dbus.c, change all the references to "org.gnome.SettingsDaemon" to "org.mate.SettingsDaemon", it should work with this change.

@fhucho
Copy link
Author

fhucho commented Jul 8, 2012

It prints this:

Error org.freedesktop.DBus.Error.UnknownMethod: Method "GetPercentage" with signature "" on interface "org.mate.SettingsDaemon.Power.Screen" doesn't exist

But there's no need to fix this, I just wanted to try lightum out without plans to use it regularly :)

@poliva
Copy link
Owner

poliva commented Jul 8, 2012

Looks like mate settings daemon doesn't work the same as gnome settings daemon. Can you change the backlight using the function keys?

@fhucho
Copy link
Author

fhucho commented Jul 8, 2012

Keyboard backlight doesn't work in MATE, only screen brightness.

BTW, I was recently wondering what is the "right" approach for dealing with function keys and ambient light in Linux. If the desktop environment takes care of that, it leads to code duplication and it won't work with some fullscreen games, virtual terminals, lock screens or login managers.

@fhucho
Copy link
Author

fhucho commented Jul 8, 2012

In my opinion the best way is a daemon running under root, that does all the work (setting brightness, volume, ...) and only sends a dbus message when hotkey was pressed (so that the desktop environment can show a notification etc.). But this is offtopic, sorry :)

@poliva
Copy link
Owner

poliva commented Jul 9, 2012

that's what gnome-settings-daemon does, it forks gsd-backlight-helper to change the backlight with root permissions when instructed to do so via dbus. For some reason, mate-settings-daemon doesn't work the same way, but I have never tried mate, so I can't say for sure.

@graue
Copy link

graue commented Sep 16, 2012

I'm also getting this with Xfce on Xubuntu 12.10 beta. Does this need separately written code to deal with every desktop environment? That seems disappointing. The brightness keys on my MBA do work perfectly with Xfce.

@mkfs
Copy link

mkfs commented Sep 19, 2012

Just want to chime in that I have the same problem on E17. What's the point of putting Linux on a Macbook Air if you can't also run the most advanced WM out there, eh?

I tried to solve this by running
bash$ /usr/lib/gnome-settings-daemon/gnome-settings-daemon &
...but just got an error message that "you can only run one xsettings manager at a time".

If this requires a compile-time fix, then that really needs a re-design. Perhaps a config file where you can set the service name (and hope it works?)

Alternatively, command-line options to increment/decrement the brightness and backlight (by a fixed amount, like 10%, or by an amount determined by an argument) would allow users to map their keys to those commands.

@poliva
Copy link
Owner

poliva commented Sep 19, 2012

I will implement a mode that doesn't use gnome or kde dbus wrappers to set the brightness/backlight, so it will work on every window manager, but then it will have to be run as root. I currently don't have time for this, but is on my todo list.

@mkfs
Copy link

mkfs commented Sep 19, 2012

Understandable.

It looks like E17 allows you to disable its xsettings daemon -- specifically in order to run the GNOME or KDE one for situations like this. I'll give that a shot.

@mkfs
Copy link

mkfs commented Sep 20, 2012

Just wanted to follow up that E17 allows you to run GNOME settings (and lightum) at startup, which solves the problem nicely.

XFCE might have a similar option (e.g. disable xfce-settings-helper). Not sure if MATE will allow its settings daemon to be replaced, though.

@Kukunin
Copy link
Contributor

Kukunin commented Oct 23, 2012

No, this shouldn't be the daemon to work under root. The problems, which lightum solves are user-specific. Don't forget, Linux is multiuser system.

DBus has a perfect communication capabilities to do all work. UPower provides keyboard backlight supporting already. I've asked they about supporting display backlight too, I think, this feature should be done by UPower too.

Project has to be refactored, some abstraction has to be introduced. You can use xbacklight for display backlight controlling. I don't know, maybe there is more cool interface exists, then invoking 'xbacklight' utility

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

5 participants