#endif
}
-static void
-toolbar_progress_init(void)
-{
-GtkToolItem *item;
-
-item=gtk_tool_item_new();
-_progress_item=gtk_progress_bar_new();
-gtk_container_add(item, _progress_item);
-gtk_toolbar_insert(GTK_TOOLBAR (toolbar), item, -1);
-}
-
void
mapper_init_variables(void)
{
GtkNotebook *notebook;
GdkColor color;
GError *error = NULL;
+GtkToolItem *item;
#ifdef WITH_HILDON
/* Initialize _program. */
toolbar = gtk_ui_manager_get_widget (ui, "/ToolBar");
g_assert(toolbar);
-toolbar_progress_init();
+
+item=gtk_tool_item_new();
+_progress_item=gtk_progress_bar_new();
+gtk_tool_item_set_expand(item, TRUE);
+gtk_container_add(item, _progress_item);
+gtk_toolbar_insert(GTK_TOOLBAR(toolbar), item, -1);
/* Notebook with different views */
notebook = gtk_notebook_new();
info_banner.location=gtk_label_new("");
info_banner.speed=gtk_label_new("");
info_banner.distance=gtk_label_new("");
+
gtk_label_set_max_width_chars(GTK_LABEL(info_banner.speed), 10);
gtk_label_set_width_chars(GTK_LABEL(info_banner.speed), 14);
-gtk_box_pack_start(GTK_BOX(info_banner.container), info_banner.speed, FALSE, FALSE, 0);
+gtk_label_set_max_width_chars(GTK_LABEL(info_banner.distance), 14);
+gtk_label_set_width_chars(GTK_LABEL(info_banner.distance), 18);
+
+gtk_misc_set_alignment(GTK_MISC(info_banner.location), 0.f, 0.5f);
+gtk_misc_set_alignment(GTK_MISC(info_banner.speed), 1.f, 0.5f);
+gtk_misc_set_alignment(GTK_MISC(info_banner.distance), 1.f, 0.5f);
+
gtk_box_pack_start(GTK_BOX(info_banner.container), info_banner.location, TRUE, TRUE, 0);
-gtk_box_pack_start(GTK_BOX(info_banner.container), info_banner.distance, FALSE, FALSE, 0);
+gtk_box_pack_end(GTK_BOX(info_banner.container), info_banner.speed, FALSE, FALSE, 0);
+gtk_box_pack_end(GTK_BOX(info_banner.container), info_banner.distance, FALSE, FALSE, 0);
vbox_main = gtk_vbox_new(FALSE, 0);
gtk_container_add(GTK_CONTAINER(_window), vbox_main);
#ifdef WITH_HILDON
/* Create and add widgets and supporting data. */
-gtk_box_pack_start(GTK_BOX(vbox_main), notebook, TRUE, TRUE, 0);
-gtk_box_pack_start(GTK_BOX(vbox_main), info_banner.container, FALSE, FALSE, 0);
-hildon_program_set_common_toolbar(_program, toolbar);
+gtk_box_pack_start(GTK_BOX(vbox_main), GTK_WIDGET(notebook), TRUE, TRUE, 0);
+gtk_box_pack_start(GTK_BOX(vbox_main), GTK_WIDGET(info_banner.container), FALSE, FALSE, 0);
+hildon_program_set_common_toolbar(_program, GTK_TOOLBAR(toolbar));
{
GtkMenu *hmenu;
hmenu = GTK_MENU(gtk_menu_new());