A more nuanced approach to Python warnings.
[elinks.git] / src / bookmarks / bookmarks.h
blob55f2d2835c1c8bb64bd856d66d277f08e3093d5f
1 #ifndef EL__BOOKMARKS_BOOKMARKS_H
2 #define EL__BOOKMARKS_BOOKMARKS_H
4 #include "main/module.h"
5 #include "main/object.h"
6 #include "util/lists.h"
8 struct listbox_item;
9 struct terminal;
11 /* Bookmark record structure */
13 struct bookmark {
14 OBJECT_HEAD(struct bookmark);
16 struct bookmark *root;
18 struct listbox_item *box_item;
20 /** @todo Bug 1066: The bookmark::url string should be in UTF-8 too,
21 * but this has not yet been fully implemented. */
22 unsigned char *title; /* UTF-8 title of bookmark */
23 unsigned char *url; /* Location of bookmarked item */
25 LIST_OF(struct bookmark) child;
28 /* Bookmark lists */
30 extern LIST_OF(struct bookmark) bookmarks;
32 /* The bookmarks module */
34 extern struct module bookmarks_module;
36 /* Read/write bookmarks functions */
38 void read_bookmarks(void);
39 void write_bookmarks(void);
41 /* Bookmarks manipulation */
42 void bookmarks_set_dirty(void);
43 void bookmarks_unset_dirty(void);
44 int bookmarks_are_dirty(void);
46 void delete_bookmark(struct bookmark *);
47 struct bookmark *add_bookmark(struct bookmark *, int, unsigned char *, unsigned char *);
48 struct bookmark *add_bookmark_cp(struct bookmark *, int, int,
49 unsigned char *, unsigned char *);
50 struct bookmark *get_bookmark_by_name(struct bookmark *folder,
51 unsigned char *title);
52 struct bookmark *get_bookmark(unsigned char *url);
53 void bookmark_terminal_tabs(struct terminal *term, unsigned char *foldername);
54 unsigned char *get_auto_save_bookmark_foldername_utf8(void);
55 void bookmark_auto_save_tabs(struct terminal *term);
56 int update_bookmark(struct bookmark *, int,
57 unsigned char *, unsigned char *);
58 void open_bookmark_folder(struct session *ses, unsigned char *foldername);
60 #endif