KubuntuLaptopButtons

Differences between revisions 4 and 5
Revision 4 as of 2006-06-13 12:21:16
Size: 2677
Editor: host-82-138-218-202
Comment:
Revision 5 as of 2006-06-20 09:27:49
Size: 2311
Editor: 81
Comment:
Deletions are marked like this. Additions are marked like this.
Line 10: Line 10:
Make Kubuntu support for laptop buttons as good as in Ubuntu. Use the Ubuntu laptop buttons infrastructure in KDE.
Line 18: Line 18:
Masie has a laptop with suspend and brightness buttons, she wants to make sure these work. Masie has a laptop with suspend and brightness buttons, when pressing these buttons nothing happens and she doesn't know how to make them work.

Bob notices that all his laptop buttons work in Ubuntu but none of them work in Kubuntu which would otherwise be his preferred environment.

Daniel follows the complex kmilo thinkpad instructions to get his thinkpad buttons working, he has to enable nvram writing to get this to work but wonders if it is a security risk.
Line 22: Line 26:
Specific laptops are the problem of acpi-support and hotkey-setup, this spec is for making sure KDE does the right thing with the output of hotkey-setup.
Line 23: Line 29:

KDE has KMilo, a kde daemon module for handling laptop keys. KMilo has plugins for different types of laptop and each plugin for KMilo works in different ways and has different abilities. With the abstraction provided by hotkey-setup we no longer need different parts of KMilo for each laptop. We will create a new KMilo plugin for hotkey-support.
Line 26: Line 34:
=== Code === Our KMilo hotket-setup plugin will run xmodmap on startup to map the xevents from hotkey-setup to X keys. We will setup global bindings in KMix, Amarok and KubuntuPowerManagement to handle volume up/down, play/pause, suspend/hibernate and screen brightness. The KMilo plugin will also have global bindings for volume and screen brightness and will show its on screen display to give feedback to the user, it will get its values by querying KMix and KubuntuPowerManagement with DCOP.
Line 28: Line 36:
=== Data preservation and migration ===

== Outstanding issues ==

== BoF agenda and discussion ==

Ubuntu uses hotkey-setup package to properly map different laptop keys into defined set of Linux keycode. For more info see:
 * /usr/share/doc/hotkey-setup/NOTES

This ensures that every laptop will send the same keycode for the same key. Ubuntu/GNOME was patched that gnome-settings-daemon catches those events and starts appropriate action.

KMilo module of kded provides handling of laptop keys and on-screen display of action. KMilo has modules for asus, delli8k, generic, vaio, powerbook, thinkpad, we should make sure these all work.
 * The thinkpad one polls nvram and tells kmix to change, it should probably leave most of it to thinkpad-buttons and just offer an onscreen display, or if necessary a key event.
 * The generic one handles standard xkeysyms and works for laptops/keyboards with proper Xkb keyboard layout.

KMix should listen to the key events and have working default bindings.

Questions: how the heck to fix for all these types of laptops?
 * we should add new KMilo module: keycode (or ubuntu)
 * this module would catch linux keycodes (done by hotkey-setup) and transform them into appropriate actions (volume/brightness control, launch applications...)
 * we should package/enable only generic (for xkeysym) and new keycode modules of KMilo
   * we need to ensure that no (major?) functonality of dropped modules (asus, delli8k, vaio, powerbook, thinkpad) is not lost
 * Use the framework the laptop-testing team has in place LaptopTestingTeam and get people to test Kubuntu Edgy on their laptops. A possibility might be to supply from Canonical laptops to key testors like they do for Ubuntu. Build wiki pages like LaptopTestingTeam/DellLatitudeD810/Kubuntu but with more laptops

See notes from talking with mjg59 KubuntuLaptopNotes

----
CategorySpec
The KMilo plugin will also have global keybindings to listen for the ''e-mail'' and ''web browser'' buttons, these will run the default application which the user can set in the normal KDE way.

Summary

Use the Ubuntu laptop buttons infrastructure in KDE.

Rationale

Many laptops and also desktops have extra feature buttons which handle power management, display controls and other features. These should work as well in Kubuntu as they do in Ubuntu.

Use cases

Masie has a laptop with suspend and brightness buttons, when pressing these buttons nothing happens and she doesn't know how to make them work.

Bob notices that all his laptop buttons work in Ubuntu but none of them work in Kubuntu which would otherwise be his preferred environment.

Daniel follows the complex kmilo thinkpad instructions to get his thinkpad buttons working, he has to enable nvram writing to get this to work but wonders if it is a security risk.

Scope

Specific laptops are the problem of acpi-support and hotkey-setup, this spec is for making sure KDE does the right thing with the output of hotkey-setup.

Design

KDE has KMilo, a kde daemon module for handling laptop keys. KMilo has plugins for different types of laptop and each plugin for KMilo works in different ways and has different abilities. With the abstraction provided by hotkey-setup we no longer need different parts of KMilo for each laptop. We will create a new KMilo plugin for hotkey-support.

Implementation

Our KMilo hotket-setup plugin will run xmodmap on startup to map the xevents from hotkey-setup to X keys. We will setup global bindings in KMix, Amarok and KubuntuPowerManagement to handle volume up/down, play/pause, suspend/hibernate and screen brightness. The KMilo plugin will also have global bindings for volume and screen brightness and will show its on screen display to give feedback to the user, it will get its values by querying KMix and KubuntuPowerManagement with DCOP.

The KMilo plugin will also have global keybindings to listen for the e-mail and web browser buttons, these will run the default application which the user can set in the normal KDE way.

KubuntuLaptopButtons (last edited 2008-08-06 16:27:41 by localhost)