Sponsored Content
Full Discussion: xlib and keyboard events
Top Forums UNIX for Advanced & Expert Users xlib and keyboard events Post 302721633 by DGPickett on Thursday 25th of October 2012 03:25:13 PM
Old 10-25-2012
Yes, but a tty solution works a it more simply, in an xterm or not. For the input side of your requirement, I do not see any requirement for X expertise to write such an app. Keeping things as simple as possible is usually a good thing. You can even script it:
Code:
$ stty raw -echo ; cat -uvte | line ; stty -raw echo
1234^M^C^D$
           $

There are good tutorials out there for just about everything: http://tronche.com/gui/x/xlib/input/
 

5 More Discussions You Might Find Interesting

1. UNIX for Advanced & Expert Users

How can I map Unix keyboard for PC keyboard

A Solaris AXI 440 machine with Solaris 8 version. I have PC users who use an emulation to login to the Solaris server. How can I change the keyboard mapping of the Sun keyboard to fit to the PC keyboard ? Any comment will be appreciated. Thanks (1 Reply)
Discussion started by: simhab
1 Replies

2. Programming

How to get capture input events from keyboard and mouse

Hi, Is there any way to capture/record the input events from keyboard, as well as from mouse using C. Thanks in advance (4 Replies)
Discussion started by: yhacks
4 Replies

3. Programming

Xlib mouse events and ButtonPressMask

I have written a simple program which will report key press and release events for a particular window. In my case, it is mostly the terminal since I invoke the program from the terminal. I am able to get the key press and release events taking place in the terminal window (I have used... (0 Replies)
Discussion started by: abhinav.zoso
0 Replies

4. UNIX for Dummies Questions & Answers

Problem getting vertical bar with British keyboard layout on US (physical) keyboard

Hi, I've got a bit of a ridiculous problem and wasn't sure where to post it. I need to use the vertical bar for piping in Bash but, as per the title, am using a UK layout on a US (physical) keyboard which doesn't have a key for it in the place I'd expect. I've tried using xbindkeys and Unicode... (7 Replies)
Discussion started by: crunchgargoyle
7 Replies

5. Programming

Xlib registering

hey, Im new to the linux world. Lately, I have tried to create a glx window with xlib, making it a popup window(fullscreen) so I set override_redirect to true. Im happy with the removed borders, but apparantly, the application doesnt show up in the left bar in ubuntu, neither when I press alt... (4 Replies)
Discussion started by: thedardanius
4 Replies
STTY(3) 						   BSD Library Functions Manual 						   STTY(3)

NAME
stty, gtty -- set and get terminal state (defunct) LIBRARY
Compatibility Library (libcompat, -lcompat) SYNOPSIS
#include <sgtty.h> stty(int fd, struct sgttyb *buf); gtty(int fd, struct sgttyb *buf); DESCRIPTION
These interfaces are obsoleted by ioctl(2). They are available from the compatibility library, libcompat. The stty() function sets the state of the terminal associated with fd. The gtty() function retrieves the state of the terminal associated with fd. To set the state of a terminal the call must have write permission. The stty() call is actually 'ioctl(fd, TIOCSETP, buf)', while the gtty() call is 'ioctl(fd, TIOCGETP, buf)'. See ioctl(2) and tty(4) for an explanation. DIAGNOSTICS
If the call is successful 0 is returned, otherwise -1 is returned and the global variable errno contains the reason for the failure. SEE ALSO
ioctl(2), tty(4) HISTORY
The stty() and gtty() functions appeared in 4.2BSD. BSD
June 4, 1993 BSD
All times are GMT -4. The time now is 08:50 AM.
Unix & Linux Forums Content Copyright 1993-2022. All Rights Reserved.
Privacy Policy