add posix_path filter

mainly for unixy things on Windows (latex) that don't allow Windows paths.
ensure filenames have posix-paths in latex on Windows
add missing import, properly use os.path.join
Merge pull request #4 from ivanov/posix_path

add missing import, properly use os.path.join
Merge pull request #3888 from minrk/posix_path

posixify paths for Windows latex

closes #3823, #3885