diff options
author | Christopher James Lahey <clahey@helixcode.com> | 2000-05-31 01:06:11 +0800 |
---|---|---|
committer | Chris Lahey <clahey@src.gnome.org> | 2000-05-31 01:06:11 +0800 |
commit | 936611683a969d2a93bde1c41d048881e860edea (patch) | |
tree | 4d30ce4db8310ffc3fd0dfbbd6c92405b0856aa6 /addressbook/gui/widgets | |
parent | 016b2a545c3b3f79132f0b2fb333fbf830203eb5 (diff) | |
download | gsoc2013-evolution-936611683a969d2a93bde1c41d048881e860edea.tar.gz gsoc2013-evolution-936611683a969d2a93bde1c41d048881e860edea.tar.zst gsoc2013-evolution-936611683a969d2a93bde1c41d048881e860edea.zip |
Added alphabet.glade and alphabet.glade.h.
2000-05-30 Christopher James Lahey <clahey@helixcode.com>
* gui/component/Makefile.am: Added alphabet.glade and
alphabet.glade.h.
* gui/component/addressbook.c, gui/component/alphabet.glade,
gui/component/alphabet.glade.h: Added an alphabet bar.
* gui/minicard/e-minicard-view.c, gui/minicard/e-minicard-view.h,
gui/minicard/e-reflow-sorted.c, gui/minicard/e-reflow-sorted.h:
Added the ability to just to a particular spot in the reflow.
svn path=/trunk/; revision=3283
Diffstat (limited to 'addressbook/gui/widgets')
-rw-r--r-- | addressbook/gui/widgets/alphabet.glade | 382 | ||||
-rw-r--r-- | addressbook/gui/widgets/alphabet.glade.h | 34 | ||||
-rw-r--r-- | addressbook/gui/widgets/e-minicard-view.c | 30 | ||||
-rw-r--r-- | addressbook/gui/widgets/e-minicard-view.h | 2 |
4 files changed, 447 insertions, 1 deletions
diff --git a/addressbook/gui/widgets/alphabet.glade b/addressbook/gui/widgets/alphabet.glade new file mode 100644 index 0000000000..a2c61d4a47 --- /dev/null +++ b/addressbook/gui/widgets/alphabet.glade @@ -0,0 +1,382 @@ +<?xml version="1.0"?> +<GTK-Interface> + +<project> + <name>alphabet</name> + <program_name>alphabet</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> + <use_widget_names>True</use_widget_names> + <output_main_file>False</output_main_file> + <output_support_files>False</output_support_files> + <output_build_files>False</output_build_files> + <gnome_help_support>True</gnome_help_support> + <output_translatable_strings>True</output_translatable_strings> + <translatable_strings_file>alphabet.glade.h</translatable_strings_file> +</project> + +<widget> + <class>GtkWindow</class> + <name>window2</name> + <visible>False</visible> + <title>window2</title> + <type>GTK_WINDOW_TOPLEVEL</type> + <position>GTK_WIN_POS_NONE</position> + <modal>False</modal> + <allow_shrink>False</allow_shrink> + <allow_grow>True</allow_grow> + <auto_shrink>False</auto_shrink> + + <widget> + <class>GtkScrolledWindow</class> + <name>scrolledwindow-top</name> + <hscrollbar_policy>GTK_POLICY_NEVER</hscrollbar_policy> + <vscrollbar_policy>GTK_POLICY_AUTOMATIC</vscrollbar_policy> + <hupdate_policy>GTK_UPDATE_CONTINUOUS</hupdate_policy> + <vupdate_policy>GTK_UPDATE_CONTINUOUS</vupdate_policy> + + <widget> + <class>GtkViewport</class> + <name>viewport1</name> + <shadow_type>GTK_SHADOW_NONE</shadow_type> + + <widget> + <class>GtkVBox</class> + <name>vbox2</name> + <width>27</width> + <homogeneous>False</homogeneous> + <spacing>0</spacing> + + <widget> + <class>GtkButton</class> + <name>button-1</name> + <can_focus>True</can_focus> + <label>123</label> + <child> + <padding>0</padding> + <expand>False</expand> + <fill>False</fill> + </child> + </widget> + + <widget> + <class>GtkButton</class> + <name>button-a</name> + <can_focus>True</can_focus> + <label>a</label> + <child> + <padding>0</padding> + <expand>False</expand> + <fill>False</fill> + </child> + </widget> + + <widget> + <class>GtkButton</class> + <name>button-b</name> + <can_focus>True</can_focus> + <label>b</label> + <child> + <padding>0</padding> + <expand>False</expand> + <fill>False</fill> + </child> + </widget> + + <widget> + <class>GtkButton</class> + <name>button-c</name> + <can_focus>True</can_focus> + <label>c</label> + <child> + <padding>0</padding> + <expand>False</expand> + <fill>False</fill> + </child> + </widget> + + <widget> + <class>GtkButton</class> + <name>button-d</name> + <can_focus>True</can_focus> + <label>d</label> + <child> + <padding>0</padding> + <expand>False</expand> + <fill>False</fill> + </child> + </widget> + + <widget> + <class>GtkButton</class> + <name>button-e</name> + <can_focus>True</can_focus> + <label>e</label> + <child> + <padding>0</padding> + <expand>False</expand> + <fill>False</fill> + </child> + </widget> + + <widget> + <class>GtkButton</class> + <name>button-f</name> + <can_focus>True</can_focus> + <label>f</label> + <child> + <padding>0</padding> + <expand>False</expand> + <fill>False</fill> + </child> + </widget> + + <widget> + <class>GtkButton</class> + <name>button-g</name> + <can_focus>True</can_focus> + <label>g</label> + <child> + <padding>0</padding> + <expand>False</expand> + <fill>False</fill> + </child> + </widget> + + <widget> + <class>GtkButton</class> + <name>button-h</name> + <can_focus>True</can_focus> + <label>h</label> + <child> + <padding>0</padding> + <expand>False</expand> + <fill>False</fill> + </child> + </widget> + + <widget> + <class>GtkButton</class> + <name>button-i</name> + <can_focus>True</can_focus> + <label>i</label> + <child> + <padding>0</padding> + <expand>False</expand> + <fill>False</fill> + </child> + </widget> + + <widget> + <class>GtkButton</class> + <name>button-j</name> + <can_focus>True</can_focus> + <label>j</label> + <child> + <padding>0</padding> + <expand>False</expand> + <fill>False</fill> + </child> + </widget> + + <widget> + <class>GtkButton</class> + <name>button-k</name> + <can_focus>True</can_focus> + <label>k</label> + <child> + <padding>0</padding> + <expand>False</expand> + <fill>False</fill> + </child> + </widget> + + <widget> + <class>GtkButton</class> + <name>button-l</name> + <can_focus>True</can_focus> + <label>l</label> + <child> + <padding>0</padding> + <expand>False</expand> + <fill>False</fill> + </child> + </widget> + + <widget> + <class>GtkButton</class> + <name>button-m</name> + <can_focus>True</can_focus> + <label>m</label> + <child> + <padding>0</padding> + <expand>False</expand> + <fill>False</fill> + </child> + </widget> + + <widget> + <class>GtkButton</class> + <name>button-n</name> + <can_focus>True</can_focus> + <label>n</label> + <child> + <padding>0</padding> + <expand>False</expand> + <fill>False</fill> + </child> + </widget> + + <widget> + <class>GtkButton</class> + <name>button-o</name> + <can_focus>True</can_focus> + <label>o</label> + <child> + <padding>0</padding> + <expand>False</expand> + <fill>False</fill> + </child> + </widget> + + <widget> + <class>GtkButton</class> + <name>button-p</name> + <can_focus>True</can_focus> + <label>p</label> + <child> + <padding>0</padding> + <expand>False</expand> + <fill>False</fill> + </child> + </widget> + + <widget> + <class>GtkButton</class> + <name>button-q</name> + <can_focus>True</can_focus> + <label>q</label> + <child> + <padding>0</padding> + <expand>False</expand> + <fill>False</fill> + </child> + </widget> + + <widget> + <class>GtkButton</class> + <name>button-r</name> + <can_focus>True</can_focus> + <label>r</label> + <child> + <padding>0</padding> + <expand>False</expand> + <fill>False</fill> + </child> + </widget> + + <widget> + <class>GtkButton</class> + <name>button-s</name> + <can_focus>True</can_focus> + <label>s</label> + <child> + <padding>0</padding> + <expand>False</expand> + <fill>False</fill> + </child> + </widget> + + <widget> + <class>GtkButton</class> + <name>button-t</name> + <can_focus>True</can_focus> + <label>t</label> + <child> + <padding>0</padding> + <expand>False</expand> + <fill>False</fill> + </child> + </widget> + + <widget> + <class>GtkButton</class> + <name>button-u</name> + <can_focus>True</can_focus> + <label>u</label> + <child> + <padding>0</padding> + <expand>False</expand> + <fill>False</fill> + </child> + </widget> + + <widget> + <class>GtkButton</class> + <name>button-v</name> + <can_focus>True</can_focus> + <label>v</label> + <child> + <padding>0</padding> + <expand>False</expand> + <fill>False</fill> + </child> + </widget> + + <widget> + <class>GtkButton</class> + <name>button-w</name> + <can_focus>True</can_focus> + <label>w</label> + <child> + <padding>0</padding> + <expand>False</expand> + <fill>False</fill> + </child> + </widget> + + <widget> + <class>GtkButton</class> + <name>button-x</name> + <can_focus>True</can_focus> + <label>x</label> + <child> + <padding>0</padding> + <expand>False</expand> + <fill>False</fill> + </child> + </widget> + + <widget> + <class>GtkButton</class> + <name>button-y</name> + <can_focus>True</can_focus> + <label>y</label> + <child> + <padding>0</padding> + <expand>False</expand> + <fill>False</fill> + </child> + </widget> + + <widget> + <class>GtkButton</class> + <name>button-z</name> + <can_focus>True</can_focus> + <label>z</label> + <child> + <padding>0</padding> + <expand>False</expand> + <fill>False</fill> + </child> + </widget> + </widget> + </widget> + </widget> +</widget> + +</GTK-Interface> diff --git a/addressbook/gui/widgets/alphabet.glade.h b/addressbook/gui/widgets/alphabet.glade.h new file mode 100644 index 0000000000..2448eeb4fc --- /dev/null +++ b/addressbook/gui/widgets/alphabet.glade.h @@ -0,0 +1,34 @@ +/* + * Translatable strings file generated by Glade. + * Add this file to your project's POTFILES.in. + * DO NOT compile it as part of your application. + */ + +gchar *s = N_("window2"); +gchar *s = N_("123"); +gchar *s = N_("a"); +gchar *s = N_("b"); +gchar *s = N_("c"); +gchar *s = N_("d"); +gchar *s = N_("e"); +gchar *s = N_("f"); +gchar *s = N_("g"); +gchar *s = N_("h"); +gchar *s = N_("i"); +gchar *s = N_("j"); +gchar *s = N_("k"); +gchar *s = N_("l"); +gchar *s = N_("m"); +gchar *s = N_("n"); +gchar *s = N_("o"); +gchar *s = N_("p"); +gchar *s = N_("q"); +gchar *s = N_("r"); +gchar *s = N_("s"); +gchar *s = N_("t"); +gchar *s = N_("u"); +gchar *s = N_("v"); +gchar *s = N_("w"); +gchar *s = N_("x"); +gchar *s = N_("y"); +gchar *s = N_("z"); diff --git a/addressbook/gui/widgets/e-minicard-view.c b/addressbook/gui/widgets/e-minicard-view.c index d3acb1ad54..bc2e22fa32 100644 --- a/addressbook/gui/widgets/e-minicard-view.c +++ b/addressbook/gui/widgets/e-minicard-view.c @@ -107,7 +107,7 @@ e_minicard_view_init (EMinicardView *view) view->canvas_destroy_id = 0; gtk_object_set(GTK_OBJECT(view), - "empty_message", _("There are no items to show in this view\n\n" + "empty_message", _("\n\nThere are no items to show in this view\n\n" "Double-click here to create a new Contact."), NULL); @@ -380,3 +380,31 @@ e_minicard_view_remove_selection(EMinicardView *view, } } } + +static int +compare_to_letter(EMinicard *card, char *letter) +{ + g_return_val_if_fail(card != NULL, 0); + g_return_val_if_fail(E_IS_MINICARD(card), 0); + + if (card->card) { + char *file_as; + gtk_object_get(GTK_OBJECT(card->card), + "file_as", &file_as, + NULL); + if (file_as) + return strncasecmp(file_as, letter, 1); + else + return 0; + } else { + return 0; + } +} + +void e_minicard_view_jump_to_letter (EMinicardView *view, + char letter) +{ + e_reflow_sorted_jump(E_REFLOW_SORTED(view), + (GCompareFunc) compare_to_letter, + &letter); +} diff --git a/addressbook/gui/widgets/e-minicard-view.h b/addressbook/gui/widgets/e-minicard-view.h index 780b0dde33..a166a6ade1 100644 --- a/addressbook/gui/widgets/e-minicard-view.h +++ b/addressbook/gui/widgets/e-minicard-view.h @@ -84,6 +84,8 @@ GtkType e_minicard_view_get_type (void); void e_minicard_view_remove_selection (EMinicardView *view, EBookCallback cb, gpointer closure); +void e_minicard_view_jump_to_letter (EMinicardView *view, + char letter); #ifdef __cplusplus } |