Skip to content

Commit 7551d5e

Browse files
dfishburnvim-scripts
authored andcommitted
Version 15.0
NF: Automatically turn off relativenumber for the YankRing window (Emma Tramp). NF: The YankRing window supports 1-9 to choose to paste those items for quicker access to the top 9 items. BF: When re-executing a macro using @<letter> and the macro used f, F, t, T, a "Press ENTER to continue" prompt was displayed (Greg Sexton). BF: Some documentation updates and script tweaks (Dominique Pellé). BF: The 0 register was updated during delete operations (Christian Brabandt). BF: When running a macro (@A), pressing @ displays a YankRing prompt (YR:Enter character:) to choose which macro name to run. This prompt was displayed twice leading to a "Press ENTER or type command to continue" Vim message. This change suppresses the "Press ENTER" message (Greg Sexton). BF: The YankRing prevented you from re-running the last macro using @@. BF: YRToggle (to disable / enable the YankRing) did not unmap @. BF: When prompted for a macro to run, if an invalid value was provided, Vim could report "E354: Invalid register name". BF: When using a Vim instance with < 80 columns and using a horizontal YankRing window after opening and closing the YankRing window the Vim window did not shrink back to its original size (Eric Weir). BF: Updated documented values of yankring_window_height and yankring_window_width (Paul). BF: It was not possible to paste from the * register if the clipboard option contains unnamedplus before unnamed (Marcin Szamotulski).
1 parent 8ebc225 commit 7551d5e

File tree

2 files changed

+205
-117
lines changed

2 files changed

+205
-117
lines changed

doc/yankring.txt

Lines changed: 64 additions & 30 deletions
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,7 @@
11
*yankring.txt* For Vim version 7.0.
22

3-
Author: David Fishburn April 1, 2011
4-
Version: 14.0
3+
Author: David Fishburn Jnauary 2, 2013
4+
Version: 15.0
55

66
For instructions on installing this file, type
77
:help add-local-help |add-local-help| inside Vim.
@@ -196,12 +196,12 @@ your |.vimrc|.
196196
setting this option to 0. >
197197
let g:yankring_window_use_horiz = 0 " Use vertical split
198198
yankring_window_height
199-
< Default: 1
199+
< Default: 8
200200
If using a horizontal split, this option controls how high to make
201201
the window. >
202202
let g:yankring_window_height = 8
203203
yankring_window_width
204-
< Default: 1
204+
< Default: 30
205205
If using a vertical split, this option controls how wide to make the
206206
window. >
207207
let g:yankring_window_width = 30
@@ -282,7 +282,7 @@ your |.vimrc|.
282282
GUI is not running, this option will be enabled by default.
283283
To disable this feature you can put the following in your |vimrc| >
284284
let g:yankring_manual_clipboard_check = 0
285-
yankring_paste_check_default_buffer
285+
yankring_paste_check_default_register
286286
< Default: 1
287287
If the default register has changed without the YankRing registering
288288
the change the YankRing will paste the top item from the history
@@ -291,7 +291,7 @@ your |.vimrc|.
291291
intentionally change the default buffer which the YankRing has
292292
no way to noticing. To disable this feature you can put the following
293293
in your |vimrc| >
294-
let g:yankring_paste_check_default_buffer = 0
294+
let g:yankring_paste_check_default_register = 0
295295
yankring_default_menu_mode
296296
< - Menus are useful for a number of reasons:
297297
See a list of available commands.
@@ -535,7 +535,7 @@ specific maps that allow you to operate over the various elements from
535535
within the yankring.
536536

537537
To display the YankRing buffer you can issue the :YRShow command. For
538-
convience you can map a key, <F11>, to this command: >
538+
convenience you can map a key, <F11>, to this command: >
539539
:nnoremap <silent> <F11> :YRShow<CR>
540540
541541
Status line~
@@ -572,7 +572,7 @@ in the YankRing window.
572572
<CR> Just like "p".
573573
<Enter> Just like "p".
574574
<2-LeftMouse> Just like "p". Normal mode only.
575-
1-9 Short cut to paste the n'th number from the YankRing.
575+
1-9 Shortcut to paste the n'th number from the YankRing.
576576
d Removes the element from the yankring. In visual mode all
577577
elements selected will be removed.
578578
r Just like "p", but in visual mode if many lines are selected
@@ -598,7 +598,7 @@ through maps against a buffer, instead of commands. This makes it much easier
598598
to use.
599599

600600

601-
5.1 YRToggle :*YRToggle*
601+
5.1 YRToggle *:YRToggle*
602602
Allows you to enable and disable the YankRing quickly. This
603603
command will remove the default maps and recreate them.
604604

@@ -608,12 +608,12 @@ to use.
608608
:YRToggle 0 " Disables it
609609
<
610610

