提交 c32617a1 编写于 作者: M Markus Armbruster

qapi2texi: Fix translation of *strong* and _emphasized_

Signed-off-by: NMarkus Armbruster <armbru@redhat.com>
Message-Id: <1490015515-25851-7-git-send-email-armbru@redhat.com>
Reviewed-by: NMarc-André Lureau <marcandre.lureau@redhat.com>
上级 80d1f2e4
...@@ -35,12 +35,12 @@ EXAMPLE_FMT = """@example ...@@ -35,12 +35,12 @@ EXAMPLE_FMT = """@example
def subst_strong(doc): def subst_strong(doc):
"""Replaces *foo* by @strong{foo}""" """Replaces *foo* by @strong{foo}"""
return re.sub(r'\*([^*\n]+)\*', r'@emph{\1}', doc) return re.sub(r'\*([^*\n]+)\*', r'@strong{\1}', doc)
def subst_emph(doc): def subst_emph(doc):
"""Replaces _foo_ by @emph{foo}""" """Replaces _foo_ by @emph{foo}"""
return re.sub(r'\b_([^_\n]+)_\b', r' @emph{\1} ', doc) return re.sub(r'\b_([^_\n]+)_\b', r'@emph{\1}', doc)
def subst_vars(doc): def subst_vars(doc):
......
...@@ -2,7 +2,7 @@ ...@@ -2,7 +2,7 @@
@subsection Subsection @subsection Subsection
@emph{strong} @emph{with emphasis} @strong{strong} @emph{with emphasis}
@code{var} @{in braces@} @code{var} @{in braces@}
@itemize @bullet @itemize @bullet
@item @item
...@@ -67,7 +67,7 @@ Example: ...@@ -67,7 +67,7 @@ Example:
Examples: Examples:
@itemize @minus @itemize @minus
@item @item
@emph{verbatim} @strong{verbatim}
@item @item
@{braces@} @{braces@}
@end itemize @end itemize
...@@ -76,7 +76,7 @@ Examples: ...@@ -76,7 +76,7 @@ Examples:
@deftp {Enum} Enum @deftp {Enum} Enum
@subsection Produces @emph{invalid} texinfo @subsection Produces @strong{invalid} texinfo
@b{Values:} @b{Values:}
@table @asis @table @asis
......
Markdown is supported
0% .
You are about to add 0 people to the discussion. Proceed with caution.
先完成此消息的编辑!
想要评论请 注册