Eclipse Community Forums
Forum Search:

Search      Help    Register    Login    Home
Home » Eclipse Projects » Vex » Implementing undo/copy/cut in Vex Dialog
Implementing undo/copy/cut in Vex Dialog [message #1062069] Wed, 05 June 2013 16:41 Go to next message
shay leon is currently offline shay leon
Messages: 9
Registered: June 2012
Junior Member
Hi

When implementing a Vex dialog, similar to Florian's magazine sample, is there an easy way to add copy, undo and cut XML?

I tried:

vexWidget.addKeyListener(new KeyListener() {            
  public void keyReleased(KeyEvent e) {
  ...            
}            

but it does the operations on TEXT format and not XML format (it will copy pure text, but not XML).

Putting a breakpoint in EditorManager, I noticed that when using the editor, the base contributor is VexActionBarContributor, but when using Vex inside the dialog, the base contributor is ComponentEditorContributor.

Any feedback would be appreciated.

Many thanks.
Re: Implementing undo/copy/cut in Vex Dialog [message #1062189 is a reply to message #1062069] Thu, 06 June 2013 13:06 Go to previous message
shay leon is currently offline shay leon
Messages: 9
Registered: June 2012
Junior Member
OK. Found the solution. Extended the widget and implemented the copy/paste without actually using the clipboard, but doing getSelectedFragment() in the copy and keeping the result for the paste.
Previous Topic:MathML Support
Next Topic:Reopening a dialog with Vex
Goto Forum:
  


Current Time: Tue Oct 21 16:47:59 GMT 2014

Powered by FUDForum. Page generated in 0.05648 seconds
.:: Contact :: Home ::.

Powered by: FUDforum 3.0.2.
Copyright ©2001-2010 FUDforum Bulletin Board Software