Subject: Re: Notification: incoming/697

From: David O Shea <[email-masked]>
Date: 6 Mar 2001 19:40:53 -0800

Hi Dominik,

First,

> Is this 'NCD' free software so I can get it for my system?

No, I'm referring to an NCD terminal, a sort of "dumb" terminal that supports X.  They seem to be popular for connecting to big Sun Sparc servers with.

> Does this happen with other applications too?  

No, it seems to be very specific to vncviewer in full-screen mode.

> Could you please try this with the latest beta realease and see if
> the problem persists?  If it does, can you provide the config
> files for vnc and fvwm so I can try to reproduce this?

Okay, I've tried using the latest beta and the problem persists.  Obviously since you don't have an NCD terminal you won't be able to reproduce the exact problem I had.  However, I found another situation that causes problems.  I modified by .tcshrc so that when tcsh is run in an xterm from my .xsession, it starts VNC automatically.  I found that, sometimes, I'd have VNC not respond to input at all after this startup, and this occured when the xterm had been raised over the top of my vncviewer.  This seemed to happen because of some timing issues with fvwm starting after the vncviewer had gone full-screen.  I basically put a "sleep 1" before calling vncviewer so that fvwm has started up before I start it and that fixed it.  The reason I mention this is that it might be a way for you to reproduce the problem without having to have an NCD terminal :)

I do wonder if there are other ways of screwing this up, though - maybe if I just make an xterm come up over the top of the vncviewer it'll screw up the session.  I'll try this and get back to you, as it'd be much easier for you than logging in and out.  I can't do this unless I'm at work (and I can't send you my .fvwm2rc either).

Thanks for your reply,
David

--
Find the best deals on the web at AltaVista Shopping!
http://www.shopping.altavista.com
--
Visit the official FVWM web page at <URL:http://www.fvwm.org/>.
To unsubscribe from the list, send "unsubscribe fvwm-workers" in the
body of a message to [email-masked].
To report problems, send mail to [email-masked]

---

From: Dominik Vogt <[email-masked]>
Date: Sun, 18 Mar 2001 03:54:19 +0100

> I do wonder if there are other ways of screwing this up, though - maybe if I just make an xterm come up over the top of the vncviewer it'll screw up the session.  I'll try this and get back to you,…

There is another way to make that happen.  Actually, all one has
to do is to take away the keyboard focus from the fullscreen vnc
window (which is an override redirect window which means that the
window manager knows nothing about it).  Fvwm will never give the
keyvboard focus to an override redirect window, so you are stuck
with the full screen vnc window without the input focus.

For example:

1) Use this in your fvwm config on the original server:

    Style * ClickToFocus
    Module FvwmCommandS

2) Open any window on the original server.

3) Start the vnc server.

4) Start the vncviewer in full screen mode on the vnc server.

5) Open a shell window in the vnc session.

6) Type this into the shell:

     export DISPLAY=<display>; FvwmCommand "next focus"

   (where display is the value of the DISPLAY variable on the
   original X server).

This will give the focus to a window on the original X server and
leave the vnc session stranded without keyboard input.

--

I don't see a clean way to cope with this situation inside fvwm.
Vnc explicitly requests that a long term window (its "root"
window) has the override redirect attribute which means that the
window manager basically does not know about it.  First of all,
this is a violation of the ICCCM2 specifications which demand
that only short lived windows use override redirect.  Next, vnc
does not grab the X server as it should do if it expects
continuous input from the X server.  For example, a message
window on the underlying X server might pop up and take away the
focus from vnc.  There are even applications that take the focus
on their own, even without a window manager.

This is really a bug in vnc that may show up depending on the
configuration on the underlying window manager and the running
applications.  The right fix would be to grab the X server for vnc
as soon as it enters full screen mode by calling XGrabServer().

Window managers are not supposed to manage override redirect
windows and doing so would be very hard.  Even if fvwm would
remember from which override redirect window it had taken the
focus, it would have no indication if the window still existed at
the moment fvwm tried to return the focus.  Well, it could check
the window id, but the window might already have died and been
replaced with a new window with the same id.

Please report this bug to the vnc developers.

--

P.S: Please replay always to the mailing lists, not to me
personally.

Bye

Dominik ^_^  ^_^

--
Dominik Vogt, [email-masked]
Reply-To: [email-masked]
--
Visit the official FVWM web page at <URL:http://www.fvwm.org/>.
To unsubscribe from the list, send "unsubscribe fvwm-workers" in the
body of a message to [email-masked].
To report problems, send mail to [email-masked]