[comp.windows.news] X side of X/NeWS does not see /Synthetic keyboard events

hugh@hoptoad.uucp (Hugh Daniel) (04/09/91)

  I am working on a new keyboard for Sun's, its a chording keyboard (one
hand, but it comes with both left and right hand keyboards so you can go
really fast).  The current version plugs into a serial port, and I have
taken it's output and fed it into XNeWS.
  My problem is that when I generate a keyboard event via a NeWS event,
the X side of XNeWS does not see the event.  The events I generate are
exactly the same as the ones that are generated by the server except for
the undcoumented /Synthetic key/value which is readonly anyway.
  It seems silly for my client to sell keyboards that work for only some
of the windows on the screen!  So if anyone out there knows how to fix
this the right way please enlighten us all.

                ||ugh Daniel
hugh@toad.com                   Grasshopper  Group,   +1 415/668-5998
hugh@xanadu.com			210 Clayton St. San Francisco CA94117

hopkins@sun.com (Don Hopkins) (04/10/91)

In article <16956@hoptoad.uucp> hugh@hoptoad.uucp (Hugh Daniel) writes:

     I am working on a new keyboard for Sun's, its a chording keyboard (one
   hand, but it comes with both left and right hand keyboards so you can go
   really fast).  The current version plugs into a serial port, and I have
   taken it's output and fed it into XNeWS.
     My problem is that when I generate a keyboard event via a NeWS event,
   the X side of XNeWS does not see the event.  The events I generate are
   exactly the same as the ones that are generated by the server except for
   the undcoumented /Synthetic key/value which is readonly anyway.
     It seems silly for my client to sell keyboards that work for only some
   of the windows on the screen!  So if anyone out there knows how to fix
   this the right way please enlighten us all.

		   ||ugh Daniel
   hugh@toad.com                   Grasshopper  Group,   +1 415/668-5998
   hugh@xanadu.com			210 Clayton St. San Francisco CA94117

Try starting the xnews server with the -defeateventsecurity flag,
which I hope does just what you want:

     [ -defeateventsecurity ]
          This tells xnews to disable the security  feature  that
          detects  synthetically  created events.  Any event dis-
          tributed by the server, even if it  was  created  by  a
          client  program, will have a synthetic field with value
          false.  NeWS events will see this as a false  value  in
          the  /Synthetic  field  of events.  X11 events will all
          lack the synthetic bit in the type  field.   This  flag
          allows   clients  which  need  to  generated  synthetic
          events, such as the journalling demo, to run correctly.
          Running  the  X11/NeWS  server with this option enabled
          exposes your workstation to many security risks.  It is
          not recommended that this option be enabled except when
          explicitly needed.

This was from "xnews" server manual page (as opposed to "openwin"
shell script manual page).

	-Don