![Avatar](https://secure.gravatar.com/avatar/377c902022830b2ef9fdea964712232f.jpg?s=64&d=identicon&r=g)
Hello,
Back with the old syntax editor, we used to be able to alter the context menu to whatever we wanted by hooking up to the editor's ContextMenuRequested event as such:The events do not seem to be the same with the WPF editor.
I tried to hookup to the editor's event:
OnContextMenuOpening()
but it never fired unless i clicked on the scroll bars or the editor margin, but on the editor itself the event was not triggered.
How do i accomplish this in SyntaxEditor WPF?
Thank you
Nassim
[Modified at 01/06/2012 04:26 PM]
[Modified at 01/09/2012 09:33 AM]
Back with the old syntax editor, we used to be able to alter the context menu to whatever we wanted by hooking up to the editor's ContextMenuRequested event as such:
private void OnContextMenuRequested(object sender, ContextMenuRequestEventArgs e)
{
...
ContextMenu menu = this.STsyntaxEditor.GetDefaultContextMenu();
...
...
//build the context menu and show it
...
this.STsyntaxEditor.DefaultContextMenuEnabled = false;
}
I tried to hookup to the editor's event:
OnContextMenuOpening()
but it never fired unless i clicked on the scroll bars or the editor margin, but on the editor itself the event was not triggered.
How do i accomplish this in SyntaxEditor WPF?
Thank you
Nassim
[Modified at 01/06/2012 04:26 PM]
[Modified at 01/09/2012 09:33 AM]