Part of a word bold in reStructuredText

痞子三分冷 提交于 2019-11-30 00:15:06

问题


How can I make a part of a word bold in reStructuredText?

Here is an example of what I need: ".rst stands for restructured text."


回答1:


I was surprised that you could not simply write

.rst stands for **r**e**s**tructured **t**ext.

but the reStructuredText specification indeed states that inline markup must be followed by white-space or one of - . , : ; ! ? \ / ' " ) ] } or >, so the above string of reStructuredText is not valid. However, only a minor change is required to get valid character markup with backslash escapes. Changing the above to

.rst stands for **r**\ e\ **s**\ tructured **t**\ ext.

works fine. To see this in action try the online reST to HTML converter.



来源:https://stackoverflow.com/questions/12771480/part-of-a-word-bold-in-restructuredtext

易学教程内所有资源均来自网络或用户发布的内容,如有违反法律规定的内容欢迎反馈
该文章没有解决你所遇到的问题?点击提问,说说你的问题,让更多的人一起探讨吧!