Converted README to markdown
[rox-filer.git] / ROX-Filer / src / xtypes.h
blob8ad5cf4c3df440ede399d77d7cb834b2d6d67e2e
1 /*
2 * ROX-Filer, filer for the ROX desktop project
3 * By Thomas Leonard, <tal197@users.sourceforge.net>.
5 * Extended filesystem attribute support, particularly for MIME types
6 */
8 #ifndef _XTYPES_H
9 #define _XTYPES_H
11 /* Know attribute names */
12 #define XATTR_MIME_TYPE "user.mime_type"
13 #define XATTR_HIDDEN "user.hidden"
15 /* If set, do not use extended attributes */
16 extern Option o_xattr_ignore; /* Set up in xattr_init() */
18 /* Prototypes */
19 void xattr_init(void);
21 /* path may be NULL to test for support in libc */
22 int xattr_supported(const char *path);
24 int xattr_have(const char *path);
25 gchar *xattr_get(const char *path, const char *attr, int *len);
26 int xattr_set(const char *path, const char *attr,
27 const char *value, int value_len);
29 MIME_type *xtype_get(const char *path);
30 int xtype_set(const char *path, const MIME_type *type);
32 #endif