mirror of
https://codeberg.org/dnkl/foot.git
synced 2026-02-05 04:06:08 -05:00
render: minor optimization
Don't instantiate a pixman color unnecessarily when drawing a block cursor.
This commit is contained in:
parent
80aef9b6af
commit
9b6d0cfcd1
1 changed files with 1 additions and 1 deletions
2
render.c
2
render.c
|
|
@ -215,7 +215,7 @@ render_cell(struct terminal *term, pixman_image_t *pix,
|
|||
&(pixman_rectangle16_t){x, y, cell_cols * width, height});
|
||||
|
||||
/* Non-block cursors */
|
||||
if (has_cursor) {
|
||||
if (has_cursor && !block_cursor) {
|
||||
pixman_color_t cursor_color = term->cursor_color.text >> 31
|
||||
? color_hex_to_pixman(term->cursor_color.cursor)
|
||||
: color_hex_to_pixman(_fg);
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue