Posted 8 years ago by Thida Chiang
Avatar
I am implementing FindReplace function in SyntaxEditor and tried to bind custom key 'Ctrl+F' and 'Ctrl+H' but not able to get them work. Is there any solution to this?

Thanks,
Thida

[Modified at 06/30/2011 06:58 PM]

Comments (3)

Posted 8 years ago by Actipro Software Support - Cleveland, OH, USA
Avatar
Hi Thida,

In our ActiproSoftware.Compatibility namespace we have a lot of the WPF input and command binding classes so we do things like this in our code:
editor.InputBindings.Add(new KeyBinding(ApplicationCommands.Redo, Key.Y, ModifierKeys.Control));
Then if you have a command binding set up for the related command, you can handle it.

Otherwise you'd have to try and handle the key events off the editor view. I believe you can get to it via editor.ActiveView.VisualElement.KeyDown.


Actipro Software Support

Posted 8 years ago by Thida Chiang
Avatar
I am able to get the key binding works for other keys but when I use 'Ctrl+F', the find popup from Internet Explorer keeps showing up and my key is not getting fired. Any suggestions to it?

Thanks,
Thida
Posted 8 years ago by Actipro Software Support - Cleveland, OH, USA
Avatar
Ahh, that is a browser hotkey. I'm not sure that you can work around that issue from within Silverlight per articles like this:
http://forums.silverlight.net/forums/t/19032.aspx


Actipro Software Support

The latest build of this product (v2018.1 build 0232) was released 6 months ago, which was after the last post in this thread.

Add Comment

Please log in to a validated account to post comments.