diff options
author | Kartik K. Agaram <vc@akkartik.com> | 2023-06-07 21:57:39 -0700 |
---|---|---|
committer | Kartik K. Agaram <vc@akkartik.com> | 2023-06-07 21:57:39 -0700 |
commit | 037fb843c86f34b640d32c9776971f8aa5e448e0 (patch) | |
tree | 284190934663d96d17adc004bf6bcb858074c1d1 /text.lua | |
parent | a9c68776db3dde49e090f223ec098f04c62b588a (diff) | |
download | view.love-037fb843c86f34b640d32c9776971f8aa5e448e0.tar.gz |
stop showing the cursor
Diffstat (limited to 'text.lua')
-rw-r--r-- | text.lua | 7 |
1 files changed, 6 insertions, 1 deletions
diff --git a/text.lua b/text.lua index f25c7b3..63c559d 100644 --- a/text.lua +++ b/text.lua @@ -41,7 +41,7 @@ function Text.draw(State, line_index, y, startpos) love.graphics.print(State.search_term, State.left+lo_px,y) end else - Text.draw_cursor(State, State.left+Text.x(screen_line, State.cursor1.pos-pos+1), y) + Text.pretend_draw_cursor(State, State.left+Text.x(screen_line, State.cursor1.pos-pos+1), y) end end end @@ -75,6 +75,11 @@ function Text.draw_cursor(State, x, y) State.cursor_y = y+State.line_height end +function Text.pretend_draw_cursor(State, x, y) + State.cursor_x = x + State.cursor_y = y+State.line_height +end + function Text.populate_screen_line_starting_pos(State, line_index) local line = State.lines[line_index] local line_cache = State.line_cache[line_index] |