aboutsummaryrefslogtreecommitdiff
path: root/helix-view/src/document.rs
diff options
context:
space:
mode:
authorBlaž Hrastnik2022-09-01 07:14:38 +0000
committerBlaž Hrastnik2022-09-01 07:14:38 +0000
commit5c2b77b41fadd0e65e02455d36d8509f622bc520 (patch)
tree57bb35e6cb6e9c0cc55237cb02d3a409203f8abc /helix-view/src/document.rs
parent10d9355b340f65ba534c66772e9d930188ed0a1b (diff)
Make mode editor-wide rather than per-document
Diffstat (limited to 'helix-view/src/document.rs')
-rw-r--r--helix-view/src/document.rs9
1 files changed, 0 insertions, 9 deletions
diff --git a/helix-view/src/document.rs b/helix-view/src/document.rs
index b2a66415..3c406f8b 100644
--- a/helix-view/src/document.rs
+++ b/helix-view/src/document.rs
@@ -90,8 +90,6 @@ pub struct Document {
path: Option<PathBuf>,
encoding: &'static encoding::Encoding,
- /// Current editing mode.
- pub mode: Mode,
pub restore_cursor: bool,
/// Current indent style.
@@ -133,7 +131,6 @@ impl fmt::Debug for Document {
.field("selections", &self.selections)
.field("path", &self.path)
.field("encoding", &self.encoding)
- .field("mode", &self.mode)
.field("restore_cursor", &self.restore_cursor)
.field("syntax", &self.syntax)
.field("language", &self.language)
@@ -349,7 +346,6 @@ impl Document {
selections: HashMap::default(),
indent_style: DEFAULT_INDENT,
line_ending: DEFAULT_LINE_ENDING,
- mode: Mode::Normal,
restore_cursor: false,
syntax: None,
language: None,
@@ -925,11 +921,6 @@ impl Document {
self.last_saved_revision = current_revision;
}
- /// Current editing mode for the [`Document`].
- pub fn mode(&self) -> Mode {
- self.mode
- }
-
/// Corresponding language scope name. Usually `source.<lang>`.
pub fn language_scope(&self) -> Option<&str> {
self.language