vim visual block (#2849)
Release notes: - vim: add Visual Block mode ([#984](https://github.com/zed-industries/community/issues/984)), ([#1415](https://github.com/zed-industries/community/issues/1415)). - vim: add support for `a<object>` and `i<object>` in visual modes - vim: fix scroll shortcuts (`ctrl-{f,b,d,u,e,y}`) in visual modes - allow `shift-enter` to type a newline.
This commit is contained in:
commit
d1aa82bb48
28 changed files with 946 additions and 321 deletions
|
@ -76,12 +76,12 @@ impl<'a> VimTestContext<'a> {
|
|||
}
|
||||
|
||||
pub fn mode(&mut self) -> Mode {
|
||||
self.cx.read(|cx| cx.global::<Vim>().state.mode)
|
||||
self.cx.read(|cx| cx.global::<Vim>().state().mode)
|
||||
}
|
||||
|
||||
pub fn active_operator(&mut self) -> Option<Operator> {
|
||||
self.cx
|
||||
.read(|cx| cx.global::<Vim>().state.operator_stack.last().copied())
|
||||
.read(|cx| cx.global::<Vim>().state().operator_stack.last().copied())
|
||||
}
|
||||
|
||||
pub fn set_state(&mut self, text: &str, mode: Mode) -> ContextHandle {
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue