I need to program a keyboard, with some configurations and customizations.
I need to configure it to be enabled if any text area is focused before the keyboard.
mainly I need to know what control is selected.
The Keyboard is a standalone application, so it cannot deal directly with the controls, just by accessing the OS.
for more explanation, I am gonna tell you the scenario:
- the user runs the keyboard application, which its ‘topmost’ is set, and
ShowInTaskBaris unset, and the keyboard is disabled. -
the user clicks on any text control in the window, like the notepad or a TextBox in Microsoft Word or Paint, then after clicking the keyboard application is enabled.
-
the user clicks on the keyboard application and its keys to write text on the TextBox selected before in step 2, please note that the previous TextBox will loose focus but the keyboard will still enabled.
It is easy by searching for the caret position, since it should be larger than 0