使用自动文档的自己的功能与Qt Creator? [英] Using automatic documentation of my own function with Qt Creator?

查看:153
本文介绍了使用自动文档的自己的功能与Qt Creator?的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

我正在使用Qt Creator,我决定要记录一个我写的函数,所以我把光标放在我的函数定义之上,并键入 / **< ENTER> 像这样:

I was using Qt Creator and I decided I wanted to document a function I had written so I positioned my cursor above my function definition and typed /**<ENTER> like so:

/**<ENTER>
void MyClass::myFunction(int myArg)
{
...


$ b b

Qt Creator会自动展开该评论:

Qt Creator auto-expanded that comment:

/**
 * @brief MyClass::myFunction
 * @param myArg
 */
void MyClass::myFunction(int myArg)
{
...

这是什么?在哪里可以记录?

What is this? Where is it documented?

我可以使用它来生成我自己的Qt助手 qch 帮助文件或什么? / p>

Can I use this to generate my own Qt Assistant qch help files or something?

推荐答案

应该记录此处此处,但它的不是...

It should be documented here or here, but its not...

这里是一些信息:

此功能的设置在这里找到:

The settings for this feature are found here:

Windows:

Qt Creator>编辑器>完成>文档注释

Qt Creator > Tools > Options > Text Editor > Completion > Documentation Comments

Mac OS X

首选项>文本编辑器>完成>文档注释

Qt Creator > Preferences > Text Editor > Completion > Documentation Comments

它列出的三个选项是:


  • 启用Doxygen块

  • 生成简要说明

  • 添加星号

(在Qt 2.6中找到,但是可能在早期版本中也可以,或者在某些时候它可能是默认插件集的一部分。)

(Found in Qt 2.6, but possibly in earlier versions, too?, or it may be part of the default plugin set at some point.)

您可以使用doxygen来运行您的源代码,并在chm文件和chm文件中创建一些花哨的文档a html文档和pdf。

You can use doxygen to run through your source code and create some fancy documentation, both in a chm file and in a html document and pdf.

http://www.stack .nl /〜dimitri / doxygen /

http://www.stack.nl/~dimitri/doxygen/manual/output.html (包含qch文件)

这里是Qt Creator的相关插件:

Here is a related plugin for Qt Creator:

http:// dev.kofee.org/projects/qtcreator-doxygen/wiki

并使用 QHelpEngine 您自己的程序...

And using the QHelpEngine in your own program...

http ://qt-project.org/doc/qt-4.8/qthelp-framework.html

最后,您可以使用QDesktopServices处理帮助样式网址:

And finally, you can use QDesktopServices to handle a help styled url:

http: //doc-snapshot.qt-project.org/4.8/qdesktopservices.html#url-handlers

希望有所帮助。

这篇关于使用自动文档的自己的功能与Qt Creator?的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

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