public inbox for cygwin-xfree@sourceware.org help / color / mirror / Atom feed
* text fields in app don't allow input when running Cygwin X [not found] <1364236089.7676.YahooMailNeo@web122603.mail.ne1.yahoo.com> @ 2013-03-25 18:39 ` KM 2013-03-27 16:09 ` Jon TURNEY [not found] ` <1366210255.40306.YahooMailNeo@web122602.mail.ne1.yahoo.com> 0 siblings, 2 replies; 12+ messages in thread From: KM @ 2013-03-25 18:39 UTC (permalink / raw) To: cygwin-xfree I have an application that I have always compiled on Linux and then invoked via X Windows with my installed Cygwin X. Basically use a shortcut to startwin.exe (full command is C:\cygwin\bin\run.exe /usr/bin/bash.exe -l -c /usr/bin/startxwin.exe ). This always started my X server in the background (no root window, or invisible root window), and still does. All I had to do is log into my server, export my DISPLAY and start the app. However I have recompiled my application with java 7 and now all of the radio buttons, buttons, scrollbars, and checkboxes, etc. all still work as before. The only thing that does NOT work is a text field. I can not get the focus of the mouse in there, nor can I change or enter any data in those fields. When I start Cygwin x from the Cygwin xterminal in a windowed env (e.g. starx from command line), and export my DISPLAY on the server, the application works, but is contained within the root window. I never had to do it this way before and it looks slightly different, no separate window borders etc. We also use Reflection for an X server - that seems to run the recompiled application fine. Any ideas? Also I apologize if I'm not saying this quite right! Thanks for any help. If you need more info let me know. KM -- Unsubscribe info: http://cygwin.com/ml/#unsubscribe-simple Problem reports: http://cygwin.com/problems.html Documentation: http://x.cygwin.com/docs/ FAQ: http://x.cygwin.com/docs/faq/ ^ permalink raw reply [flat|nested] 12+ messages in thread
* Re: text fields in app don't allow input when running Cygwin X 2013-03-25 18:39 ` text fields in app don't allow input when running Cygwin X KM @ 2013-03-27 16:09 ` Jon TURNEY 2013-03-28 6:58 ` Mark Hansen [not found] ` <1366210255.40306.YahooMailNeo@web122602.mail.ne1.yahoo.com> 1 sibling, 1 reply; 12+ messages in thread From: Jon TURNEY @ 2013-03-27 16:09 UTC (permalink / raw) To: cygwin-xfree On 25/03/2013 18:39, KM wrote: > I have an application that I have always compiled on Linux and then invoked > via X Windows with my installed Cygwin X. Basically use a shortcut to > startwin.exe (full command is C:\cygwin\bin\run.exe /usr/bin/bash.exe -l > -c /usr/bin/startxwin.exe ). This always started my X server in the > background (no root window, or invisible root window), and still does. > All I had to do is log into my server, export my DISPLAY and start the > app. > > However I have recompiled my application with java 7 and now all of the > radio buttons, buttons, scrollbars, and checkboxes, etc. all still work as > before. The only thing that does NOT work is a text field. I can not get > the focus of the mouse in there, nor can I change or enter any data in > those fields. > > When I start Cygwin x from the Cygwin xterminal in a windowed env (e.g. > starx from command line), and export my DISPLAY on the server, the > application works, but is contained within the root window. I never had to > do it this way before and it looks slightly different, no separate window > borders etc. > > We also use Reflection for an X server - that seems to run the recompiled > application fine. > > Any ideas? Also I apologize if I'm not saying this quite right! Thanks for > any help. If you need more info let me know. There have been some problems in the past with assumptions that Java Windowing toolkits makes about window manager behaviour which XWin's multiwidow mode breaks (e.g. [1],[2]), so this might be something similar. If you can provide a *small* Java application which demonstrates the problem, and the precise java version which you are using, I will see if I can reproduce and investigate the problem. [1] https://bugs.eclipse.org/bugs/show_bug.cgi?id=36806 [2] http://cygwin.com/ml/cygwin-xfree/2010-07/msg00079.html -- Jon TURNEY Volunteer Cygwin/X X Server maintainer -- Unsubscribe info: http://cygwin.com/ml/#unsubscribe-simple Problem reports: http://cygwin.com/problems.html Documentation: http://x.cygwin.com/docs/ FAQ: http://x.cygwin.com/docs/faq/ ^ permalink raw reply [flat|nested] 12+ messages in thread
* Re: text fields in app don't allow input when running Cygwin X 2013-03-27 16:09 ` Jon TURNEY @ 2013-03-28 6:58 ` Mark Hansen 0 siblings, 0 replies; 12+ messages in thread From: Mark Hansen @ 2013-03-28 6:58 UTC (permalink / raw) To: cygwin-xfree On 3/27/2013 9:09 AM, Jon TURNEY wrote: > On 25/03/2013 18:39, KM wrote: >> I have an application that I have always compiled on Linux and then invoked >> via X Windows with my installed Cygwin X. Basically use a shortcut to >> startwin.exe (full command is C:\cygwin\bin\run.exe /usr/bin/bash.exe -l >> -c /usr/bin/startxwin.exe ). This always started my X server in the >> background (no root window, or invisible root window), and still does. >> All I had to do is log into my server, export my DISPLAY and start the >> app. >> >> However I have recompiled my application with java 7 and now all of the >> radio buttons, buttons, scrollbars, and checkboxes, etc. all still work as >> before. The only thing that does NOT work is a text field. I can not get >> the focus of the mouse in there, nor can I change or enter any data in >> those fields. >> >> When I start Cygwin x from the Cygwin xterminal in a windowed env (e.g. >> starx from command line), and export my DISPLAY on the server, the >> application works, but is contained within the root window. I never had to >> do it this way before and it looks slightly different, no separate window >> borders etc. >> >> We also use Reflection for an X server - that seems to run the recompiled >> application fine. >> >> Any ideas? Also I apologize if I'm not saying this quite right! Thanks for >> any help. If you need more info let me know. > > There have been some problems in the past with assumptions that Java Windowing > toolkits makes about window manager behaviour which XWin's multiwidow mode > breaks (e.g. [1],[2]), so this might be something similar. > > If you can provide a *small* Java application which demonstrates the problem, > and the precise java version which you are using, I will see if I can > reproduce and investigate the problem. > > [1] https://bugs.eclipse.org/bugs/show_bug.cgi?id=36806 > [2] http://cygwin.com/ml/cygwin-xfree/2010-07/msg00079.html > I had a problem with one Java application when running on a Linux host and displaying to my Cygwin X server on my local PC. This started when the application first moved to Java 1.6 and the problems I encountered were not identical to the OP's problems, but I thought I would mention my work around anyway, in case it helps. I just added the following command-line argument to the Java command line: -Dawt.toolkit=sun.awt.motif.MToolkit Good luck. -- Unsubscribe info: http://cygwin.com/ml/#unsubscribe-simple Problem reports: http://cygwin.com/problems.html Documentation: http://x.cygwin.com/docs/ FAQ: http://x.cygwin.com/docs/faq/ ^ permalink raw reply [flat|nested] 12+ messages in thread
[parent not found: <1366210255.40306.YahooMailNeo@web122602.mail.ne1.yahoo.com>]
* Re: text fields in app don't allow input when running Cygwin X [not found] ` <1366210255.40306.YahooMailNeo@web122602.mail.ne1.yahoo.com> @ 2013-06-13 14:02 ` Deryl Steinert 2013-06-13 15:00 ` Deryl Steinert 0 siblings, 1 reply; 12+ messages in thread From: Deryl Steinert @ 2013-06-13 14:02 UTC (permalink / raw) To: cygwin-xfree I am seeing this same issue with running a Java 7 app through the Cygwin xserver in multiwindowed mode (startxwin). Once a Java window loses keyboard focus I can't get it to regain focus for keyboard events. Basically all keyboard input to a window must be completed without the window losing focus or the window will appear to hang. At least my users are seeing it as a hang even though the app is still responsive to other interaction (buttons, menus, etc). Just not keyboard input. New Java windows that are opened do have keyboard input focus until that window loses focus. As KM states it all works fine when running the Cygwin xserver in windowed mode (startx rather than startxwin). A possible explanation is that the Focus model has changed in Java 7. See section "2.7.2 Communication With Native Focus System" from the following link; http://docs.oracle.com/javase/7/docs/webnotes/tsg/TSG-Desktop/html/awt.html So, is this a bug in Cygwin, Java 7 or our apps? Thank you for any insight. -- View this message in context: http://cygwin.1069669.n5.nabble.com/text-fields-in-app-don-t-allow-input-when-running-Cygwin-X-tp97212p99552.html Sent from the cygwin-xfree mailing list archive at Nabble.com. -- Unsubscribe info: http://cygwin.com/ml/#unsubscribe-simple Problem reports: http://cygwin.com/problems.html Documentation: http://x.cygwin.com/docs/ FAQ: http://x.cygwin.com/docs/faq/ ^ permalink raw reply [flat|nested] 12+ messages in thread
* Re: text fields in app don't allow input when running Cygwin X 2013-06-13 14:02 ` Deryl Steinert @ 2013-06-13 15:00 ` Deryl Steinert 2013-06-15 21:31 ` Jon TURNEY 0 siblings, 1 reply; 12+ messages in thread From: Deryl Steinert @ 2013-06-13 15:00 UTC (permalink / raw) To: cygwin-xfree Here is a reference to a Java bug that suggests that the problem may be related to the X window manager being used; http://bugs.sun.com/view_bug.do?bug_id=6798064 It doesn't specifically address the issue under Cygwin but does talk about the issue occurring under the ION window manager which is not officially supported by Java. Perhaps the internal window manager used by Cygwin in multwindowed mode has the same issue? Can the default internal window manger be changed when starting Xwin in multiwindow mode? Thanks! -- View this message in context: http://cygwin.1069669.n5.nabble.com/text-fields-in-app-don-t-allow-input-when-running-Cygwin-X-tp97212p99554.html Sent from the cygwin-xfree mailing list archive at Nabble.com. -- Unsubscribe info: http://cygwin.com/ml/#unsubscribe-simple Problem reports: http://cygwin.com/problems.html Documentation: http://x.cygwin.com/docs/ FAQ: http://x.cygwin.com/docs/faq/ ^ permalink raw reply [flat|nested] 12+ messages in thread
* Re: text fields in app don't allow input when running Cygwin X 2013-06-13 15:00 ` Deryl Steinert @ 2013-06-15 21:31 ` Jon TURNEY 2013-06-17 14:44 ` Deryl Steinert 0 siblings, 1 reply; 12+ messages in thread From: Jon TURNEY @ 2013-06-15 21:31 UTC (permalink / raw) To: cygwin-xfree; +Cc: dus On 13/06/2013 16:00, Deryl Steinert wrote: > Here is a reference to a Java bug that suggests that the problem may be > related to the X window manager being used; > > http://bugs.sun.com/view_bug.do?bug_id=6798064 > > It doesn't specifically address the issue under Cygwin but does talk about > the issue occurring under the ION window manager which is not officially > supported > by Java. Thanks for researching this issue. > Perhaps the internal window manager used by Cygwin in multwindowed mode has > the same issue? Yes, this seems quite likely, the multiwindow mode WM has no support for WM_TAKE_FOCUS currently (One of it's many ICCCM conformance issues :-) ). Reading the text of the ICCCM ([1] 4.1.7. etc.), it's not quite clear to me that WM_TAKE_FOCUS support is mandatory for the WM (it's clearly optional for a client), but the bug above seems to be saying that Java 7 requires it for focusing to work as expected. > Can the default internal window manger be changed when starting Xwin in > multiwindow mode? No, it's internal because it's a special window manager that knows how to draw the X window contents in native Window frames, you can't replace it with an arbitrary other WM. XtoW [2] is another WM that also knows how to achieve this (by different means), but probably suffers from the same bug. [1] http://www.tronche.com/gui/x/icccm/ [2] http://cygwin.com/ml/cygwin-xfree-announce/2012-12/msg00003.html -- Jon TURNEY Volunteer Cygwin/X X Server maintainer -- Unsubscribe info: http://cygwin.com/ml/#unsubscribe-simple Problem reports: http://cygwin.com/problems.html Documentation: http://x.cygwin.com/docs/ FAQ: http://x.cygwin.com/docs/faq/ ^ permalink raw reply [flat|nested] 12+ messages in thread
* Re: text fields in app don't allow input when running Cygwin X 2013-06-15 21:31 ` Jon TURNEY @ 2013-06-17 14:44 ` Deryl Steinert 2013-06-19 14:37 ` Jon TURNEY 0 siblings, 1 reply; 12+ messages in thread From: Deryl Steinert @ 2013-06-17 14:44 UTC (permalink / raw) To: cygwin-xfree Hi, Jon, Thanks for the quick response. Do you consider this an issue with Cygwin, Java 7 or with our Java apps? If the issue is with Cygwin do you foresee implementing a solution anytime = soon? Or do you know of a workaround we can use in Java? Trying to figure out what I can do to remedy the issue for my Windows custo= mers. I'm a Mac user myself. Do I spend time trying to workaround the issue? Wait for a Cygwin solution? Or just tell my customers that they can't use Cygwin in multi window mode w= ith the next release of my app? Thanks, Deryl -- View this message in context: http://cygwin.1069669.n5.nabble.com/text-fields-in-app-don-t-allow-input-when-running-Cygwin-X-tp97212p99717.html Sent from the cygwin-xfree mailing list archive at Nabble.com. -- Unsubscribe info: http://cygwin.com/ml/#unsubscribe-simple Problem reports: http://cygwin.com/problems.html Documentation: http://x.cygwin.com/docs/ FAQ: http://x.cygwin.com/docs/faq/ ^ permalink raw reply [flat|nested] 12+ messages in thread
* Re: text fields in app don't allow input when running Cygwin X 2013-06-17 14:44 ` Deryl Steinert @ 2013-06-19 14:37 ` Jon TURNEY 2013-06-19 16:03 ` Deryl Steinert 2013-06-28 12:38 ` Jon TURNEY 0 siblings, 2 replies; 12+ messages in thread From: Jon TURNEY @ 2013-06-19 14:37 UTC (permalink / raw) To: cygwin-xfree; +Cc: dus On 17/06/2013 15:44, Deryl Steinert wrote: > Do you consider this an issue with Cygwin, Java 7 or with our Java apps? If > the issue is with Cygwin do you foresee implementing a solution anytime > soon? Or do you know of a workaround we can use in Java? This might just be a bug in the way the multiwindow mode WM handles focus. Even if it isn't, a workaround in the multiwindow mode WM seems like a good idea. There are no guarantees about when. Patches thoughtfully considered. Sorry, I don't know enough about the Java windowing toolkit to know if this can be worked around in Java. > Trying to figure out what I can do to remedy the issue for my Windows > customers. I'm a Mac user myself. > > Do I spend time trying to workaround the issue? Wait for a Cygwin > solution? Or just tell my customers that they can't use Cygwin in multi > window mode with the next release of my app? -- Jon TURNEY Volunteer Cygwin/X X Server maintainer -- Unsubscribe info: http://cygwin.com/ml/#unsubscribe-simple Problem reports: http://cygwin.com/problems.html Documentation: http://x.cygwin.com/docs/ FAQ: http://x.cygwin.com/docs/faq/ ^ permalink raw reply [flat|nested] 12+ messages in thread
* Re: text fields in app don't allow input when running Cygwin X 2013-06-19 14:37 ` Jon TURNEY @ 2013-06-19 16:03 ` Deryl Steinert 2013-06-28 12:38 ` Jon TURNEY 1 sibling, 0 replies; 12+ messages in thread From: Deryl Steinert @ 2013-06-19 16:03 UTC (permalink / raw) To: cygwin-xfree Jon, Here is a link to another java bug report that does refer to CygwinX directly; http://bugs.sun.com/bugdatabase/view_bug.do?bug_id=7147075 Thanks, Deryl -- View this message in context: http://cygwin.1069669.n5.nabble.com/text-fields-in-app-don-t-allow-input-when-running-Cygwin-X-tp97212p99889.html Sent from the cygwin-xfree mailing list archive at Nabble.com. -- Unsubscribe info: http://cygwin.com/ml/#unsubscribe-simple Problem reports: http://cygwin.com/problems.html Documentation: http://x.cygwin.com/docs/ FAQ: http://x.cygwin.com/docs/faq/ ^ permalink raw reply [flat|nested] 12+ messages in thread
* Re: text fields in app don't allow input when running Cygwin X 2013-06-19 14:37 ` Jon TURNEY 2013-06-19 16:03 ` Deryl Steinert @ 2013-06-28 12:38 ` Jon TURNEY 2013-07-08 21:21 ` Deryl Steinert 1 sibling, 1 reply; 12+ messages in thread From: Jon TURNEY @ 2013-06-28 12:38 UTC (permalink / raw) To: cygwin-xfree; +Cc: dus, info4km On 19/06/2013 15:37, Jon TURNEY wrote: > On 17/06/2013 15:44, Deryl Steinert wrote: >> Do you consider this an issue with Cygwin, Java 7 or with our Java apps? If >> the issue is with Cygwin do you foresee implementing a solution anytime >> soon? Or do you know of a workaround we can use in Java? > > This might just be a bug in the way the multiwindow mode WM handles focus. > > Even if it isn't, a workaround in the multiwindow mode WM seems like a good > idea. There are no guarantees about when. Patches thoughtfully considered. Looking at this again, while the text of ICCCM section 4.1.7 is pretty opaque, the implementation actually seems to be quite straightforward. I've added a patch which makes input focus handling more closely follow ICCCM, and generates the WM_TAKE_FOCUS message when needed. I've tested this very briefly with the TypeInSwing.java test case in sun bug #6798064 and the jdk Notepad demo. I've uploaded a snapshot at [1]. Perhaps you could try that and see if it improves things for you? [1] ftp://cygwin.com/pub/cygwinx/XWin.20130628-git-c1a05551e2bc2d30.exe.bz2 -- Jon TURNEY Volunteer Cygwin/X X Server maintainer -- Unsubscribe info: http://cygwin.com/ml/#unsubscribe-simple Problem reports: http://cygwin.com/problems.html Documentation: http://x.cygwin.com/docs/ FAQ: http://x.cygwin.com/docs/faq/ ^ permalink raw reply [flat|nested] 12+ messages in thread
* Re: text fields in app don't allow input when running Cygwin X 2013-06-28 12:38 ` Jon TURNEY @ 2013-07-08 21:21 ` Deryl Steinert 2013-07-08 22:08 ` Jon TURNEY 0 siblings, 1 reply; 12+ messages in thread From: Deryl Steinert @ 2013-07-08 21:21 UTC (permalink / raw) To: cygwin-xfree Jon, Thanks for all the help and explanation. The new XWin.exe seems to fix the problem. I just set up a link from /usr/bin/XWin.exe to the new .exe file so that I can switch between the original and new easier. I can reproduce the issue with the original and the issue is fixed with the new XWin.exe. I did notice a lot more debug info coming out to my terminal from the X server and I see that the .exe file is much larger than the original; <http://cygwin.1069669.n5.nabble.com/file/n100563/Capture.jpg> Do you expect to make this an official mod to the base or should I pass this snapshot to my customers? Is there any way to turn off the debug info from the x server? Thanks so much for all you have done with this! Deryl -- View this message in context: http://cygwin.1069669.n5.nabble.com/text-fields-in-app-don-t-allow-input-when-running-Cygwin-X-tp97212p100563.html Sent from the cygwin-xfree mailing list archive at Nabble.com. -- Unsubscribe info: http://cygwin.com/ml/#unsubscribe-simple Problem reports: http://cygwin.com/problems.html Documentation: http://x.cygwin.com/docs/ FAQ: http://x.cygwin.com/docs/faq/ ^ permalink raw reply [flat|nested] 12+ messages in thread
* Re: text fields in app don't allow input when running Cygwin X 2013-07-08 21:21 ` Deryl Steinert @ 2013-07-08 22:08 ` Jon TURNEY 0 siblings, 0 replies; 12+ messages in thread From: Jon TURNEY @ 2013-07-08 22:08 UTC (permalink / raw) To: cygwin-xfree; +Cc: dus On 08/07/2013 22:21, Deryl Steinert wrote: > Thanks for all the help and explanation. > The new XWin.exe seems to fix the problem. > > I just set up a link from /usr/bin/XWin.exe to the new .exe file > so that I can switch between the original and new easier. > I can reproduce the issue with the original and the issue is > fixed with the new XWin.exe. > > I did notice a lot more debug info coming out to my terminal > from the X server and I see that the .exe file is much larger > than the original; Yes, this is a unstripped, debug build. > Do you expect to make this an official mod to the base or should I pass this > snapshot > to my customers? I'll package an updated release including this fix, probably tomorrow. > Is there any way to turn off the debug info from the x server? > > Thanks so much for all you have done with this! Thanks for testing. -- Jon TURNEY Volunteer Cygwin/X X Server maintainer -- Unsubscribe info: http://cygwin.com/ml/#unsubscribe-simple Problem reports: http://cygwin.com/problems.html Documentation: http://x.cygwin.com/docs/ FAQ: http://x.cygwin.com/docs/faq/ ^ permalink raw reply [flat|nested] 12+ messages in thread
end of thread, other threads:[~2013-07-08 22:08 UTC | newest] Thread overview: 12+ messages (download: mbox.gz / follow: Atom feed) -- links below jump to the message on this page -- [not found] <1364236089.7676.YahooMailNeo@web122603.mail.ne1.yahoo.com> 2013-03-25 18:39 ` text fields in app don't allow input when running Cygwin X KM 2013-03-27 16:09 ` Jon TURNEY 2013-03-28 6:58 ` Mark Hansen [not found] ` <1366210255.40306.YahooMailNeo@web122602.mail.ne1.yahoo.com> 2013-06-13 14:02 ` Deryl Steinert 2013-06-13 15:00 ` Deryl Steinert 2013-06-15 21:31 ` Jon TURNEY 2013-06-17 14:44 ` Deryl Steinert 2013-06-19 14:37 ` Jon TURNEY 2013-06-19 16:03 ` Deryl Steinert 2013-06-28 12:38 ` Jon TURNEY 2013-07-08 21:21 ` Deryl Steinert 2013-07-08 22:08 ` Jon TURNEY
This is a public inbox, see mirroring instructions for how to clone and mirror all data and code used for this inbox; as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).