public inbox for gentoo-user@lists.gentoo.org
 help / color / mirror / Atom feed
* [gentoo-user] how to copy a file's content to clipboard?
@ 2005-08-12 15:53 Qiangning Hong
  2005-08-12 16:19 ` Uwe Thiem
  2005-08-12 19:20 ` Neil Bothwick
  0 siblings, 2 replies; 5+ messages in thread
From: Qiangning Hong @ 2005-08-12 15:53 UTC (permalink / raw
  To: gentoo-user

Do you know how to copy the content of a file to the X clipboard using
command?  Every time now I need to paste a file into my email, I have to
cat it in a terminal and use mouse to select the text.  Is there a more
convenient way?


-- 
Qiangning Hong

I'm usually annoyed by IDEs because, for instance, they don't use VIM
as an editor. Since I'm hooked to that, all IDEs I've used so far have
failed to impress me.
    -- Sybren Stuvel @ c.l.python

Get Firefox!
<http://www.spreadfirefox.com/?q=affiliates&amp;id=67907&amp;t=1>
-- 
gentoo-user@gentoo.org mailing list



^ permalink raw reply	[flat|nested] 5+ messages in thread

* Re: [gentoo-user] how to copy a file's content to clipboard?
  2005-08-12 15:53 [gentoo-user] how to copy a file's content to clipboard? Qiangning Hong
@ 2005-08-12 16:19 ` Uwe Thiem
  2005-08-12 16:43   ` Qiangning Hong
  2005-08-12 19:20 ` Neil Bothwick
  1 sibling, 1 reply; 5+ messages in thread
From: Uwe Thiem @ 2005-08-12 16:19 UTC (permalink / raw
  To: gentoo-user

On 12 August 2005 16:53, Qiangning Hong wrote:
> Do you know how to copy the content of a file to the X clipboard using
> command?  Every time now I need to paste a file into my email, I have to
> cat it in a terminal and use mouse to select the text.  Is there a more
> convenient way?

Depends on your mailer. In KDE's kmail, I just click Message -> Insert File. 
Since you are using Thunderbird, I am pretty sure it offers something 
similar.

Uwe

-- 
95% of all programmers rate themselves among the top 5% of all software 
developers. - Linus Torvalds

http://www.uwix.iway.na (last updated: 20.06.2004)
-- 
gentoo-user@gentoo.org mailing list



^ permalink raw reply	[flat|nested] 5+ messages in thread

* Re: [gentoo-user] how to copy a file's content to clipboard?
  2005-08-12 16:19 ` Uwe Thiem
@ 2005-08-12 16:43   ` Qiangning Hong
  2005-08-12 17:01     ` Willie Wong
  0 siblings, 1 reply; 5+ messages in thread
From: Qiangning Hong @ 2005-08-12 16:43 UTC (permalink / raw
  To: gentoo-user

Uwe Thiem wrote:
> On 12 August 2005 16:53, Qiangning Hong wrote:
> 
>>Do you know how to copy the content of a file to the X clipboard using
>>command?  Every time now I need to paste a file into my email, I have to
>>cat it in a terminal and use mouse to select the text.  Is there a more
>>convenient way?
> 
> 
> Depends on your mailer. In KDE's kmail, I just click Message -> Insert File. 
> Since you are using Thunderbird, I am pretty sure it offers something 
> similar.

Do you means there isn't an X or desktop environment level utility?
What if I want to paste the content of a file in other places, i.e. fill
a textarea in web browser?

In my cygwin time, the command "cat myfile > /dev/clipboard" was quite
handy.  I hadn't expected that I am missing a windows function when I am
under Linux, ever.

P.S. It seems Thunderbird doesn't provide this kind of function except
using attachment. :(

-- 
Qiangning Hong

I'm usually annoyed by IDEs because, for instance, they don't use VIM
as an editor. Since I'm hooked to that, all IDEs I've used so far have
failed to impress me.
    -- Sybren Stuvel @ c.l.python

Get Firefox!
<http://www.spreadfirefox.com/?q=affiliates&amp;id=67907&amp;t=1>
-- 
gentoo-user@gentoo.org mailing list



^ permalink raw reply	[flat|nested] 5+ messages in thread

* Re: [gentoo-user] how to copy a file's content to clipboard?
  2005-08-12 16:43   ` Qiangning Hong
@ 2005-08-12 17:01     ` Willie Wong
  0 siblings, 0 replies; 5+ messages in thread
From: Willie Wong @ 2005-08-12 17:01 UTC (permalink / raw
  To: gentoo-user

On Sat, Aug 13, 2005 at 12:43:34AM +0800, Qiangning Hong wrote:
> Uwe Thiem wrote:
> > On 12 August 2005 16:53, Qiangning Hong wrote:
> > 
> >>Do you know how to copy the content of a file to the X clipboard using
> >>command?  Every time now I need to paste a file into my email, I have to
> >>cat it in a terminal and use mouse to select the text.  Is there a more
> >>convenient way?
> > 
> > 
> > Depends on your mailer. In KDE's kmail, I just click Message -> Insert File. 
> > Since you are using Thunderbird, I am pretty sure it offers something 
> > similar.
> 
> Do you means there isn't an X or desktop environment level utility?
> What if I want to paste the content of a file in other places, i.e. fill
> a textarea in web browser?
> 

If you run KDE, you can probably use some incantation magic with
klipper and DCOP. 

Otherwise, try xcut or xclip 

[12:59 PM]wwong ~ $ emerge search xcut xclip
Searching...   
[ Results for search key : xcut ]
[ Applications found : 1 ]
 
*  x11-misc/xcut
      Latest version available: 0.2
      Latest version installed: [ Not Installed ]
      Size of downloaded files: 10 kB
      Homepage:    http://xcut.sourceforge.net
      Description: Commandline tool to manipulate the X11 cut and paste buffers
      License:     GPL-2


Searching...   
[ Results for search key : xclip ]
[ Applications found : 2 ]
 
*  x11-apps/xclipboard [ Masked ]
      Latest version available: 0.99.0
      Latest version installed: [ Not Installed ]
      Size of downloaded files: 58 kB
      Homepage:    http://xorg.freedesktop.org/
      Description: X.Org xclipboard application
      License:     X11

*  x11-misc/xclip
      Latest version available: 0.08
      Latest version installed: [ Not Installed ]
      Size of downloaded files: 27 kB
      Homepage:    http://people.debian.org/~kims/xclip/
      Description: Command-line utility to read data from standard in and place it in an X selection for pasting into X applications.
      License:     GPL-2


HTH, 

W
-- 
If I could reach up an pick one star for everytime you've made me smile, the
whole evening sky would be in the palm of my hand.
Sortir en Pantoufles: up 20:00
-- 
gentoo-user@gentoo.org mailing list



^ permalink raw reply	[flat|nested] 5+ messages in thread

* Re: [gentoo-user] how to copy a file's content to clipboard?
  2005-08-12 15:53 [gentoo-user] how to copy a file's content to clipboard? Qiangning Hong
  2005-08-12 16:19 ` Uwe Thiem
@ 2005-08-12 19:20 ` Neil Bothwick
  1 sibling, 0 replies; 5+ messages in thread
From: Neil Bothwick @ 2005-08-12 19:20 UTC (permalink / raw
  To: gentoo-user

[-- Attachment #1: Type: text/plain, Size: 465 bytes --]

On Fri, 12 Aug 2005 23:53:19 +0800, Qiangning Hong wrote:

> Do you know how to copy the content of a file to the X clipboard using
> command?  Every time now I need to paste a file into my email, I have to
> cat it in a terminal and use mouse to select the text.  Is there a more
> convenient way?

Use xclip, it does just what you want, and the reverse. It's in portage.


-- 
Neil Bothwick

I've got a mind like a... a... what's that thing called?

[-- Attachment #2: Type: application/pgp-signature, Size: 189 bytes --]

^ permalink raw reply	[flat|nested] 5+ messages in thread

end of thread, other threads:[~2005-08-12 19:27 UTC | newest]

Thread overview: 5+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2005-08-12 15:53 [gentoo-user] how to copy a file's content to clipboard? Qiangning Hong
2005-08-12 16:19 ` Uwe Thiem
2005-08-12 16:43   ` Qiangning Hong
2005-08-12 17:01     ` Willie Wong
2005-08-12 19:20 ` Neil Bothwick

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox