Add namespaced functions for win_file.py

Fixes #4902