# -*- coding: utf-8 -*- import markdown import os from codecs import open as _open import languageHandler languageHandler.setLanguage("en") import strings # the list of supported language codes of TW Blue languages = ["en", "es", "fr"] #"eu", "ar", "ca", "es", "fi", "fr", "gl", "hu", "it", "pl", "pt", "ru", "tr"] def generate_document(language): reload(languageHandler) languageHandler.setLanguage(language) reload(strings) markdown_file = markdown.markdown("\n".join(strings.documentation[1:]), extensions=["markdown.extensions.toc"]) first_html_block = """