mirror of
https://github.com/kovidgoyal/kitty
synced 2026-07-25 17:52:02 +02:00
fix build with old compiler
This commit is contained in:
@@ -1272,7 +1272,8 @@ commit(Canvas *self, Edge lines, bool solid) {
|
|||||||
}
|
}
|
||||||
|
|
||||||
// thin and fat line levels
|
// thin and fat line levels
|
||||||
static const uint t = 1, f = 3;
|
#define t 1u
|
||||||
|
#define f 3u
|
||||||
|
|
||||||
static void
|
static void
|
||||||
corner(Canvas *self, uint hlevel, uint vlevel, Corner which) {
|
corner(Canvas *self, uint hlevel, uint vlevel, Corner which) {
|
||||||
@@ -1799,4 +1800,6 @@ END_ALLOW_CASE_RANGE
|
|||||||
#undef C
|
#undef C
|
||||||
#undef S
|
#undef S
|
||||||
#undef SB
|
#undef SB
|
||||||
|
#undef t
|
||||||
|
#undef f
|
||||||
}
|
}
|
||||||
|
|||||||
@@ -841,7 +841,7 @@ static bool
|
|||||||
render_glyph_with_cairo(Face *self, int glyph_id, ProcessedBitmap *ans, unsigned width, unsigned height, ARGB32 fg, unsigned cell_baseline) {
|
render_glyph_with_cairo(Face *self, int glyph_id, ProcessedBitmap *ans, unsigned width, unsigned height, ARGB32 fg, unsigned cell_baseline) {
|
||||||
cairo_glyph_t g = {.index=glyph_id};
|
cairo_glyph_t g = {.index=glyph_id};
|
||||||
cairo_text_extents_t bb = {0};
|
cairo_text_extents_t bb = {0};
|
||||||
if (!ensure_cairo_resources(self, MAX(width, 256), MAX(height, 256))) return false;
|
if (!ensure_cairo_resources(self, MAX(width, 256u), MAX(height, 256u))) return false;
|
||||||
set_cairo_font_size(self, self->metrics.size_in_pts);
|
set_cairo_font_size(self, self->metrics.size_in_pts);
|
||||||
cairo_scaled_font_t *sf = cairo_get_scaled_font(self->cairo.cr);
|
cairo_scaled_font_t *sf = cairo_get_scaled_font(self->cairo.cr);
|
||||||
cairo_scaled_font_glyph_extents(sf, &g, 1, &bb);
|
cairo_scaled_font_glyph_extents(sf, &g, 1, &bb);
|
||||||
|
|||||||
Reference in New Issue
Block a user