On Sun, 6 Jan 2002, Davy Durham wrote:

> Hi,
>    I'm developing an audio editor where the user can open multiple audio
> files at once.   So there is a main window and a child window for each
> sound loaded (by window I mean, top level, with title bar and all)...
> 
>    Now, the play control and action buttons are on the separate main
> window... I would like to have the idea of the 'active' sound window so
> that when the user hits the play button it plays the sound for the
> 'active' sound window...

   All of this is window manager dependent.

> 
>   The question remains: "How do I know what the 'active' sound window
> is"
>         - Is it the last focused sound window?  No, because I like the
> focus to follow the mouse pointer.
>         - Well, I think it's the last window raised.  But, alas, there
> is no X event for when a window is raised.

   There should be some visual queue indicating which window is
active.  Maybe a checkbox or something.

> 
>    What I thought I might be able to do is query the window stacking
> order from X... If I knew the top most window (which represents a loaded
> sound), then that would be the window for which I play the sound when
> the play button is pressed.

   The active window might not be top-most.  It's up to the window
manager.  In my fvwm configuration, I don't have windows pop to the
top when I'm working in them.  I've have to explicitly click the
title bar to move them forward. 

   I don't think relying on window position in the stack makes
for a good user interface.  I think you're better off with a
checkbox indicating which is current, and not changing it until
somebody clicks a different box.  Just my opinion.


                                Mark.


_______________________________________________
Xpert mailing list
[EMAIL PROTECTED]
http://XFree86.Org/mailman/listinfo/xpert

Reply via email to