View Single Post
Quote:
Originally Posted by curt.clifton View Post
Just got back from a long trip, so no time to update at the moment.

That's a strange incantation for the frontmost window. How much did you test that solution? I ask because there was an outstanding bug with OF's scripting interface not correctly returning the frontmost window. I wonder if it's fixed.
Yes, it is strange, but seems to work with a medium amount of testing. And there may well be a better way to do it.

I hit upon this by poking around the dictionary and running some test scripts. I noticed that each window had an property "index" that changed when a different window was brought frontmost. So "document window 2" might well have index 1. The class definition for 'window' says that the index property refers to 'the number of the window'.

So it looks to me like the weird part is just that you *should* be able to refer to the window with index 1 as 'document window 1'.