r1601: Turned on more compiler warnings, and fixed some minor issues it threw up.
[rox-filer.git] / ROX-Filer / src / support.h
blob0857a4224ea6e0995f96b20e80cabb85b496171b
1 /*
2 * $Id$
4 * ROX-Filer, filer for the ROX desktop project
5 * By Thomas Leonard, <tal197@users.sourceforge.net>.
6 */
8 #ifndef _SUPPORT_H
9 #define _SUPPORT_H
11 #define PRETTY_SIZE_LIMIT 10000
12 #define TIME_FORMAT "%T %d %b %Y"
14 #include <glib-object.h>
16 XMLwrapper *xml_cache_load(const gchar *pathname);
17 int save_xml_file(xmlDocPtr doc, const gchar *filename);
18 xmlDocPtr soap_new(xmlNodePtr *ret_body);
19 char *pathdup(const char *path);
20 GString *make_path(const char *dir, const char *leaf);
21 const char *our_host_name(void);
22 const char *our_host_name_for_dnd(void);
23 void debug_free_string(void *data);
24 const char *user_name(uid_t uid);
25 const char *group_name(gid_t gid);
26 char *format_size(off_t size);
27 char *format_size_aligned(off_t size);
28 gchar *format_double_size(double size);
29 char *fork_exec_wait(const char **argv);
30 char *pretty_permissions(mode_t m);
31 gint applicable(uid_t uid, gid_t gid);
32 const char *get_local_path(const char *uri);
33 void close_on_exec(int fd, gboolean close);
34 void set_blocking(int fd, gboolean blocking);
35 char *pretty_time(time_t *time);
36 guchar *copy_file(const guchar *from, const guchar *to);
37 guchar *shell_escape(const guchar *word);
38 gboolean is_sub_dir(const char *sub, const char *parent);
39 gboolean in_list(const guchar *item, const guchar *list);
40 GPtrArray *split_path(const guchar *path);
41 guchar *get_relative_path(const guchar *from, const guchar *to);
42 int text_to_boolean(const char *text, int defvalue);
43 char *readlink_dup(const char *path);
44 gchar *to_utf8(const gchar *src);
45 gchar *from_utf8(const gchar *src);
46 char *md5_hash(const char *message);
47 gchar *expand_path(const gchar *path);
49 #endif /* _SUPPORT_H */