Make doc styler behave properly on Windows
# What does this PR do?

This is code that should have been pushed in #9488 but wasn't because... Friday afternoon and my brain was apparently fried. Making a clean PR of it!

Fixes #9438