我正在使用reStructuredText和epydoc。如何才能使内部链接的文本不同于链接的目标?我有:
:todo: Figure out the `Product.manufacturer` relationship in `Product`.Product链接看起来很好,并且链接到Product对象。制造商链接指向正确的成员变量,但文本不是Product.manufacturer,而是Product.manufacturer。
我知道如果我使用epytext就可以做到这一点,但是我们想坚持使用reStructuredText,这样我们以后可以根据需要切换文档生成器。
发布于 2010-11-30 09:42:16
我自己并不熟悉epydoc,但是正常的reStructuredText方式是这样的:
`manufacturer <Product.manufacturer>`_或者,和斯芬克斯,
:attribute:`manufacturer <Product.manufacturer>`考虑到epydoc似乎已经覆盖了提供链接的默认角色,它将被留给它。然而,这是最有可能起作用的:
:todo: Figure out the `manufacturer <Product.manufacturer>` relationship in `Product`.https://stackoverflow.com/questions/3515115
复制相似问题