API requirements for sawfish in support of SPI


In my previous email I mentioned that we expected to need C bindings to some 
sawfish methods, in support of the AccessibleDesktop SPI.

AccessibleDesktop is actually just a special type of "Accessible" and it exports 
the same interfaces.  However the semantics of AccessibleDesktop are slightly 
different from those of Accessible, in that the children of AccessibleDesktop are 
always of type AccessibleApplication.

In summary the SPI methods that we expect will require calls to the accessible 
window manager (hopefully sawfish) are summarized as follows (based on the current 
SPI definitions):

short getVirtualDesktopCount ();

SomeReferenceToVirtualDesktop *getDesktop (in short n);

[given a reference to one of these virtual desktops, we need to be able to 
implement the following:]

wstring getName ();
wstring getDescription ();

[If virtual desktops have no "description" that's probably OK, one can be 

long getChildCount ();

[the above function, for an "AccessibleDesktop", should return the number of 
accessible applications that are associated with that virtual desktop.]

long getPIDAtIndex (in long index);

[Our implementation requires that the virtual desktop's getChildAtIndex method 
returns an AccessibleApplication.  Probably the best way to do this is to 
implement the above method in which the window manager returns the PID of the 
"Nth" application on said desktop.  Alternatively we need a way of getting a list 
of PIDs from the window manager, at which point we can construct the index-PID 
mapping ourselves. ]

long getIndexOfPID (in long PID);

[the above method would be nice, but again we can do the search ourselves if we 
have to, based on a window manager API that allows us to get a list of PIDs for a 
given virtual desktop].

boolean isActive (in short desktopIndex);

[Must be able to determine which desktop is the currently active one].

We also need to be able to register for the following window manager 

APPLICATION_ADDED (or new PID added to virtual desktop's app list)
APPLICATION_REMOVED (or moved from one desktop to another)

Note that since the last two events concern the relationship between apps and 
virtual desktops, not "window create" or "application exit", I think they need to 
be delivered by the window manager and not the application.


Bill Haneman x19279
Gnome Accessibility / Batik SVG Toolkit
Sun Microsystems Ireland 

[Date Prev][Date Next]   [Thread Prev][Thread Next]   [Thread Index] [Date Index] [Author Index]