611-
5.2 YRClear :*YRClear*
611+
5.2 YRClear *:YRClear*
612612
Clears all elements from the yankring.
613613
See also |YRClear-example|.
614614

615615

616-
5.3 YRShow :*YRShow*
616+
5.3 YRShow *:YRShow*
617617
Similar to |:register|, will display all the entries in the yankring.
618618
The element at the top will be the next element pasted from the
619619
yankring.
@@ -630,7 +630,7 @@ to use.
630630
5 one^@
631631
<
632632

633-
5.5 YRGetElem :*YRGetElem*
633+
5.5 YRGetElem *:YRGetElem*
634634
This command has two modes. If no parameters are provided, it
635635
becomes interactive. It uses YRShow to display the list and
636636
allows you to choose which element to paste. If a parameter
@@ -650,7 +650,7 @@ to use.
650650
:YRGetElem 0 " Error, invalid choice is reported
651651
652652
653-
5.6 YRGetMultiple :*YRGetMultiple*
653+
5.6 YRGetMultiple *:YRGetMultiple*
654654
Will paste many elements from the YankRing in one command.
655655
If the number specified is 1 or less, it is assumed you want
656656
just the current element pasted. If the number specified is
@@ -669,7 +669,7 @@ to use.
669669
:YRGetMultiple 0 " Will paste element 1
670670
671671
672-
5.7 YRPush :*YRPush*
672+
5.7 YRPush *:YRPush*
673673
Allows the user to "push" additional entries into the yankring.
674674
If you yanked text via a key mapping which does not use the
675675
YankRing (or there is text on the clipboard) you can use this
@@ -683,7 +683,7 @@ to use.
683683
< See also |YRPush-example|.
684684

685685

686-
5.8 YRPop :*YRPop*
686+
5.8 YRPop *:YRPop*
687687
Allows you to pop any elements from the yankring. If no parameters
688688
are provided, the 1st element is removed from the yankring. The
689689
command optionally takes a second parameter to specify how many
@@ -698,7 +698,7 @@ to use.
698698
< See also |YRPop-example|.
699699

700700

701-
5.9 YRYankCount :*YRYankCount*
701+
5.9 YRYankCount *:YRYankCount*
702702
This command has the most mappings created for it. If you are
703703
in normal mode and you are not specifying a range, this command
704704
will add the text to the yankring.
@@ -740,7 +740,7 @@ to use.
740740
See also |yankring-tutorial|.
741741

742742

743-
5.10 YRYankRange :*YRYankRange*
743+
5.10 YRYankRange *:YRYankRange*
744744
This command by default is only called in visual mode. All
745745
visual modes (|characterwise-visual|, |linewise-visual|,
746746
|blockwise-visual|) are supported. Any visually selected text
@@ -762,12 +762,12 @@ to use.
762762
< See also |YRYankRange-example|.
763763

764764

765-
5.11 YRDeleteRange :*YRDeleteRange*
765+
5.11 YRDeleteRange *:YRDeleteRange*
766766
This command is identical to YRYankRange, except the range is
767767
also deleted.
768768

769769

770-
5.12 YRPaste :*YRPaste*
770+
5.12 YRPaste *:YRPaste*
771771
This command will paste elements from the yankring. By default it has
772772
been mapped to p and P to match Vim's native key strokes. The text
773773
pasted is exactly what was yanked, including newline characters and
@@ -784,7 +784,7 @@ to use.
784784
See also |yankring-tutorial|.
785785

786786

787-
5.13 YRReplace :*YRReplace*
787+
5.13 YRReplace *:YRReplace*
788788
The purpose of the YankRing is to gain access to previously yanked
789789
(or deleted) elements. This command will replace the previous
790790
paste with a different entry from the yankring.
@@ -813,33 +813,33 @@ to use.
813813
let g:yankring_replace_n_nkey = '<Char-174>'
814814
endif
815815

816-
5.14 YRMapsCreate :*YRMapsCreate*
816+
5.14 YRMapsCreate *:YRMapsCreate*
817817
This public function is responsible for creating the maps which
818818
enable the yankring. This function is called by the YRToggle
819819
command.
820820

821821

822-
5.15 YRMapsDelete :*YRMapsDelete*
822+
5.15 YRMapsDelete *:YRMapsDelete*
823823
This public function removes the YankRing maps and disables
824824
the yankring. This function is called by the YRToggle command.
825825

826826

827-
5.16 YRSearch :*YRSearch*
827+
5.16 YRSearch *:YRSearch*
828828
This command is similar to |YRGetElem|. The command takes
829829
one parameter which is a regular expression. Similar to
830830
YRGetElem, it will display all items in the YankRing that match
831831
the regular expression. It is also interactive, and will
832832
prompt you to enter which match you wish pasted.
833833
See also |YRSearch-example|.
834834

