oni icon indicating copy to clipboard operation
oni copied to clipboard

Ctral+A doesn't work

Open scienceasdf opened this issue 8 years ago • 5 comments

I configure the vim file so that it can behave mswin-like. Copy, paste and cut seem to work. But is not working for selecting all. The relevant configuration is below:

noremap <C-A> gggH<C-O>G  
inoremap <C-A> <C-O>gg<C-O>gH<C-O>G  
cnoremap <C-A> <C-C>gggH<C-O>G  
onoremap <C-A> <C-C>gggH<C-O>G  
snoremap <C-A> <C-C>gggH<C-O>G  
xnoremap <C-A> <C-C>ggVG  
   

scienceasdf avatar Apr 14 '18 03:04 scienceasdf

Hello and welcome to the Oni repository! Thanks for opening your first issue here. To help us out, please make sure to include as much detail as possible - including screenshots and logs, if possible.

oni-bot avatar Apr 14 '18 03:04 oni-bot

Just tried nnoremap <c-a> ggVG and it worked. Oni: v0.3.2 OS: Ubuntu 17.10

Can you try a simpler binding, just to verify that <C-A> is executed?

TalAmuyal avatar Apr 14 '18 06:04 TalAmuyal

Ok, solved it. Append the init.vim with runtime mswin.vim

scienceasdf avatar Apr 15 '18 12:04 scienceasdf

Is this config something necessary to keep compatibility with windows?

If that's the case we should add it to the installation instructions or to the default init.vim with a check for windows.

badosu avatar Apr 15 '18 21:04 badosu

Is this config something necessary to keep compatibility with windows?

It doesn't seem to be:

https://github.com/neovim/neovim/blob/6e9f329d051cf6bf6d83dbe5335f86a1752ec45a/runtime/mswin.vim

Looks like a lot of default options to make N/vim closer to other Windows apps. I've been using Oni fine for however long on Windows and haven't noticed anything wrong, but I did learn Vim on Linux.

That said, it seem very opinionated, so I wouldn't think we'd want it enabled by default. Ie rebinding Ctrl-v to me would break my muscle memory for visual block mode etc. I think its a personal thing if you want vim to behave more like other Windows apps and so on.

CrossR avatar Apr 15 '18 21:04 CrossR