diff options
author | Drew DeVault <sir@cmpwn.com> | 2015-11-29 15:27:28 -0500 |
---|---|---|
committer | Drew DeVault <sir@cmpwn.com> | 2015-11-29 15:27:28 -0500 |
commit | 82d464bb90af7fed57a36aacc2dce22994849bac (patch) | |
tree | 471b8eba3fb838115b163980b558cb151c6dbefc /include | |
parent | Only strip comments at the start of a line (diff) | |
download | sway-82d464bb90af7fed57a36aacc2dce22994849bac.tar.gz sway-82d464bb90af7fed57a36aacc2dce22994849bac.tar.zst sway-82d464bb90af7fed57a36aacc2dce22994849bac.zip |
Add text rendering support to wayland clients
Diffstat (limited to 'include')
-rw-r--r-- | include/client/pango.h | 12 | ||||
-rw-r--r-- | include/client/window.h | 1 |
2 files changed, 13 insertions, 0 deletions
diff --git a/include/client/pango.h b/include/client/pango.h new file mode 100644 index 00000000..e25a2211 --- /dev/null +++ b/include/client/pango.h | |||
@@ -0,0 +1,12 @@ | |||
1 | #ifndef _SWAY_CLIENT_PANGO_H | ||
2 | #define _SWAY_CLIENT_PANGO_H | ||
3 | |||
4 | #include "client/window.h" | ||
5 | #include "client/buffer.h" | ||
6 | #include <stdarg.h> | ||
7 | |||
8 | PangoLayout *get_pango_layout(struct window *window, struct buffer *buffer, const char *text); | ||
9 | void get_text_size(struct window *window, int *width, int *height, const char *fmt, ...); | ||
10 | void pango_printf(struct window *window, const char *fmt, ...); | ||
11 | |||
12 | #endif | ||
diff --git a/include/client/window.h b/include/client/window.h index af954003..eff9032d 100644 --- a/include/client/window.h +++ b/include/client/window.h | |||
@@ -34,6 +34,7 @@ struct window { | |||
34 | struct wl_callback *frame_cb; | 34 | struct wl_callback *frame_cb; |
35 | struct cursor cursor; | 35 | struct cursor cursor; |
36 | uint32_t width, height; | 36 | uint32_t width, height; |
37 | char *font; | ||
37 | cairo_t *cairo; | 38 | cairo_t *cairo; |
38 | }; | 39 | }; |
39 | 40 | ||