On Monday, March 14, 2016 at 10:43:15 AM UTC-5, Yang Luo wrote:
> I found many vim configure have this script. I don't understand why do this.
> " Don't use Ex mode, use Q for formatting
> map Q gq
There are two parts to answer:
1) What does the Q do (this is the reference in the comment "Don't use ex mode")
Q in normal mode switches vim to "Ex mode" an interface the predates vi (the "visual" editor). It's an entirely command line driven mode, with no screen editor functions. Using the CmdLine you can search help for this:
:help Q
Which will pull up some information about this.
2) What does gq do.
gq is a formatting command. It reflows and wraps the given text object (defaults to a single line) to the textwidth set width.
Again, you can find out more with:
:help gq
--
--
You received this message from the "vim_use" maillist.
Do not top-post! Type your reply below the text you are replying to.
For more information, visit http://www.vim.org/maillist.php
---
You received this message because you are subscribed to the Google Groups "vim_use" group.
To unsubscribe from this group and stop receiving emails from it, send an email to vim_use+unsubscribe@googlegroups.com.
For more options, visit https://groups.google.com/d/optout.
Thursday, March 17, 2016
Subscribe to:
Post Comments (Atom)
No comments:
Post a Comment