<div dir="ltr"><div class="gmail_extra"><div class="gmail_quote"><blockquote class="gmail_quote" style="margin:0px 0px 0px 0.8ex;border-left-width:1px;border-left-color:rgb(204,204,204);border-left-style:solid;padding-left:1ex"><br></blockquote><blockquote class="gmail_quote" style="margin:0px 0px 0px 0.8ex;border-left-width:1px;border-left-color:rgb(204,204,204);border-left-style:solid;padding-left:1ex"><span>
> - xcb_get_geometry always returns the initial dimensions even after<br>
> the window gets resized (what gives?)<br>
<br>
</span>That makes no sense at all. Do you have a small example on this?<br></blockquote><div><br></div><div>Hi again Uli, thanks for answering. </div><div><br></div><div>It's a Lua backend for a cross-platform windowing lib[1] so I can't easily make C examples.</div><div><br></div><div>Anyway, your skepticism made me look deeper and I finally found the problem. I was enabling too many bits on the event mask, including XCB_EVENT_MASK_RESIZE_REDIRECT which was causing the described behavior. I was confident I did nothing wrong because of a note in the pyglet source code saying the same thing about XGetGeometry, but apparently the author fell into the same trap by coincidence. Sorry for the noise and thanks for the help.</div><div><br></div><div>About the 4.1.5 section of the ICCCM, I can do it that way but first I want to ask: wouldn't the following stateless piece work too?</div><div><br></div><div>frame_rect(win) {</div><div><div>  x, y = xcb_translate_coords(win, screen.root, 0, 0)</div><div>  geom = xcb_get_geometry(win)</div><div>  w, h = geom.width, geom.height</div><div>  w1, h1, w2, h2 = xcb_frame_extents(win)</div><div>  return x - w1, y - h1, w + w2, h + h2<br></div></div><div>}</div><div><br></div><div>This assumes the wm gives frame extents -- are there known wms that don't?<br></div><div><br></div><div>[1] <a href="https://github.com/luapower/nw/blob/master/nw_xcb.lua" target="_blank">https://github.com/luapower/nw/blob/master/nw_xcb.lua</a><br></div><div><div><br></div></div></div></div></div>