public inbox for cygwin-xfree@sourceware.org
help / color / mirror / Atom feed
* nomultiplemonitors does not work in windowed mode
@ 2011-06-30 12:16 szalai endre
  2011-06-30 17:03 ` Jon TURNEY
  0 siblings, 1 reply; 6+ messages in thread
From: szalai endre @ 2011-06-30 12:16 UTC (permalink / raw)
  To: cygwin-xfree

Guys, I am going crazy. I have 2 monitors and I would like Cygwin-X to use only the primary. So I am using the nomultiplemonitors option like this:
xwin.exe -nomultiplemonitors

But. Cygwin has the following modes:
(default) Windowed or rooted mode.
This is not an option, I want to use the multiwindow mode. Otherwise I could just use VNC, using Cygwin-X for this is pointless (for me).

-multiwindow
This mode automatically sets the multiplemonitors option and it cannot be overriden from command line.

-rootless
Unusable, since I can't move to resize the windows.

-mwextwm
This one gets frozen, so it's not really an option right now.

Do I see correctly, that the only mode that would be usable for me (multiwindow) cannot be used with the option -nomultiplemonitors?

Please advice.

Thanks,
Endre

--
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] 6+ messages in thread

* Re: nomultiplemonitors does not work in windowed mode
  2011-06-30 12:16 nomultiplemonitors does not work in windowed mode szalai endre
@ 2011-06-30 17:03 ` Jon TURNEY
  2011-06-30 20:48   ` szalai endre
  0 siblings, 1 reply; 6+ messages in thread
From: Jon TURNEY @ 2011-06-30 17:03 UTC (permalink / raw)
  To: cygwin-xfree; +Cc: hufilufi

On 30/06/2011 13:16, szalai endre wrote:
> Guys, I am going crazy. I have 2 monitors and I would like Cygwin-X to use only the primary. So I am using the nomultiplemonitors option like this:
> xwin.exe -nomultiplemonitors
> 
> But. Cygwin has the following modes:
> (default) Windowed or rooted mode.
> This is not an option, I want to use the multiwindow mode. Otherwise I could just use VNC, using Cygwin-X for this is pointless (for me).
> 
> -multiwindow
> This mode automatically sets the multiplemonitors option and it cannot be overriden from command line.

What is it that makes you think this?

For the current version of Cygwin/X this is not the case.  However, perhaps it
should be, as it doesn't work in a useful way.  You can move the X windows off
the primary monitor, but they don't get their contents drawn when you do so
(because the underlying X screen is only the size of the primary monitor)

I'm not sure if I understand what you are expecting to happen with
-multiwindow -nomultiplemonitors:  Should the X windows be forced to stay on
the primary monitor when you try to move them off it?  It might also help to
describe your use case in a bit more detail.

> -rootless
> Unusable, since I can't move to resize the windows.

You will need to run an X window manager to move, resize etc. the X windows in
this mode, as described at [1]

> -mwextwm
> This one gets frozen, so it's not really an option right now.

As bug reports go, this leaves something to be desired :-)

> Do I see correctly, that the only mode that would be usable for me (multiwindow) cannot be used with the option -nomultiplemonitors?
> 
> Please advice.

[1] http://x.cygwin.com/docs/ug/configure.html#configure-cygwin-x-windowing-modes

-- 
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] 6+ messages in thread

* Re: nomultiplemonitors does not work in windowed mode
  2011-06-30 17:03 ` Jon TURNEY
@ 2011-06-30 20:48   ` szalai endre
  2011-07-01 15:28     ` Jon TURNEY
  0 siblings, 1 reply; 6+ messages in thread
From: szalai endre @ 2011-06-30 20:48 UTC (permalink / raw)
  To: cygwin-xfree, cygwin-xfree

Hi,

>> This mode automatically sets the multiplemonitors option and it cannot be overriden from command line.
> What is it that makes you think this?

According to XWin docs:
"-[no]multimonitors or -[no]multiplemonitors
Create a screen 0 that covers all monitors [the primary monitor] on a system with multiple monitors. This option is currently enabled by default in -multiwindow mode."

And this is exactly what happens. When I start a program, it shows up on both monitors (half here, half there). This is not supposed to happen (see next point). 

> I'm not sure if I understand what you are expecting to happen with -multiwindow -nomultiplemonitors: 

