font: turn rasterization options into a struct, add thicken

This commit is contained in:
Mitchell Hashimoto
2023-07-01 09:55:19 -07:00
parent e99376cac1
commit 3795cd6c2d
9 changed files with 63 additions and 39 deletions

View File

@@ -991,7 +991,7 @@ fn addCursor(self: *OpenGL, screen: *terminal.Screen) void {
self.alloc,
font.sprite_index,
@intFromEnum(sprite),
null,
.{},
) catch |err| {
log.warn("error rendering cursor glyph err={}", .{err});
return;
@@ -1144,7 +1144,7 @@ pub fn updateCell(
self.alloc,
shaper_run.font_index,
shaper_cell.glyph_index,
@intFromFloat(@ceil(self.cell_size.height)),
.{ .max_height = @intFromFloat(@ceil(self.cell_size.height)) },
);
// If we're rendering a color font, we use the color atlas
@@ -1190,7 +1190,7 @@ pub fn updateCell(
self.alloc,
font.sprite_index,
@intFromEnum(sprite),
null,
.{},
);
const color = if (cell.attrs.underline_color) cell.underline_fg else colors.fg;