特集コンテンツ
ドキュメント内容コマンドは、ドキュメント内の特定の部分、つまり特別な表示、概念的な意味、または機能を持つ部分を識別します。
\quotation
\quotation および\endquotation コマンドは、長い引用文を区切ります。
区切られたブロック内のテキストは、HTML出力において<blockquote>と</blockquote>で囲まれます。例:
/*!
Although the prospect of a significantly broader market is
good news for Firstlogic, the notion also posed some
challenges. Dave Dobson, director of technology for the La
Crosse, Wisconsin-based company, said:
\quotation
As our solutions were being adopted into new
environments, we saw an escalating need for easier
integration with a wider range of enterprise
applications.
\endquotation
*/<blockquote> と </blockquote> で囲まれたブロック内のテキストは、生成されたHTMLで次のように表示されます: \quotation ブロック内のテキストは、生成されたHTMLでは次のように表示されます:
<blockquote>
<p>As our solutions were being adopted into new environments,
we saw an escalating need for easier integration with a wider
range of enterprise applications.</p>
</blockquote>ほとんどのブラウザの組み込みスタイルシートでは、<blockquote> タグの内容は左右にインデントされて表示されます。上記の例は次のように表示されます:
当社のソリューションが新しい環境に導入されるにつれ、より幅広いエンタープライズアプリケーションとの統合を容易にする必要性がますます高まってきました。
しかし、style.css ファイルで<blockquote>タグを再定義することができます。
\note
\note コマンドは、「Note:」という太字の文言で始まる新しい段落を定義します。このコマンドは、引数として連続した段落を受け取り、その段落の終了位置で終了します。noteコマンドは短い記述専用であり、長文の複数行にわたる段落には使用できません。
\warning コマンドと同様に、noteは短く重要な記述に使用します。使用方法については、『Qt ライティングガイドライン』を参照してください。
\notranslate
\notranslate コマンドは、生成された出力が言語翻訳サービスに渡される際、その引数を翻訳対象外とすることを指定します。
その他のコマンド(\c, \tt)も同様の効果がありますが、\notranslate は引数に対して一切の書式設定を行いません。
このコマンドは、QDoc バージョン 6.10 で導入されました。
\brief
\brief コマンドは、任意のトピックコマンドについて、1文による説明を追加します。
この短いテキストは、関連するオブジェクトのドキュメントの冒頭で説明として使用されるほか、 \generatelist コマンドおよび \annotatedlist コマンドを使用して生成されるリストで、関連するオブジェクトのドキュメントを紹介するために使用されます。
この概要テキストは、その特定のトピックに関するドキュメント内に表示されます。
たとえば、ブール型のQWidget::isWindow プロパティの場合:
/*!
\property QWidget::isActiveWindow
\brief Whether this widget's window is the active window.
The active window is the window that contains the widget that
has keyboard focus.
When popup windows are visible, this property is \c true
for both the active window \e and the popup.
\sa activateWindow(), QApplication::activeWindow()
*/およびQWidget::geometry プロパティ
/*!
\property QWidget::geometry
\brief The geometry of the widget relative to its parent and
excluding the window frame.
When changing the geometry, the widget, if visible,
receives a move event (moveEvent()) and/or a resize
event (resizeEvent()) immediately.
...
\sa frameGeometry(), rect(), ...
*/\brief コマンドを使用してクラスを記述する際は、次のような完全な文を使用することをお勧めします:
The <classname> class is|provides|contains|specifies...警告: 簡潔な説明文は詳細な説明の最初の段落となるため、詳細な説明の中で同じ文を繰り返さないでください 。
/*!
\class PreviewWindow
\brief The PreviewWindow class is a custom widget
displaying the names of its currently set
window flags in a read-only text editor.
The PreviewWindow class inherits QWidget. The widget
displays the names of its window flags set with the
setWindowFlags() function. It is also provided with a
QPushButton that closes the window.
...
\sa QWidget
*/\brief を \namespace:
/*!
\namespace Qt
\brief The Qt namespace contains miscellaneous identifiers
used throughout the Qt library.
*/\brief を \headerfile:
/*!
\headerfile <QtGlobal>
\title Global Qt Declarations
\brief The <QtGlobal> header file provides basic
declarations and is included by all other Qt headers.
\sa <QtAlgorithms>
*/関連項目 \property, \class, \namespace および \headerfile。
\legalese
\legalese および\endlegalese コマンドは、ライセンス契約の範囲を定義します。
生成されたHTMLでは、区切られたテキストは<div class="LegaleseLeft">および</div>タグで囲まれています。
\legalese および\endlegalese で囲まれた利用許諾契約書の例:
/*!
\legalese
Copyright 1996 Daniel Dardailler.
Permission to use, copy, modify, distribute, and sell this
software for any purpose is hereby granted without fee,
provided that the above copyright notice appear in all
copies and that both that copyright notice and this
permission notice appear in supporting documentation, and
that the name of Daniel Dardailler not be used in
advertising or publicity pertaining to distribution of the
software without specific, written prior permission. Daniel
Dardailler makes no representations about the suitability of
this software for any purpose. It is provided "as is"
without express or implied warranty.
Modifications Copyright 1999 Matt Koss, under the same
license as above.
\endlegalese
*/生成されたHTMLでは、次のように表示されます:
<div class="LegaleseLeft">
<p>Copyright 1996 Daniel Dardailler.</p>
<p>Permission to use, copy, modify, distribute, and sell
this software for any purpose is hereby granted without fee,
provided that the above copyright notice appear in all
copies and that both that copyright notice and this
permission notice appear in supporting documentation, and
that the name of Daniel Dardailler not be used in
advertising or publicity pertaining to distribution of the
software without specific, written prior permission. Daniel
Dardailler makes no representations about the suitability of
this software for any purpose. It is provided "as is"
without express or implied warranty.</p>
<p>Modifications Copyright 1999 Matt Koss, under the same
license as above.</p>
</div>\endlegalese コマンドが省略された場合、QDocは\legalese コマンドを処理しますが、ドキュメントページの残りの部分をライセンス契約として扱います。
理想的には、ライセンスのテキストはライセンス対象のコードと同じ場所に配置してください。
それ以外の場所では、 \legalese コマンドで指定されたドキュメントは、 \generatelistlegalese を引数として指定することで、集約することができます。これは、ソースコードに関連するライセンス契約の概要を生成するのに役立ちます。
注: \generatelist legalese コマンドの出力には 、現在のドキュメント・プロジェクトに含まれる\legalese のテキストのみが含まれます。現在のドキュメント・プロジェクトが他のモジュールに依存している場合、それらのライセンス・テキストは一覧に表示されません。
\warning
\warning コマンドは、コマンドの引数の先頭に「Warning:」を太字で付加します。
/*!
Qt::HANDLE is a platform-specific handle type
for system objects. This is equivalent to
\c{void *} on Windows and macOS, and to
\c{unsigned long} on X11.
\warning Using this type is not portable.
*/© 2026 The Qt Company Ltd. Documentation contributions included herein are the copyrights of their respective owners. The documentation provided herein is licensed under the terms of the GNU Free Documentation License version 1.3 as published by the Free Software Foundation. Qt and respective logos are trademarks of The Qt Company Ltd. in Finland and/or other countries worldwide. All other trademarks are property of their respective owners.