![]() |
![]()
| ![]() |
![]()
NAMExclip - command line interface to X selections (clipboard) SYNOPSISxclip [OPTION] [FILE]... DESCRIPTIONReads from standard in, or from one or more files, and makes the data available as an X selection for pasting into X applications. Prints current X selection to standard out.
xclip reads text from standard in or files and makes it available to other X applications for pasting as an X selection (traditionally with the middle mouse button). It reads from all files specified, or from standard in if no files are specified. xclip can also print the contents of a selection to standard out with the -o option. xclip was designed to allow tighter integration of X applications and command line programs. The default action is to silently wait in the background for X selection requests (pastes) until another X application places data in the clipboard, at which point xclip exits silently. You can use the -verbose option to see if and when xclip actually receives selection requests from other X applications. Options can be abbreviated as long as they remain unambiguous. For example, it is possible to use -d or -disp instead of -display. However, -v couldn't be used because it is ambiguous (it could be short for -verbose or -version), so it would be interpreted as a filename. Note that only the first character of the selection specified with the -selection option is important. This means that "p", "sec" and "clip" would have the same effect as using "primary", "secondary" or "clipboard" respectively. EXAMPLESI hate man pages without examples! uptime | xclip Put your uptime in the X selection. Then middle click in an X application to paste. xclip -o > helloworld.c Put the contents of the selection into a file. xclip -t text/html index.html Middle click in an X application supporting HTML to paste the contents of the given file as HTML. xclip -loops 10 -verbose /etc/motd Exit after /etc/motd (message of the day) has been pasted 10 times. Show how many selection requests (pastes) have been processed. NOTESUsing the -sensitive option will clear the selection buffer of the sensitive information 50 milliseconds after it has been pasted, effectively only allowing the selection to be pasted once. In some instances this may be too low and will prevent pasting. If this is the case, or if the user needs to be able to paste more than once for some other reason, they may use -wait n instead. -wait is the same as -sensitive, except it allows one to adjust the time to wait before clearing the selection to be n milliseconds. Ideally, -sensitive would allow exactly one paste and not need a timeout, but due to subtleties in the way the X clipboard protocol works, doing so is not as simple as it may seem. ENVIRONMENT
REPORTING BUGSPlease report any bugs, problems, queries, experiences, etc. directly to the author. AUTHORSKim Saunders <kims@debian.org> Peter Åstrand <astrand@lysator.liu.se>
|