documentation - reStructuredText 中粗体字的一部分

如何在 reStructuredText 中将单词的一部分加粗?

这是我需要的示例:“.rst 代表 restructured text。”

最佳答案

我很惊讶你不能简单地写

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

但是 reStructuredText specification确实指出内联标记必须后跟空格或 - . , : 之一; ! ? \ / ' " ) ] }>,所以上面的 reStructuredText 字符串是 not 有效。但是,只需稍作更改即可使用反斜杠转义获得有效的 character markup。将上述更改为

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

工作正常。要查看实际情况,请尝试 online reST to HTML converter .

https://stackoverflow.com/questions/12771480/

相关文章:

eclipse - 有没有办法在 Eclipse 中手动折叠代码?

java - 如何在 Java 中按语言环境格式化日期?

iphone - 如何使用 iPhone SDK 将 TimeStyle AM/PM 设置为小写

c#-3.0 - 如何在 Resharper 中更改 "Use Object Initializer

c - 如何填充 printf 以考虑负号和可变长度数字?

formatting - 如何在 Erlang 中使用填充格式化数字

formatting - EditorConfig vs. Eslint vs. Prettier

xml - XSL - 舍入/格式数字问题

coding-style - 在 TextMate 中显示 80 个字符的边距线

java - 只想看到 Allman 样式代码并保存 K&R 样式代码