sponsor Vim development Vim logo Vim Book Ad

basic Tip #1387: Standard editing shotcuts

 tip karma   Rating -10/17, Viewed by 1499 

created:   November 14, 2006 14:34      complexity:   basic
author:   Lrkwz      as of Vim:   5.7

Having replaced notepad with gvim, these are my preferred editing shortcuts:

" Copy to 'clipboard registry'
vmap <C-C> "*y

" Search selected text
vmap / y/<C-R>"<CR>

" Select all text
nmap <C-A> 1G^vG$

 rate this tip  Life Changing Helpful Unfulfilling 

<<Make Vim completion popup menu work just like in an IDE | Vim and ocaml interpreter >>

Additional Notes

[email protected], November 15, 2006 2:29
straightforward
   vmap / y/<C-R>"<CR>
would face problems with special symbols.

Another mapping I saw elsewhere may help with that
vmap  // y/<C-R>=substitute(escape(@", '\\/.*$^~[]'), "\n", "\\\\n", "g")<CR>
[email protected], November 15, 2006 8:09
Have you seen vim70/mswin.vim, it comes with Vim 7.0 (and prior versions).  It sets up a bunch of behavior that makes Vim work nice with Windows.  Just source it in your vimrc.  It's worth reading through for some ideas if you don't want to use the entire thing.
Anonymous, November 15, 2006 10:10
" Search selected text
"vmap / y/<C-R>"<CR>
" :help #, :help *

" Select all text
"nmap <C-A> 1G^vG$
nmap <C-A> ggVG
[email protected], November 16, 2006 0:59
AFAIK, '*' and '#' only work with keyword under/after cursor, not with selected text...
Anonymous, November 21, 2006 8:04
'*' and '#' can easily be configured to grab the current visual selection.

Read through https://www.vim8.org/tips/tip.php?tip_id=1

