Sophie

Sophie

distrib > Mandriva > 8.2 > i586 > by-pkgid > 6282078ae76a671f49c6af38c67b1a07 > files > 853

kdelibs-devel-2.2.2-49.2mdk.i586.rpm

<HTML>
<HEAD>
<TITLE>class KComboBox</TITLE>

<META NAME="Generator" CONTENT="KDOC ">
</HEAD>
<BODY bgcolor="#ffffff" text="#000000" link="#0000ff" vlink="#000099" alink= "#ffffff">
<TABLE WIDTH="100%" BORDER="0">
<TR>
<TD>
	<TABLE BORDER="0">
		<TR><TD valign="top" align="left" cellspacing="10">
		<h1>class KComboBox</h1>
		</TD>
		<TD valign="top" align="right" colspan="1">An enhanced combo box.
 <small><A HREF="#longdesc">More...</A></small></TD></TR>
	</TABLE>
	<HR>
	<TABLE BORDER="0">
		<TR><TH>Definition</TH><TD><code>#include &lt;<A HREF="kcombobox_h.html">kcombobox.h</A>&gt;</code></TD></TR>
<TR><TH>Inherits</TH><TD><A HREF="../kdecore/KCompletionBase.html">KCompletionBase</A> <small>(kdecore)</small> <small>[public ]</small>, <A HREF="../../../../../../../../../usr/share/doc/qt-2.3.1/html/qcombobox.html">QComboBox</A> <small>(qt)</small> <small>[public ]</small></TD></TR>
<TR><TH>Inherited by</TH><TD><A HREF="KFontCombo.html">KFontCombo</A>, <A HREF="KHistoryCombo.html">KHistoryCombo</A></TD></TR>
<TR><TH><A HREF="full-list-KComboBox.html">List of all Methods</A></TH></TR>
	</TABLE>
	</TD>
<TD align="right"><TABLE BORDER="0"><TR><TD><small><A HREF="index-long.html">Annotated List</A></small></TD></TR>
<TR><TD><small><A HREF="header-list.html">Files</A></small></TD></TR>
<TR><TD><small><A HREF="all-globals.html">Globals</A></small></TD></TR>
<TR><TD><small><A HREF="hier.html">Hierarchy</A></small></TD></TR>
<TR><TD><small><A HREF="index.html">Index</A></small></TD></TR>
</TABLE></TD></TR></TABLE>
<h4>Public Methods</h4><ul><LI>&nbsp;<b><A HREF="#ref4">KComboBox</A></b> ( <A HREF="../../../../../../../../../usr/share/doc/qt-2.3.1/html/qwidget.html">QWidget</A> *parent=0, const char *name=0 ) 
</LI>
<LI>&nbsp;<b><A HREF="#ref5">KComboBox</A></b> ( bool rw, <A HREF="../../../../../../../../../usr/share/doc/qt-2.3.1/html/qwidget.html">QWidget</A> *parent=0, const char *name=0 ) 
</LI>
<LI>virtual  &nbsp;<b><A HREF="#ref6">~KComboBox</A></b> () 
</LI>
<LI>void &nbsp;<b><A HREF="#ref7">setEditURL</A></b> ( const <A HREF="../kdecore/KURL.html">KURL</A>& url ) 
</LI>
<LI>void &nbsp;<b><A HREF="#ref8">insertURL</A></b> ( const <A HREF="../kdecore/KURL.html">KURL</A>& url, int index = -1 ) 
</LI>
<LI>void &nbsp;<b><A HREF="#ref9">insertURL</A></b> ( const <A HREF="../../../../../../../../../usr/share/doc/qt-2.3.1/html/qpixmap.html">QPixmap</A>& pixmap, const <A HREF="../kdecore/KURL.html">KURL</A>& url, int index = -1 ) 
</LI>
<LI>void &nbsp;<b><A HREF="#ref10">changeURL</A></b> ( const <A HREF="../kdecore/KURL.html">KURL</A>& url, int index ) 
</LI>
<LI>void &nbsp;<b><A HREF="#ref11">changeURL</A></b> ( const <A HREF="../../../../../../../../../usr/share/doc/qt-2.3.1/html/qpixmap.html">QPixmap</A>& pixmap, const <A HREF="../kdecore/KURL.html">KURL</A>& url, int index ) 
</LI>
<LI>int &nbsp;<b><A HREF="#ref12">cursorPosition</A></b> ()  const
</LI>
<LI>virtual  void &nbsp;<b><A HREF="#ref13">setAutoCompletion</A></b> ( bool autocomplete ) 
</LI>
<LI>bool &nbsp;<b><A HREF="#ref14">autoCompletion</A></b> ()  const
</LI>
<LI>virtual  void &nbsp;<b><A HREF="#ref15">setContextMenuEnabled</A></b> ( bool showMenu ) 
</LI>
<LI>bool &nbsp;<b><A HREF="#ref16">isContextMenuEnabled</A></b> ()  const
</LI>
<LI>void &nbsp;<b><A HREF="#ref17">setURLDropsEnabled</A></b> ( bool enable ) 
</LI>
<LI>bool &nbsp;<b><A HREF="#ref18">isURLDropsEnabled</A></b> ()  const
</LI>
<LI>bool &nbsp;<b><A HREF="#ref19">isEditable</A></b> ()  const
</LI>
<LI>bool &nbsp;<b><A HREF="#ref20">contains</A></b> ( const <A HREF="../../../../../../../../../usr/share/doc/qt-2.3.1/html/qstring.html">QString</A>& text )  const
</LI>
<LI>void &nbsp;<b><A HREF="#ref21">setTrapReturnKey</A></b> ( bool trap ) 
</LI>
<LI>bool &nbsp;<b><A HREF="#ref22">trapReturnKey</A></b> ()  const
</LI>
<LI>virtual  void &nbsp;<b><A HREF="#ref24">setCompletionMode</A></b> ( KGlobalSettings::Completion mode ) 
</LI>
<LI><A HREF="KCompletionBox.html">KCompletionBox</A> * &nbsp;<b><A HREF="#ref25">completionBox</A></b> () 
</LI>
<LI><A HREF="KCompletionBox.html">KCompletionBox</A> * &nbsp;<b><A HREF="#ref26">completionBox</A></b> ( bool create ) 
</LI>
<LI>virtual  void &nbsp;<b><A HREF="#ref27">setCompletionObject</A></b> ( <A HREF="../kdecore/KCompletion.html">KCompletion</A> *, bool hsig = true ) 
</LI>
</ul><h4>Public Slots</h4><ul><LI>void &nbsp;<b><A HREF="#ref34">rotateText</A></b> ( KCompletionBase::KeyBindingType  ) 
</LI>
<LI>virtual  void &nbsp;<b><A HREF="#ref35">setCompletedText</A></b> ( const <A HREF="../../../../../../../../../usr/share/doc/qt-2.3.1/html/qstring.html">QString</A>& ) 
</LI>
<LI>void &nbsp;<b><A HREF="#ref36">setCompletedItems</A></b> ( const <A HREF="#QStringList">QStringList</A>& items ) 
</LI>
</ul><h4>Signals</h4><ul><LI>void &nbsp;<b><A HREF="#ref28">returnPressed</A></b> () 
</LI>
<LI>void &nbsp;<b><A HREF="#ref29">returnPressed</A></b> ( const <A HREF="../../../../../../../../../usr/share/doc/qt-2.3.1/html/qstring.html">QString</A>& ) 
</LI>
<LI>void &nbsp;<b><A HREF="#ref30">completion</A></b> ( const <A HREF="../../../../../../../../../usr/share/doc/qt-2.3.1/html/qstring.html">QString</A>& ) 
</LI>
<LI>void &nbsp;<b><A HREF="#ref31">textRotation</A></b> ( KCompletionBase::KeyBindingType ) 
</LI>
<LI>void &nbsp;<b><A HREF="#ref32">completionModeChanged</A></b> ( KGlobalSettings::Completion ) 
</LI>
<LI>void &nbsp;<b><A HREF="#ref33">aboutToShowContextMenu</A></b> ( <A HREF="../../../../../../../../../usr/share/doc/qt-2.3.1/html/qpopupmenu.html">QPopupMenu</A> * ) 
</LI>
</ul><h4>Protected Methods</h4><ul><LI>virtual  void &nbsp;<b><A HREF="#ref42">setCompletedText</A></b> ( const <A HREF="../../../../../../../../../usr/share/doc/qt-2.3.1/html/qstring.html">QString</A>& , bool  ) 
</LI>
<LI>virtual  void &nbsp;<b><A HREF="#ref43">create</A></b> ( WId = 0, bool initializeWindow = true,
                         bool destroyOldWindow = true ) 
