wood burning stoves 2.0*
The moose likes Swing / AWT / SWT and the fly likes How can I catch the CTRL_C or CTRL_V event Big Moose Saloon
  Search | Java FAQ | Recent Topics | Flagged Topics | Hot Topics | Zero Replies
Register / Login
JavaRanch » Java Forums » Java » Swing / AWT / SWT
Bookmark "How can I catch the CTRL_C or CTRL_V event" Watch "How can I catch the CTRL_C or CTRL_V event" New topic
Author

How can I catch the CTRL_C or CTRL_V event

yu yong
Ranch Hand

Joined: Mar 09, 2008
Posts: 44
Dear everyone.
How can I catch the Ctrl_C or Ctrl_V event in the StyledText widget.
Which event listener should I use. KeyListener or anyone else.
Thanks.


Yours sincerely,<br />yuyong<br /> <br /> <br /> E-mail:yuyong22@hotmail.com<br /> msn: yuyong22@hotmail.com<br /> Skype:yuyong88
pete stein
Bartender

Joined: Feb 23, 2007
Posts: 1561
Originally posted by yu yong:
How can I catch the Ctrl_C or Ctrl_V event in the StyledText widget.
Which event listener should I use. KeyListener or anyone else.


Hm, sorry for my ignorance, but what is a StyledText widget? If it's part of the Swing standard jcomponents, then your best bet may be to use Key Bindings. There's a decent tutorial on this at the Sun Java tutorials. HTH.
yu yong
Ranch Hand

Joined: Mar 09, 2008
Posts: 44
Sorry, I dont describe my question in detail.
My project is a rcp project besides swt widgets. All the swt widgets should be run on the a viewpart ui or a dialog widget which belong among the rcp.
Andy Selador
Ranch Hand

Joined: May 02, 2008
Posts: 34
If you're running from the command line, there may be some issues, but here is a link that may help.

http://dev.eclipse.org/newslists/news.eclipse.platform.rcp/msg27323.html
 
jQuery in Action, 2nd edition
 
subject: How can I catch the CTRL_C or CTRL_V event
 
Similar Threads
mouse event
Servlet can't get the xmlhttp post request
Help me ,immediately !!!!
create new event
JDialog X Button