applidium / Vim

Port of the Vim text editor to the iOS
https://applidium.com/en
533 stars 100 forks source link

map <cr> not working #10

Open cecamp opened 12 years ago

cecamp commented 12 years ago

Netrw uses nnoremap ... to select files and open directories. I've tested some maps; they do appear to work, but this one doesn't.

The ipad vim app does have netrw included (try :e . to see). Pressing the while atop a file or directory should open it, but isn't.

Ecco commented 12 years ago

I think you accidentally a word ;-)

cecamp commented 12 years ago

Romain Goyet wrote:

I think you accidentally a word ;-)

You correct! :)

Chip

(strictly speaking, it wasn't a word, for those who may be lurking: its

)
javiertejero commented 12 years ago

I had the same issue. And I realised that on this VIM version there is no keyboard equivalent for "Carriage return". Instead, they all map to "Line feed"... (even if you manage to type CTRL+V CTRL+M, it just issues a line feed).

The good news is that there seems to be an easy workaround. Just remap <LF> to <CR> as follows:

map <lf> <cr>

As a bonus: Since many Control+<key> will not work, you can also remap them using another key, e.g. to remap CTRL+W (to run afterwards multiple :wincmd related commands)

map cw <CTRL-W>

Please let me know if you find any problem related to using this simple workaround.

cecamp commented 12 years ago

javiertejero wrote:

I had the same issue. And I realised that on this VIM version there is no keyboard equivalent for "Carriage return". Instead, they all map to "Line feed"... (even if you manage to type CTRL+V CTRL+M, it just issues a line feed).

The good news is that there seems to be an easy workaround. Just remap <LF> to <CR> as follows:

map<lf>  <cr>

As a bonus: Since many Control+<key> will not work, you can also remap them using another key, e.g. to remap CTRL+W (to run afterwards multiple :wincmd related commands)

map cw<CTRL-W>

Please let me know if you find any problem related to using this simple workaround.

Thank you -- I didn't think about mapping. It does seem to work! Now I am interested again; I'll have to find some way to download my .vimrc, .vim/*, and plugins and whatnot to my iPad.

Regards, Chip Campbell

javiertejero commented 12 years ago

Using Vimball is the easier way I found for multiple file insertion into your VIM for IOS (iTunes "file sharing" does not allow uploading multiple files at once AFAIK, yet).

Vimball system works well in IOS, and it's really easy and very handy. You might know it already, don't you? (as per your name you do and quite well)

Using it I've been able to move several hundreds of files with minimal effort.

Thanks and regards, Javier