</LI>
</ul><h4>Protected Slots</h4><ul><LI>virtual  void &nbsp;<b><A HREF="#ref37">itemSelected</A></b> ( <A HREF="../../../../../../../../../usr/share/doc/qt-2.3.1/html/qlistboxitem.html">QListBoxItem</A>* ) 
</LI>
<LI>virtual  void &nbsp;<b><A HREF="#ref38">makeCompletion</A></b> ( const <A HREF="../../../../../../../../../usr/share/doc/qt-2.3.1/html/qstring.html">QString</A>& ) 
</LI>
<LI>void &nbsp;<b><A HREF="#ref39">slotAboutToShow</A></b> () 
</LI>
<LI>void &nbsp;<b><A HREF="#ref40">slotCancelled</A></b> () 
</LI>
</ul><HR><H2><A NAME="longdesc">Detailed Description</A></H2><p>
 A combined button, line-edit and a popup list widget.
</p>
<p></p>

<H3>Detail
</H3>
<p>
</p>
<p> This widget inherits from <A HREF="../../../../../../../../../usr/share/doc/qt-2.3.1/html/qcombobox.html">QComboBox</A> and implements
 the following additional functionalities:  a completion
 object that provides both automatic and manual text
 completion as well as text rotation features, configurable
 key-bindings to activate these features, and a popup-menu
 item that can be used to allow the user to set text completion
 modes on the fly based on their preference.
</p>
<p> To support these new features <A HREF="KComboBox.html#KComboBox">KComboBox</A> also emits a few
 more additional signals as well.  The main ones are the
 <A HREF="KComboBox.html#completion">completion</A>( const QString& ) and <A HREF="KComboBox.html#textRotation">textRotation</A>( KeyBindgingType )
 signals.  The completion signal is intended to be connected to a slot
 that will assist the user in filling out the remaining text while
 the rotation signals is intended to be used to trasverse through all
 possible matches whenever text completion results in multiple matches.
 The <A HREF="KComboBox.html#returnPressed">returnPressed</A>() and <A HREF="KComboBox.html#returnPressed">returnPressed</A>( const QString& )
 signal is emitted when the user presses the Enter/Return key.
