sponsor Vim development Vim logo Vim Book Ad

ExpandBackspace : Make backspace eat white space to the last tabstop

 script karma  Rating 0/0, Downloaded by 143    Comments, bugs, improvements  Vim wiki

created by
Yury Shvedov
script type
This plugin is based on GreedyBackspace #1390 plugin.

This plugin will cause your backspace key to delete all the white spaces to the previous tabstop. For example, if you typed "printf("Hello World!");      " and then hit backspace, you'd only have "printf("Hello World!");  ". Its behavior is similar to softtabstop, but it doesn't care of how do you put white spaces - with tab key or spacebar.

This plugin will cause your delete key to delete &tabstop or less white spaces after character. For example, if you typed "printf("Hello World!");      " and then twice hit hit left and then delete, you'd only have "printf("Hello World!");    ".

This plugin works only when expandtab is enabled. You are free to set or unset this option. Plugin will switch on or off accordingly.
install details
Source the script from your vimrc or just place it in your plugin directory.

rate this script Life Changing Helpful Unfulfilling 
script versions (upload new version)

Click on the package to download.

package script version date Vim version user release notes
ExpandBackspace.vim 0.6-1 2016-12-07 7.0 Yury Shvedov Fix buffer reseting
ExpandBackspace.vim 0.6 2016-12-06 7.0 Yury Shvedov Initial upload
ip used for rating:

If you have questions or remarks about this site, visit the vimonline development pages. Please use this site responsibly.
Questions about Vim should go to the maillist. Help Bram help Uganda.
SourceForge.net Logo