On Thu, 15 Mar 2012 12:59:44 -0700, bourdox wrote:
> The real pain is trying to "correct" user actions as they happen...
Given that you are using a window manager, I do not think that there is
any way to do this with normal Motif or X programming. As I understand
the programming model, these Window managers are what actually controls
what and how a window is moved, not the application itself. You can
create a Window with certain constraints of course, but I do not think
you can reliably prevent windows from moving "too far" if you allow
movement at all. I think you can prevent movement at all....
I suppose that you can catch the movement action as you are doing and try
to "correct" it as you have been trying. Of course, that is likely to
lead to problems as you have seen. I am not familiar with the 1.2 Motif,
only 2.1, but maybe you can somehow ensure that movement operations do
not overlap somehow with timestamps? I know that there are some actions
in Motif that can be done with these timestamps, like some of the text
widget actions, but I am not familiar with what you can get done with the
1.2 callbacks on windows.
Maybe there is another way to setup your application so that you do not
have to rely on having moveable top-level windows?