Mouse offset when using java swing based gui applications

Richard Evans
Thu Jul 15 14:41:00 GMT 2010

There's a bug reported against Java relating to this, with some more
details.  It claims to be fixed, but it still occurs.  There's a small
test case in the bug report.  It makes many Java UI applications
unusable with Cygwin/X.


-----Original Message-----
From: Jon TURNEY [] 
Sent: 15 July 2010 14:38
Subject: Re: Mouse offset when using java swing based gui applications

On 13/07/2010 22:56, Jonas Winkler wrote:
> I just noticed a very strange behaviour of my Cygwin/X-setup. I have a
> laptop running Debian 5.0 and openssh-server 1.5.1. My windows7 x64
> machine is running cygwin 1.7.5 and cygwin/x 1.8.0 (fresh
> I'm using ssh and x forwarding to use gui applications - especially
> Netbeans 6.9 - on my windows machine.
> So far, all X applications run fine on windows. Using Netbeans is
> somewhat weird. After startup, i can use the menues, edit code, etc.
> as soon as I change the window position (moving, maximizing) of
> Netbeans, it seems as if the position of the window actually does not
> change. Clicking works, but selecting a menu item not. I need to click
> and hold on the menu item, drag the mouse to the position where the
> would be before moving the window and then release it.
> Same goes for code completition windows - they pop up where they
> be before moving the window.
> I investigated a bit more and build a very basic Java gui application
> using swing (same library used by netbeans to display gui elemets) and
> the problem persists. As said before other applications (tested:
> gnome-terminal, gedit and nautilus) just work fine. So this is a
> swing-related rather than a netbeans-related problem.
> I attached the cygcheck.out. I dont know what other kind of
> I should provide, so if there's anything you need, please let me know.

Thanks very much for the clear problem report.

We've had some similar reports before of problems with the mouse
reporting with Java applications, for e.g. [1], but I've never had a
test case that has allowed me to reproduce it and investigate.

So, I'd be very interested to see your simple Java application which 
demonstrates the problem.

If you could also start the Xserver with the '-logverbose 3' option and
your /var/log/XWin.0.log, that would be most helpful.


Volunteer Cygwin/X X Server maintainer

Unsubscribe info:
Problem reports:

More information about the Cygwin-xfree mailing list