You are not logged in.
Hello everyone!
I am trying to find the way to create multiple lines like:
pano01
pano02
pano03
etc...
This can be achieved perfectly using macros, but I have a problem with the increase number command.
When I write pano01 and press Ctrl+A several times, it jumps from pano07 to pano010. It's ok when I try with pano1, pano2, pano3, etc.. but I really need to use the number 0.
Any ideas of why this behaviour and a solution?
Thank you very much in advance.
EDIT:
I just need to type the following:
:set nrformat=alpha
Explanation why in :help ctrl-a and :help nrformat
Last edited by rafaelgp (2010-05-19 17:02:46)
Offline
vimhelp
The CTRL-A and CTRL-X commands work for (signed) decimal numbers, unsigned
octal and hexadecimal numbers and alphabetic characters. This depends on the
'nrformats' option.
- When 'nrformats' includes "octal", Vim considers numbers starting with a '0'
to be octal, unless the number includes a '8' or '9'. Other numbers are
decimal and may have a preceding minus sign.
And I recommend using visincr from Charles E. Campbell http://vim.sourceforge.net/scripts/scri … ipt_id=670
Offline
And it's the same for 017 - next is 020. Some octal stuff?
Edit: OK, so I was right about the octal stuff :-)
Last edited by karol (2010-05-19 17:03:13)
Offline