Got ubuntu 11.10 on this laptop.
Only thing I've found to be a right pain is the brightness, so I thought I'd share the script I am using. This is on a pretty much default 11.10 install, would probably worth with others.
The script will set your screen to default brightness of 20%, which you can change by clicking on the brightness icon in the top toolbar (that will appear when you run the script) and changing. It forces the brightness back to this level every 5s in case you (like me) often press keys that reset it.
Save below as a script called something like brightness_applet.py
Code:
#!/usr/bin/env python
import datetime
import sys
import gtk
import appindicator
import imaplib
import re
import dbus
bus = dbus.SessionBus()
proxy = bus.get_object('org.gnome.SettingsDaemon',
'/org/gnome/SettingsDaemon/Power')
iface=dbus.Interface(proxy,dbus_interface='org.gnome.SettingsDaemon.Power.Screen')
PING_FREQUENCY = 5 # how often script forces brightness back
class ShowDate:
def __init__(self):
self.brightness = 20
self.ind = appindicator.Indicator("date-display",
'/usr/share/notify-osd/icons/gnome/scalable/status/notification-display-brightness-full.svg',
appindicator.CATEGORY_OTHER)
self.ind.set_status(appindicator.STATUS_ACTIVE)
self.menu_setup()
self.ind.set_menu(self.menu)
def menu_setup(self):
def menuLambda(b): return lambda x:self.setBright(b)
self.menu = gtk.Menu()
for pc in range(0,101,10):
self.item = gtk.MenuItem("%s%%"%(pc))
self.item.connect("activate", menuLambda(pc))
self.item.show()
self.menu.append(self.item)
def main(self):
self.set_brightness()
gtk.timeout_add(PING_FREQUENCY * 1000, self.set_brightness)
gtk.main()
def quit(self, widget):
sys.exit(0)
def setBright(self, b):
self.brightness = b
self.set_brightness()
def set_brightness(self):
iface.SetPercentage(self.brightness)
return True
if __name__ == "__main__":
indicator = ShowDate()
indicator.main()
Make it runnable using
Code:
chmod +x brightness_applet.py
Run it to test is ok using
Code:
./brightness_applet.py
Ctrl+C to exit
Set it up to start on login by clicking on icon in top right corner of screen to get menu, choose Startup Applications..., then click Add button, type a name, browse to find this script, save, logout, login.
Decide what you like as a default (I like 20) and edit the 20 in the script to your favourite.
Hope this helps someone, it was cobbled together from multiple sites/posts from the net.