]> git.decadent.org.uk Git - ion3.git/blob - ioncore/names.h
57dd5aae8dc4812b43ff0f658979fb93a467452c
[ion3.git] / ioncore / names.h
1 /*
2  * ion/ioncore/names.h
3  *
4  * Copyright (c) Tuomo Valkonen 1999-2007. 
5  *
6  * Ion is free software; you can redistribute it and/or modify it under
7  * the terms of the GNU Lesser General Public License as published by
8  * the Free Software Foundation; either version 2.1 of the License, or
9  * (at your option) any later version.
10  */
11
12 #ifndef ION_IONCORE_NAMES_H
13 #define ION_IONCORE_NAMES_H
14
15 #include "region.h"
16 #include "clientwin.h"
17 #include "gr.h"
18 #include <libextl/extl.h>
19
20
21 typedef struct{
22     struct rb_node *rb;
23     bool initialised;
24 } WNamespace;
25
26
27 extern WNamespace ioncore_internal_ns;
28 extern WNamespace ioncore_clientwin_ns;
29
30
31 extern bool region_register(WRegion *reg);
32 extern bool region_set_name(WRegion *reg, const char *name);
33 extern bool region_set_name_exact(WRegion *reg, const char *name);
34
35 extern bool clientwin_register(WClientWin *cwin);
36 extern bool clientwin_set_name(WClientWin *cwin, const char *name);
37
38 extern void region_unregister(WRegion *reg);
39 extern void region_do_unuse_name(WRegion *reg, bool insert_unnamed);
40
41 extern const char *region_name(WRegion *reg);
42 DYNFUN const char *region_displayname(WRegion *reg);
43
44 extern char *region_make_label(WRegion *reg, int maxw, GrBrush *brush);
45
46 extern bool ioncore_region_i(ExtlFn fn, const char *typenam);
47 extern bool ioncore_clientwin_i(ExtlFn fn);
48 extern WRegion *ioncore_lookup_region(const char *cname, const char *typenam);
49 extern WClientWin *ioncore_lookup_clientwin(const char *cname);
50
51 #endif /* ION_IONCORE_NAMES_H */