Ensure indexing by feature id is consistent throughout.

Changed the window lookup to used the dictionary based feature ids, and 
pulled out a bit of code to test and re-use for creating the feature id lookup.


Did you want to add a tag here as well, while you're at it?

Unrelated, but we should re-write that spec with properties. As it stands it's not a very good test. (Not in this PR unless you're bored)