summaryrefslogtreecommitdiff
path: root/buffer.c
diff options
context:
space:
mode:
authorLeo Tenenbaum <pommicket@gmail.com>2021-02-28 21:46:18 -0500
committerLeo Tenenbaum <pommicket@gmail.com>2021-02-28 21:46:18 -0500
commit9d9993607c9093bd59a02138f5e51f1c678e17e9 (patch)
treeb26210dc32e96409e029488ad62309699919a5bf /buffer.c
parentd00c3247691c2f30214bcfeffb1830d725a173b9 (diff)
fix find highlighting when cursor is on same line
Diffstat (limited to 'buffer.c')
-rw-r--r--buffer.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/buffer.c b/buffer.c
index 54931ce..a3d9c51 100644
--- a/buffer.c
+++ b/buffer.c
@@ -2167,7 +2167,7 @@ void buffer_render(TextBuffer *buffer, Rect r) {
// the rectangle that the cursor is rendered as
Rect cursor_rect = rect(cursor_display_pos, V2(settings->cursor_width, char_height));
- { // highlight line cursor is on
+ if (!buffer->is_line_buffer) { // highlight line cursor is on
Rect hl_rect = rect(V2(x1, cursor_display_pos.y), V2(x2-x1-1, char_height));
buffer_clip_rect(buffer, &hl_rect);
gl_geometry_rect(hl_rect, colors[COLOR_CURSOR_LINE_BG]);