如何更改默认的Javadoc样式表? [英] How to change default javadoc stylesheet?

查看:109
本文介绍了如何更改默认的Javadoc样式表?的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

是否存在用于更改javadoc创建的样式表文件的命令行选项? 我想使用自己的CSS文件. 默认的蓝色无聊.我尝试了-stylesheet选项,但不支持.

解决方案

是的,这是可能的,而且实际上非常简单.如果您看一下Mockito的javadoc:

如果您使用的是Maven,则可以通过在maven-javadoc-plugin中添加一些配置来实现:

如果您使用的是ant,则有一种方法可以将参数注入到javadoc工具中:

有关更多信息,请参见stackoverflow中的一些相关讨论主题: JavaDoc样式表

Is there a command line option to change the stylesheet file created by javadoc? I would like to use my own css file. The default blue one is boring. I tried a -stylesheet option, but it's not supported.

解决方案

Yes, it's possible and actually quite straightforward. If you look for example at Mockito's javadoc:

If you are using Maven, you can do that by adding some config in the maven-javadoc-plugin:

In case you are using ant, there is a way to inject the parameter to the javadoc tool:

For more information, there are some discussion topics about that in stackoverflow: JavaDoc Style Sheets

这篇关于如何更改默认的Javadoc样式表?的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