changing window hierarchy / Send a window to the background?

Hi,

I am trying to write a script that will send adium’s buddylist window to the background-- to become to lowest window z-index order…

I’m not sure how to accomplish this because If I do:

return windows

I get:

I have no idea how to tell what window is the buddylist… Can anyone give me any insight?

Thanks.

-patrick

Maybe something like this? Not tested tough:

tell application "System Events" to tell process "Adium"
	set index of (some window whose name is "YOUR WINDOW NAME HERE") to (count every window)
end tell

Hope it helps,
ief2

Thanks for your reply.

The problem with that is “(count every window)” in that context is only counting adiums windows. I want this window to be behind every single window open on my computer, whether it’s safari, or mail, or whatever. So I need a way to sort of combine all windows into one grouping that I can use to count and then move one behind all the others… If I ask system events to count every window, it just returns 0.

-patrick

anyone?

Have you tried using “Spaces”? You can assign adium to space 4 let’s say and have everything else in space 1. Then using AS change the space from 4 to 1 and off it disappears.

-Mark

Well I should explain what I am doing… I basically have my buddy list as a transparent window with just text, and I want this to be flush against my desktop. When this window appears ontop of other windows, it’s impossible to read because it’s transparent… So I just wanted a way to always keep it directly above the desktop so it’s always readable.

-patrick

So I assume you have your buddy list in a specific quadrant on your desktop, and it would be best for no other windows to popup over that quadrant, as this would cover your buddy list? Pardon my questions, just trying to get a better understanding of what your desktop looks like and what ultimately you are aiming for. If you just want to pop back and forth to a clean desktop with you buddy list in it then the “Spaces” option I mentioned seems reasonable, but this won’t allow you to always see your buddy list. If you want your buddy list always available for viewing, then there would need to be a way to keep new windows/apps from being placed on top of it, and hence going under it when the buddy list returned to the top/active window. Which of these two are you looking to achieve? Your original post really didn’t offer as much detail as is now becoming apparent.

I basically want the buddy list to always be the lowest Z-index position on windows. It should be directly above the desktop but beneath all other windows. I gave up on this, because it doesn’t seem possible to do.

-patrick