summaryrefslogtreecommitdiff
path: root/helix-term/src/ui/editor.rs
diff options
context:
space:
mode:
Diffstat (limited to 'helix-term/src/ui/editor.rs')
-rw-r--r--helix-term/src/ui/editor.rs8
1 files changed, 3 insertions, 5 deletions
diff --git a/helix-term/src/ui/editor.rs b/helix-term/src/ui/editor.rs
index 5913df29..95587b4c 100644
--- a/helix-term/src/ui/editor.rs
+++ b/helix-term/src/ui/editor.rs
@@ -26,6 +26,7 @@ use tui::{
buffer::Buffer as Surface,
layout::Rect,
style::{Color, Modifier, Style},
+ terminal::CursorKind,
};
pub struct EditorView {
@@ -739,15 +740,12 @@ impl Component for EditorView {
}
}
- fn cursor_position(&self, area: Rect, editor: &Editor) -> Option<Position> {
+ fn cursor(&self, area: Rect, editor: &Editor) -> (Option<Position>, CursorKind) {
// match view.doc.mode() {
// Mode::Insert => write!(stdout, "\x1B[6 q"),
// mode => write!(stdout, "\x1B[2 q"),
// };
- // return editor.cursor_position()
-
- // It's easier to just not render the cursor and use selection rendering instead.
- None
+ editor.cursor()
}
}