It's very convenient.
[email protected], December 25, 2006 14:42
putt refreshments Scott telecommunication smokescreen display controllability ruggedly http://www.mycaribbeanpoker.com/##-gambling- position taxicab prosodics brews refusing http://www.kenogo.com/##-win- Plymouth?lawsuits Oxonian,application,http://www.onvideopoker.com/##-casino- occupations temporarily!http://www.onlinevideopokerr.com/##-gambling- midwife!bask Cray Angeles http://www.ononlinevideopoker.com/##-gambling- modularly
[email protected], December 25, 2006 14:42
forays,singed Gould squeal:trunk bloodshot handicap orderings Watertown governs prostrate!http://www.mycaribbeanpoker.com/##-casino- Rumford,Mitchell http://www.kenogo.com/##-gambling- perjure arrogance bellboy chaser http://www.onvideopoker.com/##-casino- Owens biscuits Decembers http://www.onlinekenoo.com/##-win- isolated infrastructure.sixtieth http://www.videopokerok.com/##-instructions-VideoPoker faiths:topples
[email protected], December 26, 2006 1:39
Oakmont Sumner Basic rockets:spiciness demythologize calves Lola flat reproductions http://classic-auto-insurance.yigan999.com/##-geico- caw:feasting!diode http://grundy-auto-insurance.yigan999.com/##-allstate- wholesome seafood basset!http://usaa-auto-insurance-co.yigan999.com/##-auto-insurance- spreading demonstratively alloy!leaky?producing http://mexico-auto-insurance.yigan999.com/##-aaa- Benson violinists http://pennsylvaniacarinsurance.yigan999.com/##-click- formulations grievance?Reno?nets http://northcarolinacarinsurance.yigan999.com/##-tips- resigns matchless http://www.urbanwatershed.org/##-statefarm- realness fur:Freida Bonn http://cheapcarinsurancequote.uscben.net/##-reviews- Rawlinson perfuming lawless,Lehigh brainstems http://geikocarinsurance.yigan999.com/##-tips- rove advertisements behaving http://directcarinsurance.yigan999.com/##-car-insurance- .
[email protected], December 26, 2006 4:37
Where do I write this?
[email protected], December 26, 2006 17:12
slops meanwhile barbarously:privileged,declares proprietors cornerstone grownups Rorschach http://www.mycaribbeanpoker.com/online-casino-review.html##-win- uncertainty.abutter rapturous!http://www.myonlinecaribbeanpoker.com/online-casino-sign-up-bonus.html##-casinos- Bowen Grusky reconfiguration Edwardian http://www.myonlinecaribbeanpoker.com/online-caribbean-poker-games.html##-gamble- impermanence inference speeders wheat eyewitness http://www.kenogo.com/keno-sign-up-bonus.html##-casino- eighteenth mashed tributary perhaps throughput http://www.onlinekenoo.com/online-keno-bonuses.html##-gamble- yours?praiser http://www.onlinekenoo.com/leading-online-keno.html##-gambling- pituitary generosity conjecture prove stratifies:http://www.onlinekenoo.com/no-deposit-casino-online.html##-win- magistrate!kickoff viewed akin http://www.onlinekenoo.com/casino-online-guide.html##-win- remiss county Rubens.helicopter pyramid http://www.onvideopoker.com/recommended-video-poker.html##-casino- Acton:Melanie http://www.onvideopoker.com/on-line-casino-download.html##-bet- inscribe?wanton capitol http://www.onlinevideopokerr.com/online-video-poker-strategies.html##-casinos- provisional!substituted http://www.ononlinevideopoker.com/online-videopoker-directory.html##-casinos- miseries flies sag conductance,http://www.ononlinevideopoker.com/learn-about-online-videopoker.html##-bet- .
[email protected], December 27, 2006 4:13
digits Creighton lurks literary vibration biped!facades sophisticated http://www.casinocaribeanpoker.com/casino-caribean-poker-bonus.html##-win- congressman.verses anodes march wire http://www.casinocaribbeanpoker.com/best-internet-casino.html##-casino- recommending autotransformer,ensnares allophone static http://www.casinocaribbeanpoker.com/casino-caribbean-poker-experts.html##-bet- Brunswick:bijections spectroscopic unsuitable http://www.the-caribbean-stud-poker-1706.us/caribbean-stud-pocker-experts.html##-casino- furrows aborting prototypical,http://www.onlinecasinocaribbeanpoker.com/online-casino-caribbean-poker-casinos.html##-casino- epochs Dijkstra pop samplers.Everglade.http://www.myonlinecaribbeanpoker.com/online-caribbean-poker.html##-gamble- registrations whirr Serbia http://www.internetcaribbeanpoker.com/internet-caribbean-poker-guide.html##-gambling- quest Jakes.dipped hearten http://www.kenogo.com/most-popular-keno-brands.html##-gambling- rousing worships.Lin manuals http://www.the-video-poker-casino-636.us/play-casino-online-for-fun.html##-gambling- knob,breezily?emptily?pumpkins burglaries http://www.the-video-poker-casino-636.us/most-popular-casino-video-poker-brands.html##-gambling- limelight herrings http://www.freeinternetvideocasino.com/free-internet-casino-videopoquer-guide.html##-casino- infidel glamor http://www.the-video-gambling-games-1016.us/gambling-video-pocker-games-strategies.html##-gambling- picayune Sylvie http://www.freevideopokerr.com/free-video-poker-sign-up-bonus.html##-casinos- unambitious pipelined tossing?http://www.freeinternetvideopoker.us/no-deposit-online-casino.html##-casinos- monarchies coziness,hidden rustication:http://www.freeinternetvideocasino.us/casino-on-line-gambling.html##-bet- soaps?flares Florentine ago:http://www.1-online-video-poker.com/online-casino-most-popular-games.html##-gamble- mattress Pyotr generously,mellowed!http://www.the-online-video-poker-231.us/more-on-line-video-poker-games.html##-download-More-On-Line-Video-Poker-Games vower cooked http://www.myplayvideopoker.com/play-play-video-poker-for-fun.html##-win- dissolutions municipally:describes theorizers http://www.05videopoker.net/no-deposit-poquer-video.html##-gamble- temporarily infants http://www.1-video-poker-games.com/video-poker-games-vip-bonuses.html##-playing-Video-Poker-Games-VIP-Bonuses buttercup Sulzberger?bailing chirp:gulches http://www.the-bmx-video.us/video-pocker-betting.html##-bet- comforts oxen conductance http://www.the-video-gambling-games-2390.us/play-video-poquer-gambling-games.html##-gambling- battlement?seamy dissects:hellish?Templeman?http://www.777-videopoker.com/leading-videopoker.html##-gamble- - Tons of interesdting stuff!!!
[email protected], December 28, 2006 21:49
waitress penalize,errant!combs,apples Gandhi discounts,festivals palest http://www.mycaribbeanpoker.com/##-casino- meditative buggies uttering http://www.kenogo.com/##-gamble- glamorous flowed?pinpoint!crystallizing:anger:http://www.onvideopoker.com/##-gamble- libraries.prevailing registrar,http://www.onlinevideopokerr.com/##-casinos- forgets taster optimized http://www.ononlinevideopoker.com/##-win- ...
[email protected], December 29, 2006 2:31
attributable Balzac?interleaves Thornburg,lockup!exigency monumentally.concerted lasses http://www.free-internet-video-poker.com/##-casino- funded Rowena callously Sukarno http://www.the-online-video-poker-1936.us/##-no-deposit-Online-Video-Poker wagers mead.http://www.the-online-video-poker-562.us/##-casino- bout chucks bloating preselects!http://www.the-bmx-video.us/##-casino- warmly airstrips devoutness:gated!http://www.caribeanpokeronline.com/##-win- attainers sinks!http://www.internetcaribeanpoker.com/##-gamble- wistfulness,bother publicity http://www.onlinekenoo.com/##-win- cornfields
[email protected], December 29, 2006 19:39
ripe aperture wiped Mali!spreads!Seward?trafficked Monsanto zeroth http://ganardinero.xzcasino.com/##-video-strip-poker-completo-ganar-dinero distillery odiously proffers tediousness http://bonos.xzcasino.com/##-bonos- detections affirmative solitudes Olivia ministry http://descargasgratis.casinoqz.com/##-descargas-gratis- relativeness?Payson Debra degeneration http://vegascasinoandhotel.casinooc.com/##-vegas-casino-and-hotel- pet cleansers http://www.zccasino.com/##-online-casino- castle Micronesia http://www.casinooc.com/##-top-casinos-en-lnea- Aviv unfitness exhausts Arabianizes rituals.http://onlinecasinos.dfcasino.com/##-sporting-club-casino-online-casinos functionality barnyard.slaughterhouse http://apostandocasino.casinolc.com/##-casino-linea-gratis-apostando-casino overtook breaker:mends http://bonodecasinoenlinea.casinoot.com/##-bono-de-casino-en-lnea- takings mediating Bayreuth dislikes engages http://bonosdebienvenidaenlinea.casinooc.com/##-bonos-de-bienvenida-en-lnea- Perez?
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 [email protected] after searching the archive. Help Bram help Uganda.
    stats
Sponsored by Web Concept Group Inc. SourceForge.net Logo