Latex Javadoc 生成
有没有办法从我的 java 源文件的文档生成乳胶文档? 我不想在文档注释中包含 LaTeX 元素,我只是想创建 LaTeX 文件而不是 HTML。
谢谢
Is there a way to generate a latex document from my java sourcefile's documentation?
I don't want to include LaTeX Elements in my documentation comments, I simply want to create LaTeX files instead of HTML.
Thanks
如果你对这篇内容有疑问,欢迎到本站社区发帖提问 参与讨论,获取更多帮助,或者扫码二维码加入 Web 技术交流群。
绑定邮箱获取回复消息
由于您还没有绑定你的真实邮箱,如果其他用户或者作者回复了您的评论,将不能在第一时间通知您!
发布评论
评论(3)
Texdoclet 的替代方案是我创建的
ltxdoclet
。我认为主要区别在于它还包括源代码,而不仅仅是 Javadoc 注释,尽管您可以将其关闭。
github 站点上没有很好地记录它 - 只需下载代码并执行
ant pdfdoku
即可获得示例输出(ant Latexdoku
如果您只需要 LaTeX 文件)。 (不过,它是用德语记录的。)我真的应该在那里添加一个自述文件。
现在,这里是 jar 文件 - 将其下载到某处,然后
用于查看可用选项列表。 (如果您没有英语语言环境,这将是德语。在 bash 上添加“LC_ALL=en_US”或类似前缀以获得英语版本,或者查看 help_en.txt 如果您不懂德语。)
我正在研究一个包含更多文档的网页,但我不确定它什么时候准备好。
现在我们也有了一个网页。它链接 jar 文件,并且作为示例 应用于自身的 javadocs。
An alternative to Texdoclet is the
ltxdoclet
I created.I think the main difference is that it also includes the source code, not only the Javadoc comments, though you can switch this off.
It is not very well documented on the github site - just download the code and do
ant pdfdoku
for an example output (ant latexdoku
if you only want the LaTeX files). (It is documented in german, though.)I really should add a readme file there.
For now, here is the jar file - download it somewhere, and then use
to see a list of options available. (This will be in german, if you have no english locale. Prefix it with "LC_ALL=en_US" or similar on bash to get the english version, or have a look at help_en.txt instead if you don't know german.)
I'm working on a webpage with some more documentation, but I'm not sure when it will be ready.
Now we have a webpage, too. It links the jar file, and also as an example the javadocs when applied to itself.
Texdoclet 似乎就是您所需要的。至于如何使用它: 就像其他任何东西一样doclet。
Texdoclet seems to be what you need. As for how to use it: just like any other doclet.
如果您不想依赖任何 doclet 依赖项,而是依赖 javascript 依赖项,则只需添加以下 javadoc 参数:
并在注释中使用 clean Latex,例如
\(\sum_i a_i\)< /code> 或
\[\sum_i a_i\]
If you don't want to rely on any doclet dependency, but rather on a javascript one, you can just add the following javadoc param:
and simply use clean latex inside your comments such as
\(\sum_i a_i\)
or\[\sum_i a_i\]