updated copyright in source files
[geeqie.git] / src / ui_bookmark.h
1 /*
2  * (SLIK) SimpLIstic sKin functions
3  * (C) 2004 John Ellis
4  * Copyright (C) 2008 The Geeqie Team
5  *
6  * Author: John Ellis
7  *
8  * This software is released under the GNU General Public License (GNU GPL).
9  * Please read the included file COPYING for more information.
10  * This software comes with no warranty of any kind, use at your own risk!
11  */
12
13
14 #ifndef UI_BOOKMARK_H
15 #define UI_BOOKMARK_H
16
17
18 /* history lists */
19
20 gint history_list_load(const gchar *path);
21 gint history_list_save(const gchar *path);
22
23 void history_list_free_key(const gchar *key);
24
25 void history_list_add_to_key(const gchar *key, const gchar *path, gint max);
26
27 void history_list_item_change(const gchar *key, const gchar *oldpath, const gchar *newpath);
28 void history_list_item_move(const gchar *key, const gchar *path, gint direction);
29 void history_list_item_remove(const gchar *key, const gchar *path);
30
31 const gchar *history_list_find_last_path_by_key(const gchar* key);
32
33 /* the returned GList is internal, don't free it */
34 GList *history_list_get_by_key(const gchar *key);
35
36
37 /* bookmarks */
38
39 GtkWidget *bookmark_list_new(const gchar *key,
40                              void (*select_func)(const gchar *path, gpointer data), gpointer select_data);
41 void bookmark_list_set_key(GtkWidget *list, const gchar *key);
42 void bookmark_list_set_no_defaults(GtkWidget *list, gint no_defaults);
43 void bookmark_list_set_editable(GtkWidget *list, gint editable);
44 void bookmark_list_add(GtkWidget *list, const gchar *name, const gchar *path);
45
46 /* allows apps to set up the defaults */
47 void bookmark_add_default(const gchar *name, const gchar *path);
48
49
50 /* history combo entry */
51
52 GtkWidget *history_combo_new(GtkWidget **entry, const gchar *text,
53                              const gchar *history_key, gint max_levels);
54 void history_combo_append_history(GtkWidget *widget, const gchar *text);
55
56
57 /* dnd data parsers (uris) */
58
59 gchar *uri_text_escape(const gchar *text);
60 void uri_text_decode(gchar *text);
61
62 GList *uri_list_from_text(gchar *data, gint files_only);
63 GList *uri_filelist_from_text(gchar *data, gint files_only);
64 gchar *uri_text_from_list(GList *list, gint *len, gint plain_text);
65 gchar *uri_text_from_filelist(GList *list, gint *len, gint plain_text);
66
67
68 #endif