Skip to content

Instantly share code, notes, and snippets.

@miohtama
Created February 11, 2017 11:52
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save miohtama/1714c950ee69cb49aa99f977c8849233 to your computer and use it in GitHub Desktop.
Save miohtama/1714c950ee69cb49aa99f977c8849233 to your computer and use it in GitHub Desktop.
def translator(term):
return get_localizer(get_current_request()).translate(term)
deform_template_dir = resource_filename('deform', 'templates/')
deformdemo_template_dir = resource_filename('deformdemo', 'custom_widgets/')
zpt_renderer = deform.ZPTRendererFactory(
(deformdemo_template_dir, deform_template_dir,), translator=translator)
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment