From 99ec8a898b7571c07fb322e2365b186df1681687 Mon Sep 17 00:00:00 2001 From: Jesse Luehrs Date: Sun, 12 Feb 2017 16:36:12 -0500 Subject: avoid an allocation on every glyph string draw probably not super meaningful compared to the cost of the cairo operations, but may as well --- src/display.h | 2 ++ 1 file changed, 2 insertions(+) (limited to 'src/display.h') diff --git a/src/display.h b/src/display.h index e4ddc28..79ab068 100644 --- a/src/display.h +++ b/src/display.h @@ -11,6 +11,7 @@ struct runes_display { PangoLayout *layout; cairo_scaled_font_t *scaled_font; PangoGlyph *ascii_glyph_index_cache; + cairo_glyph_t *glyph_buf; int row_visible_offset; @@ -31,6 +32,7 @@ struct runes_display { }; RunesDisplay *runes_display_new(char *font_name); +void runes_display_set_window_size(RunesTerm *t, int row, int col); void runes_display_set_context(RunesTerm *t, cairo_t *cr); void runes_display_draw_screen(RunesTerm *t); void runes_display_draw_cursor(RunesTerm *t); -- cgit v1.2.3-54-g00ecf