aboutsummaryrefslogtreecommitdiff
path: root/runtime/doc/provider.txt
blob: 5c335a39ef4919e5ee5a8b7e4c4313f0f43b09bc (plain) (blame)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
*provider.txt*								{Nvim}


		 NVIM REFERENCE MANUAL    by Thiago de Arruda


Providers	 						    *provider*

Nvim delegates some features to dynamic "providers".

==============================================================================
Clipboard integration 						   *clipboard*

Nvim has no direct connection to the system clipboard. Instead it is
accessible through a |provider| which transparently uses shell commands for
communicating with the clipboard.

Clipboard access is implicitly enabled if any of the following clipboard tools
are found in your `$PATH`.

  - xclip
  - xsel (newer alternative to xclip)
  - pbcopy/pbpaste (Mac OS X)
  - lemonade (for SSH) https://github.com/pocke/lemonade
  - doitclient (for SSH) http://www.chiark.greenend.org.uk/~sgtatham/doit/

The presence of a suitable clipboard tool implicitly enables the '+' and '*'
registers.

If you want to ALWAYS use the clipboard for ALL operations (as opposed
to interacting with the '+' and/or '*' registers explicitly), set the
following option:
>
    set clipboard+=unnamedplus
<
See 'clipboard' for details and more options.

==============================================================================
X11 selection mechanism			       *clipboard-x11* *x11-selection*

The clipboard providers for X11 store text in what is known as "selections".
Selections are "owned" by an application, so when the application is closed,
the selection text is lost.

The contents of selections are held by the originating application (e.g., upon
a copy), and only passed on to another application when that other application
asks for them (e.g., upon a paste).

							      *quoteplus* *quote+*

There are three documented X11 selections: `PRIMARY`, `SECONDARY`, and `CLIPBOARD`.
`CLIPBOARD` is typically used in X11 applications for copy/paste operations
(`Ctrl-c`/`v`), while `PRIMARY` is used for the last selected text, which is
generally inserted with the middle mouse button.

Nvim's X11 clipboard providers only utilize the `PRIMARY` and `CLIPBOARD`
selections, used for the '*' and '+' registers, respectively.

==============================================================================
 vim:tw=78:ts=8:noet:ft=help:norl: