|
|
| Line 15: |
Line 15: |
| |
|
|
|
| |
<pre> |
|
<pre> |
| − |
imap <Backspace> <left><del> |
+ |
imap <Backspace> <Left><del> |
| |
" this will allow me to always use the backspace key in insert mode |
|
" this will allow me to always use the backspace key in insert mode |
| |
|
|
|
| − |
imap <C-j> <Esc>Ji |
+ |
imap <C-j> <Esc>Ji |
| |
" this will allow me to join a line while still in insert mode |
|
" this will allow me to join a line while still in insert mode |
| |
|
|
|
| Line 24: |
Line 24: |
| |
" fold an entire block of code |
|
" fold an entire block of code |
| |
|
|
|
| − |
nnmap ,y <S-v>y |
+ |
nnmap ,y <S-v>y |
| |
" This will select a whole line of text or it will select |
|
" This will select a whole line of text or it will select |
| |
" everything in a fold. |
|
" everything in a fold. |
| |
|
|
|
| − |
map .; v%:s/^/;;;/<CR>:noh<CR> |
+ |
map .; v%:s/^/;;;/<CR>:noh<CR> |
| |
" comments out and entire block of code from paren to paren |
|
" comments out and entire block of code from paren to paren |
| |
|
|
|
| − |
:au BufRead *.lsp :loadview 1<cr> |
+ |
:au BufRead *.lsp :loadview 1<CR> |
| − |
:au BufRead *.LSP :loadview 1<cr> |
+ |
:au BufRead *.LSP :loadview 1<CR> |
| |
" load the first fold view file for the current file |
|
" load the first fold view file for the current file |
| |
|
|
|
| − |
map st :set tw=70<cr>v<S-}>gq<End> |
+ |
map st :set tw=70<CR>v<S-}>gq<End> |
| |
" this will allow you to format an entire block of text |
|
" this will allow you to format an entire block of text |
| |
</pre> |
|
</pre> |
| |
|
|
|
| |
==Comments== |
|
==Comments== |
| − |
Regarding imap <backspace>, you might want to see {{help|'bs'}}. |
+ |
Regarding imap <backspace>, you might want to see {{help|'bs'}}. |
| |
|
|
|
| |
---- |
|
---- |
| |
You can also do |
|
You can also do |
| − |
imap <C-j> <Esc>Ji |
+ |
imap <C-j> <Esc>Ji |
| |
|
|
|
| |
this way |
|
this way |
| − |
imap <C-j> <C-o>J |
+ |
imap <C-j> <C-o>J |
| |
|
|
|
| |
Then you do not leave insert mode. |
|
Then you do not leave insert mode. |
| |
You might also consider using |
|
You might also consider using |
| − |
inoremap <C-j> <C-o>J |
+ |
inoremap <C-j> <C-o>J |
| |
|
|
|
| |
{{help|i_CTRL-O}} |
|
{{help|i_CTRL-O}} |
Here are tips for use when programming in Lisp and Visual lisp for AutoCAD.
imap <Backspace> <Left><del>
" this will allow me to always use the backspace key in insert mode
imap <C-j> <Esc>Ji
" this will allow me to join a line while still in insert mode
map .f v%zf
" fold an entire block of code
nnmap ,y <S-v>y
" This will select a whole line of text or it will select
" everything in a fold.
map .; v%:s/^/;;;/<CR>:noh<CR>
" comments out and entire block of code from paren to paren
:au BufRead *.lsp :loadview 1<CR>
:au BufRead *.LSP :loadview 1<CR>
" load the first fold view file for the current file
map st :set tw=70<CR>v<S-}>gq<End>
" this will allow you to format an entire block of text
Regarding imap <backspace>, you might want to see :help 'bs'.
You can also do
imap <C-j> <Esc>Ji
this way
imap <C-j> <C-o>J
Then you do not leave insert mode.
You might also consider using
inoremap <C-j> <C-o>J
:help i_CTRL-O
So the tip should be changed for this:
set backspace=indent,eol,start
" allow backspacing over everything in insert mode