<html>
<head>
<meta http-equiv="content-type" content="text/html; charset=UTF-8">
</head>
<body>
<p><span style="color: rgb(65, 65, 65); font-family: Tahoma, Arial,
Helvetica, sans-serif; font-size: 14px; font-style: normal;
font-variant-ligatures: normal; font-variant-caps: normal;
font-weight: 400; letter-spacing: normal; orphans: 2;
text-align: start; text-indent: 0px; text-transform: none;
white-space: normal; widows: 2; word-spacing: 0px;
-webkit-text-stroke-width: 0px; background-color: rgb(241, 241,
241); text-decoration-style: initial; text-decoration-color:
initial; display: inline !important; float: none;">Unfortunately
I'm not able to include a screenshot of this due to size
constraints of messages here. So I'll describe it as best I can.
The Temporary window partially covers the Gambas window (i.e. is
higher in the windows' stacking order), and the Gambas window is
physically above (i.e. on the screen) the Temporary window. As
the Gambas DesktopWindow object is returned before the Temporary
DesktopWindow object when the FindWindow method is invoked in
the FMain form's Form_Open event of my app: each DesktopWindow
returned being stored in an array. Thus, the first DesktopWindow
in that array (found by coding for the MouseUp event in a
DrawingArea of the SelectWindow form (called by the FMain form
which has its Expanded property set to true) - when the user
clicks on the overlapping area (so that the position of the
mouse will be in both desktop windows) - will be the Gambas
DesktopWindow: this will be the selected window. I want the
Temporary window to be the selected window as it's on top (i.e.
higher in the Stacking Order) of the Gambas window; currently
the Temporary window is selected as evidenced by the Console at
runtime. Obviously I still want the Gambas window to be the
selected window when the user clicks on any point in it outside
the overlapping area. From the user's point of view, this seems
to me to be the logical behaviour of the app.</span></p>
<span style="color: rgb(65, 65, 65); font-family: Tahoma, Arial,
Helvetica, sans-serif; font-size: 14px; font-style: normal;
font-variant-ligatures: normal; font-variant-caps: normal;
font-weight: 400; letter-spacing: normal; orphans: 2; text-align:
start; text-indent: 0px; text-transform: none; white-space:
normal; widows: 2; word-spacing: 0px; -webkit-text-stroke-width:
0px; background-color: rgb(241, 241, 241); text-decoration-style:
initial; text-decoration-color: initial; display: inline
!important; float: none;">I've attached my app. I've started
coding in the MouseUp event using a Shell command to call xprop in
order to determine which window is on top. This needs a fair
amount of extra coding as the data returned from xprop has to
evaluated against the windows data (e.g. stacking order from xprop
versus window positions stored in the array). It seems to me that
if each DesktopWindow had a z-order property (to determine its
priority in the windows' stacking order) then this coding would be
much easier. I think that I vaguely remember a z-order property in
VB: but this could be wishful thinking!</span>
<div class="moz-signature">-- <br>
John
<br>
07476 041418
<br>
01902 331266
<br>
<p><br>
</p>
</div>
</body>
</html>