我在组织模式文件中有“[16]”,这是你在ipython shell中看到的文本。如何转义该文本以使其不生成组织模式脚注?它在一个示例块中很好,但在一般文本中没有。第一个[16]是麻烦,到目前为止我尝试过的所有内容在导出文件时都没有在html输出中直接产生正常的“[16]”。
#+BEGIN_SRC python
def setfrequency():
print 'Setting frequency'
# Write code here to set the frequency
setfrequency()
#+END_SRC
# This next line is the footnote problem
Run it again and you should see this, but the command number [16]
will be different for you:
#+BEGIN_EXAMPLE
In [16]: run sonar # This does not export as a footnote.
Setting frequency
#+END_EXAMPLE
谢谢!
答案 0 :(得分:4)
您可以使用= [1] =(代码)或〜[1]〜(逐字)块来转义语法。请参阅Emphasis and Monospace上的组织手册部分。
* This will export the footnote style brackets verbatim
[1] by itself will fail
=[1]= and ~[1]~ will export as is.
HTML导出的相关部分是
<p class="footnote"><sup><a class="footnum" name="fn.1" href="#fnr.1">1</a>
</sup> by itself will fail
<code>[1]</code> and <code>[1]</code> will export as is.
</p>
<p class="footnote"><sup><a class="footnum" name="fn.1" href="#fnr.1">1</a>
</sup> DEFINITION NOT FOUND: 1
答案 1 :(得分:0)
我试过这种方式。
Run it again and you should see this, but the command number
#+latex: [16]
will be different for you: