[190] | 1 | <!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.0 Transitional//EN">
|
---|
| 2 | <!-- /home/espenr/tmp/qt-3.3.8-espenr-2499/qt-x11-free-3.3.8/tools/assistant/lib/qassistantclient.cpp:55 -->
|
---|
| 3 | <html>
|
---|
| 4 | <head>
|
---|
| 5 | <meta http-equiv="Content-Type" content="text/html; charset=ISO-8859-1">
|
---|
| 6 | <title>QAssistantClient Class</title>
|
---|
| 7 | <style type="text/css"><!--
|
---|
| 8 | fn { margin-left: 1cm; text-indent: -1cm; }
|
---|
| 9 | a:link { color: #004faf; text-decoration: none }
|
---|
| 10 | a:visited { color: #672967; text-decoration: none }
|
---|
| 11 | body { background: #ffffff; color: black; }
|
---|
| 12 | --></style>
|
---|
| 13 | </head>
|
---|
| 14 | <body>
|
---|
| 15 |
|
---|
| 16 | <table border="0" cellpadding="0" cellspacing="0" width="100%">
|
---|
| 17 | <tr bgcolor="#E5E5E5">
|
---|
| 18 | <td valign=center>
|
---|
| 19 | <a href="index.html">
|
---|
| 20 | <font color="#004faf">Home</font></a>
|
---|
| 21 | | <a href="classes.html">
|
---|
| 22 | <font color="#004faf">All Classes</font></a>
|
---|
| 23 | | <a href="mainclasses.html">
|
---|
| 24 | <font color="#004faf">Main Classes</font></a>
|
---|
| 25 | | <a href="annotated.html">
|
---|
| 26 | <font color="#004faf">Annotated</font></a>
|
---|
| 27 | | <a href="groups.html">
|
---|
| 28 | <font color="#004faf">Grouped Classes</font></a>
|
---|
| 29 | | <a href="functions.html">
|
---|
| 30 | <font color="#004faf">Functions</font></a>
|
---|
| 31 | </td>
|
---|
| 32 | <td align="right" valign="center"><img src="logo32.png" align="right" width="64" height="32" border="0"></td></tr></table><h1 align=center>QAssistantClient Class Reference</h1>
|
---|
| 33 |
|
---|
| 34 | <p>The QAssistantClient class provides a means of using Qt
|
---|
| 35 | Assistant as an application's help tool.
|
---|
| 36 | <a href="#details">More...</a>
|
---|
| 37 | <p><tt>#include <<a href="qassistantclient-h.html">qassistantclient.h</a>></tt>
|
---|
| 38 | <p>Inherits <a href="qobject.html">QObject</a>.
|
---|
| 39 | <p><a href="qassistantclient-members.html">List of all member functions.</a>
|
---|
| 40 | <h2>Public Members</h2>
|
---|
| 41 | <ul>
|
---|
| 42 | <li class=fn><a href="#QAssistantClient"><b>QAssistantClient</b></a> ( const QString & path, QObject * parent = 0, const char * name = 0 )</li>
|
---|
| 43 | <li class=fn><a href="#~QAssistantClient"><b>~QAssistantClient</b></a> ()</li>
|
---|
| 44 | <li class=fn>bool <a href="#isOpen"><b>isOpen</b></a> () const</li>
|
---|
| 45 | <li class=fn>void <a href="#setArguments"><b>setArguments</b></a> ( const QStringList & args )</li>
|
---|
| 46 | </ul>
|
---|
| 47 | <h2>Public Slots</h2>
|
---|
| 48 | <ul>
|
---|
| 49 | <li class=fn>virtual void <a href="#openAssistant"><b>openAssistant</b></a> ()</li>
|
---|
| 50 | <li class=fn>virtual void <a href="#closeAssistant"><b>closeAssistant</b></a> ()</li>
|
---|
| 51 | <li class=fn>virtual void <a href="#showPage"><b>showPage</b></a> ( const QString & page )</li>
|
---|
| 52 | </ul>
|
---|
| 53 | <h2>Signals</h2>
|
---|
| 54 | <ul>
|
---|
| 55 | <li class=fn>void <a href="#assistantOpened"><b>assistantOpened</b></a> ()</li>
|
---|
| 56 | <li class=fn>void <a href="#assistantClosed"><b>assistantClosed</b></a> ()</li>
|
---|
| 57 | <li class=fn>void <a href="#error"><b>error</b></a> ( const QString & msg )</li>
|
---|
| 58 | </ul>
|
---|
| 59 | <h2>Properties</h2>
|
---|
| 60 | <ul>
|
---|
| 61 | <li class=fn>bool <a href="#open-prop"><b>open</b></a> - whether Qt Assistant is open <em>(read only)</em></li>
|
---|
| 62 | </ul>
|
---|
| 63 | <hr><a name="details"></a><h2>Detailed Description</h2>
|
---|
| 64 |
|
---|
| 65 |
|
---|
| 66 | The QAssistantClient class provides a means of using Qt
|
---|
| 67 | Assistant as an application's help tool.
|
---|
| 68 | <p> Using Qt Assistant is simple: Create a QAssistantClient instance,
|
---|
| 69 | then call <a href="#showPage">showPage</a>() as often as necessary to show your help
|
---|
| 70 | pages. When you call showPage(), Qt Assistant will be launched if
|
---|
| 71 | it isn't already running.
|
---|
| 72 | <p> The QAssistantClient instance can open (<a href="#openAssistant">openAssistant</a>()) or close
|
---|
| 73 | (<a href="#closeAssistant">closeAssistant</a>()) Qt Assistant whenever required. If Qt Assistant
|
---|
| 74 | is open, <a href="#isOpen">isOpen</a>() returns TRUE.
|
---|
| 75 | <p> One QAssistantClient instance interacts with one Qt Assistant
|
---|
| 76 | instance, so every time you call openAssistant(), showPage() or
|
---|
| 77 | closeAssistant() they are applied to the particular Qt Assistant
|
---|
| 78 | instance associated with the QAssistantClient.
|
---|
| 79 | <p> When you call openAssistant() the <a href="#assistantOpened">assistantOpened</a>() signal is
|
---|
| 80 | emitted. Similarly when closeAssistant() is called,
|
---|
| 81 | <a href="#assistantClosed">assistantClosed</a>() is emitted. In either case, if an error occurs,
|
---|
| 82 | <a href="#error">error</a>() is emitted.
|
---|
| 83 | <p> This class is not included in the Qt library itself. To use it you
|
---|
| 84 | must link against <tt>libqassistantclient.a</tt> (Unix) or <tt>qassistantclient.lib</tt> (Windows), which is built into <tt>INSTALL/lib</tt>
|
---|
| 85 | if you built the Qt tools (<tt>INSTALL</tt> is the directory where Qt is
|
---|
| 86 | installed). If you use qmake, then you can simply add the following
|
---|
| 87 | line to your pro file:
|
---|
| 88 | <p> <pre>
|
---|
| 89 | LIBS += -lqassistantclient
|
---|
| 90 | </pre>
|
---|
| 91 |
|
---|
| 92 | <p> See also "Adding Documentation to Qt Assistant" in the <a href="assistant.html">Qt Assistant manual</a>.
|
---|
| 93 |
|
---|
| 94 | <hr><h2>Member Function Documentation</h2>
|
---|
| 95 | <h3 class=fn><a name="QAssistantClient"></a>QAssistantClient::QAssistantClient ( const <a href="qstring.html">QString</a> & path, <a href="qobject.html">QObject</a> * parent = 0, const char * name = 0 )
|
---|
| 96 | </h3>
|
---|
| 97 | Constructs an assistant client object. The <em>path</em> specifies the
|
---|
| 98 | path to the Qt Assistant executable. If <em>path</em> is an empty
|
---|
| 99 | string the system path (<tt>%PATH%</tt> or <tt>$PATH</tt>) is used.
|
---|
| 100 | <p> The assistant client object is a child of <em>parent</em> and is called
|
---|
| 101 | <em>name</em>.
|
---|
| 102 |
|
---|
| 103 | <h3 class=fn><a name="~QAssistantClient"></a>QAssistantClient::~QAssistantClient ()
|
---|
| 104 | </h3>
|
---|
| 105 | Destroys the assistant client object and frees up all allocated
|
---|
| 106 | resources.
|
---|
| 107 |
|
---|
| 108 | <h3 class=fn>void <a name="assistantClosed"></a>QAssistantClient::assistantClosed ()<tt> [signal]</tt>
|
---|
| 109 | </h3>
|
---|
| 110 |
|
---|
| 111 | <p> This signal is emitted when the connection to Qt Assistant is
|
---|
| 112 | closed. This happens when the user exits Qt Assistant, or when an
|
---|
| 113 | error in the server or client occurs, or if <a href="#closeAssistant">closeAssistant</a>() is
|
---|
| 114 | called.
|
---|
| 115 |
|
---|
| 116 | <h3 class=fn>void <a name="assistantOpened"></a>QAssistantClient::assistantOpened ()<tt> [signal]</tt>
|
---|
| 117 | </h3>
|
---|
| 118 |
|
---|
| 119 | <p> This signal is emitted when Qt Assistant is open and the
|
---|
| 120 | client-server communication is set up.
|
---|
| 121 |
|
---|
| 122 | <h3 class=fn>void <a name="closeAssistant"></a>QAssistantClient::closeAssistant ()<tt> [virtual slot]</tt>
|
---|
| 123 | </h3>
|
---|
| 124 | Use this function to close Qt Assistant.
|
---|
| 125 | <p> <p>See also <a href="#assistantClosed">assistantClosed</a>().
|
---|
| 126 |
|
---|
| 127 | <h3 class=fn>void <a name="error"></a>QAssistantClient::error ( const <a href="qstring.html">QString</a> & msg )<tt> [signal]</tt>
|
---|
| 128 | </h3>
|
---|
| 129 |
|
---|
| 130 | <p> This signal is emitted if Qt Assistant cannot be started or if an
|
---|
| 131 | error occurs during the initialization of the connection between
|
---|
| 132 | Qt Assistant and the calling application. The <em>msg</em> provides an
|
---|
| 133 | explanation of the error.
|
---|
| 134 |
|
---|
| 135 | <h3 class=fn>bool <a name="isOpen"></a>QAssistantClient::isOpen () const
|
---|
| 136 | </h3><p>Returns TRUE if Qt Assistant is open; otherwise returns FALSE.
|
---|
| 137 | See the <a href="qassistantclient.html#open-prop">"open"</a> property for details.
|
---|
| 138 | <h3 class=fn>void <a name="openAssistant"></a>QAssistantClient::openAssistant ()<tt> [virtual slot]</tt>
|
---|
| 139 | </h3>
|
---|
| 140 | This function opens Qt Assistant and sets up the client-server
|
---|
| 141 | communiction between the application and Qt Assistant. If it is
|
---|
| 142 | already open, this function does nothing. If an error occurs,
|
---|
| 143 | <a href="#error">error</a>() is emitted.
|
---|
| 144 | <p> <p>See also <a href="#assistantOpened">assistantOpened</a>().
|
---|
| 145 |
|
---|
| 146 | <h3 class=fn>void <a name="setArguments"></a>QAssistantClient::setArguments ( const <a href="qstringlist.html">QStringList</a> & args )
|
---|
| 147 | </h3>
|
---|
| 148 | Sets the command line arguments used when Qt Assistant is
|
---|
| 149 | started to <em>args</em>.
|
---|
| 150 |
|
---|
| 151 | <h3 class=fn>void <a name="showPage"></a>QAssistantClient::showPage ( const <a href="qstring.html">QString</a> & page )<tt> [virtual slot]</tt>
|
---|
| 152 | </h3>
|
---|
| 153 | Call this function to make Qt Assistant show a particular <em>page</em>.
|
---|
| 154 | The <em>page</em> is a filename (e.g. <tt>myhelpfile.html</tt>). See "Adding
|
---|
| 155 | Documentation to Qt Assistant" in the <a href="assistant.html">Qt
|
---|
| 156 | Assistant manual</a> for further information.
|
---|
| 157 | <p> If Qt Assistant hasn't been <a href="#openAssistant">opened</a>
|
---|
| 158 | yet, this function will do nothing. You can use <a href="#isOpen">isOpen</a>() to
|
---|
| 159 | determine whether Qt Assistant is up and running, or you can
|
---|
| 160 | connect to the asssistantOpened() signal.
|
---|
| 161 | <p> <p>See also <a href="#open-prop">open</a> and <a href="#assistantOpened">assistantOpened</a>().
|
---|
| 162 |
|
---|
| 163 | <p>Example: <a href="helpsystem-example.html#x2686">helpsystem/mainwindow.cpp</a>.
|
---|
| 164 | <hr><h2>Property Documentation</h2>
|
---|
| 165 | <h3 class=fn>bool <a name="open-prop"></a>open</h3>
|
---|
| 166 | <p>This property holds whether Qt Assistant is open.
|
---|
| 167 | <p>
|
---|
| 168 | <p>Get this property's value with <a href="#isOpen">isOpen</a>().
|
---|
| 169 | <!-- eof -->
|
---|
| 170 | <hr><p>
|
---|
| 171 | This file is part of the <a href="index.html">Qt toolkit</a>.
|
---|
| 172 | Copyright © 1995-2007
|
---|
| 173 | <a href="http://www.trolltech.com/">Trolltech</a>. All Rights Reserved.<p><address><hr><div align=center>
|
---|
| 174 | <table width=100% cellspacing=0 border=0><tr>
|
---|
| 175 | <td>Copyright © 2007
|
---|
| 176 | <a href="troll.html">Trolltech</a><td align=center><a href="trademarks.html">Trademarks</a>
|
---|
| 177 | <td align=right><div align=right>Qt 3.3.8</div>
|
---|
| 178 | </table></div></address></body>
|
---|
| 179 | </html>
|
---|