GitHub - kana/vim-textobj-function: Vim plugin: Text objects for functions
source link: https://github.com/kana/vim-textobj-function
Go to the source link to view the article. You can view the picture content, updated content and better typesetting reading experience. If the link is broken, please click the button below to view the snapshot at that time.
README.md
vim-textobj-function
vim-textobj-function is a Vim plugin to text objects for functions. You can
directly target a function (af
) or the code inside a function (if
).
For example,
daf
to Delete A Function, andvif
to Visually select the code Inside a Function.
You can also use aF
to target a function with leading or trailing blank
lines like ap
, or use iF
to target just a function like ip
.
For example,
yaF
to Yank A Function with leading or trailing blank lines, andviF
to visually select a function without leading or trailing blank lines.
The syntax of a "function" is varied for each language. So that you have to tell the syntax of a function to vim-textobj-function before editing. By default, the following languages are supported:
- C language
- Java
- Vim script (including vim-vspec-specific syntax)
To support new languages, see:
Recommend
About Joyk
Aggregate valuable and interesting links.
Joyk means Joy of geeK