</p>
<p> This widget by default creates a completion object when you invoke
 the completionObject( bool ) member function for the first time
 or use <A HREF="KComboBox.html#setCompletionObject">setCompletionObject</A>( KCompletion*, bool ) to assign your
 own completion object.  Additionally, to make this widget more functional,
 <A HREF="KComboBox.html#KComboBox">KComboBox</A> will by default handle the text rotation and completion
 events internally whenever a completion object is created through either
 one of the methods mentioned above.  If you do not need this functionality,
 simply use <A HREF="../kdecore/KCompletionBase.html#setHandleSignals">KCompletionBase::setHandleSignals</A>( bool ) or alternatively
 set the boolean parameter in the above methods to FALSE.
</p>
<p> The default key-bindings for completion and rotation is determined
 from the global settings in <A HREF="../kdecore/KStdAccel.html">KStdAccel</A>.  These values, however,
 can be overriden locally by invoking <A HREF="../kdecore/KCompletionBase.html#setKeyBinding">KCompletionBase::setKeyBinding</A>().
 The values can easily be reverted back to the default setting, by simply
 calling useGlobalSettings(). An alternate method would be to default
 individual key-bindings by usning setKeyBinding() with the default
 second argument.
</p>
<p> Note that if this widget is not editable ( i.e. select-only ), then only
 one completion mode, <code>CompletionAuto</code>, will work.  All the other modes are
 simply ignored.  The <code>CompletionAuto</code> mode in this case allows you to
 automatically select an item from the list by trying to match the pressed
 keycode with the first letter of the enteries in the combo box.
</p>
<p></p>

