Mercurial > geeqie.yaz
annotate src/filelist.h @ 454:57459cf0952c
Prefix editor entries in the main menu with numbers.
It allows Alt+E+number as shortcut to start an editor.
author | zas_ |
---|---|
date | Sun, 20 Apr 2008 22:29:23 +0000 |
parents | ddabc4873a3f |
children | 48c8e49b571c |
rev | line source |
---|---|
9 | 1 /* |
196 | 2 * Geeqie |
9 | 3 * (C) 2004 John Ellis |
4 * | |
5 * Author: John Ellis | |
6 * | |
7 * This software is released under the GNU General Public License (GNU GPL). | |
8 * Please read the included file COPYING for more information. | |
9 * This software comes with no warranty of any kind, use at your own risk! | |
10 */ | |
11 | |
12 | |
13 #ifndef FILELIST_H | |
14 #define FILELIST_H | |
15 | |
16 | |
17 typedef struct _FilterEntry FilterEntry; | |
18 struct _FilterEntry { | |
19 gchar *key; | |
20 gchar *description; | |
21 gchar *extensions; | |
212
c7021159079d
differentiate among normal image, raw image and metadata
nadvornik
parents:
196
diff
changeset
|
22 FileFormatClass file_class; |
9 | 23 gint enabled; |
24 }; | |
25 | |
26 /* you can change, but not add or remove entries from the returned list */ | |
27 GList *filter_get_list(void); | |
28 void filter_remove_entry(FilterEntry *fe); | |
29 | |
212
c7021159079d
differentiate among normal image, raw image and metadata
nadvornik
parents:
196
diff
changeset
|
30 void filter_add(const gchar *key, const gchar *description, const gchar *extensions, FileFormatClass file_class, gint enabled); |
c7021159079d
differentiate among normal image, raw image and metadata
nadvornik
parents:
196
diff
changeset
|
31 void filter_add_unique(const gchar *description, const gchar *extensions, FileFormatClass file_class, gint enabled); |
9 | 32 void filter_add_defaults(void); |
33 void filter_reset(void); | |
34 void filter_rebuild(void); | |
147
b2266996fa83
added possibility to specify prefered file type for external commands
nadvornik
parents:
145
diff
changeset
|
35 GList *filter_to_list(const gchar *extensions); |
9 | 36 |
37 gint filter_name_exists(const gchar *name); | |
212
c7021159079d
differentiate among normal image, raw image and metadata
nadvornik
parents:
196
diff
changeset
|
38 gint filter_file_class(const gchar *name, FileFormatClass file_class); |
9 | 39 |
276 | 40 void filter_write_list(SecureSaveInfo *ssi); |
9 | 41 void filter_parse(const gchar *text); |
42 | |
170
9a56e3d13e67
basic sidecar files configuration via preferences dialog
nadvornik
parents:
167
diff
changeset
|
43 void sidecar_ext_parse(const gchar *text, gint quoted); |
276 | 44 void sidecar_ext_write(SecureSaveInfo *ssi); |
442 | 45 char *sidecar_ext_to_string(); |
145
8be2cc687304
fixed grouping sidecar files and made it configurable via config file
nadvornik
parents:
143
diff
changeset
|
46 void sidecar_ext_add_defaults(); |
8be2cc687304
fixed grouping sidecar files and made it configurable via config file
nadvornik
parents:
143
diff
changeset
|
47 |
9 | 48 gint ishidden(const gchar *name); |
49 | |
50 | |
51 GList *path_list_filter(GList *list, gint is_dir_list); | |
52 | |
53 GList *path_list_sort(GList *list); | |
54 GList *path_list_recursive(const gchar *path); | |
55 | |
56 gchar *text_from_size(gint64 size); | |
57 gchar *text_from_size_abrev(gint64 size); | |
58 const gchar *text_from_time(time_t t); | |
59 | |
60 /* this expects a utf-8 path */ | |
138 | 61 FileData *file_data_new_simple(const gchar *path_utf8); |
145
8be2cc687304
fixed grouping sidecar files and made it configurable via config file
nadvornik
parents:
143
diff
changeset
|
62 |
138 | 63 FileData *file_data_ref(FileData *fd); |
64 void file_data_unref(FileData *fd); | |
9 | 65 |
241 | 66 void file_data_do_change(FileData *fd); |
143
0d1bf3ac6cd8
improved FileDataChangeInfo structure, check for another file operation in progress
nadvornik
parents:
139
diff
changeset
|
67 gboolean file_data_add_change_info(FileData *fd, FileDataChangeType type, const gchar *src, const gchar *dest); |
138 | 68 void file_data_change_info_free(FileDataChangeInfo *fdci, FileData *fd); |
69 | |
139 | 70 gchar *sidecar_file_data_list_to_string(FileData *fd); |
71 | |
138 | 72 gint filelist_sort_compare_filedata(FileData *fa, FileData *fb); |
167 | 73 gint filelist_sort_compare_filedata_full(FileData *fa, FileData *fb, SortType method, gint ascend); |
9 | 74 GList *filelist_sort(GList *list, SortType method, gint ascend); |
75 GList *filelist_insert_sort(GList *list, FileData *fd, SortType method, gint ascend); | |
138 | 76 GList *filelist_sort_full(GList *list, SortType method, gint ascend, GCompareFunc cb); |
77 GList *filelist_insert_sort_full(GList *list, void *data, SortType method, gint ascend, GCompareFunc cb); | |
9 | 78 |
79 gint filelist_read(const gchar *path, GList **files, GList **dirs); | |
138 | 80 gint filelist_read_lstat(const gchar *path, GList **files, GList **dirs); |
9 | 81 void filelist_free(GList *list); |
138 | 82 GList *filelist_copy(GList *list); |
83 GList *filelist_from_path_list(GList *list); | |
84 GList *filelist_to_path_list(GList *list); | |
85 | |
86 GList *filelist_filter(GList *list, gint is_dir_list); | |
87 | |
88 GList *filelist_sort_path(GList *list); | |
89 GList *filelist_recursive(const gchar *path); | |
9 | 90 |
91 #endif |