Google Groups no longer supports new Usenet posts or subscriptions. Historical content remains viewable.
Dismiss

On-Screen keyboard: how is it done?

3 views
Skip to first unread message

Polaris

unread,
May 10, 2008, 2:14:18 PM5/10/08
to
Hi Experts:

I saw an PC without keyboard attached, it uses an on-screen keyboard
software program. When user clicks on a "key" (a button) on the program, the
program can find the currently active (focused) window application (for
example, notepad.exe) and input "typed" key into that active program; but
the keyboard program itself seems did not get activated while user click on
a button on it.

I could not figure out how it is accomplished? How does the keyboard program
avoid getting focus (active) even when user click on a "key" button of the
program? It must be able to do so in order to find the currently active
Windows program that user is working with (etc, a notepad.exe).

Thanks for your thoughts in advance.
Polaris

Marcin Hoppe

unread,
May 10, 2008, 2:40:13 PM5/10/08
to
Polaris pisze:

> Thanks for your thoughts in advance.

What I'd do if I were you and didn't want to buy an off-the-shelf
product (like itKeyboard from http://www.touch-soft.com/) would be to
download a trial version of an off-the-shelf product and use Spy++ to
look at messages that it sends and receives.

Best regards!
--
Marcin Hoppe
Email: marcin...@gmail.com
Blog: http://devlicio.us/blogs/marcin_hoppe

Scott Seligman

unread,
May 10, 2008, 2:45:06 PM5/10/08
to
"Polaris" <etpo...@hotmail.com> wrote:
>
>I could not figure out how it is accomplished? How does the keyboard program
>avoid getting focus (active) even when user click on a "key" button of the
>program? It must be able to do so in order to find the currently active
>Windows program that user is working with (etc, a notepad.exe).

The window has the WS_EX_NOACTIVATE extended window style set.

--
--------- Scott Seligman <scott at <firstname> and michelle dot net> ---------
The universe is driven by the complex interaction between three
ingredients: matter, energy, and enlightened self-interest.
-- G'Kar in Babylon 5:"Survivors"

David Ching

unread,
May 10, 2008, 4:44:52 PM5/10/08
to
"Scott Seligman" <seli...@example.com> wrote in message
news:g04qfi$s1e$1...@panix3.panix.com...

> The window has the WS_EX_NOACTIVATE extended window style set.
>

Very cool... I had not known about this style. Before Win2K, the way to do
it was to intercept WM_MOUSEACTIVATE and return MA_NOACTIVATE (or
MA_NOACTIVATEANDEAT).

-- David


clintonG

unread,
May 11, 2008, 1:10:44 PM5/11/08
to
Go look around http://www.codeproject.com/

"Polaris" <etpo...@hotmail.com> wrote in message
news:OSU6wmss...@TK2MSFTNGP04.phx.gbl...

0 new messages