<H3>Useage
</H3>
<p>
</p>
<p> To enable the basic completion feature:
</p>
<p></p><table border="0" width="100%">
<tr>
<td bgcolor="#BEEAE0">
<pre>

 <A HREF="KComboBox.html#KComboBox">KComboBox</A> *combo = new <A HREF="KComboBox.html#KComboBox">KComboBox</A>( true, this, "mywidget" );
 <A HREF="../kdecore/KCompletion.html">KCompletion</A> *comp = combo->completionObject();
 // Connect to the return pressed signal - optional
 connect(combo,SIGNAL(<A HREF="KComboBox.html#returnPressed">returnPressed</A>(const <A HREF="../../../../../../../../../usr/share/doc/qt-2.3.1/html/qstring.html">QString</A>&)),comp,SLOT(addItem(const <A HREF="../../../../../../../../../usr/share/doc/qt-2.3.1/html/qstring.html">QString</A>&));

</pre>
</td></tr>

</table> <p>
</p>
<p> To use your own completion object:
</p>
<p></p><table border="0" width="100%">
<tr>
<td bgcolor="#BEEAE0">
<pre>

 <A HREF="KComboBox.html#KComboBox">KComboBox</A> *combo = new <A HREF="KComboBox.html#KComboBox">KComboBox</A>( this,"mywidget" );
 KURLCompletion *comp = new KURLCompletion();
 combo-><A HREF="KComboBox.html#setCompletionObject">setCompletionObject</A>( comp );
 // Connect to the return pressed signal - optional
 connect(combo,SIGNAL(<A HREF="KComboBox.html#returnPressed">returnPressed</A>(const <A HREF="../../../../../../../../../usr/share/doc/qt-2.3.1/html/qstring.html">QString</A>&)),comp,SLOT(addItem(const <A HREF="../../../../../../../../../usr/share/doc/qt-2.3.1/html/qstring.html">QString</A>&));

</pre>
</td></tr>

</table> <p>
</p>
<p> Note that you have to either delete the allocated completion object
 when you don't need it anymore, or call
 setAutoDeleteCompletionObject( true );
</p>
<p> Miscellaneous function calls:
</p>
<p></p><table border="0" width="100%">
<tr>
<td bgcolor="#BEEAE0">
<pre>

 // Tell the widget not to handle <A HREF="KComboBox.html#completion">completion</A> and rotation
 combo->setHandleSignals( false );
 // Set your own <A HREF="KComboBox.html#completion">completion</A> key for manual completions.
 combo->setKeyBinding( KCompletionBase::TextCompletion, Qt::End );
 // Hide the context (popup) menu
 combo-><A HREF="KComboBox.html#setContextMenuEnabled">setContextMenuEnabled</A>( false );
 // Temporarly disable signal emition
 combo->disableSignals();
 // Default the all key-bindings to their system-wide settings.
 combo->useGlobalKeyBindings();

</pre>
</td></tr>

</table> <p>
</p>
<p></p>
<A NAME="KComboBox"></A><A NAME="ref4"></A><table width="100%"><tr bgcolor="#eeeeee"><td>&nbsp;<strong>KComboBox</strong> ( <A HREF="../../../../../../../../../usr/share/doc/qt-2.3.1/html/qwidget.html">QWidget</A> *parent=0, const char *name=0 )
<br></td><td align="right"><h3><strong>KComboBox</strong></h3></td></tr></table><p></p><p>
 Construct a read-only or rather select-only combo box with a
 parent object and a name.
</p>
<p></p>
<p><b>Parameters</b>:<TABLE BORDER="0" CELLPADDING="5">
<TR><TD align="left" valign="top"><i>parent</i></TD><TD align="left" valign="top">The parent object of this widget
</TD></TR>
<TR><TD align="left" valign="top"><i>name</i></TD><TD align="left" valign="top">The name of this widget
    </TD></TR>
</TABLE></P>
<A NAME="KComboBox"></A><A NAME="ref5"></A><table width="100%"><tr bgcolor="#eeeeee"><td>&nbsp;<strong>KComboBox</strong> ( bool rw, <A HREF="../../../../../../../../../usr/share/doc/qt-2.3.1/html/qwidget.html">QWidget</A> *parent=0, const char *name=0 )
<br></td><td align="right"><h3><strong>KComboBox</strong></h3></td></tr></table><p></p><p>
 Construct a "read-write" or "read-only" combo box depending on
 the value of the first argument( <code>rw</code> ) with a parent, a
 name.
</p>
<p></p>
<p><b>Parameters</b>:<TABLE BORDER="0" CELLPADDING="5">
<TR><TD align="left" valign="top"><i>rw</i></TD><TD align="left" valign="top">When <code>true</code>, widget will be editable.
</TD></TR>
<TR><TD align="left" valign="top"><i>parent</i></TD><TD align="left" valign="top">The parent object of this widget.
</TD></TR>
<TR><TD align="left" valign="top"><i>name</i></TD><TD align="left" valign="top">The name of this widget.
    </TD></TR>
</TABLE></P>
<A NAME="~KComboBox"></A><A NAME="ref6"></A><table width="100%"><tr bgcolor="#eeeeee"><td> &nbsp;<strong>~KComboBox</strong> ()
<br></td><td align="right"><h3><strong>~KComboBox</strong></h3></td></tr></table><p> <small>[virtual]</small></p><p>
 Destructor.
    </p>
<A NAME="setEditURL"></A><A NAME="ref7"></A><table width="100%"><tr bgcolor="#eeeeee"><td>void &nbsp;<strong>setEditURL</strong> ( const <A HREF="../kdecore/KURL.html">KURL</A>& url )
<br></td><td align="right"><h3><strong>setEditURL</strong></h3></td></tr></table><p></p><p>
 Sets <code>url</code> into the edit field of the combobox. It uses
 <A HREF="../kdecore/KURL.html#prettyURL">KURL::prettyURL</A>() so that the url is properly decoded for
 displaying.
     </p>
<A NAME="insertURL"></A><A NAME="ref8"></A><table width="100%"><tr bgcolor="#eeeeee"><td>void &nbsp;<strong>insertURL</strong> ( const <A HREF="../kdecore/KURL.html">KURL</A>& url, int index = -1 )
<br></td><td align="right"><h3><strong>insertURL</strong></h3></td></tr></table><p></p><p>
 Inserts <code>url</code> at position <code>index</code> into the combobox. The item will
 be appended if <code>index</code> is negative. <A HREF="../kdecore/KURL.html#prettyURL">KURL::prettyURL</A>() is used
 so that the url is properly decoded for displaying.
     </p>
<A NAME="insertURL"></A><A NAME="ref9"></A><table width="100%"><tr bgcolor="#eeeeee"><td>void &nbsp;<strong>insertURL</strong> ( const <A HREF="../../../../../../../../../usr/share/doc/qt-2.3.1/html/qpixmap.html">QPixmap</A>& pixmap, const <A HREF="../kdecore/KURL.html">KURL</A>& url, int index = -1 )
<br></td><td align="right"><h3><strong>insertURL</strong></h3></td></tr></table><p></p><p>
 Inserts <code>url</code> with the pixmap &p pixmap at position <code>index</code> into
 the combobox. The item will be appended if <code>index</code> is negative.
 <A HREF="../kdecore/KURL.html#prettyURL">KURL::prettyURL</A>() is used so that the url is properly decoded
 for displaying.
     </p>
<A NAME="changeURL"></A><A NAME="ref10"></A><table width="100%"><tr bgcolor="#eeeeee"><td>void &nbsp;<strong>changeURL</strong> ( const <A HREF="../kdecore/KURL.html">KURL</A>& url, int index )
<br></td><td align="right"><h3><strong>changeURL</strong></h3></td></tr></table><p></p><p>
 Replaces the item at position <code>index</code> with <code>url</code>.
 <A HREF="../kdecore/KURL.html#prettyURL">KURL::prettyURL</A>() is used so that the url is properly decoded
 for displaying.
     </p>
<A NAME="changeURL"></A><A NAME="ref11"></A><table width="100%"><tr bgcolor="#eeeeee"><td>void &nbsp;<strong>changeURL</strong> ( const <A HREF="../../../../../../../../../usr/share/doc/qt-2.3.1/html/qpixmap.html">QPixmap</A>& pixmap, const <A HREF="../kdecore/KURL.html">KURL</A>& url, int index )
<br></td><td align="right"><h3><strong>changeURL</strong></h3></td></tr></table><p></p><p>
 Replaces the item at position <code>index</code> with <code>url</code> and pixmap <code>pixmap</code>.
 <A HREF="../kdecore/KURL.html#prettyURL">KURL::prettyURL</A>() is used so that the url is properly decoded
 for displaying.
     </p>
<A NAME="cursorPosition"></A><A NAME="ref12"></A><table width="100%"><tr bgcolor="#eeeeee"><td>int &nbsp;<strong>cursorPosition</strong> ()
<br></td><td align="right"><h3><strong>cursorPosition</strong></h3></td></tr></table><p> <small>[const]</small></p><p>
 Retreive the current cursor position.
</p>
<p> This method always returns a -1 if the combo-box is <em>not</em>
 editable (read-write).
</p>
<p></p>
<p><b>Returns</b>: Current cursor position.
    </p>
<A NAME="setAutoCompletion"></A><A NAME="ref13"></A><table width="100%"><tr bgcolor="#eeeeee"><td> void &nbsp;<strong>setAutoCompletion</strong> ( bool autocomplete )
<br></td><td align="right"><h3><strong>setAutoCompletion</strong></h3></td></tr></table><p> <small>[virtual]</small></p><p>
 Re-implemented from <A HREF="../../../../../../../../../usr/share/doc/qt-2.3.1/html/qcombobox.html">QComboBox</A>.
</p>
<p> If <code>true</code>, the completion mode will be set to automatic.
 Otherwise, it is defaulted to the gloabl setting.  This
 methods has been replaced by the more comprehensive
 <A HREF="KComboBox.html#setCompletionMode">setCompletionMode</A>().
</p>
<p></p>
<p><b>Parameters</b>:<TABLE BORDER="0" CELLPADDING="5">
<TR><TD align="left" valign="top"><i>autocomplete</i></TD><TD align="left" valign="top">Flag to enable/disable automatic completion mode.
    </TD></TR>
</TABLE></P>
<p>Reimplemented from <A HREF="../../../../../../../../../usr/share/doc/qt-2.3.1/html/qcombobox.html#6e84ed">QComboBox</A>.</p>
<A NAME="autoCompletion"></A><A NAME="ref14"></A><table width="100%"><tr bgcolor="#eeeeee"><td>bool &nbsp;<strong>autoCompletion</strong> ()
<br></td><td align="right"><h3><strong>autoCompletion</strong></h3></td></tr></table><p> <small>[const]</small></p><p>
 Re-implemented from QComboBox.
</p>
<p> Returns <code>true</code> if the current completion mode is set
 to automatic.  See its more comprehensive replacement
 completionMode().
</p>
<p></p>
<p><b>Returns</b>: <code>true</code> when completion mode is automatic.
    </p>
<p>Reimplemented from <A HREF="../../../../../../../../../usr/share/doc/qt-2.3.1/html/qcombobox.html#cc98e9">QComboBox</A>.</p>
<A NAME="setContextMenuEnabled"></A><A NAME="ref15"></A><table width="100%"><tr bgcolor="#eeeeee"><td> void &nbsp;<strong>setContextMenuEnabled</strong> ( bool showMenu )
<br></td><td align="right"><h3><strong>setContextMenuEnabled</strong></h3></td></tr></table><p> <small>[virtual]</small></p><p>
 Enable or disable the popup (context) menu.
</p>
<p> This method only works if this widget is editable, i.e.
 read-write and allows you to enable/disable the context
 menu.  It does nothing if invoked for a none-editable
 combo-box.  Note that by default the mode changer item
 is made visiable whenever the context menu is enabled.
 Use hideModechanger() if you want to hide this
 item.    Also by default, the context menu is created if
 this widget is editable. Call this function with the
 argument set to false to disable the popup menu.
</p>
<p></p>
<p><b>Parameters</b>:<TABLE BORDER="0" CELLPADDING="5">
<TR><TD align="left" valign="top"><i>showMenu</i></TD><TD align="left" valign="top">If <code>true</code>, show the context menu.
</TD></TR>
<TR><TD align="left" valign="top"><i>showMode</i></TD><TD align="left" valign="top">If <code>true</code>, show the mode changer.
    </TD></TR>
</TABLE></P>
<A NAME="isContextMenuEnabled"></A><A NAME="ref16"></A><table width="100%"><tr bgcolor="#eeeeee"><td>bool &nbsp;<strong>isContextMenuEnabled</strong> ()
<br></td><td align="right"><h3><strong>isContextMenuEnabled</strong></h3></td></tr></table><p> <small>[const]</small></p><p>
 Returns <code>true</code> when the context menu is enabled.
</p>
<p></p>
<p><b>Returns</b>: <code>true</code> if context menu is enabled.
    </p>
<A NAME="setURLDropsEnabled"></A><A NAME="ref17"></A><table width="100%"><tr bgcolor="#eeeeee"><td>void &nbsp;<strong>setURLDropsEnabled</strong> ( bool enable )
<br></td><td align="right"><h3><strong>setURLDropsEnabled</strong></h3></td></tr></table><p></p><p>
 Enables/Disables handling of URL drops. If enabled and the user
 drops an URL, the decoded URL will be inserted. Otherwise the default
 behaviour of QComboBox is used, which inserts the encoded URL.
</p>
<p></p>
<p><b>Parameters</b>:<TABLE BORDER="0" CELLPADDING="5">
<TR><TD align="left" valign="top"><i>enable</i></TD><TD align="left" valign="top">If <code>true</code>, insert decoded URLs
     </TD></TR>
</TABLE></P>
<A NAME="isURLDropsEnabled"></A><A NAME="ref18"></A><table width="100%"><tr bgcolor="#eeeeee"><td>bool &nbsp;<strong>isURLDropsEnabled</strong> ()
<br></td><td align="right"><h3><strong>isURLDropsEnabled</strong></h3></td></tr></table><p> <small>[const]</small></p><p>
 Returns <code>true</code> when decoded URL drops are enabled
</p>
<p></p>
<p><b>Returns</b>: <code>true</code> if decoded URL drops are enabled
     </p>
<A NAME="isEditable"></A><A NAME="ref19"></A><table width="100%"><tr bgcolor="#eeeeee"><td>bool &nbsp;<strong>isEditable</strong> ()
<br></td><td align="right"><h3><strong>isEditable</strong></h3></td></tr></table><p> <small>[const]</small></p><p>
 Returns <code>true</code> if the combo-box is editable.
</p>
<p></p>
<p><b>Returns</b>: <code>true</code> if combo is editable.
    </p>
<A NAME="contains"></A><A NAME="ref20"></A><table width="100%"><tr bgcolor="#eeeeee"><td>bool &nbsp;<strong>contains</strong> ( const <A HREF="../../../../../../../../../usr/share/doc/qt-2.3.1/html/qstring.html">QString</A>& text )
<br></td><td align="right"><h3><strong>contains</strong></h3></td></tr></table><p> <small>[const]</small></p><p>
 Convenience method which iterates over all items and checks if
 any of them is equal to <code>text</code>.
</p>
<p> If <code>text</code> is an empty string, <code>false</code>
 is returned.
</p>
<p></p>
<p><b>Returns</b>: <code>true</code> if an item with the string <code>text</code> is in the combobox.
     </p>
<A NAME="setTrapReturnKey"></A><A NAME="ref21"></A><table width="100%"><tr bgcolor="#eeeeee"><td>void &nbsp;<strong>setTrapReturnKey</strong> ( bool trap )
<br></td><td align="right"><h3><strong>setTrapReturnKey</strong></h3></td></tr></table><p></p><p>
 By default, <A HREF="KComboBox.html#KComboBox">KComboBox</A> recognizes Key_Return and Key_Enter
 and emits
 the <A HREF="KComboBox.html#returnPressed">returnPressed</A>() signals, but it also lets the event pass,
 for example causing a dialog's default-button to be called.
</p>
<p> Call this method with <code>trap</code> equal to <code>true</code> to make <A HREF="KComboBox.html#KComboBox">KComboBox</A>
 stop these
 events. The signals will still be emitted of course.
</p>
<p> Only affects read-writable comboboxes.
</p>
<p></p>
<p><b>See also</b>: setTrapReturnKey()</p>
<A NAME="trapReturnKey"></A><A NAME="ref22"></A><table width="100%"><tr bgcolor="#eeeeee"><td>bool &nbsp;<strong>trapReturnKey</strong> ()
<br></td><td align="right"><h3><strong>trapReturnKey</strong></h3></td></tr></table><p> <small>[const]</small></p><p>
</p>
<p></p>
<p><b>Returns</b>: <code>true</code> if keyevents of Key_Return or Key_Enter will
 be stopped or if they will be propagated.
</p>
<p><b>See also</b>: setTrapReturnKey, ()</p>
<A NAME="eventFilter"></A><A NAME="ref23"></A><table width="100%"><tr bgcolor="#eeeeee"><td> bool &nbsp;<strong>eventFilter</strong> ( <A HREF="../../../../../../../../../usr/share/doc/qt-2.3.1/html/qobject.html">QObject</A> *, <A HREF="../../../../../../../../../usr/share/doc/qt-2.3.1/html/qevent.html">QEvent</A> * )
<br></td><td align="right"><h3><strong>eventFilter</strong></h3></td></tr></table><p> <small>[virtual]</small></p><p>
 Re-implemented for internal reasons.  API not affected.
</p>
<p>    </p>
<p>Reimplemented from <A HREF="../../../../../../../../../usr/share/doc/qt-2.3.1/html/qcombobox.html#f75507">QComboBox</A> for internal purposes..</p>
<A NAME="setCompletionMode"></A><A NAME="ref24"></A><table width="100%"><tr bgcolor="#eeeeee"><td> void &nbsp;<strong>setCompletionMode</strong> ( KGlobalSettings::Completion mode )
<br></td><td align="right"><h3><strong>setCompletionMode</strong></h3></td></tr></table><p> <small>[virtual]</small></p><p>
 Re-implemented from <A HREF="../kdecore/KCompletionBase.html">KCompletionBase</A> for internal reasons.
    </p>
<p>Reimplemented from <A HREF="../kdecore/KCompletionBase.html#setCompletionMode">KCompletionBase</A>.</p>
<A NAME="completionBox"></A><A NAME="ref25"></A><table width="100%"><tr bgcolor="#eeeeee"><td><A HREF="KCompletionBox.html">KCompletionBox</A> * &nbsp;<strong>completionBox</strong> ()
<br></td><td align="right"><h3><strong>completionBox</strong></h3></td></tr></table><p></p><p>
</p>
<p><b>Returns</b>: the completion-box, that is used in completion mode
 KGlobalSettings::CompletionPopup.
 This method will create a completion-box by calling
 <A HREF="KComboBox.html#makeCompletionBox">makeCompletionBox</A>, if none is there, yet.
     </p>
<A NAME="completionBox"></A><A NAME="ref26"></A><table width="100%"><tr bgcolor="#eeeeee"><td><A HREF="KCompletionBox.html">KCompletionBox</A> * &nbsp;<strong>completionBox</strong> ( bool create )
<br></td><td align="right"><h3><strong>completionBox</strong></h3></td></tr></table><p></p><p>
</p>
<p><b>Returns</b>: the completion box or 0L if none is available
     </p>
<A NAME="setCompletionObject"></A><A NAME="ref27"></A><table width="100%"><tr bgcolor="#eeeeee"><td> void &nbsp;<strong>setCompletionObject</strong> ( <A HREF="../kdecore/KCompletion.html">KCompletion</A> *, bool hsig = true )
<br></td><td align="right"><h3><strong>setCompletionObject</strong></h3></td></tr></table><p> <small>[virtual]</small></p><p>
 Reimplemented for internal reasons, the API is not affected.
     </p>
<p>Reimplemented from <A HREF="../kdecore/KCompletionBase.html#setCompletionObject">KCompletionBase</A>.</p>
<A NAME="returnPressed"></A><A NAME="ref28"></A><table width="100%"><tr bgcolor="#eeeeee"><td>void &nbsp;<strong>returnPressed</strong> ()
<br></td><td align="right"><h3><strong>returnPressed</strong></h3></td></tr></table><p> <small>[signal]</small></p><p>
 Emitted when the user presses the Enter key.
</p>
<p> Note that this signal is only
 emitted if this widget is editable.
    </p>
<A NAME="returnPressed"></A><A NAME="ref29"></A><table width="100%"><tr bgcolor="#eeeeee"><td>void &nbsp;<strong>returnPressed</strong> ( const <A HREF="../../../../../../../../../usr/share/doc/qt-2.3.1/html/qstring.html">QString</A>& )
<br></td><td align="right"><h3><strong>returnPressed</strong></h3></td></tr></table><p> <small>[signal]</small></p><p>
 Emitted when the user presses
 the Enter key.
</p>
<p> The argument is the current
 text being edited.  This signal is just like
 <A HREF="KComboBox.html#returnPressed">returnPressed</A>() except it contains the
 current text as its argument.
</p>
<p> Note that this signal is only emitted if this
 widget is editable.
    </p>
<A NAME="completion"></A><A NAME="ref30"></A><table width="100%"><tr bgcolor="#eeeeee"><td>void &nbsp;<strong>completion</strong> ( const <A HREF="../../../../../../../../../usr/share/doc/qt-2.3.1/html/qstring.html">QString</A>& )
<br></td><td align="right"><h3><strong>completion</strong></h3></td></tr></table><p> <small>[signal]</small></p><p>
 This signal is emitted when the completion key
 is pressed.
</p>
<p> The argument is the current text
 being edited.
</p>
<p> Note that this signal is <em>not</em> available if this
 widget is non-editable or the completion mode is
 set to <code>KGlobalSettings::CompletionNone</code>.
    </p>
<A NAME="textRotation"></A><A NAME="ref31"></A><table width="100%"><tr bgcolor="#eeeeee"><td>void &nbsp;<strong>textRotation</strong> ( KCompletionBase::KeyBindingType )
<br></td><td align="right"><h3><strong>textRotation</strong></h3></td></tr></table><p> <small>[signal]</small></p><p>
 Emitted when the text rotation key-bindings are pressed.
</p>
<p> The argument indicates which key-binding was pressed.
 In this case this can be either one of four values:
 <code>PrevCompletionMatch</code>, <code>NextCompletionMatch</code>, <code>RotateUp</code> or
 <code>RotateDown</code>. See <A HREF="../kdecore/KCompletionBase.html#setKeyBinding">KCompletionBase::setKeyBinding</A>() for
 details.
</p>
<p> Note that this signal is <em>NOT</em> emitted if the completion
 mode is set to CompletionNone.
    </p>
<A NAME="completionModeChanged"></A><A NAME="ref32"></A><table width="100%"><tr bgcolor="#eeeeee"><td>void &nbsp;<strong>completionModeChanged</strong> ( KGlobalSettings::Completion )
<br></td><td align="right"><h3><strong>completionModeChanged</strong></h3></td></tr></table><p> <small>[signal]</small></p><p>
 Emitted when the user changed the completion mode by using the
 popupmenu.
     </p>
<A NAME="aboutToShowContextMenu"></A><A NAME="ref33"></A><table width="100%"><tr bgcolor="#eeeeee"><td>void &nbsp;<strong>aboutToShowContextMenu</strong> ( <A HREF="../../../../../../../../../usr/share/doc/qt-2.3.1/html/qpopupmenu.html">QPopupMenu</A> * )
<br></td><td align="right"><h3><strong>aboutToShowContextMenu</strong></h3></td></tr></table><p> <small>[signal]</small></p><p>
 Emitted before the context menu is displayed.
</p>
<p> The signal allows you to add your own entries into the
 the context menu that is created on demand.
</p>
<p> NOTE: Do not store the pointer to the QPopupMenu
 provided through since it is created and deleted
 on demand.
</p>
<p></p>
<p><b>Parameters</b>:<TABLE BORDER="0" CELLPADDING="5">
<TR><TD align="left" valign="top"><i>the</i></TD><TD align="left" valign="top">context menu about to be displayed
     </TD></TR>
</TABLE></P>
<A NAME="rotateText"></A><A NAME="ref34"></A><table width="100%"><tr bgcolor="#eeeeee"><td>void &nbsp;<strong>rotateText</strong> ( KCompletionBase::KeyBindingType  )
<br></td><td align="right"><h3><strong>rotateText</strong></h3></td></tr></table><p> <small>[slot]</small></p><p>
 Iterate through all possible matches of the completed text
 or the history list.
</p>
<p> Depending on the value of the argument, this function either
 iterates through the history list of this widget or the all
 possible matches in whenever multiple matches result from a
 text completion request.  Note that the all-possible-match
 iteration will not work if there are no previous matches, i.e.
 no text has been completed and the *nix shell history list
 rotation is only available if the insertion policy for this
 widget is set either <code>QComobBox::AtTop</code> or <code>QComboBox::AtBottom</code>.
 For other insertion modes whatever has been typed by the user
 when the rotation event was initiated will be lost.
</p>
<p></p>
<p><b>Parameters</b>:<TABLE BORDER="0" CELLPADDING="5">
<TR><TD align="left" valign="top"><i>type</i></TD><TD align="left" valign="top">The key-binding invoked.
    </TD></TR>
</TABLE></P>
<A NAME="setCompletedText"></A><A NAME="ref35"></A><table width="100%"><tr bgcolor="#eeeeee"><td> void &nbsp;<strong>setCompletedText</strong> ( const <A HREF="../../../../../../../../../usr/share/doc/qt-2.3.1/html/qstring.html">QString</A>& )
<br></td><td align="right"><h3><strong>setCompletedText</strong></h3></td></tr></table><p> <small>[virtual slot]</small></p><p>
 Sets the completed text in the line-edit appropriately.
</p>
<p> This function is an implementation for
 <A HREF="../kdecore/KCompletionBase.html#setCompletedText">KCompletionBase::setCompletedText</A>.
     </p>
<p>Reimplemented from <A HREF="../kdecore/KCompletionBase.html#setCompletedText">KCompletionBase</A>.</p>
<A NAME="setCompletedItems"></A><A NAME="ref36"></A><table width="100%"><tr bgcolor="#eeeeee"><td>void &nbsp;<strong>setCompletedItems</strong> ( const <A HREF="#QStringList">QStringList</A>& items )
<br></td><td align="right"><h3><strong>setCompletedItems</strong></h3></td></tr></table><p> <small>[slot]</small></p><p>
 Sets <code>items</code> into the completion-box if completionMode() is
 CompletionPopup. The popup will be shown immediately.
     </p>
<A NAME="itemSelected"></A><A NAME="ref37"></A><table width="100%"><tr bgcolor="#eeeeee"><td> void &nbsp;<strong>itemSelected</strong> ( <A HREF="../../../../../../../../../usr/share/doc/qt-2.3.1/html/qlistboxitem.html">QListBoxItem</A>* )
<br></td><td align="right"><h3><strong>itemSelected</strong></h3></td></tr></table><p> <small>[protected slots virtual slot]</small></p><p>
    </p>
<A NAME="makeCompletion"></A><A NAME="ref38"></A><table width="100%"><tr bgcolor="#eeeeee"><td> void &nbsp;<strong>makeCompletion</strong> ( const <A HREF="../../../../../../../../../usr/share/doc/qt-2.3.1/html/qstring.html">QString</A>& )
<br></td><td align="right"><h3><strong>makeCompletion</strong></h3></td></tr></table><p> <small>[protected slots virtual slot]</small></p><p>
 Completes text according to the completion mode.
</p>
<p> Note: this method is <code>not</code> invoked if the completion mode is
 set to CompletionNone.  Also if the mode is set to <code>CompletionShell</code>
 and multiple matches are found, this method will complete the
 text to the first match with a beep to inidicate that there are
 more matches.  Then any successive completion key event iterates
 through the remaining matches.  This way the rotation functionality
 is left to iterate through the list as usual.
    </p>
<A NAME="slotAboutToShow"></A><A NAME="ref39"></A><table width="100%"><tr bgcolor="#eeeeee"><td>void &nbsp;<strong>slotAboutToShow</strong> ()
<br></td><td align="right"><h3><strong>slotAboutToShow</strong></h3></td></tr></table><p> <small>[protected slots slot]</small></p><p>
     </p>
<A NAME="slotCancelled"></A><A NAME="ref40"></A><table width="100%"><tr bgcolor="#eeeeee"><td>void &nbsp;<strong>slotCancelled</strong> ()
<br></td><td align="right"><h3><strong>slotCancelled</strong></h3></td></tr></table><p> <small>[protected slots slot]</small></p><p>
     </p>
<A NAME="keyPressEvent"></A><A NAME="ref41"></A><table width="100%"><tr bgcolor="#eeeeee"><td> void &nbsp;<strong>keyPressEvent</strong> ( <A HREF="../../../../../../../../../usr/share/doc/qt-2.3.1/html/qkeyevent.html">QKeyEvent</A>* )
<br></td><td align="right"><h3><strong>keyPressEvent</strong></h3></td></tr></table><p> <small>[protected virtual]</small></p><p>
    </p>
<p>Reimplemented from <A HREF="../../../../../../../../../usr/share/doc/qt-2.3.1/html/qcombobox.html#8a8d58">QComboBox</A> for internal purposes..</p>
<A NAME="setCompletedText"></A><A NAME="ref42"></A><table width="100%"><tr bgcolor="#eeeeee"><td> void &nbsp;<strong>setCompletedText</strong> ( const <A HREF="../../../../../../../../../usr/share/doc/qt-2.3.1/html/qstring.html">QString</A>& , bool  )
<br></td><td align="right"><h3><strong>setCompletedText</strong></h3></td></tr></table><p> <small>[protected virtual]</small></p><p>Reimplemented from <A HREF="../kdecore/KCompletionBase.html#setCompletedText">KCompletionBase</A>.</p>
<A NAME="create"></A><A NAME="ref43"></A><table width="100%"><tr bgcolor="#eeeeee"><td> void &nbsp;<strong>create</strong> ( WId = 0, bool initializeWindow = true,
                         bool destroyOldWindow = true )
<br></td><td align="right"><h3><strong>create</strong></h3></td></tr></table><p> <small>[protected virtual]</small></p><p>
 Reimplemented for internal reasons, the API is not affected.
     </p>
<HR><UL><LI><i>Author</i>: Dawit Alemayehu <adawit@kde.org>
 </LI><LI><i>Generated</i>: qateam on updates.mandrakesoft.com on Mon Dec 30 16:09:05 2002, using kdoc 2.0a53.</LI></UL></BODY></HTML>