pass render function into window creation
Merge pull request #4 from skofo/render-arg

pass render function into window creation