Tuomo Valkonen <[EMAIL PROTECTED]> writes:
> On 2007-05-28, Matthieu Moy <[EMAIL PROTECTED]> wrote:
>> What am I missing?
>
> You have to make the client window the "bottom" of the group.
OK, that's it.
Tuomo Valkonen <[EMAIL PROTECTED]> writes:
> On 2007-05-28, Tuomo Valkonen <[EMAIL PROTECTED]> wrote:
>> You have to make the client window the "bottom" of the group.
>> (Set bottom=true in the attach parameter table). Also note that
>
> One more thing: The name=cwin:name() setting is also unnecessary,
> because the "displayname" is always the bottom's name, when bottom
> is set.
It should be unnecessary, but there's a bug. The name remains
WGroupCW<something> until the first redraw (resize the frame or so).
Here's the result :
detach = {
}
function detach.topmost_transient(cwin)
local reg = cwin
while obj_typename(reg) ~= "WGroupCW" do
reg = reg:manager()
end
ioncore.defer(function ()
local g = reg:manager():attach_new({type = 'WGroupCW',
switchto = true})
g:attach(cwin, {bottom = true})
end)
return false
end
function detach.topmost_transient_fl(cwin)
local reg = cwin
while obj_typename(reg) ~= "WGroupCW" do
reg = reg:manager()
end
ioncore.defer(function ()
local g = reg:manager():attach_new({type = 'WGroupCW',
switchto = true})
local cwing = cwin:geom()
ioncore.detach(g)
-- g is a group of window, we set the size of the
containing frame.
g:manager():rqgeom(cwing)
g:attach(cwin, {bottom = true, switchto = true})
g:goto()
end)
return false
end
Thanks a lot,
--
Matthieu