<!DOCTYPE html PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN">
<html>
<head>
<meta content="text/html;charset=UTF-8" http-equiv="Content-Type">
<title></title>
</head>
<body dir="ltr" bgcolor="#ffffff" text="#000000">
Erez D wrote:
<blockquote
cite="mid:6c32b541003032347p4f8c96d7u88deaeae0719a79e@mail.gmail.com"
type="cite">
<div dir="ltr"><br>
<br>
<div class="gmail_quote">On Wed, Mar 3, 2010 at 5:05 PM, Shachar
Shemesh <span dir="ltr"><<a moz-do-not-send="true"
href="mailto:shachar@shemesh.biz">shachar@shemesh.biz</a>></span>
wrote:<br>
<blockquote class="gmail_quote"
style="border-left: 1px solid rgb(204, 204, 204); margin: 0pt 0pt 0pt 0.8ex; padding-left: 1ex;">
<div dir="ltr" bgcolor="#ffffff" text="#000000">
<div class="im">Erez D wrote:<br>
<blockquote type="cite">
<div dir="ltr">
<div class="gmail_quote">
<blockquote class="gmail_quote"
style="border-left: 1px solid rgb(204, 204, 204); margin: 0pt 0pt 0pt 0.8ex; padding-left: 1ex;"><font
color="#888888"><br>
</font></blockquote>
<div>when i write a program, i expect to get the same behaviour
which
doesn't depend on the WM.<br>
however: Traditional window managers reparent the window, and add the
titlebar to the parent.<br>
compize on the other hand doesn't reparent the window, so the behaviour
is different.<br>
<br>
</div>
</div>
</div>
</blockquote>
</div>
Yes, but that's avoiding Nadav's question, which was - why is this
something for the program to do?
<div class="im"><br>
</div>
</div>
</blockquote>
<div>i have two displays i want one to be a copy of the other, so
when i move a window on one display, i want it to move to the same
position in the other. <br>
</div>
</div>
</div>
</blockquote>
Then it seems to me that you are trying to move the wrong window. Why
not run XMoveWindow not on the window you opened, but walk up the
parents until you reach the window whose parent is root, and move that
one?<br>
<br>
<blockquote
cite="mid:6c32b541003032347p4f8c96d7u88deaeae0719a79e@mail.gmail.com"
type="cite">
<div dir="ltr">
<div class="gmail_quote">
<div></div>
<blockquote class="gmail_quote"
style="border-left: 1px solid rgb(204, 204, 204); margin: 0pt 0pt 0pt 0.8ex; padding-left: 1ex;">
<div dir="ltr" bgcolor="#ffffff" text="#000000">
<div class="im">
<blockquote type="cite">
<div dir="ltr">
<div class="gmail_quote">
<div>i woudld expext the folowing line:<br>
XTranslateCoordinates(...,win,root,0,0, &x, &y, ...) ;
XMoveWIndow(win,x,y)<br>
to do nothing.<br>
</div>
</div>
</div>
</blockquote>
</div>
Then you would be wrong. The "x, y" are supposed to be relative to the
coordinate system in which the window reside. Even without the window
manager override, the above command would not work with reparented
windows.
<div class="im"><br>
</div>
</div>
</blockquote>
<div>yes it will.<br>
</div>
</div>
</div>
</blockquote>
Emmmm. No it won't?<br>
<br>
The x,y for a reparented window are relative to its parent. If you
treat them as relative to the root window, your XMoveWindow will,
almost always, move your window way too much to the right and down.<br>
<br>
And please, if you think differently, say why.<br>
<blockquote
cite="mid:6c32b541003032347p4f8c96d7u88deaeae0719a79e@mail.gmail.com"
type="cite">
<div dir="ltr">
<div class="gmail_quote"><br>
<blockquote class="gmail_quote"
style="border-left: 1px solid rgb(204, 204, 204); margin: 0pt 0pt 0pt 0.8ex; padding-left: 1ex;">
<div dir="ltr" bgcolor="#ffffff" text="#000000"><font
color="#888888"><br>
</font></div>
</blockquote>
<div><br>
why are you so angry ? <br>
</div>
</div>
</div>
</blockquote>
I'm sorry if you got that impression. You come with the inside of the
problem which seems unsolvable, instead of explaining what you are
actually trying to do, which can be solved by different means. It can
get frustrating to try and help.<br>
<br>
Shachar<br>
<pre class="moz-signature" cols="72">--
Shachar Shemesh
Lingnu Open Source Consulting Ltd.
<a class="moz-txt-link-freetext" href="http://www.lingnu.com">http://www.lingnu.com</a>
</pre>
</body>
</html>