aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorIain Holmes <iain@src.gnome.org>2001-06-30 02:34:53 +0800
committerIain Holmes <iain@src.gnome.org>2001-06-30 02:34:53 +0800
commitc470087c9b5663a64c338fadee3594d261ab65f3 (patch)
tree39f601455981886c8c21bfcc2fed03ac56bd7624
parente64a02be08f27b9a403de2bdf147626b8c8f2523 (diff)
downloadgsoc2013-evolution-c470087c9b5663a64c338fadee3594d261ab65f3.tar
gsoc2013-evolution-c470087c9b5663a64c338fadee3594d261ab65f3.tar.gz
gsoc2013-evolution-c470087c9b5663a64c338fadee3594d261ab65f3.tar.bz2
gsoc2013-evolution-c470087c9b5663a64c338fadee3594d261ab65f3.tar.lz
gsoc2013-evolution-c470087c9b5663a64c338fadee3594d261ab65f3.tar.xz
gsoc2013-evolution-c470087c9b5663a64c338fadee3594d261ab65f3.tar.zst
gsoc2013-evolution-c470087c9b5663a64c338fadee3594d261ab65f3.zip
Configure My Evolution
svn path=/trunk/; revision=10604
-rw-r--r--my-evolution/ChangeLog41
-rw-r--r--my-evolution/Makefile.am5
-rw-r--r--my-evolution/e-summary-calendar.c6
-rw-r--r--my-evolution/e-summary-calendar.h14
-rw-r--r--my-evolution/e-summary-factory.c12
-rw-r--r--my-evolution/e-summary-mail.c82
-rw-r--r--my-evolution/e-summary-mail.h1
-rw-r--r--my-evolution/e-summary-preferences.c1009
-rw-r--r--my-evolution/e-summary-preferences.h15
-rw-r--r--my-evolution/e-summary-rdf.c94
-rw-r--r--my-evolution/e-summary-rdf.h2
-rw-r--r--my-evolution/e-summary-weather.c215
-rw-r--r--my-evolution/e-summary-weather.h5
-rw-r--r--my-evolution/e-summary.c24
-rw-r--r--my-evolution/e-summary.h30
-rw-r--r--my-evolution/main.c2
-rw-r--r--my-evolution/metar.c63
-rw-r--r--my-evolution/metar.h1
-rw-r--r--my-evolution/my-evolution.glade1590
19 files changed, 3158 insertions, 53 deletions
diff --git a/my-evolution/ChangeLog b/my-evolution/ChangeLog
index 63f8467d96..deb7798445 100644
--- a/my-evolution/ChangeLog
+++ b/my-evolution/ChangeLog
@@ -1,3 +1,44 @@
+2001-06-29 Iain Holmes <iain@ximian.com>
+
+ * e-summary-preferences.c: Do everything preferences related.
+
+ * my-evolution.glade: Glade file for the preferences box.
+
+ * e-summary-calendar.c (e_summary_calendar_reconfigure): Stub for later
+
+ * e-summary-calendar.h: Some enums for settings.
+
+ * e-summary-mail.c (folder_gen_html): Change the prototype so it
+ doesn't work as a hash table foreach function.
+ (new_folder_cb): Fix typo in comment :)
+ Create a list of folders we display.
+ (remove_folder_cb): Remove the folder from the display folder list.
+ (maybe_add_to_shown): Hash table foreach function to create a display
+ folder list.
+ (e_summary_mail_reconfigure): Recreate the mail HTML.
+
+ * e-summary-rdf.c (tree_walk): Obey preferences.
+ (e_summary_rdf_update): Separate the updating and downloading logic.
+ (e_summary_rdf_init): Start an updating timeout.
+ (e_summary_rdf_reconfigure): Recreate the RDF html.
+
+ * e-summary-weather.c (e_summary_weather_update): Separate the updating
+ and downloading logic.
+ (e_summary_weather_init): Start timeout.
+ (e_summary_weather_code_to_name): Convert code to location name.
+ (e_summary_weather_ctree_fill): Fill a CTree with the location data.
+ (e_summary_weather_reconfigure): Regenerate the HTML.
+
+ * e-summary.c (e_summary_init): Create the preferences.
+ (e_summary_reconfigure): Reconfigure the whole summary.
+
+ * metar.c: Obey preferences.
+
+2001-06-27 Iain Holmes <iain@ximian.com>
+
+ * e-summary-factory.c: Add the pixmaps to the menus.
+ Add a new menu item for the configuration stuff.
+
2001-06-27 Ettore Perazzoli <ettore@ximian.com>
* component-factory.c (factory_fn): Pass NULL as the
diff --git a/my-evolution/Makefile.am b/my-evolution/Makefile.am
index 22af538ec0..af1b39fc10 100644
--- a/my-evolution/Makefile.am
+++ b/my-evolution/Makefile.am
@@ -12,7 +12,6 @@ INCLUDES = \
$(GNOME_VFS_CFLAGS) \
$(GTKHTML_CFLAGS) \
-DEVOLUTION_GLADEDIR=\""$(gladedir)"\" \
- -DEVOLUTION_ICONSDIR=\""$(iconsdir)"\" \
-DEVOLUTION_LOCALEDIR=\""$(localedir)"\" \
-DEVOLUTION_DATADIR=\""$(datadir)"\" \
-DG_LOG_DOMAIN=\"evolution-executive-summary\"
@@ -41,6 +40,7 @@ evolution_executive_summary_SOURCES = \
e-summary-factory.h \
e-summary-mail.c \
e-summary-mail.h \
+ e-summary-preferences.c \
e-summary-rdf.h \
e-summary-rdf.c \
e-summary-type.h \
@@ -73,6 +73,9 @@ oafdir = $(datadir)/oaf
oaf_in_files = GNOME_Evolution_Summary.oaf.in
oaf_DATA = $(oaf_in_files:.oaf.in=.oaf)
+gladedir = $(datadir)/evolution/glade
+glade_DATA = my-evolution.glade
+
@XML_I18N_MERGE_OAF_RULE@
EXTRA_DIST = $(oaf_in_files) $(oaf_DATA) $(Location_DATA)
diff --git a/my-evolution/e-summary-calendar.c b/my-evolution/e-summary-calendar.c
index 2e2a1b5199..3bc2b21f46 100644
--- a/my-evolution/e-summary-calendar.c
+++ b/my-evolution/e-summary-calendar.c
@@ -284,3 +284,9 @@ e_summary_calendar_init (ESummary *summary)
e_summary_add_protocol_listener (summary, "calendar", e_summary_calendar_protocol, calendar);
}
+
+void
+e_summary_calendar_reconfigure (ESummary *summary)
+{
+
+}
diff --git a/my-evolution/e-summary-calendar.h b/my-evolution/e-summary-calendar.h
index d485be3b7c..5cf3fd936f 100644
--- a/my-evolution/e-summary-calendar.h
+++ b/my-evolution/e-summary-calendar.h
@@ -11,8 +11,22 @@
#include "e-summary-type.h"
+typedef enum _ESummaryCalendarDays {
+ E_SUMMARY_CALENDAR_ONE_DAY,
+ E_SUMMARY_CALENDAR_FIVE_DAYS,
+ E_SUMMARY_CALENDAR_ONE_WEEK,
+ E_SUMMARY_CALENDAR_ONE_MONTH
+} ESummaryCalendarDays;
+
+typedef enum _ESummaryCalendarNumTasks {
+ E_SUMMARY_CALENDAR_ALL_TASKS,
+ E_SUMMARY_CALENDAR_TODAYS_TASKS
+} ESummaryCalendarNumTasks;
+
typedef struct _ESummaryCalendar ESummaryCalendar;
const char *e_summary_calendar_get_html (ESummary *summary);
void e_summary_calendar_init (ESummary *summary);
+void e_summary_calendar_reconfigure (ESummary *summary);
+
#endif
diff --git a/my-evolution/e-summary-factory.c b/my-evolution/e-summary-factory.c
index 1a85519584..b7dde3c861 100644
--- a/my-evolution/e-summary-factory.c
+++ b/my-evolution/e-summary-factory.c
@@ -16,20 +16,24 @@
#include <bonobo/bonobo-ui-util.h>
#include "e-util/e-gui-utils.h"
+
#include "e-summary.h"
#include "e-summary-factory.h"
+#include "e-summary-preferences.h"
+#include "evolution-shell-component-utils.h" /* For E_PIXMAP */
BonoboUIVerb verbs[] = {
BONOBO_UI_VERB ("PrintMyEvolution", e_summary_print),
+ BONOBO_UI_VERB ("ToolsSettings", e_summary_configure),
BONOBO_UI_VERB_END
};
-#if 0
+
static EPixmap pixmaps [] = {
- E_PIXMAP ("/menu/File/Print/Print", "print.xpm"),
+ E_PIXMAP ("/commands/Print", "print.xpm"),
+ E_PIXMAP ("/commands/ToolsSettings", "configure_16_mail.xpm"),
E_PIXMAP_END
};
-#endif
static void
control_activate (BonoboControl *control,
@@ -47,7 +51,7 @@ control_activate (BonoboControl *control,
bonobo_ui_util_set_ui (ui_component, EVOLUTION_DATADIR,
"my-evolution.xml", "my-evolution");
-/* e_pixmaps_update (ui_component, pixmaps); */
+ e_pixmaps_update (ui_component, pixmaps);
bonobo_ui_component_thaw (ui_component, NULL);
}
diff --git a/my-evolution/e-summary-mail.c b/my-evolution/e-summary-mail.c
index c5a2e54819..f8a3f68f7e 100644
--- a/my-evolution/e-summary-mail.c
+++ b/my-evolution/e-summary-mail.c
@@ -26,6 +26,7 @@ struct _ESummaryMail {
BonoboListener *listener;
GHashTable *folders;
+ GList *shown;
ESummaryMailMode mode;
char *html;
@@ -63,12 +64,9 @@ make_pretty_foldername (const char *foldername)
}
static void
-folder_gen_html (gpointer key,
- gpointer value,
- gpointer user_data)
+folder_gen_html (ESummaryMailFolder *folder,
+ GString *string)
{
- GString *string = user_data;
- ESummaryMailFolder *folder = value;
char *str, *pretty_name, *uri;
pretty_name = make_pretty_foldername (folder->name);
@@ -86,6 +84,7 @@ e_summary_mail_generate_html (ESummary *summary)
{
ESummaryMail *mail;
GString *string;
+ GList *p;
mail = summary->mail;
string = g_string_new ("<dl><dt><img src=\"ico-mail.png\" "
@@ -93,7 +92,9 @@ e_summary_mail_generate_html (ESummary *summary)
"height=\"48\"> <b><a href=\"evolution:/local/Inbox\">Mail summary</a>"
"</b></dt><dd><table numcols=\"2\" width=\"100%\">");
- g_hash_table_foreach (mail->folders, folder_gen_html, string);
+ for (p = mail->shown; p; p = p->next) {
+ folder_gen_html (p->data, string);
+ }
g_string_append (string, "</table></dd></dl>");
mail->html = string->str;
@@ -134,6 +135,7 @@ new_folder_cb (EvolutionStorageListener *listener,
{
ESummaryMail *mail;
ESummaryMailFolder *mail_folder;
+ GList *p;
/* Don't care about none mail */
if (strcmp (folder->type, "mail") != 0 ||
@@ -150,6 +152,19 @@ new_folder_cb (EvolutionStorageListener *listener,
mail_folder->unread = -1;
g_hash_table_insert (mail->folders, mail_folder->path, mail_folder);
+
+ /* Are we supposed to display this folder? */
+ for (p = summary->preferences->display_folders; p; p = p->next) {
+ char *uri;
+
+ uri = g_strconcat ("file://", p->data, NULL);
+ if (strcmp (uri, mail_folder->path) == 0) {
+ mail->shown = g_list_prepend (mail->shown, mail_folder);
+ }
+
+ g_free (uri);
+ }
+
e_summary_mail_get_info (mail, mail_folder->path, mail->listener);
}
@@ -160,6 +175,7 @@ remove_folder_cb (EvolutionStorageListener *listener,
{
ESummaryMail *mail;
ESummaryMailFolder *mail_folder;
+ GList *p;
mail = summary->mail;
mail_folder = g_hash_table_lookup (mail->folders, path);
@@ -167,7 +183,17 @@ remove_folder_cb (EvolutionStorageListener *listener,
return;
}
+ /* Check if we're displaying it, because we can't display it if it
+ doesn't exist :) */
+ for (p = mail->shown; p; p = p->next) {
+ if (p->data == mail_folder) {
+ mail->shown = g_list_remove_link (mail->shown, p);
+ g_list_free (p);
+ }
+ }
+
g_hash_table_remove (mail->folders, path);
+ g_free (mail_folder->name);
g_free (mail_folder->path);
g_free (mail_folder);
}
@@ -274,3 +300,47 @@ e_summary_mail_init (ESummary *summary,
e_summary_add_protocol_listener (summary, "mail", e_summary_mail_protocol, mail);
return;
}
+
+static void
+maybe_add_to_shown (gpointer key,
+ gpointer value,
+ gpointer user_data)
+{
+ ESummary *summary = user_data;
+ ESummaryMailFolder *folder = value;
+ ESummaryMail *mail = summary->mail;
+ GList *p;
+
+ /* Are we supposed to display this folder? */
+ for (p = summary->preferences->display_folders; p; p = p->next) {
+ char *uri;
+
+ uri = g_strconcat ("file://", p->data, NULL);
+ if (strcmp (uri, folder->path) == 0) {
+ mail->shown = g_list_prepend (mail->shown, folder);
+ }
+
+ g_free (uri);
+ }
+}
+
+void
+e_summary_mail_reconfigure (ESummary *summary)
+{
+ ESummaryMail *mail;
+ GList *old;
+
+ g_return_if_fail (summary != NULL);
+ g_return_if_fail (IS_E_SUMMARY (summary));
+
+ mail = summary->mail;
+ old = mail->shown;
+ mail->shown = NULL;
+ g_hash_table_foreach (mail->folders, maybe_add_to_shown, summary);
+ e_summary_mail_generate_html (summary);
+
+ /* Free the old list */
+ g_list_free (old);
+
+ e_summary_draw (summary);
+}
diff --git a/my-evolution/e-summary-mail.h b/my-evolution/e-summary-mail.h
index 858a3cbbae..67090b4271 100644
--- a/my-evolution/e-summary-mail.h
+++ b/my-evolution/e-summary-mail.h
@@ -23,4 +23,5 @@ typedef struct _ESummaryMail ESummaryMail;
const char *e_summary_mail_get_html (ESummary *summary);
void e_summary_mail_init (ESummary *summary,
GNOME_Evolution_Shell corba_shell);
+void e_summary_mail_reconfigure (ESummary *summary);
#endif
diff --git a/my-evolution/e-summary-preferences.c b/my-evolution/e-summary-preferences.c
new file mode 100644
index 0000000000..939c31ba26
--- /dev/null
+++ b/my-evolution/e-summary-preferences.c
@@ -0,0 +1,1009 @@
+/*
+ * e-summary-preferences.c:
+ *
+ * Copyright (C) 2001 Ximian, Inc
+ *
+ * Authors: Iain Holmes <iain@ximian.com>
+ */
+
+#include "e-summary.h"
+#include "e-summary-preferences.h"
+
+#include <gtk/gtk.h>
+
+#include <libgnome/gnome-defs.h>
+#include <libgnome/gnome-util.h>
+#include <libgnome/gnome-config.h>
+
+#include <libgnomeui/gnome-propertybox.h>
+#include <glade/glade.h>
+static void
+make_initial_mail_list (ESummaryPrefs *prefs)
+{
+ char *evolution_dir;
+ GList *folders;
+
+ evolution_dir = gnome_util_prepend_user_home ("evolution/local");
+
+ folders = g_list_append (NULL, g_strconcat (evolution_dir, "/Inbox", NULL));
+ folders = g_list_append (folders, g_strconcat (evolution_dir, "/Outbox", NULL));
+
+ g_free (evolution_dir);
+ prefs->display_folders = folders;
+}
+
+static void
+make_initial_rdf_list (ESummaryPrefs *prefs)
+{
+ GList *rdfs;
+
+ rdfs = g_list_prepend (NULL, g_strdup ("http://news.gnome.org/gnome-news/rdf"));
+
+ prefs->rdf_urls = rdfs;
+}
+
+static void
+make_initial_weather_list (ESummaryPrefs *prefs)
+{
+ GList *stations;
+
+ stations = g_list_prepend (NULL, g_strdup ("EGAA"));
+ stations = g_list_prepend (stations, g_strdup ("EGAC"));
+ stations = g_list_prepend (stations, g_strdup ("ENBR"));
+
+ prefs->stations = stations;
+}
+
+/* Load the prefs off disk */
+
+static char *
+vector_from_str_list (GList *strlist)
+{
+ char *vector;
+ GString *str;
+
+ g_return_val_if_fail (strlist != NULL, NULL);
+
+ str = g_string_new ("");
+ for (; strlist; strlist = strlist->next) {
+ g_string_append (str, strlist->data);
+
+ /* No space at end */
+ if (strlist->next) {
+ g_string_append (str, " ");
+ }
+ }
+
+ vector = str->str;
+ g_string_free (str, FALSE);
+
+ return vector;
+}
+
+static GList *
+str_list_from_vector (const char *vector)
+{
+ GList *strlist = NULL;
+ char **tokens;
+
+ tokens = g_strsplit (vector, " ", 8196);
+
+ if (tokens == NULL) {
+ return NULL;
+ }
+
+ for (; *tokens; tokens++) {
+ strlist = g_list_prepend (strlist, g_strdup (*tokens));
+ }
+
+ g_strfreev (tokens);
+
+ strlist = g_list_reverse (strlist);
+ return strlist;
+}
+
+gboolean
+e_summary_preferences_restore (ESummaryPrefs *prefs)
+{
+ char *evolution_dir, *key;
+ char *vector;
+
+ g_return_val_if_fail (prefs != NULL, FALSE);
+
+ evolution_dir = gnome_util_prepend_user_home ("evolution/config/my-evolution");
+ if (g_file_exists (evolution_dir) == FALSE) {
+ g_free (evolution_dir);
+ return FALSE;
+ }
+
+ key = g_strdup_printf ("=%s=/Mail/", evolution_dir);
+ gnome_config_push_prefix (key);
+ g_free (key);
+
+ vector = gnome_config_get_string ("display_folders");
+ prefs->display_folders = str_list_from_vector (vector);
+ g_free (vector);
+
+ prefs->show_full_path = gnome_config_get_bool ("show_full_path=FALSE");
+
+ gnome_config_pop_prefix ();
+ key = g_strdup_printf ("=%s=/RDF/", evolution_dir);
+ gnome_config_push_prefix (key);
+ g_free (key);
+
+ vector = gnome_config_get_string ("rdf_urls");
+ prefs->rdf_urls = str_list_from_vector (vector);
+ g_free (vector);
+
+ prefs->rdf_refresh_time = gnome_config_get_int ("rdf_refresh_time=600");
+ prefs->limit = gnome_config_get_int ("limit=10");
+ prefs->wipe_trackers = gnome_config_get_bool ("wipe_trackers=True");
+
+ gnome_config_pop_prefix ();
+ key = g_strdup_printf ("=%s=/Weather/", evolution_dir);
+ gnome_config_push_prefix (key);
+ g_free (key);
+
+ vector = gnome_config_get_string ("stations");
+ prefs->stations = str_list_from_vector (vector);
+ g_free (vector);
+
+ prefs->units = gnome_config_get_int ("units");
+ prefs->weather_refresh_time = gnome_config_get_int ("weather_refresh_time");
+
+ gnome_config_pop_prefix ();
+ key = g_strdup_printf ("=%s=/Schedule", evolution_dir);
+ gnome_config_push_prefix (key);
+ g_free (key);
+
+ prefs->days = gnome_config_get_int ("days");
+ prefs->show_tasks = gnome_config_get_int ("show_tasks");
+
+ gnome_config_pop_prefix ();
+ g_free (evolution_dir);
+ return TRUE;
+}
+
+/* Write prefs to disk */
+void
+e_summary_preferences_save (ESummaryPrefs *prefs)
+{
+ char *evolution_dir, *key;
+ char *vector;
+
+ g_return_if_fail (prefs != NULL);
+
+ evolution_dir = gnome_util_prepend_user_home ("evolution/config/my-evolution");
+ key = g_strdup_printf ("=%s=/Mail/", evolution_dir);
+ gnome_config_push_prefix (key);
+ g_free (key);
+
+ vector = vector_from_str_list (prefs->display_folders);
+ gnome_config_set_string ("display_folders", vector);
+ g_free (vector);
+
+ gnome_config_set_bool ("show_full_path", prefs->show_full_path);
+
+ gnome_config_pop_prefix ();
+ key = g_strdup_printf ("=%s=/RDF/", evolution_dir);
+ gnome_config_push_prefix (key);
+ g_free (key);
+
+ vector = vector_from_str_list (prefs->rdf_urls);
+ gnome_config_set_string ("rdf_urls", vector);
+ g_free (vector);
+
+ gnome_config_set_int ("rdf_refresh_time", prefs->rdf_refresh_time);
+ gnome_config_set_int ("limit", prefs->limit);
+ gnome_config_set_bool ("wipe_trackers", prefs->wipe_trackers);
+
+ gnome_config_pop_prefix ();
+ key = g_strdup_printf ("=%s=/Weather/", evolution_dir);
+ gnome_config_push_prefix (key);
+ g_free (key);
+
+ vector = vector_from_str_list (prefs->stations);
+ gnome_config_set_string ("stations", vector);
+ g_free (vector);
+
+ gnome_config_set_int ("units", prefs->units);
+ gnome_config_set_int ("weather_refresh_time", prefs->weather_refresh_time);
+
+ gnome_config_pop_prefix ();
+ key = g_strdup_printf ("=%s=/Schedule", evolution_dir);
+ gnome_config_push_prefix (key);
+ g_free (key);
+
+ gnome_config_set_int ("days", prefs->days);
+ gnome_config_set_int ("show_tasks", prefs->show_tasks);
+
+ gnome_config_pop_prefix ();
+ g_free (evolution_dir);
+}
+
+static void
+free_str_list (GList *list)
+{
+ for (; list; list = list->next) {
+ g_free (list->data);
+ }
+}
+
+void
+e_summary_preferences_free (ESummaryPrefs *prefs)
+{
+ if (prefs->display_folders) {
+ free_str_list (prefs->display_folders);
+ g_list_free (prefs->display_folders);
+ }
+
+ if (prefs->rdf_urls) {
+ free_str_list (prefs->rdf_urls);
+ g_list_free (prefs->rdf_urls);
+ }
+
+ if (prefs->stations) {
+ free_str_list (prefs->stations);
+ g_list_free (prefs->stations);
+ }
+
+ g_free (prefs);
+}
+
+static GList *
+copy_str_list (GList *list)
+{
+ GList *list_copy = NULL;
+
+ for (; list; list = list->next) {
+ list_copy = g_list_prepend (list_copy, g_strdup (list->data));
+ }
+
+ list_copy = g_list_reverse (list_copy);
+ return list_copy;
+}
+
+ESummaryPrefs *
+e_summary_preferences_copy (ESummaryPrefs *prefs)
+{
+ ESummaryPrefs *prefs_copy;
+
+ prefs_copy = g_new (ESummaryPrefs, 1);
+
+ prefs_copy->display_folders = copy_str_list (prefs->display_folders);
+ prefs_copy->show_full_path = prefs->show_full_path;
+
+ prefs_copy->rdf_urls = copy_str_list (prefs->rdf_urls);
+ prefs_copy->rdf_refresh_time = prefs->rdf_refresh_time;
+ prefs_copy->limit = prefs->limit;
+ prefs_copy->wipe_trackers = prefs->wipe_trackers;
+
+ prefs_copy->stations = copy_str_list (prefs->stations);
+ prefs_copy->units = prefs->units;
+ prefs_copy->weather_refresh_time = prefs->weather_refresh_time;
+
+ prefs_copy->days = prefs->days;
+ prefs_copy->show_tasks = prefs->show_tasks;
+
+ return prefs_copy;
+}
+
+void
+e_summary_preferences_init (ESummary *summary)
+{
+ ESummaryPrefs *prefs;
+
+ g_return_if_fail (summary != NULL);
+ g_return_if_fail (IS_E_SUMMARY (summary));
+
+ summary->preferences = g_new0 (ESummaryPrefs, 1);
+ summary->old_prefs = NULL;
+
+ if (e_summary_preferences_restore (summary->preferences) == TRUE) {
+ return;
+ }
+
+ prefs = summary->preferences;
+ /* Defaults */
+
+ /* Mail */
+ make_initial_mail_list (prefs);
+
+ /* RDF */
+ make_initial_rdf_list (prefs);
+ prefs->rdf_refresh_time = 600;
+ prefs->limit = 10;
+ prefs->wipe_trackers = FALSE;
+
+ /* Weather */
+ make_initial_weather_list (prefs);
+ prefs->units = UNITS_METRIC;
+ prefs->weather_refresh_time = 600;
+
+ prefs->days = E_SUMMARY_CALENDAR_ONE_DAY;
+ prefs->show_tasks = E_SUMMARY_CALENDAR_ALL_TASKS;
+}
+
+struct _MailPage {
+ GtkWidget *all, *shown;
+ GtkWidget *fullpath;
+ GtkWidget *add, *remove;
+};
+
+struct _RDFPage {
+ GtkWidget *all, *shown;
+ GtkWidget *refresh, *limit, *wipe_trackers;
+ GtkWidget *add, *remove;
+ GtkWidget *new_url;
+};
+
+struct _WeatherPage {
+ GtkWidget *all, *shown;
+ GtkWidget *refresh, *imperial, *metric;
+ GtkWidget *add, *remove;
+
+ GtkCTreeNode *selected_node;
+};
+
+struct _CalendarPage {
+ GtkWidget *one, *five, *week, *month;
+ GtkWidget *all, *today;
+};
+
+typedef struct _PropertyData {
+ ESummary *summary;
+ GnomePropertyBox *box;
+ GladeXML *xml;
+
+ struct _MailPage *mail;
+ struct _RDFPage *rdf;
+ struct _WeatherPage *weather;
+ struct _CalendarPage *calendar;
+} PropertyData;
+
+static char *rdfs[] = {
+ "http://news.gnome.org/gnome-news/rdf",
+ "http://advogato.org/rss/articles.xml",
+ "http://www.appwatch.com/appwatch.rdf",
+ "http://barrapunto.com/barrapunto.rdf",
+ "http://barrapunto.com/gnome.rdf",
+ "http://www.bsdtoday.com/backend/bt.rdf",
+ "http://beyond2000.com/b2k.rdf",
+ "http://www.newsisfree.com/export.php3?_f=rss91&_w=f&_i=1443",
+ "http://www.cnn.com/cnn.rss",
+ "http://www.dictionary.com/wordoftheday/wotd.rss",
+ "http://www.dvdreview.com/rss/newschannel.rss",
+ "http://freshmeat.net/backend/fm.rdf",
+ "http://headlines.internet.com/internetnews/prod-news/news.rss",
+ "http://www.kde.org/news/kdenews.rdf",
+ "http://www.kuro5hin.org/backend.rdf",
+ "http://linuxgames.com/bin/mynetscape.pl",
+ "http://linux.com/mrn/jobs/latest_jobs.rss",
+ "http://www.linuxplanet.com/rss",
+ "http://linuxtoday.com/backend/my-netscape.rdf",
+ "http://lwn.net/headlines/rss",
+ "http://www.linux.com/mrn/front_page.rss",
+ "http://morons.org/morons.rss",
+ "http://www.mozilla.org/news.rdf",
+ "http://www.mozillazine.org/contents.rdf",
+ "http://www.fool.com/about/headlines/rss_headlines.asp",
+ "http://www.newsforge.com/newsforge.rss",
+ "http://www.nanotechnews.com/nano/rdf",
+ "http://www.perl.com/pace/news.rss",
+ "http://www.pigdog.org/pigdog.rdf",
+ "http://www.python.org/channews.rdf",
+ "http://www.quotationspage.com/data/mqotd.rss",
+ "http://www.salon.com/feed/RDF/salon_use.rdf",
+ "http://www.scriptingnews.userland.com/xml/scriptingnews2.xml",
+ "http://www.securityfocus.com/topnews-rss.html",
+ "http://www.segfault.org/stories.xml",
+ "http://www.slashdot.org/slashdot.rdf",
+ "http://www.theregister.co.uk/tonys/slashdot.org",
+ "http://www.thinkgeek.com/thinkgeek.rdf",
+ "http://www.tomalak.org/recentTodaysLinks.xml",
+ "http://www.webreference.com/webreference.rdf",
+ "http://www.zope.org/SiteIndex/news.rss",
+ NULL
+};
+
+static void
+fill_rdf_all_clist (GtkCList *clist)
+{
+ int i;
+
+ for (i = 0; rdfs[i]; i++) {
+ char *text[1];
+
+ text[0] = rdfs[i];
+ gtk_clist_append (clist, text);
+ }
+}
+
+static void
+fill_rdf_shown_clist (GtkCList *clist,
+ PropertyData *pd)
+{
+ GList *p;
+
+ for (p = pd->summary->preferences->rdf_urls; p; p = p->next) {
+ char *text[1];
+
+ text[0] = p->data;
+ gtk_clist_append (clist, text);
+ }
+}
+
+static void
+fill_weather_all_ctree (GtkCTree *ctree)
+{
+ e_summary_weather_ctree_fill (ctree);
+}
+
+static void
+fill_weather_shown_clist (GtkCList *clist,
+ PropertyData *pd)
+{
+ GList *p;
+
+ for (p = pd->summary->preferences->stations; p; p = p->next) {
+ char *text[1];
+ char *pretty;
+
+ pretty = (char *) e_summary_weather_code_to_name (p->data);
+
+ text[0] = pretty;
+ gtk_clist_append (clist, text);
+ }
+}
+
+static void
+fill_mail_shown_clist (GtkCList *clist,
+ PropertyData *pd)
+{
+ GList *p;
+
+ for (p = pd->summary->preferences->display_folders; p; p = p->next) {
+ char *text[1];
+
+ text[0] = p->data;
+ gtk_clist_append (clist, text);
+ }
+}
+
+static void
+mail_shown_select_row_cb (GtkCList *clist,
+ int row,
+ int column,
+ GdkEvent *event,
+ PropertyData *pd)
+{
+ gtk_widget_set_sensitive (pd->mail->remove, TRUE);
+}
+
+static void
+mail_shown_unselect_row_cb (GtkCList *clist,
+ int row,
+ int column,
+ GdkEvent *event,
+ PropertyData *pd)
+{
+ if (clist->selection == NULL) {
+ gtk_widget_set_sensitive (pd->mail->remove, FALSE);
+ }
+}
+
+static void
+mail_add_clicked_cb (GtkButton *button,
+ PropertyData *pd)
+{
+
+}
+
+static void
+mail_remove_clicked_cb (GtkButton *button,
+ PropertyData *pd)
+{
+ int row;
+ GList *p;
+
+ row = GPOINTER_TO_INT (GTK_CLIST (pd->mail->shown)->selection->data);
+ p = g_list_nth (pd->summary->preferences->display_folders, row);
+
+ gtk_clist_remove (GTK_CLIST (pd->mail->shown), row);
+ pd->summary->preferences->display_folders = g_list_remove_link (pd->summary->preferences->display_folders, p);
+ g_free (p->data);
+ g_list_free (p);
+
+ gnome_property_box_changed (pd->box);
+}
+
+static void
+mail_show_full_path_toggled_cb (GtkToggleButton *tb,
+ PropertyData *pd)
+{
+ pd->summary->preferences->show_full_path = gtk_toggle_button_get_active (tb);
+}
+
+static void
+rdf_all_select_row_cb (GtkCList *clist,
+ int row,
+ int column,
+ GdkEvent *event,
+ PropertyData *pd)
+{
+ gtk_widget_set_sensitive (pd->rdf->add, TRUE);
+}
+
+static void
+rdf_all_unselect_row_cb (GtkCList *clist,
+ int row,
+ int column,
+ GdkEvent *event,
+ PropertyData *pd)
+{
+ if (GTK_CLIST (pd->rdf->all)->selection == NULL) {
+ gtk_widget_set_sensitive (pd->rdf->add, FALSE);
+ }
+}
+
+static void
+rdf_shown_select_row_cb (GtkCList *clist,
+ int row,
+ int column,
+ GdkEvent *event,
+ PropertyData *pd)
+{
+ gtk_widget_set_sensitive (pd->rdf->remove, TRUE);
+}
+
+static void
+rdf_shown_unselect_row_cb (GtkCList *clist,
+ int row,
+ int column,
+ GdkEvent *event,
+ PropertyData *pd)
+{
+ if (GTK_CLIST (pd->rdf->shown)->selection == NULL) {
+ gtk_widget_set_sensitive (pd->rdf->remove, FALSE);
+ }
+}
+
+static void
+rdf_wipe_trackers_toggled_cb (GtkToggleButton *tb,
+ PropertyData *pd)
+{
+ pd->summary->preferences->wipe_trackers = gtk_toggle_button_get_active (tb);
+
+ gnome_property_box_changed (pd->box);
+}
+
+static void
+rdf_add_clicked_cb (GtkButton *button,
+ PropertyData *pd)
+{
+ GList *p;
+ char *url, *text[1];
+ int row;
+
+ row = GPOINTER_TO_INT (GTK_CLIST (pd->rdf->all)->selection->data);
+ gtk_clist_get_text (GTK_CLIST (pd->rdf->all), row, 0, &url);
+
+ text[0] = url;
+
+ for (p = pd->summary->preferences->rdf_urls; p; p = p->next) {
+ if (strcmp (p->data, url) == 0) {
+ /* Found it already */
+ return;
+ }
+ }
+
+ pd->summary->preferences->rdf_urls = g_list_prepend (pd->summary->preferences->rdf_urls, g_strdup (url));
+ gtk_clist_prepend (GTK_CLIST (pd->rdf->shown), text);
+
+ gnome_property_box_changed (pd->box);
+}
+
+static void
+rdf_remove_clicked_cb (GtkButton *button,
+ PropertyData *pd)
+{
+ GList *p;
+ int row;
+
+ row = GPOINTER_TO_INT (GTK_CLIST (pd->rdf->shown)->selection->data);
+ gtk_clist_remove (GTK_CLIST (pd->rdf->shown), row);
+
+ p = g_list_nth (pd->summary->preferences->rdf_urls, row);
+ pd->summary->preferences->rdf_urls = g_list_remove_link (pd->summary->preferences->rdf_urls, p);
+ g_free (p->data);
+ g_list_free (p);
+
+ gnome_property_box_changed (pd->box);
+}
+
+static void
+rdf_new_url_clicked_cb (GtkButton *button,
+ PropertyData *pd)
+{
+
+}
+
+static void
+rdf_refresh_value_changed_cb (GtkAdjustment *adj,
+ PropertyData *pd)
+{
+ pd->summary->preferences->rdf_refresh_time = (int) adj->value;
+ gnome_property_box_changed (pd->box);
+}
+
+static void
+rdf_limit_value_changed_cb (GtkAdjustment *adj,
+ PropertyData *pd)
+{
+ pd->summary->preferences->limit = (int) adj->value;
+ gnome_property_box_changed (pd->box);
+}
+
+static void
+weather_all_select_row_cb (GtkCTree *ctree,
+ GtkCTreeNode *row,
+ int column,
+ PropertyData *pd)
+{
+ gtk_widget_set_sensitive (pd->weather->add, TRUE);
+ pd->weather->selected_node = row;
+}
+
+static void
+weather_all_unselect_row_cb (GtkCList *clist,
+ GtkCTreeNode *row,
+ int column,
+ PropertyData *pd)
+{
+ if (clist->selection == NULL) {
+ gtk_widget_set_sensitive (pd->weather->add, FALSE);
+ }
+ pd->weather->selected_node = NULL;
+}
+
+static void
+weather_shown_select_row_cb (GtkCList *clist,
+ int row,
+ int column,
+ GdkEvent *event,
+ PropertyData *pd)
+{
+ gtk_widget_set_sensitive (pd->weather->remove, TRUE);
+}
+
+static void
+weather_shown_unselect_row_cb (GtkCList *clist,
+ int row,
+ int column,
+ GdkEvent *event,
+ PropertyData *pd)
+{
+ if (clist->selection == NULL) {
+ gtk_widget_set_sensitive (pd->weather->remove, FALSE);
+ }
+}
+
+static void
+weather_add_clicked_cb (GtkButton *button,
+ PropertyData *pd)
+{
+ ESummaryWeatherLocation *location;
+ GList *p;
+ char *text[1];
+
+ location = gtk_ctree_node_get_row_data (GTK_CTREE (pd->weather->all), pd->weather->selected_node);
+
+ for (p = pd->summary->preferences->stations; p; p = p->next) {
+ if (strcmp (location->code, p->data) == 0) {
+ return; /* Already have it */
+ }
+ }
+
+ pd->summary->preferences->stations = g_list_prepend (pd->summary->preferences->stations, g_strdup (location->code));
+ text[0] = location->name;
+ gtk_clist_prepend (GTK_CLIST (pd->weather->shown), text);
+
+ gnome_property_box_changed (pd->box);
+}
+
+static void
+weather_remove_clicked_cb (GtkButton *button,
+ PropertyData *pd)
+{
+ int row;
+ GList *p;
+
+ row = GPOINTER_TO_INT (GTK_CLIST (pd->weather->shown)->selection->data);
+ p = g_list_nth (pd->summary->preferences->stations, row);
+ gtk_clist_remove (GTK_CLIST (pd->weather->shown), row);
+
+ pd->summary->preferences->stations = g_list_remove_link (pd->summary->preferences->stations, p);
+ g_free (p->data);
+ g_list_free (p);
+
+ gnome_property_box_changed (pd->box);
+}
+
+static void
+weather_refresh_value_changed_cb (GtkAdjustment *adj,
+ PropertyData *pd)
+{
+ pd->summary->preferences->weather_refresh_time = (int) adj->value;
+ gnome_property_box_changed (pd->box);
+}
+
+static void
+weather_metric_toggled_cb (GtkToggleButton *tb,
+ PropertyData *pd)
+{
+ if (gtk_toggle_button_get_active (tb) == FALSE) {
+ return;
+ }
+
+ pd->summary->preferences->units = UNITS_METRIC;
+ gnome_property_box_changed (pd->box);
+}
+
+static void
+weather_imperial_toggled_cb (GtkToggleButton *tb,
+ PropertyData *pd)
+{
+ if (gtk_toggle_button_get_active (tb) == FALSE) {
+ return;
+ }
+
+ pd->summary->preferences->units = UNITS_IMPERIAL;
+ gnome_property_box_changed (pd->box);
+}
+
+static gboolean
+make_property_dialog (PropertyData *pd)
+{
+ struct _MailPage *mail;
+ struct _RDFPage *rdf;
+ struct _WeatherPage *weather;
+ struct _CalendarPage *calendar;
+
+ /* Mail */
+ mail = pd->mail = g_new (struct _MailPage, 1);
+
+ /* I think this should be a fancy bonobo thingy */
+ mail->all = glade_xml_get_widget (pd->xml, "clist2");
+ g_return_val_if_fail (mail->all != NULL, FALSE);
+
+ mail->shown = glade_xml_get_widget (pd->xml, "clist1");
+ g_return_val_if_fail (mail->shown != NULL, FALSE);
+ fill_mail_shown_clist (GTK_CLIST (mail->shown), pd);
+ gtk_signal_connect (GTK_OBJECT (mail->shown), "select-row",
+ GTK_SIGNAL_FUNC (mail_shown_select_row_cb), pd);
+ gtk_signal_connect (GTK_OBJECT (mail->shown), "unselect-row",
+ GTK_SIGNAL_FUNC (mail_shown_unselect_row_cb), pd);
+
+ mail->fullpath = glade_xml_get_widget (pd->xml, "checkbutton1");
+ g_return_val_if_fail (mail->fullpath != NULL, FALSE);
+ gtk_toggle_button_set_active (GTK_TOGGLE_BUTTON (mail->fullpath),
+ pd->summary->preferences->show_full_path);
+ gtk_signal_connect (GTK_OBJECT (mail->fullpath), "toggled",
+ GTK_SIGNAL_FUNC (mail_show_full_path_toggled_cb), pd);
+
+ mail->add = glade_xml_get_widget (pd->xml, "button4");
+ g_return_val_if_fail (mail->add != NULL, FALSE);
+ gtk_signal_connect (GTK_OBJECT (mail->add), "clicked",
+ GTK_SIGNAL_FUNC (mail_add_clicked_cb), pd);
+
+ mail->remove = glade_xml_get_widget (pd->xml, "button5");
+ g_return_val_if_fail (mail->remove != NULL, FALSE);
+ gtk_signal_connect (GTK_OBJECT (mail->remove), "clicked",
+ GTK_SIGNAL_FUNC (mail_remove_clicked_cb), pd);
+
+ /* RDF */
+ rdf = pd->rdf = g_new (struct _RDFPage, 1);
+ rdf->all = glade_xml_get_widget (pd->xml, "clist6");
+ g_return_val_if_fail (rdf->all != NULL, FALSE);
+ gtk_signal_connect (GTK_OBJECT (rdf->all), "select-row",
+ GTK_SIGNAL_FUNC (rdf_all_select_row_cb), pd);
+ gtk_signal_connect (GTK_OBJECT (rdf->all), "unselect-row",
+ GTK_SIGNAL_FUNC (rdf_all_unselect_row_cb), pd);
+ fill_rdf_all_clist (GTK_CLIST (rdf->all));
+
+ rdf->shown = glade_xml_get_widget (pd->xml, "clist5");
+ g_return_val_if_fail (rdf->shown != NULL, FALSE);
+ gtk_signal_connect (GTK_OBJECT (rdf->shown), "select-row",
+ GTK_SIGNAL_FUNC (rdf_shown_select_row_cb), pd);
+ gtk_signal_connect (GTK_OBJECT (rdf->shown), "unselect-row",
+ GTK_SIGNAL_FUNC (rdf_shown_unselect_row_cb), pd);
+ fill_rdf_shown_clist (GTK_CLIST (rdf->shown), pd);
+
+ rdf->refresh = glade_xml_get_widget (pd->xml, "spinbutton1");
+ g_return_val_if_fail (rdf->refresh != NULL, FALSE);
+ gtk_spin_button_set_value (GTK_SPIN_BUTTON (rdf->refresh),
+ (float) pd->summary->preferences->rdf_refresh_time);
+ gtk_signal_connect (GTK_OBJECT (GTK_SPIN_BUTTON (rdf->refresh)->adjustment), "value_changed",
+ GTK_SIGNAL_FUNC (rdf_refresh_value_changed_cb), pd);
+
+ rdf->limit = glade_xml_get_widget (pd->xml, "spinbutton4");
+ g_return_val_if_fail (rdf->limit != NULL, FALSE);
+ gtk_spin_button_set_value (GTK_SPIN_BUTTON (rdf->limit),
+ (float) pd->summary->preferences->limit);
+ gtk_signal_connect (GTK_OBJECT (GTK_SPIN_BUTTON (rdf->limit)->adjustment), "value_changed",
+ GTK_SIGNAL_FUNC (rdf_limit_value_changed_cb), pd);
+
+ rdf->wipe_trackers = glade_xml_get_widget (pd->xml, "checkbutton2");
+ g_return_val_if_fail (rdf->wipe_trackers != NULL, FALSE);
+ gtk_signal_connect (GTK_OBJECT (rdf->wipe_trackers), "toggled",
+ GTK_SIGNAL_FUNC (rdf_wipe_trackers_toggled_cb), pd);
+ rdf->add = glade_xml_get_widget (pd->xml, "button9");
+ g_return_val_if_fail (rdf->add != NULL, FALSE);
+
+ gtk_widget_set_sensitive (rdf->add, FALSE);
+ gtk_signal_connect (GTK_OBJECT (rdf->add), "clicked",
+ GTK_SIGNAL_FUNC (rdf_add_clicked_cb), pd);
+
+ rdf->remove = glade_xml_get_widget (pd->xml, "button10");
+ g_return_val_if_fail (rdf->remove != NULL, FALSE);
+
+ gtk_widget_set_sensitive (rdf->remove, FALSE);
+ gtk_signal_connect (GTK_OBJECT (rdf->remove), "clicked",
+ GTK_SIGNAL_FUNC (rdf_remove_clicked_cb), pd);
+
+ rdf->new_url = glade_xml_get_widget (pd->xml, "button11");
+ g_return_val_if_fail (rdf->new_url != NULL, FALSE);
+ gtk_signal_connect (GTK_OBJECT (rdf->new_url), "clicked",
+ GTK_SIGNAL_FUNC (rdf_new_url_clicked_cb), pd);
+
+ /* Weather */
+ weather = pd->weather = g_new (struct _WeatherPage, 1);
+ weather->all = glade_xml_get_widget (pd->xml, "ctree1");
+ g_return_val_if_fail (weather->all != NULL, FALSE);
+ fill_weather_all_ctree (GTK_CTREE (weather->all));
+ gtk_signal_connect (GTK_OBJECT (weather->all), "tree-select-row",
+ GTK_SIGNAL_FUNC (weather_all_select_row_cb), pd);
+ gtk_signal_connect (GTK_OBJECT (weather->all), "tree-unselect-row",
+ GTK_SIGNAL_FUNC (weather_all_unselect_row_cb), pd);
+
+ weather->shown = glade_xml_get_widget (pd->xml, "clist3");
+ g_return_val_if_fail (weather->shown != NULL, FALSE);
+ fill_weather_shown_clist (GTK_CLIST (weather->shown), pd);
+ gtk_signal_connect (GTK_OBJECT (weather->shown), "select-row",
+ GTK_SIGNAL_FUNC (weather_shown_select_row_cb), pd);
+ gtk_signal_connect (GTK_OBJECT (weather->shown), "unselect-row",
+ GTK_SIGNAL_FUNC (weather_shown_unselect_row_cb), pd);
+
+ weather->refresh = glade_xml_get_widget (pd->xml, "spinbutton5");
+ g_return_val_if_fail (weather->refresh != NULL, FALSE);
+ gtk_spin_button_set_value (GTK_SPIN_BUTTON (weather->refresh),
+ (float) pd->summary->preferences->weather_refresh_time);
+ gtk_signal_connect (GTK_OBJECT (GTK_SPIN_BUTTON (weather->refresh)->adjustment),
+ "value-changed",
+ GTK_SIGNAL_FUNC (weather_refresh_value_changed_cb),
+ pd);
+
+ weather->metric = glade_xml_get_widget (pd->xml, "radiobutton7");
+ g_return_val_if_fail (weather->metric != NULL, FALSE);
+ gtk_toggle_button_set_active (GTK_TOGGLE_BUTTON (weather->metric), (pd->summary->preferences->units == UNITS_METRIC));
+ gtk_signal_connect (GTK_OBJECT (weather->metric), "toggled",
+ GTK_SIGNAL_FUNC (weather_metric_toggled_cb), pd);
+
+ weather->imperial = glade_xml_get_widget (pd->xml, "radiobutton8");
+ g_return_val_if_fail (weather->imperial != NULL, FALSE);
+ gtk_toggle_button_set_active (GTK_TOGGLE_BUTTON (weather->imperial), (pd->summary->preferences->units == UNITS_IMPERIAL));
+ gtk_signal_connect (GTK_OBJECT (weather->imperial), "toggled",
+ GTK_SIGNAL_FUNC (weather_imperial_toggled_cb), pd);
+
+ weather->add = glade_xml_get_widget (pd->xml, "button6");
+ g_return_val_if_fail (weather->add != NULL, FALSE);
+ gtk_signal_connect (GTK_OBJECT (weather->add), "clicked",
+ GTK_SIGNAL_FUNC (weather_add_clicked_cb), pd);
+
+ weather->remove = glade_xml_get_widget (pd->xml, "button7");
+ g_return_val_if_fail (weather->remove != NULL, FALSE);
+ gtk_signal_connect (GTK_OBJECT (weather->remove), "clicked",
+ GTK_SIGNAL_FUNC (weather_remove_clicked_cb), pd);
+
+ /* Calendar */
+ calendar = pd->calendar = g_new (struct _CalendarPage, 1);
+ calendar->one = glade_xml_get_widget (pd->xml, "radiobutton3");
+ g_return_val_if_fail (calendar->one != NULL, FALSE);
+ calendar->five = glade_xml_get_widget (pd->xml, "radiobutton4");
+ g_return_val_if_fail (calendar->five != NULL, FALSE);
+ calendar->week = glade_xml_get_widget (pd->xml, "radiobutton5");
+ g_return_val_if_fail (calendar->week != NULL, FALSE);
+ calendar->month = glade_xml_get_widget (pd->xml, "radiobutton6");
+ g_return_val_if_fail (calendar->month != NULL, FALSE);
+ calendar->all = glade_xml_get_widget (pd->xml, "radiobutton1");
+ g_return_val_if_fail (calendar->all != NULL, FALSE);
+ calendar->today = glade_xml_get_widget (pd->xml, "radiobutton2");
+ g_return_val_if_fail (calendar->today != NULL, FALSE);
+
+ return TRUE;
+}
+
+static void
+free_property_dialog (PropertyData *pd)
+{
+ if (pd->rdf) {
+ g_free (pd->rdf);
+ }
+ if (pd->mail) {
+ g_free (pd->mail);
+ }
+ if (pd->weather) {
+ g_free (pd->weather);
+ }
+ if (pd->calendar) {
+ g_free (pd->calendar);
+ }
+
+ if (pd->xml) {
+ gtk_object_unref (GTK_OBJECT (pd->xml));
+ }
+ if (pd->summary) {
+ gtk_object_unref (GTK_OBJECT (pd->summary));
+ }
+
+ g_free (pd);
+}
+
+static void
+property_box_clicked_cb (GnomeDialog *dialog,
+ int page_num,
+ PropertyData *pd)
+{
+ if (page_num == -1) {
+ e_summary_reconfigure (pd->summary);
+ e_summary_preferences_free (pd->summary->old_prefs);
+ pd->summary->old_prefs = NULL;
+ }
+}
+
+static void
+property_box_destroy_cb (GtkObject *object,
+ PropertyData *pd)
+{
+ free_property_dialog (pd);
+}
+
+void
+e_summary_configure (GtkWidget *widget,
+ ESummary *summary)
+{
+ PropertyData *pd;
+
+ if (summary->prefs_window != NULL) {
+ gdk_window_raise (summary->prefs_window->window);
+ gdk_window_show (summary->prefs_window->window);
+ return;
+ }
+
+ pd = g_new0 (PropertyData, 1);
+
+ gtk_object_ref (GTK_OBJECT (summary));
+ pd->summary = summary;
+
+ if (summary->old_prefs != NULL) {
+ e_summary_preferences_free (summary->old_prefs);
+ }
+
+ summary->old_prefs = e_summary_preferences_copy (summary->preferences);
+
+ pd->xml = glade_xml_new (EVOLUTION_GLADEDIR "/my-evolution.glade", NULL);
+ g_assert (pd->xml != NULL); /* Fixme: Nice GUI to explain what happened */
+ pd->box = GNOME_PROPERTY_BOX (glade_xml_get_widget (pd->xml, "dialog1"));
+ if (make_property_dialog (pd) == FALSE) {
+ g_warning ("Missing some part of XML file");
+ free_property_dialog (pd);
+ return;
+ }
+
+ gtk_signal_connect (GTK_OBJECT (pd->box), "apply",
+ GTK_SIGNAL_FUNC (property_box_clicked_cb), pd);
+ gtk_signal_connect (GTK_OBJECT (pd->box), "destroy",
+ GTK_SIGNAL_FUNC (property_box_destroy_cb), pd);
+ gtk_widget_show (GTK_WIDGET (pd->box));
+}
+
diff --git a/my-evolution/e-summary-preferences.h b/my-evolution/e-summary-preferences.h
new file mode 100644
index 0000000000..b271e0c55c
--- /dev/null
+++ b/my-evolution/e-summary-preferences.h
@@ -0,0 +1,15 @@
+/*
+ * e-summary-preferences.h
+ *
+ * Copyright (C) 2001 Ximian, Inc
+ *
+ * Authors: Iain Holmes <iain@ximian.com>
+ */
+
+gboolean e_summary_preferences_restore (ESummaryPrefs *prefs);
+void e_summary_preferences_save (ESummaryPrefs *prefs);
+void e_summary_preferences_free (ESummaryPrefs *prefs);
+ESummaryPrefs *e_summary_preferences_copy (ESummaryPrefs *prefs);
+void e_summary_configure (GtkWidget *widget,
+ ESummary *summary);
+void e_summary_preferences_init (ESummary *summary);
diff --git a/my-evolution/e-summary-rdf.c b/my-evolution/e-summary-rdf.c
index 96ee50c11d..0980640542 100644
--- a/my-evolution/e-summary-rdf.c
+++ b/my-evolution/e-summary-rdf.c
@@ -11,7 +11,10 @@
#include <config.h>
#endif
+#include <stdlib.h>
#include <glib.h>
+#include <gtk/gtkmain.h>
+
#include <gnome-xml/parser.h>
#include <gnome-xml/xmlmemory.h>
@@ -23,6 +26,7 @@ struct _ESummaryRDF {
GList *rdfs;
char *html;
+ guint32 timeout;
};
typedef struct _RDF {
@@ -39,7 +43,6 @@ typedef struct _RDF {
} RDF;
int xmlSubstituteEntitiesDefaultValue = 1;
-static int wipe_trackers = FALSE;
char *
e_summary_rdf_get_html (ESummary *summary)
@@ -147,25 +150,35 @@ tree_walk (xmlNodePtr root,
xmlNodePtr channel = NULL;
xmlNodePtr image = NULL;
xmlNodePtr item[16];
+ gboolean wipe_trackers;
int items = 0;
- int limit = 10;
+ int limit;
int i;
char *t, *u;
char *tmp;
+ if (r->summary->preferences == NULL) {
+ limit = 10;
+ wipe_trackers = FALSE;
+ } else {
+ limit = r->summary->preferences->limit;
+ g_print ("Limit: %d\n", limit);
+ wipe_trackers = r->summary->preferences->wipe_trackers;
+ }
+
/* FIXME: Need arrows */
if (r->shown == FALSE) {
char *p;
/* FIXME: Hash table & UID */
- p = g_strdup_printf ("<font size=\"-2\"><a href=\"rdf://%d\">(+)</a></font> ", r);
+ p = g_strdup_printf ("<font size=\"-2\"><a href=\"rdf://%d\">(+)</a></font>", GPOINTER_TO_INT (r));
g_string_append (html, p);
g_free (p);
} else {
char *p;
/* FIXME: Hash table & UID */
- p = g_strdup_printf ("<font size=\"-2\"><a href=\"rdf://%d\">(-)</a></font>", r);
+ p = g_strdup_printf ("<font size=\"-2\"><a href=\"rdf://%d\">(-)</a></font>", GPOINTER_TO_INT (r));
g_string_append (html, p);
g_free (p);
}
@@ -387,6 +400,22 @@ open_callback (GnomeVFSAsyncHandle *handle,
(GnomeVFSAsyncReadCallback) read_callback, r);
}
+static gboolean
+e_summary_rdf_update (ESummary *summary)
+{
+ GList *r;
+
+ for (r = summary->rdf->rdfs; r; r = r->next) {
+ RDF *rdf = r->data;
+
+ gnome_vfs_async_open (&rdf->handle, rdf->uri,
+ GNOME_VFS_OPEN_READ,
+ (GnomeVFSAsyncOpenCallback) open_callback, rdf);
+ }
+
+ return TRUE;
+}
+
static void
e_summary_rdf_add_uri (ESummary *summary,
const char *uri)
@@ -398,9 +427,6 @@ e_summary_rdf_add_uri (ESummary *summary,
r->uri = g_strdup (uri);
r->shown = TRUE;
summary->rdf->rdfs = g_list_prepend (summary->rdf->rdfs, r);
-
- gnome_vfs_async_open (&r->handle, r->uri, GNOME_VFS_OPEN_READ,
- (GnomeVFSAsyncOpenCallback) open_callback, r);
}
static void
@@ -426,15 +452,67 @@ e_summary_rdf_protocol (ESummary *summary,
void
e_summary_rdf_init (ESummary *summary)
{
+ ESummaryPrefs *prefs;
ESummaryRDF *rdf;
+ int timeout;
g_return_if_fail (summary != NULL);
g_return_if_fail (IS_E_SUMMARY (summary));
+ prefs = summary->preferences;
rdf = g_new0 (ESummaryRDF, 1);
summary->rdf = rdf;
e_summary_add_protocol_listener (summary, "rdf", e_summary_rdf_protocol, rdf);
- e_summary_rdf_add_uri (summary, "http://news.gnome.org/gnome-news/rdf");
+ if (prefs == NULL) {
+ e_summary_rdf_add_uri (summary, "http://news.gnome.org/gnome-news/rdf");
+ timeout = 600;
+ } else {
+ GList *p;
+
+ for (p = prefs->rdf_urls; p; p = p->next) {
+ e_summary_rdf_add_uri (summary, p->data);
+ }
+ timeout = prefs->rdf_refresh_time;
+ }
+
+ e_summary_rdf_update (summary);
+ rdf->timeout = gtk_timeout_add (timeout * 1000,
+ (GtkFunction) e_summary_rdf_update, summary);
+
return;
}
+
+void
+e_summary_rdf_reconfigure (ESummary *summary)
+{
+ ESummaryRDF *rdf;
+ GList *old, *p;
+
+ g_return_if_fail (summary != NULL);
+ g_return_if_fail (IS_E_SUMMARY (summary));
+
+ rdf = summary->rdf;
+
+ /* Stop timeout */
+ gtk_timeout_remove (rdf->timeout);
+
+ for (old = rdf->rdfs; old; old = old->next) {
+ RDF *r;
+
+ r = old->data;
+ g_free (r->uri);
+ g_free (r->html);
+ xmlFree (r->cache);
+ g_free (r);
+ }
+ g_list_free (rdf->rdfs);
+ rdf->rdfs = NULL;
+
+ for (p = summary->preferences->rdf_urls; p; p = p->next) {
+ e_summary_rdf_add_uri (summary, p->data);
+ }
+
+ rdf->timeout = gtk_timeout_add (summary->preferences->rdf_refresh_time * 1000, (GtkFunction) e_summary_rdf_update, summary);
+ e_summary_rdf_update (summary);
+}
diff --git a/my-evolution/e-summary-rdf.h b/my-evolution/e-summary-rdf.h
index cc0fec9e3d..329bdd8bb6 100644
--- a/my-evolution/e-summary-rdf.h
+++ b/my-evolution/e-summary-rdf.h
@@ -15,4 +15,6 @@ typedef struct _ESummaryRDF ESummaryRDF;
char *e_summary_rdf_get_html (ESummary *summary);
void e_summary_rdf_init (ESummary *summary);
+void e_summary_rdf_reconfigure (ESummary *summary);
+
#endif
diff --git a/my-evolution/e-summary-weather.c b/my-evolution/e-summary-weather.c
index 4019dcd263..ebe6158e95 100644
--- a/my-evolution/e-summary-weather.c
+++ b/my-evolution/e-summary-weather.c
@@ -11,6 +11,9 @@
#endif
#include <glib.h>
+#include <gtk/gtkctree.h>
+#include <gtk/gtkmain.h>
+
#include <libgnome/gnome-defs.h>
#include <libgnome/gnome-i18n.h>
#include <libgnome/gnome-config.h>
@@ -27,6 +30,7 @@ struct _ESummaryWeather {
GList *weathers;
char *html;
+ guint32 timeout;
};
static GHashTable *locations_hash = NULL;
@@ -284,21 +288,32 @@ open_callback (GnomeVFSAsyncHandle *handle,
}
static void
+e_summary_weather_update (ESummary *summary)
+{
+ GList *w;
+
+ for (w = summary->weather->weathers; w; w = w->next) {
+ char *uri;
+ Weather *weather = w->data;
+
+ uri = g_strdup_printf ("http://weather.noaa.gov/cgi-bin/mgetmetar.pl?cccc=%s", weather->location);
+
+ gnome_vfs_async_open (&weather->handle, uri, GNOME_VFS_OPEN_READ,
+ (GnomeVFSAsyncOpenCallback) open_callback, weather);
+ g_free (uri);
+ }
+}
+
+static void
e_summary_weather_add_location (ESummary *summary,
const char *location)
{
Weather *w;
- char *uri;
w = g_new0 (Weather, 1);
w->summary = summary;
w->location = g_strdup (location);
summary->weather->weathers = g_list_prepend (summary->weather->weathers, w);
-
- uri = g_strdup_printf ("http://weather.noaa.gov/cgi-bin/mgetmetar.pl?cccc=%s", location);
- gnome_vfs_async_open (&w->handle, uri, GNOME_VFS_OPEN_READ,
- (GnomeVFSAsyncOpenCallback) open_callback, w);
- g_free (uri);
}
static gboolean
@@ -332,7 +347,7 @@ e_summary_weather_init_locations (void)
region_name_key = g_strconcat (regions[iregions], "/name", NULL);
states_key = g_strconcat (regions[iregions], "/states", NULL);
region_name = gnome_config_get_string (region_name_key);
-
+
gnome_config_get_vector (states_key, &nstates, &states);
for (istates = nstates - 1; istates >= 0; istates--) {
@@ -361,14 +376,14 @@ e_summary_weather_init_locations (void)
g_hash_table_insert (locations_hash,
g_strdup (locdata[1]),
location);
-
+
g_strfreev (locdata);
}
-
+
g_free (iter_key);
g_free (iter_val);
}
-
+
g_free (state_name);
g_free (state_path);
g_free (state_name_key);
@@ -397,7 +412,9 @@ e_summary_weather_protocol (ESummary *summary,
void
e_summary_weather_init (ESummary *summary)
{
+ ESummaryPrefs *prefs;
ESummaryWeather *weather;
+ int timeout;
g_return_if_fail (summary != NULL);
g_return_if_fail (IS_E_SUMMARY (summary));
@@ -406,13 +423,185 @@ e_summary_weather_init (ESummary *summary)
return;
}
+ prefs = summary->preferences;
weather = g_new0 (ESummaryWeather, 1);
summary->weather = weather;
e_summary_add_protocol_listener (summary, "weather", e_summary_weather_protocol, weather);
- e_summary_weather_add_location (summary, "ENBR");
- e_summary_weather_add_location (summary, "EGAC");
- e_summary_weather_add_location (summary, "EGAA");
+ if (prefs == NULL) {
+ e_summary_weather_add_location (summary, "ENBR");
+ e_summary_weather_add_location (summary, "EGAC");
+ e_summary_weather_add_location (summary, "EGAA");
+ timeout = 600;
+ } else {
+ GList *p;
+
+ for (p = prefs->stations; p; p = p->next) {
+ e_summary_weather_add_location (summary, p->data);
+ }
+ timeout = prefs->weather_refresh_time;
+ }
+
+ e_summary_weather_update (summary);
+
+ weather->timeout = gtk_timeout_add (timeout * 1000,
+ (GtkFunction) e_summary_weather_update,
+ summary);
return;
}
+
+const char *
+e_summary_weather_code_to_name (const char *code)
+{
+ ESummaryWeatherLocation *location;
+
+ if (locations_hash == NULL) {
+ if (e_summary_weather_init_locations () == FALSE) {
+ return code;
+ }
+ }
+
+ location = g_hash_table_lookup (locations_hash, code);
+ if (location == NULL) {
+ return code;
+ } else {
+ return location->name;
+ }
+}
+
+void
+e_summary_weather_ctree_fill (GtkCTree *tree)
+{
+ GtkCTreeNode *region, *state, *location, *pref_loc_root;
+ char *key, *path;
+ int nregions, iregions;
+ char **regions, *pp[1];
+
+ path = g_strdup (EVOLUTION_DATADIR "/evolution/Locations");
+
+ key = g_strdup_printf ("=%s=/", path);
+ g_free (path);
+
+ gnome_config_push_prefix (key);
+ g_free (key);
+
+ pp[0] = _("Regions");
+ pref_loc_root = gtk_ctree_insert_node (tree, NULL, NULL, pp, 0,
+ NULL, NULL, NULL, NULL,
+ FALSE, TRUE);
+
+ gnome_config_get_vector ("Main/regions", &nregions, &regions);
+ region = NULL;
+ for (iregions = nregions - 1; iregions >= 0; iregions--) {
+ int nstates, istates;
+ char **states;
+ char *region_name;
+ char *region_name_key;
+ char *states_key;
+
+ region_name_key = g_strconcat (regions[iregions], "/name", NULL);
+ states_key = g_strconcat (regions[iregions], "/states", NULL);
+ region_name = gnome_config_get_string (region_name_key);
+
+ pp[0] = region_name;
+ region = gtk_ctree_insert_node (tree, pref_loc_root,
+ region, pp, 0, NULL,
+ NULL, NULL, NULL,
+ FALSE, FALSE);
+
+ gnome_config_get_vector (states_key, &nstates, &states);
+
+ state = NULL;
+ for (istates = nstates - 1; istates >= 0; istates--) {
+ void *iter;
+ char *iter_key, *iter_val;
+ char *state_path, *state_name_key, *state_name;
+
+ state_path = g_strconcat (regions[iregions], "_", states[istates], "/", NULL);
+ state_name_key = g_strconcat (state_path, "name", NULL);
+ state_name = gnome_config_get_string (state_name_key);
+
+ pp[0] = state_name;
+ state = gtk_ctree_insert_node (tree, region,
+ state, pp, 0,
+ NULL, NULL,
+ NULL, NULL,
+ FALSE, FALSE);
+
+ location = NULL;
+ iter = gnome_config_init_iterator (state_path);
+
+ while ((iter = gnome_config_iterator_next (iter, &iter_key, &iter_val)) != NULL) {
+ if (strstr (iter_key, "loc") != NULL) {
+ char **locdata;
+ int nlocdata;
+ ESummaryWeatherLocation *w_location;
+
+ gnome_config_make_vector (iter_val,
+ &nlocdata,
+ &locdata);
+ g_return_if_fail (nlocdata == 4);
+
+ pp[0] = locdata[0];
+ location = gtk_ctree_insert_node (tree, state, location, pp, 0,
+ NULL, NULL, NULL, NULL, FALSE, TRUE);
+ w_location = g_hash_table_lookup (locations_hash, locdata[1]);
+ gtk_ctree_node_set_row_data (tree, location, w_location);
+ g_strfreev (locdata);
+ }
+
+ g_free (iter_key);
+ g_free (iter_val);
+ }
+
+ g_free (state_name);
+ g_free (state_path);
+ g_free (state_name_key);
+ }
+
+ g_strfreev (states);
+ g_free (region_name);
+ g_free (region_name_key);
+ g_free (states_key);
+ }
+
+ g_strfreev (regions);
+ gnome_config_pop_prefix ();
+
+ return;
+}
+
+void
+e_summary_weather_reconfigure (ESummary *summary)
+{
+ ESummaryWeather *weather;
+ GList *old, *p;
+
+ g_return_if_fail (summary != NULL);
+ g_return_if_fail (IS_E_SUMMARY (summary));
+
+ weather = summary->weather;
+
+ /* Stop timeout so it doesn't occur while we're changing stuff*/
+ gtk_timeout_remove (weather->timeout);
+
+ for (old = weather->weathers; old; old = old->next) {
+ Weather *w;
+
+ w = old->data;
+ g_free (w->location);
+ g_free (w->html);
+ g_free (w->metar);
+ g_free (w);
+ }
+ g_list_free (weather->weathers);
+ weather->weathers = NULL;
+ for (p = summary->preferences->stations; p; p = p->next) {
+ e_summary_weather_add_location (summary, p->data);
+ }
+
+ weather->timeout = gtk_timeout_add (summary->preferences->weather_refresh_time * 1000,
+ (GtkFunction) e_summary_weather_update, summary);
+ e_summary_weather_update (summary);
+}
diff --git a/my-evolution/e-summary-weather.h b/my-evolution/e-summary-weather.h
index d771a05aa8..290efc6aa8 100644
--- a/my-evolution/e-summary-weather.h
+++ b/my-evolution/e-summary-weather.h
@@ -7,6 +7,7 @@
#define __E_SUMMARY_WEATHER_H__
#include <time.h>
+#include <gtk/gtkctree.h>
#include "e-summary-type.h"
typedef struct _ESummaryWeather ESummaryWeather;
@@ -125,4 +126,8 @@ typedef time_t ESummaryWeatherUpdate;
char *e_summary_weather_get_html (ESummary *summary);
void e_summary_weather_init (ESummary *summary);
+void e_summary_weather_reconfigure (ESummary *summary);
+void e_summary_weather_ctree_fill (GtkCTree *tree);
+const char *e_summary_weather_code_to_name (const char *code);
+
#endif
diff --git a/my-evolution/e-summary.c b/my-evolution/e-summary.c
index 920f2ad334..5a0dcbd0b9 100644
--- a/my-evolution/e-summary.c
+++ b/my-evolution/e-summary.c
@@ -33,6 +33,7 @@
#include <libgnomeprint/gnome-print-master-preview.h>
#include "e-summary.h"
+#include "e-summary-preferences.h"
#include "my-evolution-html.h"
#include "Mail.h"
@@ -358,6 +359,9 @@ e_summary_init (ESummary *summary)
TRUE, TRUE, 0);
priv->protocol_hash = NULL;
+
+ summary->prefs_window = NULL;
+ e_summary_preferences_init (summary);
}
E_MAKE_TYPE (e_summary, "ESummary", ESummary, e_summary_class_init,
@@ -547,3 +551,23 @@ e_summary_unset_message (ESummary *summary)
GNOME_Evolution_ShellView_unsetMessage (svi, &ev);
CORBA_exception_free (&ev);
}
+
+void
+e_summary_reconfigure (ESummary *summary)
+{
+ if (summary->mail != NULL) {
+ e_summary_mail_reconfigure (summary);
+ }
+
+ if (summary->rdf != NULL) {
+ e_summary_rdf_reconfigure (summary);
+ }
+
+ if (summary->weather != NULL) {
+ e_summary_weather_reconfigure (summary);
+ }
+
+ if (summary->calendar != NULL) {
+ e_summary_calendar_reconfigure (summary);
+ }
+}
diff --git a/my-evolution/e-summary.h b/my-evolution/e-summary.h
index 43c1440c0f..45d1905678 100644
--- a/my-evolution/e-summary.h
+++ b/my-evolution/e-summary.h
@@ -26,14 +26,40 @@
typedef struct _ESummaryPrivate ESummaryPrivate;
typedef struct _ESummaryClass ESummaryClass;
+typedef struct _ESummaryPrefs ESummaryPrefs;
typedef void (* ESummaryProtocolListener) (ESummary *summary,
const char *uri,
void *closure);
+struct _ESummaryPrefs {
+
+ /* Mail */
+ GList *display_folders;
+ gboolean show_full_path;
+
+ /* RDF */
+ GList *rdf_urls;
+ int rdf_refresh_time;
+ int limit;
+ gboolean wipe_trackers;
+
+ /* Weather */
+ GList *stations;
+ ESummaryWeatherUnits units;
+ int weather_refresh_time;
+
+ /* Schedule */
+ ESummaryCalendarDays days;
+ ESummaryCalendarNumTasks show_tasks;
+};
+
struct _ESummary {
GtkVBox parent;
+ ESummaryPrefs *preferences;
+ ESummaryPrefs *old_prefs;
+
ESummaryMail *mail;
ESummaryCalendar *calendar;
ESummaryRDF *rdf;
@@ -42,6 +68,8 @@ struct _ESummary {
ESummaryPrivate *priv;
GNOME_Evolution_ShellView shell_view_interface;
+
+ GtkWidget *prefs_window;
};
struct _ESummaryClass {
@@ -63,5 +91,5 @@ void e_summary_add_protocol_listener (ESummary *summary,
const char *protocol,
ESummaryProtocolListener listener,
void *closure);
-
+void e_summary_reconfigure (ESummary *summary);
#endif
diff --git a/my-evolution/main.c b/my-evolution/main.c
index d8c6160486..f13e76434c 100644
--- a/my-evolution/main.c
+++ b/my-evolution/main.c
@@ -30,6 +30,7 @@
#endif
#include <libgnomevfs/gnome-vfs.h>
+#include <glade/glade.h>
#include "component-factory.h"
@@ -56,6 +57,7 @@ main (int argc,
gconf_init (argc, argv, NULL);
#endif
+ glade_gnome_init ();
gnome_vfs_init ();
/* Start our component */
diff --git a/my-evolution/metar.c b/my-evolution/metar.c
index 353593da79..ee99816e00 100644
--- a/my-evolution/metar.c
+++ b/my-evolution/metar.c
@@ -142,8 +142,15 @@ char *
weather_temp_string (Weather *w)
{
char *temp;
+ ESummaryWeatherUnits units;
- temp = g_strdup_printf ("%.1f%s", w->temp, TEMP_UNIT_STR (w->units));
+ if (w->summary->preferences == NULL) {
+ units = UNITS_METRIC;
+ } else {
+ units = w->summary->preferences->units;
+ }
+
+ temp = g_strdup_printf ("%.1f%s", w->temp, TEMP_UNIT_STR (units));
return temp;
}
@@ -437,12 +444,15 @@ metar_tok_pres (gchar *tokp,
static inline gint
calc_humidity(gdouble temp,
- gdouble dewp)
+ gdouble dewp,
+ ESummaryWeatherUnits units)
{
gdouble esat, esurf;
- temp = TEMP_F_TO_C(temp);
- dewp = TEMP_F_TO_C(dewp);
+ if (units == UNITS_IMPERIAL) {
+ temp = TEMP_F_TO_C(temp);
+ dewp = TEMP_F_TO_C(dewp);
+ }
esat = 6.11 * pow(10.0, (7.5 * temp) / (237.7 + temp));
esurf = 6.11 * pow(10.0, (7.5 * dewp) / (237.7 + dewp));
@@ -454,22 +464,35 @@ gboolean
metar_tok_temp (gchar *tokp,
Weather *w)
{
- gchar *ptemp, *pdew, *psep;
-
- if (regexec(&metar_re[TEMP_RE], tokp, 0, NULL, 0) == REG_NOMATCH)
- return FALSE;
-
- psep = strchr(tokp, '/');
- *psep = 0;
- ptemp = tokp;
- pdew = psep + 1;
-
- w->temp = (*ptemp == 'M') ? TEMP_C_TO_F(-atoi(ptemp+1)) :
- TEMP_C_TO_F(atoi(ptemp));
- w->dew = (*pdew == 'M') ? TEMP_C_TO_F(-atoi(pdew+1)) :
- TEMP_C_TO_F(atoi(pdew));
- w->humidity = calc_humidity(w->temp, w->dew);
- return TRUE;
+ ESummaryWeatherUnits units;
+ gchar *ptemp, *pdew, *psep;
+
+ if (regexec(&metar_re[TEMP_RE], tokp, 0, NULL, 0) == REG_NOMATCH)
+ return FALSE;
+
+ if (w->summary->preferences == NULL) {
+ units = UNITS_METRIC;
+ } else {
+ units = w->summary->preferences->units;
+ }
+
+ psep = strchr(tokp, '/');
+ *psep = 0;
+ ptemp = tokp;
+ pdew = psep + 1;
+
+ if (units == UNITS_IMPERIAL) {
+ w->temp = (*ptemp == 'M') ? TEMP_C_TO_F(-atoi(ptemp+1)) :
+ TEMP_C_TO_F(atoi(ptemp));
+ w->dew = (*pdew == 'M') ? TEMP_C_TO_F(-atoi(pdew+1)) :
+ TEMP_C_TO_F(atoi(pdew));
+ } else {
+ w->temp = (*ptemp == 'M') ? -atoi(ptemp+1) : atoi(ptemp);
+ w->dew = (*pdew == 'M') ? -atoi(pdew+1) : atoi (pdew);
+ }
+
+ w->humidity = calc_humidity(w->temp, w->dew, units);
+ return TRUE;
}
gboolean
diff --git a/my-evolution/metar.h b/my-evolution/metar.h
index ae9b1644d6..cbbb8f9550 100644
--- a/my-evolution/metar.h
+++ b/my-evolution/metar.h
@@ -27,6 +27,7 @@ enum {
const char *weather_sky_string (Weather *w);
char *weather_temp_string (Weather *w);
const char *weather_conditions_string (Weather *w);
+const char *weather_wind_direction_string (Weather *w);
void metar_init_re (void);
gboolean metar_tok_time (char *token,
diff --git a/my-evolution/my-evolution.glade b/my-evolution/my-evolution.glade
new file mode 100644
index 0000000000..5093984ca7
--- /dev/null
+++ b/my-evolution/my-evolution.glade
@@ -0,0 +1,1590 @@
+<?xml version="1.0"?>
+<GTK-Interface>
+
+<project>
+ <name>Project1</name>
+ <program_name>project1</program_name>
+ <directory></directory>
+ <source_directory>src</source_directory>
+ <pixmaps_directory>pixmaps</pixmaps_directory>
+ <language>C</language>
+ <gnome_support>True</gnome_support>
+ <gettext_support>True</gettext_support>
+</project>
+
+<widget>
+ <class>GnomePropertyBox</class>
+ <name>dialog1</name>
+ <width>592</width>
+ <position>GTK_WIN_POS_NONE</position>
+ <modal>False</modal>
+ <allow_shrink>False</allow_shrink>
+ <allow_grow>False</allow_grow>
+ <auto_shrink>False</auto_shrink>
+
+ <widget>
+ <class>GtkNotebook</class>
+ <child_name>GnomePropertyBox:notebook</child_name>
+ <name>notebook2</name>
+ <can_focus>True</can_focus>
+ <show_tabs>True</show_tabs>
+ <show_border>True</show_border>
+ <tab_pos>GTK_POS_TOP</tab_pos>
+ <scrollable>False</scrollable>
+ <tab_hborder>2</tab_hborder>
+ <tab_vborder>2</tab_vborder>
+ <popup_enable>False</popup_enable>
+ <child>
+ <padding>0</padding>
+ <expand>True</expand>
+ <fill>True</fill>
+ </child>
+
+ <widget>
+ <class>GtkVBox</class>
+ <name>vbox3</name>
+ <homogeneous>False</homogeneous>
+ <spacing>0</spacing>
+
+ <widget>
+ <class>GtkTable</class>
+ <name>table1</name>
+ <border_width>8</border_width>
+ <rows>2</rows>
+ <columns>3</columns>
+ <homogeneous>False</homogeneous>
+ <row_spacing>0</row_spacing>
+ <column_spacing>0</column_spacing>
+ <child>
+ <padding>0</padding>
+ <expand>True</expand>
+ <fill>True</fill>
+ </child>
+
+ <widget>
+ <class>GtkLabel</class>
+ <name>label9</name>
+ <label>All folders:</label>
+ <justify>GTK_JUSTIFY_CENTER</justify>
+ <wrap>False</wrap>
+ <xalign>0.5</xalign>
+ <yalign>0.5</yalign>
+ <xpad>0</xpad>
+ <ypad>0</ypad>
+ <child>
+ <left_attach>0</left_attach>
+ <right_attach>1</right_attach>
+ <top_attach>0</top_attach>
+ <bottom_attach>1</bottom_attach>
+ <xpad>0</xpad>
+ <ypad>0</ypad>
+ <xexpand>False</xexpand>
+ <yexpand>False</yexpand>
+ <xshrink>False</xshrink>
+ <yshrink>False</yshrink>
+ <xfill>False</xfill>
+ <yfill>False</yfill>
+ </child>
+ </widget>
+
+ <widget>
+ <class>GtkLabel</class>
+ <name>label10</name>
+ <label>Display folders:</label>
+ <justify>GTK_JUSTIFY_CENTER</justify>
+ <wrap>False</wrap>
+ <xalign>0.5</xalign>
+ <yalign>0.5</yalign>
+ <xpad>0</xpad>
+ <ypad>0</ypad>
+ <child>
+ <left_attach>2</left_attach>
+ <right_attach>3</right_attach>
+ <top_attach>0</top_attach>
+ <bottom_attach>1</bottom_attach>
+ <xpad>0</xpad>
+ <ypad>0</ypad>
+ <xexpand>False</xexpand>
+ <yexpand>False</yexpand>
+ <xshrink>False</xshrink>
+ <yshrink>False</yshrink>
+ <xfill>False</xfill>
+ <yfill>False</yfill>
+ </child>
+ </widget>
+
+ <widget>
+ <class>GtkAlignment</class>
+ <name>alignment1</name>
+ <border_width>8</border_width>
+ <xalign>0.5</xalign>
+ <yalign>0.5</yalign>
+ <xscale>1</xscale>
+ <yscale>0</yscale>
+ <child>
+ <left_attach>1</left_attach>
+ <right_attach>2</right_attach>
+ <top_attach>1</top_attach>
+ <bottom_attach>2</bottom_attach>
+ <xpad>0</xpad>
+ <ypad>0</ypad>
+ <xexpand>False</xexpand>
+ <yexpand>False</yexpand>
+ <xshrink>False</xshrink>
+ <yshrink>False</yshrink>
+ <xfill>False</xfill>
+ <yfill>False</yfill>
+ </child>
+
+ <widget>
+ <class>GtkVBox</class>
+ <name>vbox4</name>
+ <homogeneous>False</homogeneous>
+ <spacing>8</spacing>
+
+ <widget>
+ <class>GtkButton</class>
+ <name>button4</name>
+ <sensitive>False</sensitive>
+ <can_focus>True</can_focus>
+ <label>Add -&gt;</label>
+ <relief>GTK_RELIEF_NORMAL</relief>
+ <child>
+ <padding>0</padding>
+ <expand>False</expand>
+ <fill>False</fill>
+ </child>
+ </widget>
+
+ <widget>
+ <class>GtkButton</class>
+ <name>button5</name>
+ <sensitive>False</sensitive>
+ <can_focus>True</can_focus>
+ <label>Remove &lt;-</label>
+ <relief>GTK_RELIEF_NORMAL</relief>
+ <child>
+ <padding>0</padding>
+ <expand>False</expand>
+ <fill>False</fill>
+ </child>
+ </widget>
+ </widget>
+ </widget>
+
+ <widget>
+ <class>GtkLabel</class>
+ <name>label11</name>
+ <label></label>
+ <justify>GTK_JUSTIFY_CENTER</justify>
+ <wrap>False</wrap>
+ <xalign>0.5</xalign>
+ <yalign>0.5</yalign>
+ <xpad>0</xpad>
+ <ypad>0</ypad>
+ <child>
+ <left_attach>1</left_attach>
+ <right_attach>2</right_attach>
+ <top_attach>0</top_attach>
+ <bottom_attach>1</bottom_attach>
+ <xpad>0</xpad>
+ <ypad>0</ypad>
+ <xexpand>False</xexpand>
+ <yexpand>False</yexpand>
+ <xshrink>False</xshrink>
+ <yshrink>False</yshrink>
+ <xfill>False</xfill>
+ <yfill>False</yfill>
+ </child>
+ </widget>
+
+ <widget>
+ <class>GtkScrolledWindow</class>
+ <name>scrolledwindow1</name>
+ <hscrollbar_policy>GTK_POLICY_AUTOMATIC</hscrollbar_policy>
+ <vscrollbar_policy>GTK_POLICY_AUTOMATIC</vscrollbar_policy>
+ <hupdate_policy>GTK_UPDATE_CONTINUOUS</hupdate_policy>
+ <vupdate_policy>GTK_UPDATE_CONTINUOUS</vupdate_policy>
+ <child>
+ <left_attach>2</left_attach>
+ <right_attach>3</right_attach>
+ <top_attach>1</top_attach>
+ <bottom_attach>2</bottom_attach>
+ <xpad>0</xpad>
+ <ypad>0</ypad>
+ <xexpand>True</xexpand>
+ <yexpand>True</yexpand>
+ <xshrink>False</xshrink>
+ <yshrink>False</yshrink>
+ <xfill>True</xfill>
+ <yfill>True</yfill>
+ </child>
+
+ <widget>
+ <class>GtkCList</class>
+ <name>clist1</name>
+ <width>100</width>
+ <height>150</height>
+ <can_focus>True</can_focus>
+ <columns>1</columns>
+ <column_widths>80</column_widths>
+ <selection_mode>GTK_SELECTION_EXTENDED</selection_mode>
+ <show_titles>False</show_titles>
+ <shadow_type>GTK_SHADOW_IN</shadow_type>
+
+ <widget>
+ <class>GtkLabel</class>
+ <child_name>CList:title</child_name>
+ <name>label12</name>
+ <label>label27</label>
+ <justify>GTK_JUSTIFY_CENTER</justify>
+ <wrap>False</wrap>
+ <xalign>0.5</xalign>
+ <yalign>0.5</yalign>
+ <xpad>0</xpad>
+ <ypad>0</ypad>
+ </widget>
+ </widget>
+ </widget>
+
+ <widget>
+ <class>GtkScrolledWindow</class>
+ <name>scrolledwindow2</name>
+ <width>100</width>
+ <height>150</height>
+ <hscrollbar_policy>GTK_POLICY_AUTOMATIC</hscrollbar_policy>
+ <vscrollbar_policy>GTK_POLICY_AUTOMATIC</vscrollbar_policy>
+ <hupdate_policy>GTK_UPDATE_CONTINUOUS</hupdate_policy>
+ <vupdate_policy>GTK_UPDATE_CONTINUOUS</vupdate_policy>
+ <child>
+ <left_attach>0</left_attach>
+ <right_attach>1</right_attach>
+ <top_attach>1</top_attach>
+ <bottom_attach>2</bottom_attach>
+ <xpad>0</xpad>
+ <ypad>0</ypad>
+ <xexpand>True</xexpand>
+ <yexpand>True</yexpand>
+ <xshrink>False</xshrink>
+ <yshrink>False</yshrink>
+ <xfill>True</xfill>
+ <yfill>True</yfill>
+ </child>
+
+ <widget>
+ <class>GtkCList</class>
+ <name>clist2</name>
+ <can_focus>True</can_focus>
+ <columns>1</columns>
+ <column_widths>80</column_widths>
+ <selection_mode>GTK_SELECTION_EXTENDED</selection_mode>
+ <show_titles>False</show_titles>
+ <shadow_type>GTK_SHADOW_IN</shadow_type>
+
+ <widget>
+ <class>GtkLabel</class>
+ <child_name>CList:title</child_name>
+ <name>label13</name>
+ <label>label26</label>
+ <justify>GTK_JUSTIFY_CENTER</justify>
+ <wrap>False</wrap>
+ <xalign>0.5</xalign>
+ <yalign>0.5</yalign>
+ <xpad>0</xpad>
+ <ypad>0</ypad>
+ </widget>
+ </widget>
+ </widget>
+ </widget>
+
+ <widget>
+ <class>GtkCheckButton</class>
+ <name>checkbutton1</name>
+ <border_width>3</border_width>
+ <can_focus>True</can_focus>
+ <label>Show full path for folders</label>
+ <active>False</active>
+ <draw_indicator>True</draw_indicator>
+ <child>
+ <padding>0</padding>
+ <expand>False</expand>
+ <fill>False</fill>
+ </child>
+ </widget>
+ </widget>
+
+ <widget>
+ <class>GtkLabel</class>
+ <child_name>Notebook:tab</child_name>
+ <name>label5</name>
+ <label>Mail</label>
+ <justify>GTK_JUSTIFY_CENTER</justify>
+ <wrap>False</wrap>
+ <xalign>0.5</xalign>
+ <yalign>0.5</yalign>
+ <xpad>0</xpad>
+ <ypad>0</ypad>
+ </widget>
+
+ <widget>
+ <class>GtkVBox</class>
+ <name>vbox6</name>
+ <homogeneous>False</homogeneous>
+ <spacing>0</spacing>
+
+ <widget>
+ <class>GtkTable</class>
+ <name>table3</name>
+ <border_width>8</border_width>
+ <rows>2</rows>
+ <columns>3</columns>
+ <homogeneous>False</homogeneous>
+ <row_spacing>0</row_spacing>
+ <column_spacing>0</column_spacing>
+ <child>
+ <padding>0</padding>
+ <expand>True</expand>
+ <fill>True</fill>
+ </child>
+
+ <widget>
+ <class>GtkLabel</class>
+ <name>label19</name>
+ <label>All RDFs:</label>
+ <justify>GTK_JUSTIFY_CENTER</justify>
+ <wrap>False</wrap>
+ <xalign>0.5</xalign>
+ <yalign>0.5</yalign>
+ <xpad>0</xpad>
+ <ypad>0</ypad>
+ <child>
+ <left_attach>0</left_attach>
+ <right_attach>1</right_attach>
+ <top_attach>0</top_attach>
+ <bottom_attach>1</bottom_attach>
+ <xpad>0</xpad>
+ <ypad>0</ypad>
+ <xexpand>False</xexpand>
+ <yexpand>False</yexpand>
+ <xshrink>False</xshrink>
+ <yshrink>False</yshrink>
+ <xfill>False</xfill>
+ <yfill>False</yfill>
+ </child>
+ </widget>
+
+ <widget>
+ <class>GtkLabel</class>
+ <name>label20</name>
+ <label>Display RDFs:</label>
+ <justify>GTK_JUSTIFY_CENTER</justify>
+ <wrap>False</wrap>
+ <xalign>0.5</xalign>
+ <yalign>0.5</yalign>
+ <xpad>0</xpad>
+ <ypad>0</ypad>
+ <child>
+ <left_attach>2</left_attach>
+ <right_attach>3</right_attach>
+ <top_attach>0</top_attach>
+ <bottom_attach>1</bottom_attach>
+ <xpad>0</xpad>
+ <ypad>0</ypad>
+ <xexpand>False</xexpand>
+ <yexpand>False</yexpand>
+ <xshrink>False</xshrink>
+ <yshrink>False</yshrink>
+ <xfill>False</xfill>
+ <yfill>False</yfill>
+ </child>
+ </widget>
+
+ <widget>
+ <class>GtkAlignment</class>
+ <name>alignment3</name>
+ <border_width>8</border_width>
+ <xalign>0.5</xalign>
+ <yalign>0.5</yalign>
+ <xscale>1</xscale>
+ <yscale>0</yscale>
+ <child>
+ <left_attach>1</left_attach>
+ <right_attach>2</right_attach>
+ <top_attach>1</top_attach>
+ <bottom_attach>2</bottom_attach>
+ <xpad>0</xpad>
+ <ypad>0</ypad>
+ <xexpand>False</xexpand>
+ <yexpand>False</yexpand>
+ <xshrink>False</xshrink>
+ <yshrink>False</yshrink>
+ <xfill>False</xfill>
+ <yfill>False</yfill>
+ </child>
+
+ <widget>
+ <class>GtkVBox</class>
+ <name>vbox7</name>
+ <homogeneous>False</homogeneous>
+ <spacing>8</spacing>
+
+ <widget>
+ <class>GtkButton</class>
+ <name>button9</name>
+ <sensitive>False</sensitive>
+ <can_focus>True</can_focus>
+ <label>Add -&gt;</label>
+ <relief>GTK_RELIEF_NORMAL</relief>
+ <child>
+ <padding>0</padding>
+ <expand>False</expand>
+ <fill>False</fill>
+ </child>
+ </widget>
+
+ <widget>
+ <class>GtkButton</class>
+ <name>button10</name>
+ <sensitive>False</sensitive>
+ <can_focus>True</can_focus>
+ <label>Remove &lt;-</label>
+ <relief>GTK_RELIEF_NORMAL</relief>
+ <child>
+ <padding>0</padding>
+ <expand>False</expand>
+ <fill>False</fill>
+ </child>
+ </widget>
+ </widget>
+ </widget>
+
+ <widget>
+ <class>GtkLabel</class>
+ <name>label21</name>
+ <label></label>
+ <justify>GTK_JUSTIFY_CENTER</justify>
+ <wrap>False</wrap>
+ <xalign>0.5</xalign>
+ <yalign>0.5</yalign>
+ <xpad>0</xpad>
+ <ypad>0</ypad>
+ <child>
+ <left_attach>1</left_attach>
+ <right_attach>2</right_attach>
+ <top_attach>0</top_attach>
+ <bottom_attach>1</bottom_attach>
+ <xpad>0</xpad>
+ <ypad>0</ypad>
+ <xexpand>False</xexpand>
+ <yexpand>False</yexpand>
+ <xshrink>False</xshrink>
+ <yshrink>False</yshrink>
+ <xfill>False</xfill>
+ <yfill>False</yfill>
+ </child>
+ </widget>
+
+ <widget>
+ <class>GtkScrolledWindow</class>
+ <name>scrolledwindow5</name>
+ <hscrollbar_policy>GTK_POLICY_AUTOMATIC</hscrollbar_policy>
+ <vscrollbar_policy>GTK_POLICY_AUTOMATIC</vscrollbar_policy>
+ <hupdate_policy>GTK_UPDATE_CONTINUOUS</hupdate_policy>
+ <vupdate_policy>GTK_UPDATE_CONTINUOUS</vupdate_policy>
+ <child>
+ <left_attach>2</left_attach>
+ <right_attach>3</right_attach>
+ <top_attach>1</top_attach>
+ <bottom_attach>2</bottom_attach>
+ <xpad>0</xpad>
+ <ypad>0</ypad>
+ <xexpand>True</xexpand>
+ <yexpand>True</yexpand>
+ <xshrink>False</xshrink>
+ <yshrink>False</yshrink>
+ <xfill>True</xfill>
+ <yfill>True</yfill>
+ </child>
+
+ <widget>
+ <class>GtkCList</class>
+ <name>clist5</name>
+ <width>100</width>
+ <height>150</height>
+ <can_focus>True</can_focus>
+ <columns>1</columns>
+ <column_widths>80</column_widths>
+ <selection_mode>GTK_SELECTION_EXTENDED</selection_mode>
+ <show_titles>False</show_titles>
+ <shadow_type>GTK_SHADOW_IN</shadow_type>
+
+ <widget>
+ <class>GtkLabel</class>
+ <child_name>CList:title</child_name>
+ <name>label22</name>
+ <label>label27</label>
+ <justify>GTK_JUSTIFY_CENTER</justify>
+ <wrap>False</wrap>
+ <xalign>0.5</xalign>
+ <yalign>0.5</yalign>
+ <xpad>0</xpad>
+ <ypad>0</ypad>
+ </widget>
+ </widget>
+ </widget>
+
+ <widget>
+ <class>GtkScrolledWindow</class>
+ <name>scrolledwindow6</name>
+ <width>100</width>
+ <height>150</height>
+ <hscrollbar_policy>GTK_POLICY_AUTOMATIC</hscrollbar_policy>
+ <vscrollbar_policy>GTK_POLICY_AUTOMATIC</vscrollbar_policy>
+ <hupdate_policy>GTK_UPDATE_CONTINUOUS</hupdate_policy>
+ <vupdate_policy>GTK_UPDATE_CONTINUOUS</vupdate_policy>
+ <child>
+ <left_attach>0</left_attach>
+ <right_attach>1</right_attach>
+ <top_attach>1</top_attach>
+ <bottom_attach>2</bottom_attach>
+ <xpad>0</xpad>
+ <ypad>0</ypad>
+ <xexpand>True</xexpand>
+ <yexpand>True</yexpand>
+ <xshrink>False</xshrink>
+ <yshrink>False</yshrink>
+ <xfill>True</xfill>
+ <yfill>True</yfill>
+ </child>
+
+ <widget>
+ <class>GtkCList</class>
+ <name>clist6</name>
+ <can_focus>True</can_focus>
+ <columns>1</columns>
+ <column_widths>80</column_widths>
+ <selection_mode>GTK_SELECTION_EXTENDED</selection_mode>
+ <show_titles>False</show_titles>
+ <shadow_type>GTK_SHADOW_IN</shadow_type>
+
+ <widget>
+ <class>GtkLabel</class>
+ <child_name>CList:title</child_name>
+ <name>label23</name>
+ <label>label26</label>
+ <justify>GTK_JUSTIFY_CENTER</justify>
+ <wrap>False</wrap>
+ <xalign>0.5</xalign>
+ <yalign>0.5</yalign>
+ <xpad>0</xpad>
+ <ypad>0</ypad>
+ </widget>
+ </widget>
+ </widget>
+ </widget>
+
+ <widget>
+ <class>GtkFrame</class>
+ <name>frame2</name>
+ <border_width>3</border_width>
+ <label>RDF settings</label>
+ <label_xalign>0</label_xalign>
+ <shadow_type>GTK_SHADOW_ETCHED_IN</shadow_type>
+ <child>
+ <padding>0</padding>
+ <expand>False</expand>
+ <fill>False</fill>
+ </child>
+
+ <widget>
+ <class>GtkTable</class>
+ <name>table4</name>
+ <border_width>3</border_width>
+ <rows>2</rows>
+ <columns>5</columns>
+ <homogeneous>False</homogeneous>
+ <row_spacing>3</row_spacing>
+ <column_spacing>3</column_spacing>
+
+ <widget>
+ <class>GtkLabel</class>
+ <name>label25</name>
+ <label>Refresh time (seconds):</label>
+ <justify>GTK_JUSTIFY_LEFT</justify>
+ <wrap>False</wrap>
+ <xalign>0</xalign>
+ <yalign>0.5</yalign>
+ <xpad>0</xpad>
+ <ypad>0</ypad>
+ <child>
+ <left_attach>0</left_attach>
+ <right_attach>1</right_attach>
+ <top_attach>0</top_attach>
+ <bottom_attach>1</bottom_attach>
+ <xpad>0</xpad>
+ <ypad>0</ypad>
+ <xexpand>False</xexpand>
+ <yexpand>False</yexpand>
+ <xshrink>False</xshrink>
+ <yshrink>False</yshrink>
+ <xfill>True</xfill>
+ <yfill>False</yfill>
+ </child>
+ </widget>
+
+ <widget>
+ <class>GtkLabel</class>
+ <name>label29</name>
+ <label>Max number of items shown:</label>
+ <justify>GTK_JUSTIFY_LEFT</justify>
+ <wrap>False</wrap>
+ <xalign>0</xalign>
+ <yalign>0.5</yalign>
+ <xpad>0</xpad>
+ <ypad>0</ypad>
+ <child>
+ <left_attach>0</left_attach>
+ <right_attach>1</right_attach>
+ <top_attach>1</top_attach>
+ <bottom_attach>2</bottom_attach>
+ <xpad>0</xpad>
+ <ypad>0</ypad>
+ <xexpand>False</xexpand>
+ <yexpand>False</yexpand>
+ <xshrink>False</xshrink>
+ <yshrink>False</yshrink>
+ <xfill>True</xfill>
+ <yfill>False</yfill>
+ </child>
+ </widget>
+
+ <widget>
+ <class>GtkSpinButton</class>
+ <name>spinbutton1</name>
+ <can_focus>True</can_focus>
+ <climb_rate>1</climb_rate>
+ <digits>0</digits>
+ <numeric>False</numeric>
+ <update_policy>GTK_UPDATE_ALWAYS</update_policy>
+ <snap>False</snap>
+ <wrap>False</wrap>
+ <value>1</value>
+ <lower>0</lower>
+ <upper>1e+06</upper>
+ <step>1</step>
+ <page>10</page>
+ <page_size>10</page_size>
+ <child>
+ <left_attach>1</left_attach>
+ <right_attach>2</right_attach>
+ <top_attach>0</top_attach>
+ <bottom_attach>1</bottom_attach>
+ <xpad>0</xpad>
+ <ypad>0</ypad>
+ <xexpand>False</xexpand>
+ <yexpand>False</yexpand>
+ <xshrink>False</xshrink>
+ <yshrink>False</yshrink>
+ <xfill>True</xfill>
+ <yfill>False</yfill>
+ </child>
+ </widget>
+
+ <widget>
+ <class>GtkSpinButton</class>
+ <name>spinbutton4</name>
+ <can_focus>True</can_focus>
+ <climb_rate>1</climb_rate>
+ <digits>0</digits>
+ <numeric>False</numeric>
+ <update_policy>GTK_UPDATE_ALWAYS</update_policy>
+ <snap>False</snap>
+ <wrap>False</wrap>
+ <value>1</value>
+ <lower>0</lower>
+ <upper>100</upper>
+ <step>1</step>
+ <page>10</page>
+ <page_size>10</page_size>
+ <child>
+ <left_attach>1</left_attach>
+ <right_attach>3</right_attach>
+ <top_attach>1</top_attach>
+ <bottom_attach>2</bottom_attach>
+ <xpad>0</xpad>
+ <ypad>0</ypad>
+ <xexpand>False</xexpand>
+ <yexpand>False</yexpand>
+ <xshrink>False</xshrink>
+ <yshrink>False</yshrink>
+ <xfill>True</xfill>
+ <yfill>False</yfill>
+ </child>
+ </widget>
+
+ <widget>
+ <class>GtkCheckButton</class>
+ <name>checkbutton2</name>
+ <can_focus>True</can_focus>
+ <label>Wipe trackers</label>
+ <active>False</active>
+ <draw_indicator>True</draw_indicator>
+ <child>
+ <left_attach>4</left_attach>
+ <right_attach>5</right_attach>
+ <top_attach>1</top_attach>
+ <bottom_attach>2</bottom_attach>
+ <xpad>0</xpad>
+ <ypad>0</ypad>
+ <xexpand>False</xexpand>
+ <yexpand>False</yexpand>
+ <xshrink>False</xshrink>
+ <yshrink>False</yshrink>
+ <xfill>True</xfill>
+ <yfill>False</yfill>
+ </child>
+ </widget>
+
+ <widget>
+ <class>GtkButton</class>
+ <name>button11</name>
+ <can_focus>True</can_focus>
+ <label>Add new RDF</label>
+ <relief>GTK_RELIEF_NORMAL</relief>
+ <child>
+ <left_attach>3</left_attach>
+ <right_attach>5</right_attach>
+ <top_attach>0</top_attach>
+ <bottom_attach>1</bottom_attach>
+ <xpad>0</xpad>
+ <ypad>0</ypad>
+ <xexpand>True</xexpand>
+ <yexpand>False</yexpand>
+ <xshrink>False</xshrink>
+ <yshrink>False</yshrink>
+ <xfill>True</xfill>
+ <yfill>False</yfill>
+ </child>
+ </widget>
+ </widget>
+ </widget>
+ </widget>
+
+ <widget>
+ <class>GtkLabel</class>
+ <child_name>Notebook:tab</child_name>
+ <name>label6</name>
+ <label>RDF Summaries</label>
+ <justify>GTK_JUSTIFY_CENTER</justify>
+ <wrap>False</wrap>
+ <xalign>0.5</xalign>
+ <yalign>0.5</yalign>
+ <xpad>0</xpad>
+ <ypad>0</ypad>
+ </widget>
+
+ <widget>
+ <class>GtkVBox</class>
+ <name>vbox8</name>
+ <homogeneous>False</homogeneous>
+ <spacing>0</spacing>
+
+ <widget>
+ <class>GtkTable</class>
+ <name>table2</name>
+ <border_width>8</border_width>
+ <rows>2</rows>
+ <columns>3</columns>
+ <homogeneous>False</homogeneous>
+ <row_spacing>0</row_spacing>
+ <column_spacing>0</column_spacing>
+ <child>
+ <padding>0</padding>
+ <expand>True</expand>
+ <fill>True</fill>
+ </child>
+
+ <widget>
+ <class>GtkLabel</class>
+ <name>label14</name>
+ <label>All stations:</label>
+ <justify>GTK_JUSTIFY_CENTER</justify>
+ <wrap>False</wrap>
+ <xalign>0.5</xalign>
+ <yalign>0.5</yalign>
+ <xpad>0</xpad>
+ <ypad>0</ypad>
+ <child>
+ <left_attach>0</left_attach>
+ <right_attach>1</right_attach>
+ <top_attach>0</top_attach>
+ <bottom_attach>1</bottom_attach>
+ <xpad>0</xpad>
+ <ypad>0</ypad>
+ <xexpand>False</xexpand>
+ <yexpand>False</yexpand>
+ <xshrink>False</xshrink>
+ <yshrink>False</yshrink>
+ <xfill>False</xfill>
+ <yfill>False</yfill>
+ </child>
+ </widget>
+
+ <widget>
+ <class>GtkLabel</class>
+ <name>label15</name>
+ <label>Display stations:</label>
+ <justify>GTK_JUSTIFY_CENTER</justify>
+ <wrap>False</wrap>
+ <xalign>0.5</xalign>
+ <yalign>0.5</yalign>
+ <xpad>0</xpad>
+ <ypad>0</ypad>
+ <child>
+ <left_attach>2</left_attach>
+ <right_attach>3</right_attach>
+ <top_attach>0</top_attach>
+ <bottom_attach>1</bottom_attach>
+ <xpad>0</xpad>
+ <ypad>0</ypad>
+ <xexpand>False</xexpand>
+ <yexpand>False</yexpand>
+ <xshrink>False</xshrink>
+ <yshrink>False</yshrink>
+ <xfill>False</xfill>
+ <yfill>False</yfill>
+ </child>
+ </widget>
+
+ <widget>
+ <class>GtkAlignment</class>
+ <name>alignment2</name>
+ <border_width>8</border_width>
+ <xalign>0.5</xalign>
+ <yalign>0.5</yalign>
+ <xscale>1</xscale>
+ <yscale>0</yscale>
+ <child>
+ <left_attach>1</left_attach>
+ <right_attach>2</right_attach>
+ <top_attach>1</top_attach>
+ <bottom_attach>2</bottom_attach>
+ <xpad>0</xpad>
+ <ypad>0</ypad>
+ <xexpand>False</xexpand>
+ <yexpand>False</yexpand>
+ <xshrink>False</xshrink>
+ <yshrink>False</yshrink>
+ <xfill>False</xfill>
+ <yfill>False</yfill>
+ </child>
+
+ <widget>
+ <class>GtkVBox</class>
+ <name>vbox5</name>
+ <homogeneous>False</homogeneous>
+ <spacing>8</spacing>
+
+ <widget>
+ <class>GtkButton</class>
+ <name>button6</name>
+ <sensitive>False</sensitive>
+ <can_focus>True</can_focus>
+ <label>Add -&gt;</label>
+ <relief>GTK_RELIEF_NORMAL</relief>
+ <child>
+ <padding>0</padding>
+ <expand>False</expand>
+ <fill>False</fill>
+ </child>
+ </widget>
+
+ <widget>
+ <class>GtkButton</class>
+ <name>button7</name>
+ <sensitive>False</sensitive>
+ <can_focus>True</can_focus>
+ <label>Remove &lt;-</label>
+ <relief>GTK_RELIEF_NORMAL</relief>
+ <child>
+ <padding>0</padding>
+ <expand>False</expand>
+ <fill>False</fill>
+ </child>
+ </widget>
+ </widget>
+ </widget>
+
+ <widget>
+ <class>GtkLabel</class>
+ <name>label16</name>
+ <label></label>
+ <justify>GTK_JUSTIFY_CENTER</justify>
+ <wrap>False</wrap>
+ <xalign>0.5</xalign>
+ <yalign>0.5</yalign>
+ <xpad>0</xpad>
+ <ypad>0</ypad>
+ <child>
+ <left_attach>1</left_attach>
+ <right_attach>2</right_attach>
+ <top_attach>0</top_attach>
+ <bottom_attach>1</bottom_attach>
+ <xpad>0</xpad>
+ <ypad>0</ypad>
+ <xexpand>False</xexpand>
+ <yexpand>False</yexpand>
+ <xshrink>False</xshrink>
+ <yshrink>False</yshrink>
+ <xfill>False</xfill>
+ <yfill>False</yfill>
+ </child>
+ </widget>
+
+ <widget>
+ <class>GtkScrolledWindow</class>
+ <name>scrolledwindow3</name>
+ <hscrollbar_policy>GTK_POLICY_AUTOMATIC</hscrollbar_policy>
+ <vscrollbar_policy>GTK_POLICY_AUTOMATIC</vscrollbar_policy>
+ <hupdate_policy>GTK_UPDATE_CONTINUOUS</hupdate_policy>
+ <vupdate_policy>GTK_UPDATE_CONTINUOUS</vupdate_policy>
+ <child>
+ <left_attach>2</left_attach>
+ <right_attach>3</right_attach>
+ <top_attach>1</top_attach>
+ <bottom_attach>2</bottom_attach>
+ <xpad>0</xpad>
+ <ypad>0</ypad>
+ <xexpand>True</xexpand>
+ <yexpand>True</yexpand>
+ <xshrink>False</xshrink>
+ <yshrink>False</yshrink>
+ <xfill>True</xfill>
+ <yfill>True</yfill>
+ </child>
+
+ <widget>
+ <class>GtkCList</class>
+ <name>clist3</name>
+ <width>100</width>
+ <height>150</height>
+ <can_focus>True</can_focus>
+ <columns>1</columns>
+ <column_widths>80</column_widths>
+ <selection_mode>GTK_SELECTION_EXTENDED</selection_mode>
+ <show_titles>False</show_titles>
+ <shadow_type>GTK_SHADOW_IN</shadow_type>
+
+ <widget>
+ <class>GtkLabel</class>
+ <child_name>CList:title</child_name>
+ <name>label17</name>
+ <label>label27</label>
+ <justify>GTK_JUSTIFY_CENTER</justify>
+ <wrap>False</wrap>
+ <xalign>0.5</xalign>
+ <yalign>0.5</yalign>
+ <xpad>0</xpad>
+ <ypad>0</ypad>
+ </widget>
+ </widget>
+ </widget>
+
+ <widget>
+ <class>GtkScrolledWindow</class>
+ <name>scrolledwindow4</name>
+ <width>100</width>
+ <height>150</height>
+ <hscrollbar_policy>GTK_POLICY_AUTOMATIC</hscrollbar_policy>
+ <vscrollbar_policy>GTK_POLICY_AUTOMATIC</vscrollbar_policy>
+ <hupdate_policy>GTK_UPDATE_CONTINUOUS</hupdate_policy>
+ <vupdate_policy>GTK_UPDATE_CONTINUOUS</vupdate_policy>
+ <child>
+ <left_attach>0</left_attach>
+ <right_attach>1</right_attach>
+ <top_attach>1</top_attach>
+ <bottom_attach>2</bottom_attach>
+ <xpad>0</xpad>
+ <ypad>0</ypad>
+ <xexpand>True</xexpand>
+ <yexpand>True</yexpand>
+ <xshrink>False</xshrink>
+ <yshrink>False</yshrink>
+ <xfill>True</xfill>
+ <yfill>True</yfill>
+ </child>
+
+ <widget>
+ <class>GtkCTree</class>
+ <name>ctree1</name>
+ <can_focus>True</can_focus>
+ <columns>1</columns>
+ <column_widths>80</column_widths>
+ <selection_mode>GTK_SELECTION_SINGLE</selection_mode>
+ <show_titles>False</show_titles>
+ <shadow_type>GTK_SHADOW_IN</shadow_type>
+
+ <widget>
+ <class>GtkLabel</class>
+ <child_name>CTree:title</child_name>
+ <name>label39</name>
+ <label>label39</label>
+ <justify>GTK_JUSTIFY_CENTER</justify>
+ <wrap>False</wrap>
+ <xalign>0.5</xalign>
+ <yalign>0.5</yalign>
+ <xpad>0</xpad>
+ <ypad>0</ypad>
+ </widget>
+ </widget>
+ </widget>
+ </widget>
+
+ <widget>
+ <class>GtkFrame</class>
+ <name>frame3</name>
+ <border_width>3</border_width>
+ <label>Weather settings</label>
+ <label_xalign>0</label_xalign>
+ <shadow_type>GTK_SHADOW_ETCHED_IN</shadow_type>
+ <child>
+ <padding>0</padding>
+ <expand>False</expand>
+ <fill>False</fill>
+ </child>
+
+ <widget>
+ <class>GtkVBox</class>
+ <name>vbox11</name>
+ <border_width>3</border_width>
+ <homogeneous>False</homogeneous>
+ <spacing>0</spacing>
+
+ <widget>
+ <class>GtkHBox</class>
+ <name>hbox4</name>
+ <homogeneous>False</homogeneous>
+ <spacing>3</spacing>
+ <child>
+ <padding>0</padding>
+ <expand>False</expand>
+ <fill>False</fill>
+ </child>
+
+ <widget>
+ <class>GtkLabel</class>
+ <name>label37</name>
+ <label>Units: </label>
+ <justify>GTK_JUSTIFY_CENTER</justify>
+ <wrap>False</wrap>
+ <xalign>0.5</xalign>
+ <yalign>0.5</yalign>
+ <xpad>0</xpad>
+ <ypad>0</ypad>
+ <child>
+ <padding>0</padding>
+ <expand>False</expand>
+ <fill>False</fill>
+ </child>
+ </widget>
+
+ <widget>
+ <class>GtkRadioButton</class>
+ <name>radiobutton7</name>
+ <can_focus>True</can_focus>
+ <label>metric</label>
+ <active>False</active>
+ <draw_indicator>True</draw_indicator>
+ <child>
+ <padding>0</padding>
+ <expand>False</expand>
+ <fill>False</fill>
+ </child>
+ </widget>
+
+ <widget>
+ <class>GtkRadioButton</class>
+ <name>radiobutton8</name>
+ <can_focus>True</can_focus>
+ <label>imperial</label>
+ <active>False</active>
+ <draw_indicator>True</draw_indicator>
+ <child>
+ <padding>0</padding>
+ <expand>False</expand>
+ <fill>False</fill>
+ </child>
+ </widget>
+ </widget>
+
+ <widget>
+ <class>GtkHBox</class>
+ <name>hbox5</name>
+ <homogeneous>False</homogeneous>
+ <spacing>3</spacing>
+ <child>
+ <padding>0</padding>
+ <expand>True</expand>
+ <fill>True</fill>
+ </child>
+
+ <widget>
+ <class>GtkLabel</class>
+ <name>label38</name>
+ <label>Refresh time (seconds):</label>
+ <justify>GTK_JUSTIFY_CENTER</justify>
+ <wrap>False</wrap>
+ <xalign>0.5</xalign>
+ <yalign>0.5</yalign>
+ <xpad>0</xpad>
+ <ypad>0</ypad>
+ <child>
+ <padding>0</padding>
+ <expand>False</expand>
+ <fill>False</fill>
+ </child>
+ </widget>
+
+ <widget>
+ <class>GtkSpinButton</class>
+ <name>spinbutton5</name>
+ <can_focus>True</can_focus>
+ <climb_rate>1</climb_rate>
+ <digits>0</digits>
+ <numeric>False</numeric>
+ <update_policy>GTK_UPDATE_ALWAYS</update_policy>
+ <snap>False</snap>
+ <wrap>False</wrap>
+ <value>1</value>
+ <lower>0</lower>
+ <upper>1e+06</upper>
+ <step>1</step>
+ <page>10</page>
+ <page_size>10</page_size>
+ <child>
+ <padding>0</padding>
+ <expand>False</expand>
+ <fill>False</fill>
+ </child>
+ </widget>
+ </widget>
+ </widget>
+ </widget>
+ </widget>
+
+ <widget>
+ <class>GtkLabel</class>
+ <child_name>Notebook:tab</child_name>
+ <name>label7</name>
+ <label>Weather</label>
+ <justify>GTK_JUSTIFY_CENTER</justify>
+ <wrap>False</wrap>
+ <xalign>0.5</xalign>
+ <yalign>0.5</yalign>
+ <xpad>0</xpad>
+ <ypad>0</ypad>
+ </widget>
+
+ <widget>
+ <class>GtkVBox</class>
+ <name>vbox9</name>
+ <homogeneous>False</homogeneous>
+ <spacing>0</spacing>
+
+ <widget>
+ <class>GtkFrame</class>
+ <name>frame4</name>
+ <border_width>3</border_width>
+ <label>Calendar</label>
+ <label_xalign>0</label_xalign>
+ <shadow_type>GTK_SHADOW_ETCHED_IN</shadow_type>
+ <child>
+ <padding>0</padding>
+ <expand>False</expand>
+ <fill>False</fill>
+ </child>
+
+ <widget>
+ <class>GtkVBox</class>
+ <name>vbox10</name>
+ <border_width>3</border_width>
+ <homogeneous>False</homogeneous>
+ <spacing>3</spacing>
+
+ <widget>
+ <class>GtkLabel</class>
+ <name>label32</name>
+ <label>How many days should the calendar display at once?</label>
+ <justify>GTK_JUSTIFY_LEFT</justify>
+ <wrap>False</wrap>
+ <xalign>7.45058e-09</xalign>
+ <yalign>0.5</yalign>
+ <xpad>3</xpad>
+ <ypad>0</ypad>
+ <child>
+ <padding>0</padding>
+ <expand>False</expand>
+ <fill>True</fill>
+ </child>
+ </widget>
+
+ <widget>
+ <class>GtkTable</class>
+ <name>table5</name>
+ <border_width>3</border_width>
+ <rows>4</rows>
+ <columns>3</columns>
+ <homogeneous>False</homogeneous>
+ <row_spacing>3</row_spacing>
+ <column_spacing>3</column_spacing>
+ <child>
+ <padding>0</padding>
+ <expand>True</expand>
+ <fill>True</fill>
+ </child>
+
+ <widget>
+ <class>GtkRadioButton</class>
+ <name>radiobutton3</name>
+ <can_focus>True</can_focus>
+ <label></label>
+ <active>False</active>
+ <draw_indicator>True</draw_indicator>
+ <child>
+ <left_attach>0</left_attach>
+ <right_attach>1</right_attach>
+ <top_attach>0</top_attach>
+ <bottom_attach>1</bottom_attach>
+ <xpad>0</xpad>
+ <ypad>0</ypad>
+ <xexpand>False</xexpand>
+ <yexpand>False</yexpand>
+ <xshrink>False</xshrink>
+ <yshrink>False</yshrink>
+ <xfill>False</xfill>
+ <yfill>False</yfill>
+ </child>
+ </widget>
+
+ <widget>
+ <class>GtkRadioButton</class>
+ <name>radiobutton5</name>
+ <can_focus>True</can_focus>
+ <label></label>
+ <active>False</active>
+ <draw_indicator>True</draw_indicator>
+ <child>
+ <left_attach>0</left_attach>
+ <right_attach>1</right_attach>
+ <top_attach>2</top_attach>
+ <bottom_attach>3</bottom_attach>
+ <xpad>0</xpad>
+ <ypad>0</ypad>
+ <xexpand>False</xexpand>
+ <yexpand>False</yexpand>
+ <xshrink>False</xshrink>
+ <yshrink>False</yshrink>
+ <xfill>True</xfill>
+ <yfill>False</yfill>
+ </child>
+ </widget>
+
+ <widget>
+ <class>GtkRadioButton</class>
+ <name>radiobutton6</name>
+ <can_focus>True</can_focus>
+ <label></label>
+ <active>False</active>
+ <draw_indicator>True</draw_indicator>
+ <child>
+ <left_attach>0</left_attach>
+ <right_attach>1</right_attach>
+ <top_attach>3</top_attach>
+ <bottom_attach>4</bottom_attach>
+ <xpad>0</xpad>
+ <ypad>0</ypad>
+ <xexpand>False</xexpand>
+ <yexpand>False</yexpand>
+ <xshrink>False</xshrink>
+ <yshrink>False</yshrink>
+ <xfill>True</xfill>
+ <yfill>False</yfill>
+ </child>
+ </widget>
+
+ <widget>
+ <class>GtkRadioButton</class>
+ <name>radiobutton4</name>
+ <can_focus>True</can_focus>
+ <label></label>
+ <active>False</active>
+ <draw_indicator>True</draw_indicator>
+ <child>
+ <left_attach>0</left_attach>
+ <right_attach>1</right_attach>
+ <top_attach>1</top_attach>
+ <bottom_attach>2</bottom_attach>
+ <xpad>0</xpad>
+ <ypad>0</ypad>
+ <xexpand>False</xexpand>
+ <yexpand>False</yexpand>
+ <xshrink>False</xshrink>
+ <yshrink>False</yshrink>
+ <xfill>False</xfill>
+ <yfill>False</yfill>
+ </child>
+ </widget>
+
+ <widget>
+ <class>GnomePixmap</class>
+ <name>pixmap2</name>
+ <filename>workweekview.xpm</filename>
+ <child>
+ <left_attach>1</left_attach>
+ <right_attach>2</right_attach>
+ <top_attach>1</top_attach>
+ <bottom_attach>2</bottom_attach>
+ <xpad>0</xpad>
+ <ypad>0</ypad>
+ <xexpand>False</xexpand>
+ <yexpand>False</yexpand>
+ <xshrink>False</xshrink>
+ <yshrink>False</yshrink>
+ <xfill>True</xfill>
+ <yfill>True</yfill>
+ </child>
+ </widget>
+
+ <widget>
+ <class>GnomePixmap</class>
+ <name>pixmap3</name>
+ <filename>weekview.xpm</filename>
+ <child>
+ <left_attach>1</left_attach>
+ <right_attach>2</right_attach>
+ <top_attach>2</top_attach>
+ <bottom_attach>3</bottom_attach>
+ <xpad>0</xpad>
+ <ypad>0</ypad>
+ <xexpand>False</xexpand>
+ <yexpand>False</yexpand>
+ <xshrink>False</xshrink>
+ <yshrink>False</yshrink>
+ <xfill>True</xfill>
+ <yfill>True</yfill>
+ </child>
+ </widget>
+
+ <widget>
+ <class>GnomePixmap</class>
+ <name>pixmap4</name>
+ <filename>monthview.xpm</filename>
+ <child>
+ <left_attach>1</left_attach>
+ <right_attach>2</right_attach>
+ <top_attach>3</top_attach>
+ <bottom_attach>4</bottom_attach>
+ <xpad>0</xpad>
+ <ypad>0</ypad>
+ <xexpand>False</xexpand>
+ <yexpand>False</yexpand>
+ <xshrink>False</xshrink>
+ <yshrink>False</yshrink>
+ <xfill>True</xfill>
+ <yfill>True</yfill>
+ </child>
+ </widget>
+
+ <widget>
+ <class>GnomePixmap</class>
+ <name>pixmap1</name>
+ <filename>dayview.xpm</filename>
+ <child>
+ <left_attach>1</left_attach>
+ <right_attach>2</right_attach>
+ <top_attach>0</top_attach>
+ <bottom_attach>1</bottom_attach>
+ <xpad>0</xpad>
+ <ypad>0</ypad>
+ <xexpand>False</xexpand>
+ <yexpand>False</yexpand>
+ <xshrink>False</xshrink>
+ <yshrink>False</yshrink>
+ <xfill>False</xfill>
+ <yfill>True</yfill>
+ </child>
+ </widget>
+
+ <widget>
+ <class>GtkLabel</class>
+ <name>label33</name>
+ <label>1 day</label>
+ <justify>GTK_JUSTIFY_CENTER</justify>
+ <wrap>False</wrap>
+ <xalign>0</xalign>
+ <yalign>0.5</yalign>
+ <xpad>0</xpad>
+ <ypad>0</ypad>
+ <child>
+ <left_attach>2</left_attach>
+ <right_attach>3</right_attach>
+ <top_attach>0</top_attach>
+ <bottom_attach>1</bottom_attach>
+ <xpad>0</xpad>
+ <ypad>0</ypad>
+ <xexpand>True</xexpand>
+ <yexpand>False</yexpand>
+ <xshrink>False</xshrink>
+ <yshrink>False</yshrink>
+ <xfill>True</xfill>
+ <yfill>False</yfill>
+ </child>
+ </widget>
+
+ <widget>
+ <class>GtkLabel</class>
+ <name>label34</name>
+ <label>5 days</label>
+ <justify>GTK_JUSTIFY_CENTER</justify>
+ <wrap>False</wrap>
+ <xalign>0</xalign>
+ <yalign>0.5</yalign>
+ <xpad>0</xpad>
+ <ypad>0</ypad>
+ <child>
+ <left_attach>2</left_attach>
+ <right_attach>3</right_attach>
+ <top_attach>1</top_attach>
+ <bottom_attach>2</bottom_attach>
+ <xpad>0</xpad>
+ <ypad>0</ypad>
+ <xexpand>True</xexpand>
+ <yexpand>False</yexpand>
+ <xshrink>False</xshrink>
+ <yshrink>False</yshrink>
+ <xfill>True</xfill>
+ <yfill>False</yfill>
+ </child>
+ </widget>
+
+ <widget>
+ <class>GtkLabel</class>
+ <name>label35</name>
+ <label>1 week</label>
+ <justify>GTK_JUSTIFY_CENTER</justify>
+ <wrap>False</wrap>
+ <xalign>0</xalign>
+ <yalign>0.5</yalign>
+ <xpad>0</xpad>
+ <ypad>0</ypad>
+ <child>
+ <left_attach>2</left_attach>
+ <right_attach>3</right_attach>
+ <top_attach>2</top_attach>
+ <bottom_attach>3</bottom_attach>
+ <xpad>0</xpad>
+ <ypad>0</ypad>
+ <xexpand>True</xexpand>
+ <yexpand>False</yexpand>
+ <xshrink>False</xshrink>
+ <yshrink>False</yshrink>
+ <xfill>True</xfill>
+ <yfill>False</yfill>
+ </child>
+ </widget>
+
+ <widget>
+ <class>GtkLabel</class>
+ <name>label36</name>
+ <label>1 month</label>
+ <justify>GTK_JUSTIFY_CENTER</justify>
+ <wrap>False</wrap>
+ <xalign>0</xalign>
+ <yalign>0.5</yalign>
+ <xpad>0</xpad>
+ <ypad>0</ypad>
+ <child>
+ <left_attach>2</left_attach>
+ <right_attach>3</right_attach>
+ <top_attach>3</top_attach>
+ <bottom_attach>4</bottom_attach>
+ <xpad>0</xpad>
+ <ypad>0</ypad>
+ <xexpand>True</xexpand>
+ <yexpand>False</yexpand>
+ <xshrink>False</xshrink>
+ <yshrink>False</yshrink>
+ <xfill>True</xfill>
+ <yfill>False</yfill>
+ </child>
+ </widget>
+ </widget>
+ </widget>
+ </widget>
+
+ <widget>
+ <class>GtkFrame</class>
+ <name>frame5</name>
+ <border_width>3</border_width>
+ <label>Tasks </label>
+ <label_xalign>0</label_xalign>
+ <shadow_type>GTK_SHADOW_ETCHED_IN</shadow_type>
+ <child>
+ <padding>0</padding>
+ <expand>False</expand>
+ <fill>False</fill>
+ </child>
+
+ <widget>
+ <class>GtkHBox</class>
+ <name>hbox3</name>
+ <homogeneous>False</homogeneous>
+ <spacing>0</spacing>
+
+ <widget>
+ <class>GtkRadioButton</class>
+ <name>radiobutton1</name>
+ <can_focus>True</can_focus>
+ <label>Show all tasks</label>
+ <active>False</active>
+ <draw_indicator>True</draw_indicator>
+ <child>
+ <padding>0</padding>
+ <expand>False</expand>
+ <fill>False</fill>
+ </child>
+ </widget>
+
+ <widget>
+ <class>GtkRadioButton</class>
+ <name>radiobutton2</name>
+ <can_focus>True</can_focus>
+ <label>Show today's tasks</label>
+ <active>False</active>
+ <draw_indicator>True</draw_indicator>
+ <child>
+ <padding>0</padding>
+ <expand>False</expand>
+ <fill>False</fill>
+ </child>
+ </widget>
+ </widget>
+ </widget>
+ </widget>
+
+ <widget>
+ <class>GtkLabel</class>
+ <child_name>Notebook:tab</child_name>
+ <name>label8</name>
+ <label>Schedule</label>
+ <justify>GTK_JUSTIFY_CENTER</justify>
+ <wrap>False</wrap>
+ <xalign>0.5</xalign>
+ <yalign>0.5</yalign>
+ <xpad>0</xpad>
+ <ypad>0</ypad>
+ </widget>
+ </widget>
+</widget>
+
+</GTK-Interface>