I have 2 monitors. Imagine you turn off one of them and you want to use the other one only. Currently, Cygwin-X will span over all monitors - unless you use the multiplemonitors option. I think the goal for this option is very clear from the docs: use only 1 monitor for the root window, no matter what. So I would expect this behavior: you should not be able to move off windows from the primary monitor, at all. The point is, you want to limit the root window to one monitor only.

I see the -multiwindow and -nomultiplemonitors options completely independent from each other. They should not have any relationship at all. The first just tells how you want to map windows within the root window, while the other simply specifies how many monitors you want to use for the root window.

I thought it is very clear from the docs, however your questions make me uncertain. Isn't is supposed to work like that?

Thanks,
Endre



Jon TURNEY <jon.turney@dronecode.org.uk> írta:
>On 30/06/2011 13:16, szalai endre wrote:>
> Guys, I am going crazy. I have 2 monitors and I would like Cygwin-X to use only the primary. So I am using the nomultiplemonitors option like this:>
> xwin.exe -nomultiplemonitors>
> >
> But. Cygwin has the following modes:>
> (default) Windowed or rooted mode.>
> This is not an option, I want to use the multiwindow mode. Otherwise I could just use VNC, using Cygwin-X for this is pointless (for me).>
> >
> -multiwindow>
> This mode automatically sets the multiplemonitors option and it cannot be overriden from command line.>
>
What is it that makes you think this?>
>
For the current version of Cygwin/X this is not the case.  However, perhaps it>
should be, as it doesn't work in a useful way.  You can move the X windows off>
the primary monitor, but they don't get their contents drawn when you do so>
(because the underlying X screen is only the size of the primary monitor)>
>
I'm not sure if I understand what you are expecting to happen with>
-multiwindow -nomultiplemonitors:  Should the X windows be forced to stay on>
the primary monitor when you try to move them off it?  It might also help to>
describe your use case in a bit more detail.>
>
> -rootless>
> Unusable, since I can't move to resize the windows.>
>
You will need to run an X window manager to move, resize etc. the X windows in>
this mode, as described at [1]>
>
> -mwextwm>
> This one gets frozen, so it's not really an option right now.>
>
As bug reports go, this leaves something to be desired :-)>
>
> Do I see correctly, that the only mode that would be usable for me (multiwindow) cannot be used with the option -nomultiplemonitors?>
> >
> Please advice.>
>
[1] http://x.cygwin.com/docs/ug/configure.html#configure-cygwin-x-windowing-modes>
>
-- >
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/>
>


--
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] 6+ messages in thread

* Re: nomultiplemonitors does not work in windowed mode
  2011-06-30 20:48   ` szalai endre
@ 2011-07-01 15:28     ` Jon TURNEY
  2011-07-01 16:15       ` szalai endre
  0 siblings, 1 reply; 6+ messages in thread
From: Jon TURNEY @ 2011-07-01 15:28 UTC (permalink / raw)
  To: cygwin-xfree; +Cc: hufilufi

On 30/06/2011 21:48, szalai endre wrote:
>>> This mode automatically sets the multiplemonitors option and it cannot
>>> be overriden from command line.
>> What is it that makes you think this?
> 
> According to XWin docs: "-[no]multimonitors or -[no]multiplemonitors Create
> a screen 0 that covers all monitors [the primary monitor] on a system with
> multiple monitors. This option is currently enabled by default in
> -multiwindow mode."

"enabled by default" is not the same as "cannot be disabled from the command
line", which is what -nomultiplemonitors does.

However...

> And this is exactly what happens. When I start a program, it shows up on
> both monitors (half here, half there). This is not supposed to happen (see
> next point).
> 
>> I'm not sure if I understand what you are expecting to happen with
>> -multiwindow -nomultiplemonitors:
> 
> I have 2 monitors. Imagine you turn off one of them and you want to use the
> other one only.

I assume that is because one of them in an external monitor attached to a
laptop which you now want to use on the move, or something like that.  This is
an interesting use case which hadn't occurred to me previously.

If that is the case, it might be that using -resize=randr is a better
approach, as this allows the X server to use both monitors for the X display
when they are attached, and then resize the X display to the primary monitor
when the secondary is detached.

(Note that this isn't something I've tested and I wouldn't be surprised if
there were some problems with doing that, like for e.g. the windows not
getting automatically moved onto the primary display when the resize occurs)

Or maybe you don't like the fact that the X windows appear centered on the
virtual desktop, and thus split between monitors?  Fixing this has been on the
todo list for some time, unfortunately.

> Currently, Cygwin-X will span over all monitors - unless
> you use the multiplemonitors option. I think the goal for this option is
> very clear from the docs: use only 1 monitor for the root window, no matter
> what. So I would expect this behavior: you should not be able to move off
> windows from the primary monitor, at all. The point is, you want to limit
> the root window to one monitor only.
> 
> I see the -multiwindow and -nomultiplemonitors options completely
> independent from each other. They should not have any relationship at all.
> The first just tells how you want to map windows within the root window,
> while the other simply specifies how many monitors you want to use for the
> root window.

... and indeed they are.

But if you actually try -multiwindow -nomultiplemonitors, you'll see that the
windows can be moved off the primary monitor, but that they don't get their
contents redrawn when you do so (because the underlying X screen is only the
size of the primary monitor, so the window is effectively 'off-screen' when
moved there)

> I thought it is very clear from the docs, however your questions make me
> uncertain. Isn't is supposed to work like that?

Well, it might be obvious, but it seems we need some special case behavior
(like constraining the movement of windows, which doesn't exist yet) to behave
in the 'obvious' way in this uncommon case.

-- 
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] 6+ messages in thread

* Re: nomultiplemonitors does not work in windowed mode
  2011-07-01 15:28     ` Jon TURNEY
