This piece of code should be able to retrieve the default station configured in the gnome-clock applet:
import gconf gconf_client = gconf.client_get_default() key = '/apps/panel/applets/clock_screen0/prefs/cities' cities = gconf_client.get_list(key, gconf.VALUE_STRING) default_city = cities[0]
default_city contains the information needed as a piece of XML that looks like this:
<location name="Barcelona/Airport" timezone="Europe/Madrid" latitude="41.283333" longitude="2.066667" code="LEBL" current="true"/>
This piece of code should be able to retrieve the default station configured in the gnome-clock applet:
import gconf get_default( ) panel/applets/ clock_screen0/ prefs/cities' get_list( key, gconf.VALUE_STRING)
gconf_client = gconf.client_
key = '/apps/
cities = gconf_client.
default_city = cities[0]
default_city contains the information needed as a piece of XML that looks like this:
<location name="Barcelona /Airport" timezone= "Europe/ Madrid" latitude= "41.283333" longitude= "2.066667" code="LEBL" current="true"/>