On Fri, Feb 11, 2011 at 11:35 AM, Largo <[email protected]> wrote: > Tim Harper wrote : > >> As seen at the top of the wiki page: >> >> http://www.emacswiki.org/emacs-es/Vimpulse >> >> "Vimpulse extends Viper with Vim features like Visual mode and text objects." >> >> So, in short: "ciw", "ci)", "viw", "V", "C-v" (block select), etc.... > > A list of commands like "ciw" doesn't help me much since I don't know > VIM and I was looking for an answer which would not require reading VIM > docs.
So would it be accurate to restate your question as "what does vim provide over vi"? viper is vi emulation (mostly) vimpulse is vim emulation (more so) Text objects gives the editor primitive knowledge about the structure of your text. In vi, you have "ce, cb, c$, etc" (I'm assuming you're familiar with those commands), they allow you to change to the end of the word, change to the beginning of a word, the change to the end of the line, etc. In vim, you get commands such as “change this word, change inside of these parentheses, delete inside of these parentheses, delete everything including these parentheses, quotes, single quotes, brackets, etc.”. This is what it refers to by “text objects”. It's a little more sophisticated than what you could achieve with VI macros: for example, certainly you can change everything inside of enclosing parentheses by issuing “T(ct)”, and that would work if you were inside of a single parenthetical enclosure. However, what if another set of parentheses is nested inside, such as: (5| + (3 * 5)) vim, with "ci)", would leave you with this: (|) the aforedescribed vi Macro would leave you with this: (5)) I hope that makes sense. In addition to adding several vim features, vimpulse also brings visual mode in most of its vim glory. Press “V” to enter line selection mode, “control-V” to enter column selection mode. You can use the previously described text objects in combination with visual mode, rendering it (in my opinion) far superior to what Viper offers alone. I hope this helps Warmly, Tim _______________________________________________ implementations-list mailing list [email protected] https://lists.ourproject.org/cgi-bin/mailman/listinfo/implementations-list
