pymdtoolsβs documentationΒΆ
pymdtools πΈΒΆ
A small python module to manipulate markdown content. We use this library to manage a lot of content in markdown.
FeaturesΒΆ
- Read Markdown
- Normalize markdown (it is more a beautifier)
- Convert to html with multiple converter (python markdown, python mistune)
- Convert to pdf with converter
- manage links inside the markdown (change update links)
- add some instructions (in html comment format):
- variable or data easy to find
- include file (like license or header)
- share content between md file (define some shared paragraph)
LicenseΒΆ
The pymdtools is licensed under the terms of the MIT license and is available for free.
MIT LicenseΒΆ
Copyright (c) 2019 Florent Tournois
Permission is hereby granted, free of charge, to any person obtaining a copy of this software and associated documentation files (the βSoftwareβ), to deal in the Software without restriction, including without limitation the rights to use, copy, modify, merge, publish, distribute, sublicense, and/or sell copies of the Software, and to permit persons to whom the Software is furnished to do so, subject to the following conditions:
The above copyright notice and this permission notice shall be included in all copies or substantial portions of the Software.
THE SOFTWARE IS PROVIDED βAS ISβ, WITHOUT WARRANTY OF ANY KIND, EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
Library APIΒΆ
Class HierarchyΒΆ
-
- Namespace pymdtools
- Namespace pymdtools::common
- Class Constant
- Namespace pymdtools::filetools
- Class FileContent
- Class FileName
- Namespace pymdtools::markdownify
- Namespace pymdtools::mdcommon
- Class Link
- Namespace pymdtools::mdfile
- Class MarkdownContent
- Namespace pymdtools::mdrender
- Class MdRenderer
- Namespace pymdtools::mistunege
- Class BlockGrammar
- Class BlockLexer
- Class InlineGrammar
- Class InlineLexer
- Class Markdown
- Class Renderer
- Namespace pymdtools::common
- Namespace pymdtools
File HierarchyΒΆ
-
- Directory pymdtools
- File __init__.py
- File common.py
- File filetools.py
- File instruction.py
- File markdownify.py
- File mdcommon.py
- File mdfile.py
- File mdrender.py
- File mdtopdf.py
- File mistunege.py
- File normalize.py
- File translate.py
- File version.py
- Directory pymdtools
Full APIΒΆ
NamespacesΒΆ
Namespace pymdtoolsΒΆ
Contents
NamespacesΒΆ
- Namespace pymdtools::common
- Namespace pymdtools::filetools
- Namespace pymdtools::instruction
- Namespace pymdtools::markdownify
- Namespace pymdtools::mdcommon
- Namespace pymdtools::mdfile
- Namespace pymdtools::mdrender
- Namespace pymdtools::mdtopdf
- Namespace pymdtools::mistunege
- Namespace pymdtools::normalize
- Namespace pymdtools::translate
- Namespace pymdtools::version
VariablesΒΆ
- Variable pymdtools::__all__
- Variable pymdtools::__author__
- Variable pymdtools::__copyright__
- Variable pymdtools::__credits__
- Variable pymdtools::__email__
- Variable pymdtools::__license__
- Variable pymdtools::__maintainer__
- Variable pymdtools::__module_name__
- Variable pymdtools::__status__
- Variable pymdtools::__version__
Namespace pymdtools::commonΒΆ
ClassesΒΆ
FunctionsΒΆ
- Function pymdtools::common::__get_this_filename
- Function pymdtools::common::apply_function_in_folder
- Function pymdtools::common::check_create_folder
- Function pymdtools::common::check_folder
- Function pymdtools::common::check_is_file_and_correct_path
- Function pymdtools::common::check_len
- Function pymdtools::common::copytree
- Function pymdtools::common::create_backup
- Function pymdtools::common::filename_ext_to
- Function pymdtools::common::filename_ext_to_chm
- Function pymdtools::common::filename_ext_to_hhc
- Function pymdtools::common::filename_ext_to_hhk
- Function pymdtools::common::filename_ext_to_hhp
- Function pymdtools::common::filename_ext_to_html
- Function pymdtools::common::filename_ext_to_md
- Function pymdtools::common::filename_ext_to_pdf
- Function pymdtools::common::get_file_content
- Function pymdtools::common::get_file_encoding
- Function pymdtools::common::get_flat_filename
- Function pymdtools::common::get_new_temp_dir
- Function pymdtools::common::get_today
- Function pymdtools::common::get_valid_filename
- Function pymdtools::common::handle_exception
- Function pymdtools::common::is_binary_file
- Function pymdtools::common::limit_str
- Function pymdtools::common::number_of_subfolder
- Function pymdtools::common::path_to_url
- Function pymdtools::common::print_conv
- Function pymdtools::common::search_for_file
- Function pymdtools::common::set_correct_path
- Function pymdtools::common::set_file_content
- Function pymdtools::common::simple_decorator
- Function pymdtools::common::slugify
- Function pymdtools::common::static
- Function pymdtools::common::str_to_ascii
- Function pymdtools::common::strip_first_and_last_space
VariablesΒΆ
Namespace pymdtools::instructionΒΆ
FunctionsΒΆ
- Function pymdtools::instruction::__get_this_filename
- Function pymdtools::instruction::del_include_file_to_md_text
- Function pymdtools::instruction::del_var_to_md_text
- Function pymdtools::instruction::get_file_content_to_include
- Function pymdtools::instruction::get_include_file_list
- Function pymdtools::instruction::get_refs_around_md_file
- Function pymdtools::instruction::get_refs_from_md_directory
- Function pymdtools::instruction::get_refs_from_md_file
- Function pymdtools::instruction::get_refs_from_md_text
- Function pymdtools::instruction::get_refs_other
- Function pymdtools::instruction::get_title_from_md_text
- Function pymdtools::instruction::get_vars_from_md_file
- Function pymdtools::instruction::get_vars_from_md_text
- Function pymdtools::instruction::include_files_to_md_file
- Function pymdtools::instruction::include_files_to_md_text
- Function pymdtools::instruction::include_refs_to_md_file
- Function pymdtools::instruction::include_refs_to_md_text
- Function pymdtools::instruction::include_vars_to_md_file
- Function pymdtools::instruction::include_vars_to_md_text
- Function pymdtools::instruction::refs_in_md_text
- Function pymdtools::instruction::search_include_refs_to_md_file
- Function pymdtools::instruction::search_include_vars_to_md_file
- Function pymdtools::instruction::search_include_vars_to_md_text
- Function pymdtools::instruction::set_include_file_to_md_text
- Function pymdtools::instruction::set_title_in_md_text
- Function pymdtools::instruction::set_var_to_md_text
- Function pymdtools::instruction::strip_xml_comment
VariablesΒΆ
- Variable pymdtools::instruction::__begin_include_re__
- Variable pymdtools::instruction::__begin_ref_re__
- Variable pymdtools::instruction::__begin_var_re__
- Variable pymdtools::instruction::__comment_re__
- Variable pymdtools::instruction::__end_include_re__
- Variable pymdtools::instruction::__end_ref_re__
- Variable pymdtools::instruction::__end_var_re__
- Variable pymdtools::instruction::__include_file_re__
- Variable pymdtools::instruction::__var_re__
Namespace pymdtools::markdownifyΒΆ
ClassesΒΆ
FunctionsΒΆ
- Function pymdtools::markdownify::_todict
- Function pymdtools::markdownify::escape
- Function pymdtools::markdownify::markdownify
- Function pymdtools::markdownify::strip_first_last_lf_large
- Function pymdtools::markdownify::strip_first_last_space
- Function pymdtools::markdownify::strip_first_last_space_large
VariablesΒΆ
- Variable pymdtools::markdownify::ATX
- Variable pymdtools::markdownify::ATX_CLOSED
- Variable pymdtools::markdownify::convert_heading_re
- Variable pymdtools::markdownify::FRAGMENT_ID
- Variable pymdtools::markdownify::line_beginning_re
- Variable pymdtools::markdownify::SETEXT
- Variable pymdtools::markdownify::UNDERLINED
- Variable pymdtools::markdownify::unicode
- Variable pymdtools::markdownify::whitespace_re
- Variable pymdtools::markdownify::wrapped
Namespace pymdtools::mdcommonΒΆ
ClassesΒΆ
FunctionsΒΆ
- Function pymdtools::mdcommon::get_domain_name
- Function pymdtools::mdcommon::is_external_link
- Function pymdtools::mdcommon::move_base_path_in_md_text
- Function pymdtools::mdcommon::search_link_in_md_file
- Function pymdtools::mdcommon::search_link_in_md_text
- Function pymdtools::mdcommon::search_link_in_md_text_json
- Function pymdtools::mdcommon::sub_string_link_by_ref_md
- Function pymdtools::mdcommon::sub_string_link_md
- Function pymdtools::mdcommon::sub_string_name_by_ref_md
- Function pymdtools::mdcommon::update_link_from_old_link
- Function pymdtools::mdcommon::update_link_in_md_text
- Function pymdtools::mdcommon::update_links_from_old_link
- Function pymdtools::mdcommon::update_links_in_md_text
Namespace pymdtools::mdtopdfΒΆ
Contents
FunctionsΒΆ
- Function pymdtools::mdtopdf::__get_this_filename
- Function pymdtools::mdtopdf::check_odd_pages
- Function pymdtools::mdtopdf::convert_html_to_pdf
- Function pymdtools::mdtopdf::convert_md_to_html
- Function pymdtools::mdtopdf::convert_md_to_pdf
- Function pymdtools::mdtopdf::converter_md_to_html_markdown
- Function pymdtools::mdtopdf::converter_md_to_html_mistune
- Function pymdtools::mdtopdf::find_wk_html_to_pdf
- Function pymdtools::mdtopdf::get_md_to_html_converter
- Function pymdtools::mdtopdf::pdf_features
Namespace pymdtools::mistunegeΒΆ
ClassesΒΆ
FunctionsΒΆ
VariablesΒΆ
- Variable pymdtools::mistunege::__all__
- Variable pymdtools::mistunege::__author__
- Variable pymdtools::mistunege::__version__
- Variable pymdtools::mistunege::_block_code_leading_pattern
- Variable pymdtools::mistunege::_block_quote_leading_pattern
- Variable pymdtools::mistunege::_block_tag
- Variable pymdtools::mistunege::_escape_pattern
- Variable pymdtools::mistunege::_inline_tags
- Variable pymdtools::mistunege::_key_pattern
- Variable pymdtools::mistunege::_newline_pattern
- Variable pymdtools::mistunege::_nonalpha_pattern
- Variable pymdtools::mistunege::_pre_tags
- Variable pymdtools::mistunege::_scheme_blacklist
- Variable pymdtools::mistunege::_valid_attr
- Variable pymdtools::mistunege::_valid_end
Namespace pymdtools::normalizeΒΆ
Contents
Namespace pymdtools::translateΒΆ
FunctionsΒΆ
- Function pymdtools::translate::__get_this_filename
- Function pymdtools::translate::__get_this_folder
- Function pymdtools::translate::_translation_parameter
- Function pymdtools::translate::eu_lang_list
- Function pymdtools::translate::get_localedir
- Function pymdtools::translate::get_translation
- Function pymdtools::translate::N_
- Function pymdtools::translate::translate
- Function pymdtools::translate::translate_dict
- Function pymdtools::translate::translate_list
- Function pymdtools::translate::translate_md
- Function pymdtools::translate::translate_str
- Function pymdtools::translate::translate_txt
VariablesΒΆ
Namespace pymdtools::versionΒΆ
Contents
Classes and StructsΒΆ
Class ConstantΒΆ
- Defined in File common.py
Class DocumentationΒΆ
-
class
Constant
ΒΆ Public Functions
-
__init__
(self self, value value = None)ΒΆ
-
get_value
(self self)ΒΆ
-
get
(self self)ΒΆ
-
__get__
(self self, _ignore_instance _ignore_instance, _ignore_owner _ignore_owner)ΒΆ
-
__set__
(self self, _ignore_instance _ignore_instance, _ignore_value _ignore_value)ΒΆ
Public Members
-
value
ΒΆ
-
Class FileContentΒΆ
- Defined in File filetools.py
Inheritance RelationshipsΒΆ
public pymdtools.filetools.FileName
(Class FileName)
public pymdtools.mdfile.MarkdownContent
(Class MarkdownContent)
Class DocumentationΒΆ
-
class
FileContent
ΒΆ Subclassed by pymdtools.mdfile.MarkdownContent
Public Functions
-
__init__
(self self, filename filename = None, content content = None, backup backup = True, encoding encoding = "utf-8")ΒΆ
-
content
(self self)
-
content
(self self, value value)
-
backup
(self self)
-
backup
(self self, value value)
-
save_needed
(self self)ΒΆ
-
save_needed
(self self, value value)
-
read
(self self, filename filename = None, encoding encoding = "utf-8")ΒΆ
-
write
(self self, filename filename = None, backup_ext backup_ext = ".bak", encoding encoding = "utf-8")ΒΆ
-
__repr__
(self self)ΒΆ
-
__str__
(self self)ΒΆ
-
Class FileNameΒΆ
- Defined in File filetools.py
Inheritance RelationshipsΒΆ
public pymdtools.filetools.FileContent
(Class FileContent)
Class DocumentationΒΆ
-
class
FileName
ΒΆ Subclassed by pymdtools.filetools.FileContent
Public Functions
-
__init__
(self self, filename filename = None)ΒΆ
-
full_filename
(self self)
-
full_filename
(self self, value value)
-
filename
(self self)ΒΆ
-
filename
(self self, value value)
-
filename_path
(self self)ΒΆ
-
filename_path
(self self, value value)
-
filename_ext
(self self)ΒΆ
-
filename_ext
(self self, value value)
-
is_file
(self self)ΒΆ
-
is_dir
(self self)ΒΆ
-
__repr__
(self self)ΒΆ
-
__str__
(self self)ΒΆ
Public Members
-
full_filename
ΒΆ
-
Class MarkdownConverterΒΆ
- Defined in File markdownify.py
Nested RelationshipsΒΆ
Class DocumentationΒΆ
-
class
MarkdownConverter
ΒΆ Public Functions
-
__init__
(self self, options options)ΒΆ
-
convert
(self self, html html)ΒΆ
-
process_tag
(self self, node node, children_only children_only = False)ΒΆ
-
process_text
(self self, text text)ΒΆ
-
__getattr__
(self self, attr attr)ΒΆ
-
should_convert_tag
(self self, tag tag)ΒΆ
-
indent
(self self, text text, level level)ΒΆ
-
underline
(self self, text text, pad_char pad_char)ΒΆ
-
convert_a
(self self, el el, text text)ΒΆ
-
convert_b
(self self, el el, text text)ΒΆ
-
convert_blockquote
(self self, el el, text text)ΒΆ
-
convert_br
(self self, el el, text text)ΒΆ
-
convert_em
(self self, el el, text text)ΒΆ
-
convert_hn
(self self, n n, el el, text text)ΒΆ
-
convert_i
(self self, el el, text text)ΒΆ
-
convert_list
(self self, el el, text text)ΒΆ
-
convert_li
(self self, el el, text text)ΒΆ
-
convert_p
(self self, el el, text text)ΒΆ
-
convert_strong
(self self, el el, text text)ΒΆ
-
convert_img
(self self, el el, text text)ΒΆ
Public Members
-
options
ΒΆ
Public Static Attributes
-
pymdtools.markdownify.MarkdownConverter.convert_ul = convert_list
-
pymdtools.markdownify.MarkdownConverter.convert_ol = convert_list
-
class
DefaultOptions
ΒΆ Subclassed by pymdtools.markdownify.MarkdownConverter.Options
Public Static Attributes
-
pymdtools.markdownify.MarkdownConverter.DefaultOptions.strip = None
-
pymdtools.markdownify.MarkdownConverter.DefaultOptions.convert = None
-
bool pymdtools.markdownify.MarkdownConverter.DefaultOptions.autolinks = True
-
pymdtools.markdownify.MarkdownConverter.DefaultOptions.heading_style = UNDERLINED
-
string pymdtools.markdownify.MarkdownConverter.DefaultOptions.bullets = '*+-'
-
-
Class MarkdownConverter::DefaultOptionsΒΆ
- Defined in File markdownify.py
Nested RelationshipsΒΆ
This class is a nested type of Class MarkdownConverter.
Inheritance RelationshipsΒΆ
public pymdtools.markdownify.MarkdownConverter.Options
(Class MarkdownConverter::Options)
Class DocumentationΒΆ
-
class
DefaultOptions
ΒΆ Subclassed by pymdtools.markdownify.MarkdownConverter.Options
Public Static Attributes
-
pymdtools.markdownify.MarkdownConverter.DefaultOptions.strip = None
-
pymdtools.markdownify.MarkdownConverter.DefaultOptions.convert = None
-
bool pymdtools.markdownify.MarkdownConverter.DefaultOptions.autolinks = True
-
pymdtools.markdownify.MarkdownConverter.DefaultOptions.heading_style = UNDERLINED
-
string pymdtools.markdownify.MarkdownConverter.DefaultOptions.bullets = '*+-'
-
Class MarkdownConverter::OptionsΒΆ
- Defined in File markdownify.py
Nested RelationshipsΒΆ
This class is a nested type of Class MarkdownConverter.
Inheritance RelationshipsΒΆ
public pymdtools.markdownify.MarkdownConverter.DefaultOptions
(Class MarkdownConverter::DefaultOptions)
Class LinkΒΆ
- Defined in File mdcommon.py
Class MarkdownContentΒΆ
- Defined in File mdfile.py
Inheritance RelationshipsΒΆ
public pymdtools.filetools.FileContent
(Class FileContent)
Class DocumentationΒΆ
-
class
MarkdownContent
ΒΆ Public Functions
-
__init__
(self self, filename filename = None, content content = None, backup backup = True, encoding encoding = "unknown", kwargs kwargs)ΒΆ
-
__setitem__
(self self, key key, item item)ΒΆ
-
__getitem__
(self self, key key)ΒΆ
-
__delitem__
(self self, key key)ΒΆ
-
has_key
(self self, k k)ΒΆ
-
keys
(self self)ΒΆ
-
values
(self self)ΒΆ
-
items
(self self)ΒΆ
-
__contains__
(self self, item item)ΒΆ
-
__iter__
(self self)ΒΆ
-
title
(self self)ΒΆ
-
title
(self self, value value)
-
toc
(self self)ΒΆ
-
set_include_file
(self self, filename filename)ΒΆ
-
del_include_file
(self self, filename filename)ΒΆ
-
beautify
(self self)ΒΆ
Public Members
-
content
ΒΆ
-
Class MdRendererΒΆ
- Defined in File mdrender.py
Class DocumentationΒΆ
-
class
MdRenderer
ΒΆ Public Functions
-
get_block
(text text)ΒΆ
-
newline
(self self)ΒΆ
-
text
(self self, text text)ΒΆ
-
linebreak
(self self)ΒΆ
-
hrule
(self self)ΒΆ
-
header
(self self, text text, level level, raw raw = None)ΒΆ
-
paragraph
(self self, text text)ΒΆ
-
list
(self self, text text, ordered ordered = True)ΒΆ
-
list_item
(self self, text text)ΒΆ
-
block_code
(self self, code code, lang lang = None)ΒΆ
-
block_quote
(self self, text text)ΒΆ
-
emphasis
(self self, text text)ΒΆ
-
double_emphasis
(self self, text text)ΒΆ
-
strikethrough
(self self, text text)ΒΆ
-
codespan
(self self, text text)ΒΆ
-
autolink
(self self, link link, is_email is_email = False)ΒΆ
-
link
(self self, link link, title title, text text, image image = False)ΒΆ
-
image
(self self, src src, title title, text text)ΒΆ
-
table
(self self, header header, body body)ΒΆ
-
table_row
(self self, content content)ΒΆ
-
table_cell
(self self, content content, flags flags)ΒΆ
-
footnote_ref
(self self, key key, index index)ΒΆ
-
footnote_item
(self self, key key, text text)ΒΆ
-
footnotes
(self self, text text)ΒΆ
-
Class BlockGrammarΒΆ
- Defined in File mistunege.py
Class DocumentationΒΆ
-
class
BlockGrammar
ΒΆ Grammars for block level tokens.
Public Static Attributes
-
pymdtools.mistunege.BlockGrammar.def_links= re.compile( r'^ *[([^^]]+)]: *' # [key]: r'<?([^s>]+)>?' # <link> or link r'(?: +["(]([^n]+)[")])? *(?:n+|$)' )
-
pymdtools.mistunege.BlockGrammar.def_footnotes= re.compile( r'^[^([^]]+)]: *(' r'[^n]*(?:n+|$)' # [^key]: r'(?: {1,}[^n]*(?:n+|$))*' r')' )
-
pymdtools.mistunege.BlockGrammar.newline = re.compile(r'^n+')
-
pymdtools.mistunege.BlockGrammar.block_code = re.compile(r'^( {4}[^n]+n*)+')
-
pymdtools.mistunege.BlockGrammar.fences= re.compile( r'^ *(`{3,}|~{3,}) *(S+)? *n' # ```lang r'([sS]+?)s*' r'1 *(?:n+|$)' # ``` )
-
pymdtools.mistunege.BlockGrammar.hrule = re.compile(r'^ {0,3}[-*_](?: *[-*_]){2,} *(?:n+|$)')
-
pymdtools.mistunege.BlockGrammar.heading = re.compile(r'^ *(#{1,6}) *([^n]+?) *#* *(?:n+|$)')
-
pymdtools.mistunege.BlockGrammar.lheading = re.compile(r'^([^n]+)n *(=|-)+ *(?:n+|$)')
-
pymdtools.mistunege.BlockGrammar.block_quote = re.compile(r'^( *>[^n]+(n[^n]+)*n*)+')
-
pymdtools.mistunege.BlockGrammar.list_block= re.compile( r'^( *)([*+-]|d+.) [sS]+?' r'(?:' r'n+(?=1?(?:[-*_] *){3,}(?:n+|$))' # hrule r'|n+(?=%s)' # def links r'|n+(?=%s)' # def footnotes r'|n{2,}' r'(?! )' r'(?!1(?:[*+-]|d+.) )n*' r'|' r's*$)' % ( _pure_pattern(def_links), _pure_pattern(def_footnotes), ) )
-
pymdtools.mistunege.BlockGrammar.list_item= re.compile( r'^(( *)(?:[*+-]|d+.) [^n]*' r'(?:n(?!2(?:[*+-]|d+.) )[^n]*)*)', flags=re.M )
-
pymdtools.mistunege.BlockGrammar.list_bullet = re.compile(r'^ *(?:[*+-]|d+.) +')
-
pymdtools.mistunege.BlockGrammar.paragraph= re.compile( r'^((?:[^n]+n?(?!' r'%s|%s|%s|%s|%s|%s|%s|%s|%s' r'))+)n*' % ( _pure_pattern(fences).replace(r'1', r'2'), _pure_pattern(list_block).replace(r'1', r'3'), _pure_pattern(hrule), _pure_pattern(heading), _pure_pattern(lheading), _pure_pattern(block_quote), _pure_pattern(def_links), _pure_pattern(def_footnotes), '<' + _block_tag, ) )
-
pymdtools.mistunege.BlockGrammar.block_html= re.compile( r'^ *(?:%s|%s|%s) *(?:n{2,}|s*$)' % ( r'<!--[sS]*?-->', r'<(%s)((?:%s)*?)>([sS]*?)</1>' % (_block_tag, _valid_attr), r'<%s(?:%s)*?s*/?>' % (_block_tag, _valid_attr), ) )
-
pymdtools.mistunege.BlockGrammar.table= re.compile( r'^ *|(.+)n *|( *[-:]+[-| :]*)n((?: *|.*(?:n|$))*)n*' )
-
pymdtools.mistunege.BlockGrammar.nptable= re.compile( r'^ *(S.*|.*)n *([-:]+ *|[-| :]*)n((?:.*|.*(?:n|$))*)n*' )
-
pymdtools.mistunege.BlockGrammar.text = re.compile(r'^[^n]+')
-
Class BlockLexerΒΆ
- Defined in File mistunege.py
Class DocumentationΒΆ
-
class
BlockLexer
ΒΆ Block level lexer for block grammars.
Public Functions
-
__init__
(self self, rules rules = None, kwargs kwargs)ΒΆ
-
__call__
(self self, text text, rules rules = None)ΒΆ
-
parse
(self self, text text, rules rules = None)ΒΆ
-
parse_newline
(self self, m m)ΒΆ
-
parse_block_code
(self self, m m)ΒΆ
-
parse_fences
(self self, m m)ΒΆ
-
parse_heading
(self self, m m)ΒΆ
-
parse_lheading
(self self, m m)ΒΆ Parse setext heading.
-
parse_hrule
(self self, m m)ΒΆ
-
parse_list_block
(self self, m m)ΒΆ
-
parse_block_quote
(self self, m m)ΒΆ
-
parse_def_links
(self self, m m)ΒΆ
-
parse_def_footnotes
(self self, m m)ΒΆ
-
parse_table
(self self, m m)ΒΆ
-
parse_nptable
(self self, m m)ΒΆ
-
parse_block_html
(self self, m m)ΒΆ
-
parse_paragraph
(self self, m m)ΒΆ
-
parse_text
(self self, m m)ΒΆ
Public Static Attributes
-
pymdtools.mistunege.BlockLexer.grammar_class = BlockGrammar
-
list pymdtools.mistunege.BlockLexer.default_rules= [ 'newline', 'hrule', 'block_code', 'fences', 'heading', 'nptable', 'lheading', 'block_quote', 'list_block', 'block_html', 'def_links', 'def_footnotes', 'table', 'paragraph', 'text' ]
-
tuple pymdtools.mistunege.BlockLexer.list_rules= ( 'newline', 'block_code', 'fences', 'lheading', 'hrule', 'block_quote', 'list_block', 'block_html', 'text', )
-
tuple pymdtools.mistunege.BlockLexer.footnote_rules= ( 'newline', 'block_code', 'fences', 'heading', 'nptable', 'lheading', 'hrule', 'block_quote', 'list_block', 'block_html', 'table', 'paragraph', 'text' )
-
Class InlineGrammarΒΆ
- Defined in File mistunege.py
Class DocumentationΒΆ
-
class
InlineGrammar
ΒΆ Grammars for inline level tokens.
Public Functions
-
hard_wrap
(self self)ΒΆ Grammar for hard wrap linebreak. You don't need to add two spaces at the end of a line.
Public Static Attributes
-
pymdtools.mistunege.InlineGrammar.escape = re.compile(r'^\([\`*{}[]()#+-.!_>~|])')
-
pymdtools.mistunege.InlineGrammar.inline_html= re.compile( r'^(?:%s|%s|%s)' % ( r'<!--[sS]*?-->', r'<(w+%s)((?:%s)*?)s*>([sS]*?)</1>' % (_valid_end, _valid_attr), r'<w+%s(?:%s)*?s*/?>' % (_valid_end, _valid_attr), ) )
-
pymdtools.mistunege.InlineGrammar.autolink = re.compile(r'^<([^ >]+(@|:)[^ >]+)>')
-
pymdtools.mistunege.InlineGrammar.link= re.compile( r'^!?[(' r'(?:[[^^]]*]|[^[]]|](?=[^[]*]))*' r')](' r')' )
-
pymdtools.mistunege.InlineGrammar.reflink= re.compile( r'^!?[(' r'(?:[[^^]]*]|[^[]]|](?=[^[]*]))*' r')]s*[([^^]]*)]' )
-
pymdtools.mistunege.InlineGrammar.nolink = re.compile(r'^!?[((?:[[^]]*]|[^[]])*)]')
-
pymdtools.mistunege.InlineGrammar.url = re.compile()
-
pymdtools.mistunege.InlineGrammar.double_emphasis= re.compile( r'^_{2}([sS]+?)_{2}(?!_)' # __word__ r'|' r'^*{2}([sS]+?)*{2}(?!*)' # **word** )
-
pymdtools.mistunege.InlineGrammar.emphasis= re.compile( r'^b_((?:__|[^_])+?)_b' # _word_ r'|' r'^*((?:**|[^*])+?)*(?!*)' # *word* )
-
pymdtools.mistunege.InlineGrammar.code = re.compile(r'^(`+)s*([sS]*?[^`])s*1(?!`)')
-
pymdtools.mistunege.InlineGrammar.linebreak = re.compile(r'^ {2,}n(?!s*$)')
-
pymdtools.mistunege.InlineGrammar.strikethrough = re.compile(r'^~~(?=S)([sS]*?S)~~')
-
pymdtools.mistunege.InlineGrammar.footnote = re.compile(r'^[^([^]]+)]')
-
pymdtools.mistunege.InlineGrammar.text = re.compile(r'^[sS]+?(?=[\<![_*`~]|https?://| {2,}n|$)')
-
Class InlineLexerΒΆ
- Defined in File mistunege.py
Class DocumentationΒΆ
-
class
InlineLexer
ΒΆ Inline level lexer for inline grammars.
Public Functions
-
__init__
(self self, renderer renderer, rules rules = None, kwargs kwargs)ΒΆ
-
__call__
(self self, text text, rules rules = None)ΒΆ
-
setup
(self self, links links, footnotes footnotes)ΒΆ
-
output
(self self, text text, rules rules = None)ΒΆ
-
output_escape
(self self, m m)ΒΆ
-
output_autolink
(self self, m m)ΒΆ
-
output_url
(self self, m m)ΒΆ
-
output_inline_html
(self self, m m)ΒΆ
-
output_footnote
(self self, m m)ΒΆ
-
output_link
(self self, m m)ΒΆ
-
output_reflink
(self self, m m)ΒΆ
-
output_nolink
(self self, m m)ΒΆ
-
output_double_emphasis
(self self, m m)ΒΆ
-
output_emphasis
(self self, m m)ΒΆ
-
output_code
(self self, m m)ΒΆ
-
output_linebreak
(self self, m m)ΒΆ
-
output_strikethrough
(self self, m m)ΒΆ
-
output_text
(self self, m m)ΒΆ
Public Static Attributes
-
pymdtools.mistunege.InlineLexer.grammar_class = InlineGrammar
-
list pymdtools.mistunege.InlineLexer.default_rules= [ 'escape', 'inline_html', 'autolink', 'url', 'footnote', 'link', 'reflink', 'nolink', 'double_emphasis', 'emphasis', 'code', 'linebreak', 'strikethrough', 'text', ]
-
list pymdtools.mistunege.InlineLexer.inline_html_rules= [ 'escape', 'autolink', 'url', 'link', 'reflink', 'nolink', 'double_emphasis', 'emphasis', 'code', 'linebreak', 'strikethrough', 'text', ]
-
Class MarkdownΒΆ
- Defined in File mistunege.py
Class DocumentationΒΆ
-
class
Markdown
ΒΆ The Markdown parser. :param renderer: An instance of ``Renderer``. :param inline: An inline lexer class or instance. :param block: A block lexer class or instance.
Public Functions
-
__init__
(self self, renderer renderer = None, inline inline = None, block block = None, kwargs kwargs)ΒΆ
-
__call__
(self self, text text)ΒΆ
-
render
(self self, text text)ΒΆ Render the Markdown text. :param text: markdown formatted text content.
-
parse
(self self, text text)ΒΆ
-
pop
(self self)ΒΆ
-
peek
(self self)ΒΆ
-
output
(self self, text text, rules rules = None)ΒΆ
-
tok
(self self)ΒΆ
-
tok_text
(self self)ΒΆ
-
output_newline
(self self)ΒΆ
-
output_hrule
(self self)ΒΆ
-
output_heading
(self self)ΒΆ
-
output_code
(self self)ΒΆ
-
output_table
(self self)ΒΆ
-
output_block_quote
(self self)ΒΆ
-
output_list
(self self)ΒΆ
-
output_list_item
(self self)ΒΆ
-
output_loose_item
(self self)ΒΆ
-
output_footnote
(self self)ΒΆ
-
output_close_html
(self self)ΒΆ
-
output_open_html
(self self)ΒΆ
-
output_paragraph
(self self)ΒΆ
-
output_text
(self self)ΒΆ
-
Class RendererΒΆ
- Defined in File mistunege.py
Class DocumentationΒΆ
-
class
Renderer
ΒΆ The default HTML renderer for rendering Markdown.
Public Functions
-
__init__
(self self, kwargs kwargs)ΒΆ
-
placeholder
(self self)ΒΆ Returns the default, empty output value for the renderer. All renderer methods use the '+=' operator to append to this value. Default is a string so rendering HTML can build up a result string with the rendered Markdown. Can be overridden by Renderer subclasses to be types like an empty list, allowing the renderer to create a tree-like structure to represent the document (which can then be reprocessed later into a separate format like docx or pdf).
-
block_code
(self self, code code, lang lang = None)ΒΆ Rendering block level code. ``pre > code``. :param code: text content of the code block. :param lang: language of the given code.
-
block_quote
(self self, text text)ΒΆ Rendering <blockquote> with the given text. :param text: text content of the blockquote.
-
block_html
(self self, html html)ΒΆ Rendering block level pure html content. :param html: text content of the html snippet.
-
header
(self self, text text, level level, raw raw = None)ΒΆ Rendering header/heading tags like ``<h1>`` ``<h2>``. :param text: rendered text content for the header. :param level: a number for the header level, for example: 1. :param raw: raw text content of the header.
-
hrule
(self self)ΒΆ Rendering method for ``<hr>`` tag.
-
list
(self self, body body, ordered ordered = True)ΒΆ Rendering list tags like ``<ul>`` and ``<ol>``. :param body: body contents of the list. :param ordered: whether this list is ordered or not.
-
list_item
(self self, text text)ΒΆ Rendering list item snippet. Like ``<li>``.
-
paragraph
(self self, text text)ΒΆ Rendering paragraph tags. Like ``<p>``.
-
table
(self self, header header, body body)ΒΆ Rendering table element. Wrap header and body in it. :param header: header part of the table. :param body: body part of the table.
-
table_row
(self self, content content)ΒΆ Rendering a table row. Like ``<tr>``. :param content: content of current table row.
-
table_cell
(self self, content content, flags flags)ΒΆ Rendering a table cell. Like ``<th>`` ``<td>``. :param content: content of current table cell. :param header: whether this is header or not. :param align: align of current table cell.
-
double_emphasis
(self self, text text)ΒΆ Rendering **strong** text. :param text: text content for emphasis.
-
emphasis
(self self, text text)ΒΆ Rendering *emphasis* text. :param text: text content for emphasis.
-
codespan
(self self, text text)ΒΆ Rendering inline `code` text. :param text: text content for inline code.
-
linebreak
(self self)ΒΆ Rendering line break like ``<br>``.
-
strikethrough
(self self, text text)ΒΆ Rendering ~~strikethrough~~ text. :param text: text content for strikethrough.
-
text
(self self, text text)ΒΆ Rendering unformatted text. :param text: text content.
-
escape
(self self, text text)ΒΆ Rendering escape sequence. :param text: text content.
-
autolink
(self self, link link, is_email is_email = False)ΒΆ Rendering a given link or email address. :param link: link content or email address. :param is_email: whether this is an email or not.
-
link
(self self, link link, title title, text text)ΒΆ Rendering a given link with content and title. :param link: href link for ``<a>`` tag. :param title: title content for `title` attribute. :param text: text content for description.
-
image
(self self, src src, title title, text text)ΒΆ Rendering a image with title and text. :param src: source link of the image. :param title: title text of the image. :param text: alt text of the image.
-
inline_html
(self self, html html)ΒΆ Rendering span level pure html content. :param html: text content of the html snippet.
-
newline
(self self)ΒΆ Rendering newline element.
-
footnote_ref
(self self, key key, index index)ΒΆ Rendering the ref anchor of a footnote. :param key: identity key for the footnote. :param index: the index count of current footnote.
-
footnote_item
(self self, key key, text text)ΒΆ Rendering a footnote item. :param key: identity key for the footnote. :param text: text content of the footnote.
-
footnotes
(self self, text text)ΒΆ Wrapper for all footnotes. :param text: contents of all footnotes.
Public Members
-
options
ΒΆ
-
FunctionsΒΆ
Function pymdtools::common::__get_this_filenameΒΆ
- Defined in File common.py
Function pymdtools::common::apply_function_in_folderΒΆ
- Defined in File common.py
Function pymdtools::common::check_create_folderΒΆ
- Defined in File common.py
Function pymdtools::common::check_folderΒΆ
- Defined in File common.py
Function pymdtools::common::check_is_file_and_correct_pathΒΆ
- Defined in File common.py
Function pymdtools::common::check_lenΒΆ
- Defined in File common.py
Function pymdtools::common::copytreeΒΆ
- Defined in File common.py
Function pymdtools::common::create_backupΒΆ
- Defined in File common.py
Function pymdtools::common::filename_ext_toΒΆ
- Defined in File common.py
Function pymdtools::common::filename_ext_to_chmΒΆ
- Defined in File common.py
Function pymdtools::common::filename_ext_to_hhcΒΆ
- Defined in File common.py
Function pymdtools::common::filename_ext_to_hhkΒΆ
- Defined in File common.py
Function pymdtools::common::filename_ext_to_hhpΒΆ
- Defined in File common.py
Function pymdtools::common::filename_ext_to_htmlΒΆ
- Defined in File common.py
Function pymdtools::common::filename_ext_to_mdΒΆ
- Defined in File common.py
Function pymdtools::common::filename_ext_to_pdfΒΆ
- Defined in File common.py
Function pymdtools::common::get_file_contentΒΆ
- Defined in File common.py
Function pymdtools::common::get_file_encodingΒΆ
- Defined in File common.py
Function pymdtools::common::get_flat_filenameΒΆ
- Defined in File common.py
Function pymdtools::common::get_new_temp_dirΒΆ
- Defined in File common.py
Function pymdtools::common::get_todayΒΆ
- Defined in File common.py
Function pymdtools::common::get_valid_filenameΒΆ
- Defined in File common.py
Function pymdtools::common::handle_exceptionΒΆ
- Defined in File common.py
Function pymdtools::common::is_binary_fileΒΆ
- Defined in File common.py
Function pymdtools::common::limit_strΒΆ
- Defined in File common.py
Function pymdtools::common::number_of_subfolderΒΆ
- Defined in File common.py
Function pymdtools::common::path_to_urlΒΆ
- Defined in File common.py
Function pymdtools::common::print_convΒΆ
- Defined in File common.py
Function pymdtools::common::search_for_fileΒΆ
- Defined in File common.py
Function pymdtools::common::set_correct_pathΒΆ
- Defined in File common.py
Function pymdtools::common::set_file_contentΒΆ
- Defined in File common.py
Function pymdtools::common::simple_decoratorΒΆ
- Defined in File common.py
Function pymdtools::common::slugifyΒΆ
- Defined in File common.py
Function pymdtools::common::staticΒΆ
- Defined in File common.py
Function pymdtools::common::str_to_asciiΒΆ
- Defined in File common.py
Function pymdtools::common::strip_first_and_last_spaceΒΆ
- Defined in File common.py
Function pymdtools::filetools::__get_this_filenameΒΆ
- Defined in File filetools.py
Function pymdtools::filetools::get_template_fileΒΆ
- Defined in File filetools.py
Function pymdtools::filetools::get_template_files_in_folderΒΆ
- Defined in File filetools.py
Function pymdtools::instruction::__get_this_filenameΒΆ
- Defined in File instruction.py
Function pymdtools::instruction::del_include_file_to_md_textΒΆ
- Defined in File instruction.py
Function pymdtools::instruction::del_var_to_md_textΒΆ
- Defined in File instruction.py
Function pymdtools::instruction::get_file_content_to_includeΒΆ
- Defined in File instruction.py
Function pymdtools::instruction::get_include_file_listΒΆ
- Defined in File instruction.py
Function pymdtools::instruction::get_refs_around_md_fileΒΆ
- Defined in File instruction.py
Function pymdtools::instruction::get_refs_from_md_directoryΒΆ
- Defined in File instruction.py
Function pymdtools::instruction::get_refs_from_md_fileΒΆ
- Defined in File instruction.py
Function pymdtools::instruction::get_refs_from_md_textΒΆ
- Defined in File instruction.py
Function pymdtools::instruction::get_refs_otherΒΆ
- Defined in File instruction.py
Function pymdtools::instruction::get_title_from_md_textΒΆ
- Defined in File instruction.py
Function pymdtools::instruction::get_vars_from_md_fileΒΆ
- Defined in File instruction.py
Function pymdtools::instruction::get_vars_from_md_textΒΆ
- Defined in File instruction.py
Function pymdtools::instruction::include_files_to_md_fileΒΆ
- Defined in File instruction.py
Function pymdtools::instruction::include_files_to_md_textΒΆ
- Defined in File instruction.py
Function pymdtools::instruction::include_refs_to_md_fileΒΆ
- Defined in File instruction.py
Function DocumentationΒΆ
-
pymdtools.instruction.
include_refs_to_md_file
(filename filename, refs refs, backup_option backup_option = True, filename_ext filename_ext = ".md", begin_include_re begin_include_re = __begin_include_re__, end_include_re end_include_re = __end_include_re__, error_if_no_key error_if_no_key = True)ΒΆ
Function pymdtools::instruction::include_refs_to_md_textΒΆ
- Defined in File instruction.py
Function pymdtools::instruction::include_vars_to_md_fileΒΆ
- Defined in File instruction.py
Function DocumentationΒΆ
-
pymdtools.instruction.
include_vars_to_md_file
(filename filename, text_vars text_vars, backup_option backup_option = True, filename_ext filename_ext = ".md", begin_var_re begin_var_re = __begin_var_re__, end_var_re end_var_re = __end_var_re__, error_if_var_not_found error_if_var_not_found = True)ΒΆ
Function pymdtools::instruction::include_vars_to_md_textΒΆ
- Defined in File instruction.py
Function pymdtools::instruction::refs_in_md_textΒΆ
- Defined in File instruction.py
Function pymdtools::instruction::search_include_refs_to_md_fileΒΆ
- Defined in File instruction.py
Function DocumentationΒΆ
-
pymdtools.instruction.
search_include_refs_to_md_file
(filename filename, backup_option backup_option = True, filename_ext filename_ext = ".md", depth_up depth_up = 1, depth_down depth_down = -1)ΒΆ Search and include reference to the markdown text @warning All the reference must be defined Depth down parameter : - -1-> every subfolder. - 0-> the current level - n-> (with n>0) n subfolder level of the folder @type filename: string @param filename The name and path of the file to work with. This file is supposed to be a markdown file. @type backup_option: boolean @param backup_option This parameter is set to true by default. If the backup option is set, then a file named filename.bak will be created. @type filename_ext: string @param filename_ext This parameter the markdown extension for the filename. @type depth_up: integer @param depth_up the number of upper folder to search for. @type depth_down: integer @param depth_down the depth to search for.
Function pymdtools::instruction::search_include_vars_to_md_fileΒΆ
- Defined in File instruction.py
Function pymdtools::instruction::search_include_vars_to_md_textΒΆ
- Defined in File instruction.py
Function pymdtools::instruction::set_include_file_to_md_textΒΆ
- Defined in File instruction.py
Function pymdtools::instruction::set_title_in_md_textΒΆ
- Defined in File instruction.py
Function pymdtools::instruction::set_var_to_md_textΒΆ
- Defined in File instruction.py
Function pymdtools::instruction::strip_xml_commentΒΆ
- Defined in File instruction.py
Function pymdtools::markdownify::_todictΒΆ
- Defined in File markdownify.py
Function pymdtools::markdownify::escapeΒΆ
- Defined in File markdownify.py
Function pymdtools::markdownify::markdownifyΒΆ
- Defined in File markdownify.py
Function pymdtools::markdownify::strip_first_last_lf_largeΒΆ
- Defined in File markdownify.py
Function pymdtools::markdownify::strip_first_last_spaceΒΆ
- Defined in File markdownify.py
Function pymdtools::markdownify::strip_first_last_space_largeΒΆ
- Defined in File markdownify.py
Function pymdtools::mdcommon::get_domain_nameΒΆ
- Defined in File mdcommon.py
Function pymdtools::mdcommon::is_external_linkΒΆ
- Defined in File mdcommon.py
Function pymdtools::mdcommon::move_base_path_in_md_textΒΆ
- Defined in File mdcommon.py
Function pymdtools::mdcommon::search_link_in_md_fileΒΆ
- Defined in File mdcommon.py
Function pymdtools::mdcommon::search_link_in_md_textΒΆ
- Defined in File mdcommon.py
Function pymdtools::mdcommon::search_link_in_md_text_jsonΒΆ
- Defined in File mdcommon.py
Function pymdtools::mdcommon::sub_string_link_by_ref_mdΒΆ
- Defined in File mdcommon.py
Function pymdtools::mdcommon::sub_string_link_mdΒΆ
- Defined in File mdcommon.py
Function pymdtools::mdcommon::sub_string_name_by_ref_mdΒΆ
- Defined in File mdcommon.py
Function pymdtools::mdcommon::update_link_from_old_linkΒΆ
- Defined in File mdcommon.py
Function pymdtools::mdcommon::update_link_in_md_textΒΆ
- Defined in File mdcommon.py
Function pymdtools::mdcommon::update_links_from_old_linkΒΆ
- Defined in File mdcommon.py
Function pymdtools::mdcommon::update_links_in_md_textΒΆ
- Defined in File mdcommon.py
Function pymdtools::mdtopdf::__get_this_filenameΒΆ
- Defined in File mdtopdf.py
Function pymdtools::mdtopdf::check_odd_pagesΒΆ
- Defined in File mdtopdf.py
Function pymdtools::mdtopdf::convert_html_to_pdfΒΆ
- Defined in File mdtopdf.py
Function pymdtools::mdtopdf::convert_md_to_htmlΒΆ
- Defined in File mdtopdf.py
Function pymdtools::mdtopdf::convert_md_to_pdfΒΆ
- Defined in File mdtopdf.py
Function DocumentationΒΆ
-
pymdtools.mdtopdf.
convert_md_to_pdf
(filename filename, filename_ext filename_ext = ".md", kwargs kwargs)ΒΆ This function take a file, load the content, create a pdf with the same name. @type filename: string @param filename: The name and path of the file to work with. This file is supposed to be a markdown file. @type filename_ext: string @param filename_ext: This parameter the markdown extension for the filename. @return nothing
Function pymdtools::mdtopdf::converter_md_to_html_markdownΒΆ
- Defined in File mdtopdf.py
Function pymdtools::mdtopdf::converter_md_to_html_mistuneΒΆ
- Defined in File mdtopdf.py
Function pymdtools::mdtopdf::find_wk_html_to_pdfΒΆ
- Defined in File mdtopdf.py
Function pymdtools::mdtopdf::get_md_to_html_converterΒΆ
- Defined in File mdtopdf.py
Function pymdtools::mdtopdf::pdf_featuresΒΆ
- Defined in File mdtopdf.py
Function pymdtools::mistunege::_keyifyΒΆ
- Defined in File mistunege.py
Function pymdtools::mistunege::_pure_patternΒΆ
- Defined in File mistunege.py
Function pymdtools::mistunege::escapeΒΆ
- Defined in File mistunege.py
Function DocumentationΒΆ
-
pymdtools.mistunege.
escape
(text text, quote quote = False, smart_amp smart_amp = True)ΒΆ Replace special characters "&", "<" and ">" to HTML-safe sequences. The original cgi.escape will always escape "&", but you can control this one for a smart escape amp. :param quote: if set to True, " and ' will be escaped. :param smart_amp: if set to False, & will always be escaped.
Function pymdtools::mistunege::escape_linkΒΆ
- Defined in File mistunege.py
Function pymdtools::mistunege::markdownΒΆ
- Defined in File mistunege.py
Function DocumentationΒΆ
-
pymdtools.mistunege.
markdown
(text text, escape escape = True, kwargs kwargs)ΒΆ Render markdown formatted text to html. :param text: markdown formatted text content. :param escape: if set to False, all html tags will not be escaped. :param use_xhtml: output with xhtml tags. :param hard_wrap: if set to True, it will use the GFM line breaks feature. :param parse_block_html: parse text only in block level html. :param parse_inline_html: parse text only in inline level html.
Function pymdtools::mistunege::preprocessingΒΆ
- Defined in File mistunege.py
Function pymdtools::normalize::md_beautifierΒΆ
- Defined in File normalize.py
Function pymdtools::normalize::md_file_beautifierΒΆ
- Defined in File normalize.py
Function DocumentationΒΆ
-
pymdtools.normalize.
md_file_beautifier
(filename filename, backup_option backup_option = True, filename_ext filename_ext = ".md")ΒΆ This function take a file, load the content, create a backup (if needed) and do some change in the file which is supposed to be a markdown file. Then saved the new file with the same filename. The goal is to beautify the markdown file. @type filename: string @param filename: The name and path of the file to work with. This file is supposed to be a markdown file. @type backup_option: boolean @param backup_option: This parameter is set to true by default. If the backup option is set, then a file named filename.bak will be created. @type filename_ext: string @param filename_ext: This parameter the markdown extension for the filename. @return nothing
Function pymdtools::translate::__get_this_filenameΒΆ
- Defined in File translate.py
Function pymdtools::translate::__get_this_folderΒΆ
- Defined in File translate.py
Function pymdtools::translate::_translation_parameterΒΆ
- Defined in File translate.py
Function pymdtools::translate::eu_lang_listΒΆ
- Defined in File translate.py
Function pymdtools::translate::get_localedirΒΆ
- Defined in File translate.py
Function pymdtools::translate::get_translationΒΆ
- Defined in File translate.py
Function pymdtools::translate::N_ΒΆ
- Defined in File translate.py
Function pymdtools::translate::translateΒΆ
- Defined in File translate.py
Function pymdtools::translate::translate_dictΒΆ
- Defined in File translate.py
Function pymdtools::translate::translate_listΒΆ
- Defined in File translate.py
Function pymdtools::translate::translate_mdΒΆ
- Defined in File translate.py
Function pymdtools::translate::translate_strΒΆ
- Defined in File translate.py
Function pymdtools::translate::translate_txtΒΆ
- Defined in File translate.py
VariablesΒΆ
Variable pymdtools::__all__ΒΆ
- Defined in File __init__.py
Variable DocumentationΒΆ
-
list pymdtools.__all__= [ 'print_conv', 'markdown_file_beautifier', 'convert_md_to_pdf', 'search_include_refs_to_md_file',]
Variable pymdtools::__author__ΒΆ
- Defined in File __init__.py
Variable DocumentationΒΆ
-
string pymdtools.__author__ = "Florent Tournois"
Variable pymdtools::__copyright__ΒΆ
- Defined in File __init__.py
Variable DocumentationΒΆ
-
string pymdtools.__copyright__ = "Copyright 2018, Florent Tournois"
Variable pymdtools::__credits__ΒΆ
- Defined in File __init__.py
Variable DocumentationΒΆ
-
list pymdtools.__credits__ = ["Arnaud Boidard"]
Variable pymdtools::__email__ΒΆ
- Defined in File __init__.py
Variable DocumentationΒΆ
-
string pymdtools.__email__ = "florent.tournois@gmail.fr"
Variable pymdtools::__license__ΒΆ
- Defined in File __init__.py
Variable DocumentationΒΆ
-
string pymdtools.__license__ = "MIT"
Variable pymdtools::__maintainer__ΒΆ
- Defined in File __init__.py
Variable DocumentationΒΆ
-
string pymdtools.__maintainer__ = "Florent Tournois"
Variable pymdtools::__module_name__ΒΆ
- Defined in File __init__.py
Variable DocumentationΒΆ
-
string pymdtools.__module_name__ = "pymdtools"
Variable pymdtools::__status__ΒΆ
- Defined in File __init__.py
Variable DocumentationΒΆ
-
string pymdtools.__status__ = "Production"
Variable pymdtools::__version__ΒΆ
- Defined in File __init__.py
Variable DocumentationΒΆ
-
string pymdtools.__version__ = '.'.join(str(c) for c in __version_info__)
Variable pymdtools::common::_TEXT_BOMSΒΆ
- Defined in File common.py
Variable DocumentationΒΆ
-
tuple pymdtools.common._TEXT_BOMS= ( codecs.BOM_UTF16_BE, codecs.BOM_UTF16_LE, codecs.BOM_UTF32_BE, codecs.BOM_UTF32_LE, codecs.BOM_UTF8,)
Variable pymdtools::instruction::__begin_include_re__ΒΆ
- Defined in File instruction.py
Variable DocumentationΒΆ
-
pymdtools.instruction.__begin_include_re__ = \
Variable pymdtools::instruction::__begin_ref_re__ΒΆ
- Defined in File instruction.py
Variable DocumentationΒΆ
-
pymdtools.instruction.__begin_ref_re__ = \
Variable pymdtools::instruction::__begin_var_re__ΒΆ
- Defined in File instruction.py
Variable DocumentationΒΆ
-
pymdtools.instruction.__begin_var_re__ = \
Variable pymdtools::instruction::__comment_re__ΒΆ
- Defined in File instruction.py
Variable DocumentationΒΆ
-
pymdtools.instruction.__comment_re__ = \
Variable pymdtools::instruction::__end_include_re__ΒΆ
- Defined in File instruction.py
Variable DocumentationΒΆ
-
pymdtools.instruction.__end_include_re__ = \
Variable pymdtools::instruction::__end_ref_re__ΒΆ
- Defined in File instruction.py
Variable DocumentationΒΆ
-
pymdtools.instruction.__end_ref_re__ = \
Variable pymdtools::instruction::__end_var_re__ΒΆ
- Defined in File instruction.py
Variable DocumentationΒΆ
-
pymdtools.instruction.__end_var_re__ = \
Variable pymdtools::instruction::__include_file_re__ΒΆ
- Defined in File instruction.py
Variable DocumentationΒΆ
-
pymdtools.instruction.__include_file_re__ = \
Variable pymdtools::instruction::__var_re__ΒΆ
- Defined in File instruction.py
Variable DocumentationΒΆ
-
pymdtools.instruction.__var_re__ = \
Variable pymdtools::markdownify::ATXΒΆ
- Defined in File markdownify.py
Variable DocumentationΒΆ
-
string pymdtools.markdownify.ATX = 'atx'
Variable pymdtools::markdownify::ATX_CLOSEDΒΆ
- Defined in File markdownify.py
Variable DocumentationΒΆ
-
string pymdtools.markdownify.ATX_CLOSED = 'atx_closed'
Variable pymdtools::markdownify::convert_heading_reΒΆ
- Defined in File markdownify.py
Variable DocumentationΒΆ
-
pymdtools.markdownify.convert_heading_re = re.compile(r'convert_h(d+)')
Variable pymdtools::markdownify::FRAGMENT_IDΒΆ
- Defined in File markdownify.py
Variable DocumentationΒΆ
-
string pymdtools.markdownify.FRAGMENT_ID = '__MARKDOWNIFY_WRAPPER__'
Variable pymdtools::markdownify::line_beginning_reΒΆ
- Defined in File markdownify.py
Variable DocumentationΒΆ
-
pymdtools.markdownify.line_beginning_re = re.compile(r'^', re.MULTILINE)
Variable pymdtools::markdownify::SETEXTΒΆ
- Defined in File markdownify.py
Variable DocumentationΒΆ
-
string pymdtools.markdownify.SETEXT = UNDERLINED
Variable pymdtools::markdownify::UNDERLINEDΒΆ
- Defined in File markdownify.py
Variable DocumentationΒΆ
-
string pymdtools.markdownify.UNDERLINED = 'underlined'
Variable pymdtools::markdownify::unicodeΒΆ
- Defined in File markdownify.py
Variable DocumentationΒΆ
-
pymdtools.markdownify.unicode = six.text_type
Variable pymdtools::markdownify::whitespace_reΒΆ
- Defined in File markdownify.py
Variable DocumentationΒΆ
-
pymdtools.markdownify.whitespace_re = re.compile(r'[rnst ]+')
Variable pymdtools::markdownify::wrappedΒΆ
- Defined in File markdownify.py
Variable DocumentationΒΆ
-
string pymdtools.markdownify.wrapped = '<div id="%s">%%s</div>' % FRAGMENT_ID
Variable pymdtools::mistunege::__all__ΒΆ
- Defined in File mistunege.py
Variable DocumentationΒΆ
-
list pymdtools.mistunege.__all__= [ 'BlockGrammar', 'BlockLexer', 'InlineGrammar', 'InlineLexer', 'Renderer', 'Markdown', 'markdown', 'escape',]
Variable pymdtools::mistunege::__author__ΒΆ
- Defined in File mistunege.py
Variable DocumentationΒΆ
-
string pymdtools.mistunege.__author__ = 'Hsiaoming Yang <me@lepture.com>'
Variable pymdtools::mistunege::__version__ΒΆ
- Defined in File mistunege.py
Variable DocumentationΒΆ
-
string pymdtools.mistunege.__version__ = '0.7.3'
Variable pymdtools::mistunege::_block_code_leading_patternΒΆ
- Defined in File mistunege.py
Variable DocumentationΒΆ
-
pymdtools.mistunege._block_code_leading_pattern = re.compile(r'^ {4}', re.M)
Variable pymdtools::mistunege::_block_quote_leading_patternΒΆ
- Defined in File mistunege.py
Variable DocumentationΒΆ
-
pymdtools.mistunege._block_quote_leading_pattern = re.compile(r'^ *> ?', flags=re.M)
Variable pymdtools::mistunege::_block_tagΒΆ
- Defined in File mistunege.py
Variable DocumentationΒΆ
-
string pymdtools.mistunege._block_tag = r'(?!(?:%s)b)w+%s' % ('|'.join(_inline_tags), _valid_end)
Variable pymdtools::mistunege::_escape_patternΒΆ
- Defined in File mistunege.py
Variable DocumentationΒΆ
-
pymdtools.mistunege._escape_pattern = re.compile(r'&(?!#?w+;)')
Variable pymdtools::mistunege::_inline_tagsΒΆ
- Defined in File mistunege.py
Variable DocumentationΒΆ
-
list pymdtools.mistunege._inline_tags= [ 'a', 'em', 'strong', 'small', 's', 'cite', 'q', 'dfn', 'abbr', 'data', 'time', 'code', 'var', 'samp', 'kbd', 'sub', 'sup', 'i', 'b', 'u', 'mark', 'ruby', 'rt', 'rp', 'bdi', 'bdo', 'span', 'br', 'wbr', 'ins', 'del', 'img', 'font',]
Variable pymdtools::mistunege::_key_patternΒΆ
- Defined in File mistunege.py
Variable DocumentationΒΆ
-
pymdtools.mistunege._key_pattern = re.compile(r's+')
Variable pymdtools::mistunege::_newline_patternΒΆ
- Defined in File mistunege.py
Variable DocumentationΒΆ
-
pymdtools.mistunege._newline_pattern = re.compile(r'rn|r')
Variable pymdtools::mistunege::_nonalpha_patternΒΆ
- Defined in File mistunege.py
Variable DocumentationΒΆ
-
pymdtools.mistunege._nonalpha_pattern = re.compile(r'W')
Variable pymdtools::mistunege::_pre_tagsΒΆ
- Defined in File mistunege.py
Variable DocumentationΒΆ
-
list pymdtools.mistunege._pre_tags = ['pre', 'script', 'style']
Variable pymdtools::mistunege::_scheme_blacklistΒΆ
- Defined in File mistunege.py
Variable DocumentationΒΆ
-
tuple pymdtools.mistunege._scheme_blacklist = ('javascript:', 'vbscript:')
Variable pymdtools::mistunege::_valid_attrΒΆ
- Defined in File mistunege.py
Variable DocumentationΒΆ
-
string pymdtools.mistunege._valid_attr = r'''s*[a-zA-Z-](?:=(?:"[^"]*"|'[^']*'|d+))*'''
Variable pymdtools::mistunege::_valid_endΒΆ
- Defined in File mistunege.py
Variable DocumentationΒΆ
-
string pymdtools.mistunege._valid_end = r'(?!:/|[^ws@]*@)b'
Variable pymdtools::translate::__all__ΒΆ
- Defined in File translate.py
Variable DocumentationΒΆ
-
list pymdtools.translate.__all__ = ["N_", "translate", "translate_txt", "translate_md"]
Variable pymdtools::version::__release_date__ΒΆ
- Defined in File version.py
Variable DocumentationΒΆ
-
string pymdtools.version.__release_date__ = '2020-03-25'
Variable pymdtools::version::__version_info__ΒΆ
- Defined in File version.py
Variable DocumentationΒΆ
-
tuple pymdtools.version.__version_info__ = (1, 0, 17)
Class HierarchyΒΆ
-
- Namespace pymdtools
- Namespace pymdtools::common
- Class Constant
- Namespace pymdtools::filetools
- Class FileContent
- Class FileName
- Namespace pymdtools::markdownify
- Namespace pymdtools::mdcommon
- Class Link
- Namespace pymdtools::mdfile
- Class MarkdownContent
- Namespace pymdtools::mdrender
- Class MdRenderer
- Namespace pymdtools::mistunege
- Class BlockGrammar
- Class BlockLexer
- Class InlineGrammar
- Class InlineLexer
- Class Markdown
- Class Renderer
- Namespace pymdtools::common
- Namespace pymdtools
File HierarchyΒΆ
-
- Directory pymdtools
- File __init__.py
- File common.py
- File filetools.py
- File instruction.py
- File markdownify.py
- File mdcommon.py
- File mdfile.py
- File mdrender.py
- File mdtopdf.py
- File mistunege.py
- File normalize.py
- File translate.py
- File version.py
- Directory pymdtools