@ 2011-07-01 16:15       ` szalai endre
  2011-07-04 10:48         ` Jon TURNEY
  0 siblings, 1 reply; 6+ messages in thread
From: szalai endre @ 2011-07-01 16:15 UTC (permalink / raw)
  To: cygwin-xfree, cygwin-xfree

Hi,

when -multiwindow and -nomultimonitor is being used and eclipse starts up, it positions the welcome screen to the center of the logical display (half here-half there). Why? It looks like that the actual screen is covering both monitors, then you simply chop off everything outside the primary monitor and keep the rest. What would be the point of doing so? What kind of use case it supposed to implement?

Because as a consequence of this, you can move off completely windows from the primary monitor. They may be not-drawn, but still they are completely off. Also, this may be the reason why eclipse actually starts completely off-screen, where it is not visible, at all. I just don't see why applications should think they have a 2 monitor screen, when they actually don't.

I think it would make more sense to change the order of steps: if -nomultimonitor is specified, limit the entire root window to the primary monitor, i.e. that would be the entire logical display what applications see. Then you would get the eclipse welcome screen in the center of the primary monitor. I thought that the -nomultimonitor was exactly meant for this.

>Or maybe you don't like the fact that the X windows appear centered on the
>virtual desktop, and thus split between monitors?  Fixing this has been on the
>todo list for some time, unfortunately.

No, I don't like it, but apart from that I also would like to understand why it works as is today (see the first paragraph of this post).

What do you think?

Endre


