howto recognize the Shift and Alt keys when /pressed\
freebsd at edvax.de
Sat Oct 26 13:51:54 UTC 2013
On Wed, 23 Oct 2013 23:02:26 +0000, Gary Kline wrote:
> Organization: Thought Unlimited. Public service Unix since 1986.
> Of_Interest: With 27 years of service to the Unix community.
> On Sat, Oct 26, 2013 at 02:44:29AM +0200, Polytropon wrote:
> > On Fri, 25 Oct 2013 11:42:33 +0000, Gary Kline wrote:
> > > On Thu, Oct 24, 2013 at 02:11:32AM +0200, Polytropon wrote:
> > > > On Wed, 23 Oct 2013 16:38:05 +0000, Gary Kline wrote:
> > > > No need to re-invent the wheel here. Just "attach to" the
> > > > responsible components of the OS mentioned above. In C. :-)
> > > >
> > > >
> > >
> > >
> > > I wonder if I could take the src of xev.c and then,
> > > seeing what it does when I click on CTRL, ATL, CAPS LOCK,
> > > anf SHIFT. MAke any sense?
> > Yes, makes _perfectly_ sense as long as you're running X.
> > The X event viewer is a very good example on how to find
> > out the key codes. You simply need to get that "in between"
> > in the input chain so the keys keep working (instead of
> > "making them disappear" by reading them _from_ the input
> > buffer). I'd imagine that this is possible.
> I havent searched that far, but cant find xev.c; can you dig it out
> of the src and send it my way?
It's in the ports collection. Simply do the following:
# cd /usr/ports/x11/xev/
# make fetch
# make extract
# make patch
# cd work/xev-1.1.0
and you'll find xev.c and all other files belonging to that
program. Note that my installation here is quite old (8-STABLE
as of summer 2011) so there might be a newer version of xev
in the ports collection already. :-)
Happy FreeBSD user since 4.0
Andra moi ennepe, Mousa, ...
More information about the freebsd-questions