835-
5.17 YRCheckClipboard :*YRCheckClipboard*
835+
5.17 YRCheckClipboard *:YRCheckClipboard*
836836
Normally the GUI Vims will automatically (via autocmds)
837837
check for changes to the system clipboard and add any new
838838
changes to the YankRing. Most console Vim's do not fire
839839
the required autocmds. This command will perform the check
840840
manually.
841841

842-
5.18 YRRunAfterMaps :*YRRunAfterMaps*
842+
5.18 YRRunAfterMaps *:YRRunAfterMaps*
843843
See the following section |yankring-custom-maps|.
844844

845845

@@ -886,7 +886,7 @@ mapping: >
886886

887887
You do not need to interact with the YankRing using the YankRing window.
888888
Using the window makes many tasks must easier, but for speed using some
889-
of the other maps can be preferrable if you know what you have yanked /
889+
of the other maps can be preferable if you know what you have yanked /
890890
deleted recently. It was designed to work with Vim in the usual manner.
891891
You can press, 'p', to paste the last item in yanked or deleted.
892892

@@ -902,7 +902,7 @@ mapping: >
902902
five
903903
five
904904
<
905-
Assume you did not want 'five", but a different entry from within the
905+
Assume you did not want "five", but a different entry from within the
906906
yankring. <C-P> moves backwards through the yankring, it will replace
907907
the previous pasted text with a different item from the yankring. This
908908
allows you to quickly iterate through different elements. <C-P> is the
@@ -1220,6 +1220,40 @@ mapping: >
12201220
==============================================================================
12211221
7. History *yankring-history*
12221222

1223+
15.0: January 2, 2013
1224+
NF: Automatically turn off relativenumber for the YankRing
1225+
window (Emma Tramp).
1226+
NF: Automatically turn off relativenumber for the YankRing
1227+
window (Emma Tramp).
1228+
NF: The YankRing window supports 1-9 to choose to paste those
1229+
items for quicker access to the top 9 items.
1230+
BF: When re-executing a macro using @<letter> and the macro
1231+
used f, F, t, T, a "Press ENTER to continue" prompt
1232+
was displayed (Greg Sexton).
1233+
BF: Some documentation updates and script tweaks (Dominique Pellé).
1234+
BF: The 0 register was updated during delete operations
1235+
(Christian Brabandt).
1236+
BF: When running a macro (@a), pressing @ displays a YankRing prompt
1237+
(YR:Enter character:) to choose which macro name to run. This
1238+
prompt was displayed twice leading to a "Press ENTER or type
1239+
command to continue" Vim message. This change suppresses
1240+
the "Press ENTER" message (Greg Sexton).
1241+
BF: The YankRing prevented you from re-running the last macro
1242+
using @@.
1243+
BF: YRToggle (to disable / enable the YankRing) did not
1244+
unmap @.
1245+
BF: When prompted for a macro to run, if an invalid value was
1246+
provided, Vim could report "E354: Invalid register name".
1247+
BF: When using a Vim instance with < 80 columns and using a
1248+
horizontal YankRing window after opening and closing the
1249+
YankRing window the Vim window did not shrink back to
1250+
its original size (Eric Weir).
1251+
BF: Updated documented values of yankring_window_height and
1252+
yankring_window_width (Paul).
1253+
BF: It was not possible to paste from the * register if the
1254+
clipboard option contains unnamedplus before unnamed
1255+
(Marcin Szamotulski).
1256+
12231257
14.0: April 1, 2012
12241258
NF: The YankRing window supports 1-9 to choose to paste those
12251259
items for quicker access to the top 9 items.
@@ -1286,7 +1320,7 @@ mapping: >
12861320
NF: When displaying the YankRing using YRShow, a new command "R"
12871321
has been added to display all of Vim's registers [0-9a-z].
12881322
BF: YRMapsDelete did not remove the normal mode @ map, which
1289-
interfers with recorded macros (Philippe Vaucher).
1323+
interferes with recorded macros (Philippe Vaucher).
12901324

12911325
11.0: August 09, 2010
12921326
NF: Documented the global variables to customize the location
@@ -1439,7 +1473,7 @@ mapping: >
14391473
NF: Prior to this version only yanks and deletes were registered
14401474
in the yankring. Changes are now also captured into the
14411475
yankring.
1442-
NF: The YankRing will also capture the system cliboard when focus is
1476+
NF: The YankRing will also capture the system clipboard when focus is
14431477
returned to the vim window. This is useful if you copy text
14441478
between applications.
14451479
NF: The YankRing window always opened bottom horizontal. Now it
@@ -1449,7 +1483,7 @@ mapping: >
14491483
of Vim by storing the values in global variables within
14501484
the viminfo. This has led to some unusual ordering of
14511485
items in the ring from conflicts between instances.
1452-
This option has been turn off by default.
1486+
This option has been turned off by default.
14531487
BF: Their was an issue with yanking using y$.
14541488

14551489
3.1: September 10, 2007:

0 commit comments

Comments
 (0)