WINDOWPATH environment variable?

Carsten Haitzler (The Rasterman) raster at rasterman.com
Mon Dec 5 02:35:44 PST 2005


On Mon, 5 Dec 2005 09:11:51 +0100 S$(D+1(Bbastien Hinderer
<Sebastien.Hinderer at ens-lyon.org> babbled:

> Hi,
> 
> Carsten Haitzler :
> > now given that, i suspect you are trying to attack a problem the wrong way.
> > why do you need such a path as an environment variable? what are you trying
> > to do, why do you need such a window id chain?
> 
> Our goal is to provide a uniform way for applications to communicate with
> braille terminals. This allows applications to write text to a braille
> display, and to read and handle keys pressed on the keyboard of braille
> terminals. The communication layer we provide also handles concurrent
> accesses to the lesource. That is, several applications are allowed to
> communicate with braille terminals simultaneously, but only the
> application having the focus will have its information sent to the
> braille device.
> 
> The way this concurrency management scheme is implemented is that each
> client tells the server in which window it is running. In addition,
> the server always knows which window has the focus, either because it
> found out this information on its own, or because a client told it who
> has the focus. And this is how the server can, at any moment, know
> precisely whichApplication should be allowed to communicate with the
> braille terminal. And this is where the WINDOWPATH environment
> variable would help. It would let clients know where they are.
> 
> That being said, we remain of course open to any suggestion, so please
> let us know if you have ideas about how we could deal with this problem
> in another way.

ok - now that's good. much better info now. so this is for output from a
terminal  (or any app that needs to display text) within an xnest environment
etc.

i would assume that it works well within a single xserver as you know what
window has the focus. even so it's a co-operative system as one client can just
pretend to have the same ID of another, unless u allow for unique id's only
(and a windowpath is an id). the problem here is - with xnested xservers we are
crossing a knowledge boundary that in general should normall yonly ever be
bridges BY the xserver. the other problem is it IS possible to have 2 FOCUSED
windows at once. a window within the xnest server and another outside of the
xnest in the host x. it is perfectly possible and plausible. in fact in
developing wm's i have this all the time as i use xnest a lot :).

now if both are actually focused - how do u know which should have brail
terminal write access? the windowpath doesnt solve this - i dont think. normal
keyboard INPUT is solved because the host xserver will just not pass on
keystrokes to the xnest server and thus the focused window within the xnest
will just not get any input. it can still output though and thus the clipping
of the host xserver and the xnest xserver are used to limit the output.
youbasicalyl need a way of doing this combined with the idea of focus. so you
need a reverse inheritence system. you will probably need a braile terminal
process for the xnest session that talks to a parent terminal process that
handles focus within this xserver. so that way the parent one will just deny
the child's output if a window other than the xnest window is focused. now how
do you have the parent process know that the child braille terminal server is
focused. this i think is the crux of the problem. i think this may be best done
with a very small extension. it simply adds events to the whole xserver
gaining/losing the focus (a toplevel server gains and always has the focus,
never losing it - though maybe when vt switching...). and being able to query
if the focus is ative on that xserver. it would be the simpler of extensions
and a clean solution i think. but this is just a first thought on it, but it
would cover all styles of nested xserver, multiple xservers on different vt's
etc. etc.

-- 
------------- Codito, ergo sum - "I code, therefore I am" --------------
The Rasterman (Carsten Haitzler)    raster at rasterman.com
$BMg9%B?(B
Tokyo, Japan ($BEl5~(B $BF|K\(B)



More information about the xorg mailing list