Window arguments "path" and "index"

I added support for setting "index" and "path" for every window separately. Take a look.