Consider a path: /some where/is a file.txt If an action is taken over a path which contain spaces, then arguments passed to the command action are splitted by spaces. So, for the example above we have: /some where/is a file.txt instead of a single argument. (with very grateful thanks for the fine DE)
Put quotes around the %f. or use uris. Its not (at the point of creating the command) thunars responsibility to quote it.