Jon TURNEY <jon.turney@dronecode.org.uk> írta:
>On 30/06/2011 21:48, szalai endre wrote:>
>>> This mode automatically sets the multiplemonitors option and it cannot>
>>> be overriden from command line.>
>> What is it that makes you think this?>
> >
> According to XWin docs: "-[no]multimonitors or -[no]multiplemonitors Create>
> a screen 0 that covers all monitors [the primary monitor] on a system with>
> multiple monitors. This option is currently enabled by default in>
> -multiwindow mode.">
>
"enabled by default" is not the same as "cannot be disabled from the command>
line", which is what -nomultiplemonitors does.>
>
However...>
>
> And this is exactly what happens. When I start a program, it shows up on>
> both monitors (half here, half there). This is not supposed to happen (see>
> next point).>
> >
>> I'm not sure if I understand what you are expecting to happen with>
>> -multiwindow -nomultiplemonitors:>
> >
> I have 2 monitors. Imagine you turn off one of them and you want to use the>
> other one only.>
>
I assume that is because one of them in an external monitor attached to a>
laptop which you now want to use on the move, or something like that.  This is>
an interesting use case which hadn't occurred to me previously.>
>
If that is the case, it might be that using -resize=randr is a better>
approach, as this allows the X server to use both monitors for the X display>
when they are attached, and then resize the X display to the primary monitor>
when the secondary is detached.>
>
(Note that this isn't something I've tested and I wouldn't be surprised if>
there were some problems with doing that, like for e.g. the windows not>
getting automatically moved onto the primary display when the resize occurs)>
>
Or maybe you don't like the fact that the X windows appear centered on the>
virtual desktop, and thus split between monitors?  Fixing this has been on the>
todo list for some time, unfortunately.>
>
> Currently, Cygwin-X will span over all monitors - unless>
> you use the multiplemonitors option. I think the goal for this option is>
> very clear from the docs: use only 1 monitor for the root window, no matter>
> what. So I would expect this behavior: you should not be able to move off>
> windows from the primary monitor, at all. The point is, you want to limit>
> the root window to one monitor only.>
> >
> I see the -multiwindow and -nomultiplemonitors options completely>
> independent from each other. They should not have any relationship at all.>
> The first just tells how you want to map windows within the root window,>
> while the other simply specifies how many monitors you want to use for the>
> root window.>
>
... and indeed they are.>
>
But if you actually try -multiwindow -nomultiplemonitors, you'll see that the>
windows can be moved off the primary monitor, but that they don't get their>
contents redrawn when you do so (because the underlying X screen is only the>
size of the primary monitor, so the window is effectively 'off-screen' when>
moved there)>
>
> I thought it is very clear from the docs, however your questions make me>
> uncertain. Isn't is supposed to work like that?>
>
Well, it might be obvious, but it seems we need some special case behavior>
(like constraining the movement of windows, which doesn't exist yet) to behave>
in the 'obvious' way in this uncommon case.>
>
-- >
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/>
>


--
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] 6+ messages in thread

* Re: nomultiplemonitors does not work in windowed mode
  2011-07-01 16:15       ` szalai endre
@ 2011-07-04 10:48         ` Jon TURNEY
  0 siblings, 0 replies; 6+ messages in thread
From: Jon TURNEY @ 2011-07-04 10:48 UTC (permalink / raw)
  To: cygwin-xfree; +Cc: hufilufi

On 01/07/2011 17:15, szalai endre wrote:
> when -multiwindow and -nomultimonitor is being used and eclipse starts up,
> it positions the welcome screen to the center of the logical display (half
> here-half there).

If that is happening, that would be a bug.  I can't reproduce that using
Eclipse 3.6.1, the splash screen is correctly positioned in the in center of a
monitor. So can you provide some more details?

Your /var/log/xwin/XWin.0.log
The version of Eclipse you are running
Details of your monitor layout (size, arrangement, which one is primary)

You might also want to have a read of http://cygwin.com/problems.html and the
advice linked to from there :-)

> Why? It looks like that the actual screen is covering
> both monitors, then you simply chop off everything outside the primary
> monitor and keep the rest. What would be the point of doing so? What kind
> of use case it supposed to implement?

Your assumption about the implementation is incorrect.

You can check the size of the X screen yourself using the xrandr or xdpyinfo
commands, and, when -nomultimonitor is used, you should see that it is the
same size as the primary monitor.

Detailed and possibly accurate instructions for obtaining the source code can
be found in the Contributor's Guide at [1], so you don't need to speculate
about the implementation.

[1] http://x.cygwin.com/docs/cg/

> Because as a consequence of this, you can move off completely windows from
> the primary monitor. They may be not-drawn, but still they are completely
> off.

I've already explained this once.  It's not a consequence of the size of the X
screen.

At the moment, you can move the native windows containing X windows off the
primary monitor because no special constraints are applied on their
positioning.  They can be moved anywhere other native windows can be moved.

It would be nice if somebody wrote some code to fix that, but thinking about
it, I'm not even sure how it should work.  Normally you can move windows so
all but some part of the title bar goes off the virtual desktop (so you can
still grab the window and move it back). If you applied the same constraint to
windows and their X screen, you'd still have possibility of most of the window
being off the X screen, and thus undrawn. I suppose you could constrain the
windows so they must be entirely on the X screen, but I imagine that would
feel rather inconsistent.

-- 
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] 6+ messages in thread

end of thread, other threads:[~2011-07-04 10:34 UTC | newest]

Thread overview: 6+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2011-06-30 12:16 nomultiplemonitors does not work in windowed mode szalai endre
2011-06-30 17:03 ` Jon TURNEY
2011-06-30 20:48   ` szalai endre
2011-07-01 15:28     ` Jon TURNEY
2011-07-01 16:15       ` szalai endre
2011-07-04 10:48         ` 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).