本文介绍了在vi中快速缩进多行的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧! 问题描述 它应该是微不足道的,甚至可能在帮助中,但我不知道如何导航。如何在vi中快速缩进多行?It should be trivial, and it might even be in the help, but I can't figure out how to navigate it. How do I indent multiple lines quickly in vi?推荐答案使用命令。要缩进五行,请 。要标记一行并缩进, 可以缩进三行(仅Vim) 。要缩进大括号块,请将光标放在大括号之一上并使用 或在块内的任何地方使用 i 。Use the command. To indent five lines, . To mark a block of lines and indent it, to indent three lines (Vim only). To indent a curly-braces block, put your cursor on one of the curly braces and use or from anywhere inside block use .如果要在周围复制文本块,并且需要在其中对齐块的缩进它的新位置,请使用 ,而不仅仅是。这会将粘贴的块与周围的文本对齐。If you’re copying blocks of text around and need to align the indent of a block in its new location, use instead of just . This aligns the pasted block with the surrounding text.此外, shiftwidth 设置可让您控制要缩进多少空格。Also, the shiftwidth setting allows you to control how many spaces to indent. 这篇关于在vi中快速缩进多行的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持! 09-17 18:02