File: class-gtkcombobox.html

package info (click to toggle)
python-gtk2-doc 2.5.2-1
  • links: PTS
  • area: main
  • in suites: sarge
  • size: 8,304 kB
  • ctags: 3,741
  • sloc: makefile: 38
file content (187 lines) | stat: -rw-r--r-- 53,685 bytes parent folder | download
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
179
180
181
182
183
184
185
186
187
<html><head><meta http-equiv="Content-Type" content="text/html; charset=ISO-8859-1"><title>gtk.ComboBox</title><meta name="generator" content="DocBook XSL Stylesheets V1.65.1"><link rel="home" href="index.html" title="PyGTK 2.0 Reference Manual"><link rel="up" href="gtk-class-reference.html" title="The gtk Class Reference"><link rel="previous" href="class-gtkcombo.html" title="gtk.Combo"><link rel="next" href="class-gtkcomboboxentry.html" title="gtk.ComboBoxEntry"></head><body bgcolor="white" text="black" link="#0000FF" vlink="#840084" alink="#0000FF"><div class="navheader"><table width="100%" summary="Navigation header"><tr><th colspan="3" align="center">gtk.ComboBox</th></tr><tr><td width="20%" align="left"><a accesskey="p" href="class-gtkcombo.html">Prev</a></td><th width="60%" align="center">The gtk Class Reference</th><td width="20%" align="right"><a accesskey="n" href="class-gtkcomboboxentry.html">Next</a></td></tr></table><hr></div><div class="refentry" lang="en"><a name="class-gtkcombobox"></a><div class="titlepage"><div></div><div></div></div><div class="refnamediv"><h2>gtk.ComboBox</h2><p>gtk.ComboBox &#8212; a widget used to choose from
    a list of items (new in PyGTK 2.4)</p></div><div class="refsect1" lang="en"><a name="id3339857"></a><h2>Synopsis</h2><table bgcolor="#D0E0F0" width="100%"><tr><td><pre class="classsynopsis">class <span class="ooclass"><span class="classname">gtk.ComboBox</span></span>(<span class="ooclass"><span class="classname"><a href="class-gtkbin.html" title="gtk.Bin">gtk.Bin</a></span></span>, <span class="ooclass"><span class="classname"><a href="class-gtkcelllayout.html" title="gtk.CellLayout">gtk.CellLayout</a></span></span>):
<code class="constructorsynopsis">    <span class="methodname"><a href="class-gtkcombobox.html#constructor-gtkcombobox" title="Constructor">gtk.ComboBox</a></span>(<span class="methodparam"><span class="parameter"><b class="parameter"><tt>model</tt></b></span><span class="initializer">=None</span></span>)</code><br><code class="methodsynopsis">    def <span class="methodname"><a href="class-gtkcombobox.html#method-gtkcombobox--get-wrap-width" title="gtk.ComboBox.get_wrap_width">get_wrap_width</a></span>(<span class="methodparam"></span>)</code><br><code class="methodsynopsis">    def <span class="methodname"><a href="class-gtkcombobox.html#method-gtkcombobox--set-wrap-width" title="gtk.ComboBox.set_wrap_width">set_wrap_width</a></span>(<span class="methodparam"><span class="parameter"><b class="parameter"><tt>width</tt></b></span></span>)</code><br><code class="methodsynopsis">    def <span class="methodname"><a href="class-gtkcombobox.html#method-gtkcombobox--get-row-span-column" title="gtk.ComboBox.get_row_span_column">get_row_span_column</a></span>(<span class="methodparam"></span>)</code><br><code class="methodsynopsis">    def <span class="methodname"><a href="class-gtkcombobox.html#method-gtkcombobox--set-row-span-column" title="gtk.ComboBox.set_row_span_column">set_row_span_column</a></span>(<span class="methodparam"><span class="parameter"><b class="parameter"><tt>row_span</tt></b></span></span>)</code><br><code class="methodsynopsis">    def <span class="methodname"><a href="class-gtkcombobox.html#method-gtkcombobox--get-column-span-column" title="gtk.ComboBox.get_column_span_column">get_column_span_column</a></span>(<span class="methodparam"></span>)</code><br><code class="methodsynopsis">    def <span class="methodname"><a href="class-gtkcombobox.html#method-gtkcombobox--set-column-span-column" title="gtk.ComboBox.set_column_span_column">set_column_span_column</a></span>(<span class="methodparam"><span class="parameter"><b class="parameter"><tt>column_span</tt></b></span></span>)</code><br><code class="methodsynopsis">    def <span class="methodname"><a href="class-gtkcombobox.html#method-gtkcombobox--get-active" title="gtk.ComboBox.get_active">get_active</a></span>(<span class="methodparam"></span>)</code><br><code class="methodsynopsis">    def <span class="methodname"><a href="class-gtkcombobox.html#method-gtkcombobox--set-active" title="gtk.ComboBox.set_active">set_active</a></span>(<span class="methodparam"><span class="parameter"><b class="parameter"><tt>index</tt></b></span></span>)</code><br><code class="methodsynopsis">    def <span class="methodname"><a href="class-gtkcombobox.html#method-gtkcombobox--get-active-iter" title="gtk.ComboBox.get_active_iter">get_active_iter</a></span>(<span class="methodparam"></span>)</code><br><code class="methodsynopsis">    def <span class="methodname"><a href="class-gtkcombobox.html#method-gtkcombobox--set-active-iter" title="gtk.ComboBox.set_active_iter">set_active_iter</a></span>(<span class="methodparam"><span class="parameter"><b class="parameter"><tt>iter</tt></b></span></span>)</code><br><code class="methodsynopsis">    def <span class="methodname"><a href="class-gtkcombobox.html#method-gtkcombobox--set-model" title="gtk.ComboBox.set_model">set_model</a></span>(<span class="methodparam"><span class="parameter"><b class="parameter"><tt>model</tt></b></span><span class="initializer">=None</span></span>)</code><br><code class="methodsynopsis">    def <span class="methodname"><a href="class-gtkcombobox.html#method-gtkcombobox--get-model" title="gtk.ComboBox.get_model">get_model</a></span>(<span class="methodparam"></span>)</code><br><code class="methodsynopsis">    def <span class="methodname"><a href="class-gtkcombobox.html#method-gtkcombobox--append-text" title="gtk.ComboBox.append_text">append_text</a></span>(<span class="methodparam"><span class="parameter"><b class="parameter"><tt>text</tt></b></span></span>)</code><br><code class="methodsynopsis">    def <span class="methodname"><a href="class-gtkcombobox.html#method-gtkcombobox--insert-text" title="gtk.ComboBox.insert_text">insert_text</a></span>(<span class="methodparam"><span class="parameter"><b class="parameter"><tt>position</tt></b></span></span>, <span class="methodparam"><span class="parameter"><b class="parameter"><tt>text</tt></b></span></span>)</code><br><code class="methodsynopsis">    def <span class="methodname"><a href="class-gtkcombobox.html#method-gtkcombobox--prepend-text" title="gtk.ComboBox.prepend_text">prepend_text</a></span>(<span class="methodparam"><span class="parameter"><b class="parameter"><tt>text</tt></b></span></span>)</code><br><code class="methodsynopsis">    def <span class="methodname"><a href="class-gtkcombobox.html#method-gtkcombobox--remove-text" title="gtk.ComboBox.remove_text">remove_text</a></span>(<span class="methodparam"><span class="parameter"><b class="parameter"><tt>position</tt></b></span></span>)</code><br><code class="methodsynopsis">    def <span class="methodname"><a href="class-gtkcombobox.html#method-gtkcombobox--get-active-text" title="gtk.ComboBox.get_active_text">get_active_text</a></span>(<span class="methodparam"></span>)</code><br><code class="methodsynopsis">    def <span class="methodname"><a href="class-gtkcombobox.html#method-gtkcombobox--popup" title="gtk.ComboBox.popup">popup</a></span>(<span class="methodparam"></span>)</code><br><code class="methodsynopsis">    def <span class="methodname"><a href="class-gtkcombobox.html#method-gtkcombobox--popdown" title="gtk.ComboBox.popdown">popdown</a></span>(<span class="methodparam"></span>)</code><br><code class="methodsynopsis">    def <span class="methodname"><a href="class-gtkcombobox.html#method-gtkcombobox--get-popup-accessible" title="gtk.ComboBox.get_popup_accessible">get_popup_accessible</a></span>(<span class="methodparam"></span>)</code><br><code class="methodsynopsis">    def <span class="methodname"><a href="class-gtkcombobox.html#method-gtkcombobox--set-row-separator-func" title="gtk.ComboBox.set_row_separator_func">set_row_separator_func</a></span>(<span class="methodparam"><span class="parameter"><b class="parameter"><tt>func</tt></b></span><span class="initializer">=None</span></span>, <span class="methodparam"><span class="parameter"><b class="parameter"><tt>data</tt></b></span><span class="initializer">=None</span></span>)</code><br><code class="methodsynopsis">    def <span class="methodname"><a href="class-gtkcombobox.html#method-gtkcombobox--get-add-tearoffs" title="gtk.ComboBox.get_add_tearoffs">get_add_tearoffs</a></span>(<span class="methodparam"></span>)</code><br><code class="methodsynopsis">    def <span class="methodname"><a href="class-gtkcombobox.html#method-gtkcombobox--set-add-tearoffs" title="gtk.ComboBox.set_add_tearoffs">set_add_tearoffs</a></span>(<span class="methodparam"><span class="parameter"><b class="parameter"><tt>add_tearoffs</tt></b></span></span>)</code><br><code class="methodsynopsis">    def <span class="methodname"><a href="class-gtkcombobox.html#method-gtkcombobox--get-focus-on-click" title="gtk.ComboBox.get_focus_on_click">get_focus_on_click</a></span>(<span class="methodparam"></span>)</code><br><code class="methodsynopsis">    def <span class="methodname"><a href="class-gtkcombobox.html#method-gtkcombobox--set-focus-on-click" title="gtk.ComboBox.set_focus_on_click">set_focus_on_click</a></span>(<span class="methodparam"><span class="parameter"><b class="parameter"><tt>focus_on_click</tt></b></span></span>)</code><br></pre></td></tr></table><table border="0" bgcolor="#E0E0E0" width="100%"><tr><td><pre class="programlisting">
<span class="bold"><b>Functions</b></span>

<code class="methodsynopsis">    def <span class="methodname"><a href="class-gtkcombobox.html#function-gtk--combo-box-new-text" title="gtk.combo_box_new_text">gtk.combo_box_new_text</a></span>(<span class="methodparam"></span>)</code></pre></td></tr></table></div><div class="refsect1" lang="en"><a name="id3306074"></a><h2>Ancestry</h2><table border="0" bgcolor="#E0E0E0" width="100%"><tr><td><pre class="synopsis">+-- <a href="class-gobject.html" title="gobject.GObject">gobject.GObject</a>
  +-- <a href="class-gtkobject.html" title="gtk.Object">gtk.Object</a>
    +-- <a href="class-gtkwidget.html" title="gtk.Widget">gtk.Widget</a>
      +-- <a href="class-gtkcontainer.html" title="gtk.Container">gtk.Container</a>
        +-- <a href="class-gtkbin.html" title="gtk.Bin">gtk.Bin</a>
          +-- <a href="class-gtkcombobox.html" title="gtk.ComboBox">gtk.ComboBox</a> (implements <a href="class-gtkcelllayout.html" title="gtk.CellLayout"><tt class="classname">gtk.CellLayout</tt></a>)
</pre></td></tr></table></div><div class="refsect1" lang="en"><a name="id3306125"></a><h2>Properties</h2><div class="blockquote"><table width="100%" border="0" bgcolor="#E0E0E0"><tr><td valign="top"><div class="informaltable"><table width="100%" border="0"><colgroup><col><col><col></colgroup><tbody><tr valign="top"><td valign="top">"active"</td><td valign="top">Read-Write</td><td valign="top">The index of the item that is currently active.</td></tr><tr valign="top"><td valign="top">"add-tearoffs"</td><td valign="top">Read-Write</td><td valign="top">If <tt class="literal">TRUE</tt> generated menus have tearoff
menu items. Note that this only affects menu style combo boxes.
Default value: <tt class="literal">FALSE</tt>. Available in GTK+ 2.6 and
above.</td></tr><tr valign="top"><td valign="top">"column-span-column"</td><td valign="top">Read-Write</td><td valign="top">The TreeModel column containing the column span
values.</td></tr><tr valign="top"><td valign="top">"has-frame"</td><td valign="top">Read-Write</td><td valign="top">If <tt class="literal">TRUE</tt> the combo box grabs focus
when it is clicked with the mouse. Default value: <tt class="literal">TRUE</tt>.
Available in GTK+ 2.6 and above.</td></tr><tr valign="top"><td valign="top">"model"</td><td valign="top">Read-Write</td><td valign="top">The TreeModel for the combo box.</td></tr><tr valign="top"><td valign="top">"row-span-column"</td><td valign="top">Read-Write</td><td valign="top">The TreeModel column containing the row span
values.</td></tr><tr valign="top"><td valign="top">"wrap-width"</td><td valign="top">Read-Write</td><td valign="top">The number of columns to use to lay out the popup
items.</td></tr></tbody></table></div></td></tr></table></div></div><div class="refsect1" lang="en"><a name="id3306317"></a><h2>Style Properties</h2><div class="blockquote"><table width="100%" border="0" bgcolor="#E0E0E0"><tr><td valign="top"><div class="informaltable"><table width="100%" border="0"><colgroup><col><col><col></colgroup><tbody><tr valign="top"><td valign="top">"appears-as-list"</td><td valign="top">Read-Write</td><td valign="top">If <tt class="literal">TRUE</tt>, the combo box dropdowns should
look like lists rather than menus.</td></tr></tbody></table></div></td></tr></table></div></div><div class="refsect1" lang="en"><a name="id3306390"></a><h2>Signal Prototypes</h2><table border="0" width="100%" bgcolor="#FFECCE"><col align="left" valign="top" width="0*"><tbody><tr><td><span class="term">"<a href="class-gtkcombobox.html#signal-gtkcombobox--changed" title='The "changed" gtk.ComboBox Signal'>changed</a>"</span></td><td><code class="methodsynopsis">    def <span class="methodname">callback</span>(<span class="methodparam"><span class="parameter"><i class="parameter"><tt>combobox</tt></i></span></span>, <span class="methodparam"><span class="parameter"><i class="parameter"><tt>user_param1</tt></i></span></span>, <span class="methodparam"><span class="parameter"><i class="parameter"><tt>...</tt></i></span></span>)</code></td></tr></tbody></table></div><div class="refsect1" lang="en"><a name="id3306440"></a><h2>Description</h2><div class="note" style="margin-left: 0.5in; margin-right: 0.5in;"><h3 class="title">Note</h3><p>This widget is available in GTK+ 2.4 and PyGTK 2.4 and above.</p></div><p>The <a href="class-gtkcombobox.html" title="gtk.ComboBox"><tt class="classname">gtk.ComboBox</tt></a>
    is a replacement for the <a href="class-gtkoptionmenu.html" title="gtk.OptionMenu"><tt class="classname">gtk.OptionMenu</tt></a>. The
    <a href="class-gtkcombobox.html" title="gtk.ComboBox"><tt class="classname">gtk.ComboBox</tt></a>
    implements the <a href="class-gtkcelllayout.html" title="gtk.CellLayout"><tt class="classname">gtk.CellLayout</tt></a>
    interface that provides a number of useful methods for managing the
    contents. A <a href="class-gtkcombobox.html" title="gtk.ComboBox"><tt class="classname">gtk.ComboBox</tt></a>
    is created with the <a href="class-gtkcombobox.html#constructor-gtkcombobox" title="Constructor">gtk.ComboBox()</a> constructor that
    is associated with the optional <a href="class-gtktreemodel.html" title="gtk.TreeModel"><tt class="classname">gtk.TreeModel</tt></a>. If
    no <a href="class-gtktreemodel.html" title="gtk.TreeModel"><tt class="classname">gtk.TreeModel</tt></a>
    is specified it can be added later with the <a href="class-gtkcombobox.html#method-gtkcombobox--set-model" title="gtk.ComboBox.set_model"><tt class="methodname">set_model</tt>()</a>
    method.</p><p>Alternatively, the <a href="class-gtkcombobox.html#function-gtk--combo-box-new-text" title="gtk.combo_box_new_text"><tt class="function">gtk.combo_box_new_text</tt>()</a>
    function creates a simple <a href="class-gtkcombobox.html" title="gtk.ComboBox"><tt class="classname">gtk.ComboBox</tt></a>
    and associated <a href="class-gtkliststore.html" title="gtk.ListStore"><tt class="classname">gtk.ListStore</tt></a>
    model. A <a href="class-gtkcellrenderertext.html" title="gtk.CellRendererText"><tt class="classname">gtk.CellRendererText</tt></a>
    is also created and packed in the new combo box. In this simple combo
    box each list item is a text string that can be selected.  The
    convenience methods <a href="class-gtkcombobox.html#method-gtkcombobox--append-text" title="gtk.ComboBox.append_text"><tt class="methodname">append_text</tt>()</a>,
    <a href="class-gtkcombobox.html#method-gtkcombobox--prepend-text" title="gtk.ComboBox.prepend_text"><tt class="methodname">prepend_text</tt>()</a>,
    <a href="class-gtkcombobox.html#method-gtkcombobox--insert-text" title="gtk.ComboBox.insert_text"><tt class="methodname">insert_text</tt>()</a>
    and <a href="class-gtkcombobox.html#method-gtkcombobox--remove-text" title="gtk.ComboBox.remove_text"><tt class="methodname">remove_text</tt>()</a>
    can be used to manage the contents of the <a href="class-gtkcombobox.html" title="gtk.ComboBox"><tt class="classname">gtk.ComboBox</tt></a>. Using
    the <a href="class-gtkcombobox.html#function-gtk--combo-box-new-text" title="gtk.combo_box_new_text"><tt class="function">gtk.combo_box_new_text</tt>()</a>
    function is equivalent to:</p><table border="0" bgcolor="#E0E0E0" width="100%"><tr><td><pre class="programlisting">
  liststore = gtk.ListStore(gobject.TYPE_STRING)
  combobox = gtk.ComboBox(liststore)
  cell = gtk.CellRendererText()
  combobox.pack_start(cell, gtk.TRUE)
  combobox.add_attribute(cell, 'text', 0)
</pre></td></tr></table></div><div class="refsect1" lang="en"><a name="constructor-gtkcombobox"></a><h2>Constructor</h2><table border="0" bgcolor="#E0E0E0" width="100%"><tr><td><pre class="programlisting"><code class="constructorsynopsis">    <span class="methodname">gtk.ComboBox</span>(<span class="methodparam"><span class="parameter"><b class="parameter"><tt>model</tt></b></span><span class="initializer">=None</span></span>)</code></pre></td></tr></table><table border="0" width="100%" bgcolor="#FFECCE"><col align="left" valign="top" width="0*"><tbody><tr><td><span class="term"><b class="parameter"><tt>model</tt></b>:</span></td><td>A valid <a href="class-gtktreemodel.html" title="gtk.TreeModel"><tt class="classname">gtk.TreeModel</tt></a>.</td></tr><tr><td><span class="term"><span class="emphasis"><em>Returns</em></span>:</span></td><td>A new <a href="class-gtkcombobox.html" title="gtk.ComboBox"><tt class="classname">gtk.ComboBox</tt></a>.</td></tr></tbody></table><div class="note" style="margin-left: 0.5in; margin-right: 0.5in;"><h3 class="title">Note</h3><p>This constructor is available in PyGTK 2.4 and above.</p></div><p>Creates a new <a href="class-gtkcombobox.html" title="gtk.ComboBox"><tt class="classname">gtk.ComboBox</tt></a>
    associated with the optional <a href="class-gtktreemodel.html" title="gtk.TreeModel"><tt class="classname">gtk.TreeModel</tt></a>
    specified by <i class="parameter"><tt>model</tt></i>. If
    <i class="parameter"><tt>model</tt></i> is not specified the combo box will not
    have an associated tree model.</p></div><div class="refsect1" lang="en"><a name="id3306718"></a><h2>Methods</h2><div class="refsect2" lang="en"><a name="method-gtkcombobox--get-wrap-width"></a><h3>gtk.ComboBox.get_wrap_width</h3><table border="0" bgcolor="#E0E0E0" width="100%"><tr><td><pre class="programlisting"><code class="methodsynopsis">    def <span class="methodname">get_wrap_width</span>(<span class="methodparam"></span>)</code></pre></td></tr></table><table border="0" width="100%" bgcolor="#FFECCE"><col align="left" valign="top" width="0*"><tbody><tr><td><span class="term"><span class="emphasis"><em>Returns</em></span>:</span></td><td>The wrap width.</td></tr></tbody></table><div class="note" style="margin-left: 0.5in; margin-right: 0.5in;"><h3 class="title">Note</h3><p>This method is available in PyGTK 2.6 and above.</p></div><p>The <tt class="methodname">get_wrap_width</tt>() method returns the
value of the "wrap-width" property of the combo box as set by the <a href="class-gtkcombobox.html#method-gtkcombobox--set-wrap-width" title="gtk.ComboBox.set_wrap_width"><tt class="methodname">set_wrap_width</tt>()</a>
method. The wrap width is basically the preferred number of columns to use
to lay out the popup i.e. lays out the popup items in a table with
<i class="parameter"><tt>width</tt></i> columns.</p></div><div class="refsect2" lang="en"><a name="method-gtkcombobox--set-wrap-width"></a><h3>gtk.ComboBox.set_wrap_width</h3><table border="0" bgcolor="#E0E0E0" width="100%"><tr><td><pre class="programlisting"><code class="methodsynopsis">    def <span class="methodname">set_wrap_width</span>(<span class="methodparam"><span class="parameter"><b class="parameter"><tt>width</tt></b></span></span>)</code></pre></td></tr></table><table border="0" width="100%" bgcolor="#FFECCE"><col align="left" valign="top" width="0*"><tbody><tr><td><span class="term"><b class="parameter"><tt>width</tt></b>:</span></td><td>The preferred number of columns of
width.</td></tr></tbody></table><div class="note" style="margin-left: 0.5in; margin-right: 0.5in;"><h3 class="title">Note</h3><p>This method is available in PyGTK 2.4 and above.</p></div><p>The <tt class="methodname">set_wrap_width</tt>() method sets the
wrap width (and the "wrap-width" property) of the combo box to the value
specified by <i class="parameter"><tt>width</tt></i>. The wrap width is basically the
preferred number of columns to use to lay out the popup i.e. lays out the
popup items in a table with <i class="parameter"><tt>width</tt></i> columns.</p></div><div class="refsect2" lang="en"><a name="method-gtkcombobox--get-row-span-column"></a><h3>gtk.ComboBox.get_row_span_column</h3><table border="0" bgcolor="#E0E0E0" width="100%"><tr><td><pre class="programlisting"><code class="methodsynopsis">    def <span class="methodname">get_row_span_column</span>(<span class="methodparam"></span>)</code></pre></td></tr></table><table border="0" width="100%" bgcolor="#FFECCE"><col align="left" valign="top" width="0*"><tbody><tr><td><span class="term"><span class="emphasis"><em>Returns</em></span>:</span></td><td>The row span column.</td></tr></tbody></table><div class="note" style="margin-left: 0.5in; margin-right: 0.5in;"><h3 class="title">Note</h3><p>This method is available in PyGTK 2.6 and above.</p></div><p>The <tt class="methodname">get_row_span_column</tt>() method
returns the value of the "row-span-column" property. The "row-span-column"
property indicates the column in the associated <a href="class-gtktreemodel.html" title="gtk.TreeModel"><tt class="classname">gtk.TreeModel</tt></a> row
that contains an integer that indicates how many rows the item should
span.</p></div><div class="refsect2" lang="en"><a name="method-gtkcombobox--set-row-span-column"></a><h3>gtk.ComboBox.set_row_span_column</h3><table border="0" bgcolor="#E0E0E0" width="100%"><tr><td><pre class="programlisting"><code class="methodsynopsis">    def <span class="methodname">set_row_span_column</span>(<span class="methodparam"><span class="parameter"><b class="parameter"><tt>row_span</tt></b></span></span>)</code></pre></td></tr></table><table border="0" width="100%" bgcolor="#FFECCE"><col align="left" valign="top" width="0*"><tbody><tr><td><span class="term"><b class="parameter"><tt>row_span</tt></b>:</span></td><td>A column in the model passed during construction.</td></tr></tbody></table><div class="note" style="margin-left: 0.5in; margin-right: 0.5in;"><h3 class="title">Note</h3><p>This method is available in PyGTK 2.4 and above.</p></div><p>The <tt class="methodname">set_row_span_column</tt>() method sets
the "row-span-column" property to the value specified by
<i class="parameter"><tt>row_span</tt></i>. The "row-span-column" property indicates
the column in the associated <a href="class-gtktreemodel.html" title="gtk.TreeModel"><tt class="classname">gtk.TreeModel</tt></a> row
that contains an integer that indicates how many rows the item should
span.</p></div><div class="refsect2" lang="en"><a name="method-gtkcombobox--get-column-span-column"></a><h3>gtk.ComboBox.get_column_span_column</h3><table border="0" bgcolor="#E0E0E0" width="100%"><tr><td><pre class="programlisting"><code class="methodsynopsis">    def <span class="methodname">get_column_span_column</span>(<span class="methodparam"></span>)</code></pre></td></tr></table><table border="0" width="100%" bgcolor="#FFECCE"><col align="left" valign="top" width="0*"><tbody><tr><td><span class="term"><span class="emphasis"><em>Returns</em></span>:</span></td><td>The column span column.</td></tr></tbody></table><div class="note" style="margin-left: 0.5in; margin-right: 0.5in;"><h3 class="title">Note</h3><p>This method is available in PyGTK 2.6 and above.</p></div><p>The <tt class="methodname">get_column_span_column</tt>() method
returns the value of the "column-span-column" property. The
"column-span-column" property indicates the column in the associated <a href="class-gtktreemodel.html" title="gtk.TreeModel"><tt class="classname">gtk.TreeModel</tt></a> row
that contains an integer that indicates how many columns the item should
span.</p></div><div class="refsect2" lang="en"><a name="method-gtkcombobox--set-column-span-column"></a><h3>gtk.ComboBox.set_column_span_column</h3><table border="0" bgcolor="#E0E0E0" width="100%"><tr><td><pre class="programlisting"><code class="methodsynopsis">    def <span class="methodname">set_column_span_column</span>(<span class="methodparam"><span class="parameter"><b class="parameter"><tt>column_span</tt></b></span></span>)</code></pre></td></tr></table><table border="0" width="100%" bgcolor="#FFECCE"><col align="left" valign="top" width="0*"><tbody><tr><td><span class="term"><b class="parameter"><tt>column_span</tt></b>:</span></td><td>A column in the model passed during construction.</td></tr></tbody></table><div class="note" style="margin-left: 0.5in; margin-right: 0.5in;"><h3 class="title">Note</h3><p>This method is available in PyGTK 2.4 and above.</p></div><p>The <tt class="methodname">set_column_span_column</tt>() method
sets the "column-span-column" property to the value specified by
<i class="parameter"><tt>column_span</tt></i>. The "column-span-column" property
indicates the column in the associated <a href="class-gtktreemodel.html" title="gtk.TreeModel"><tt class="classname">gtk.TreeModel</tt></a> row
that contains an integer that indicates how many columns the item should
span.</p></div><div class="refsect2" lang="en"><a name="method-gtkcombobox--get-active"></a><h3>gtk.ComboBox.get_active</h3><table border="0" bgcolor="#E0E0E0" width="100%"><tr><td><pre class="programlisting"><code class="methodsynopsis">    def <span class="methodname">get_active</span>(<span class="methodparam"></span>)</code></pre></td></tr></table><table border="0" width="100%" bgcolor="#FFECCE"><col align="left" valign="top" width="0*"><tbody><tr><td><span class="term"><span class="emphasis"><em>Returns</em></span>:</span></td><td>An integer which is the model index of the
	  currently active item, or -1 if there's no active
	  item.</td></tr></tbody></table><div class="note" style="margin-left: 0.5in; margin-right: 0.5in;"><h3 class="title">Note</h3><p>This method is available in PyGTK 2.4 and above.</p></div><p>The <tt class="methodname">get_active</tt>() method returns the
value of the "active" property which is the index in the model of the
currently active item, or -1 if there's no active item.</p></div><div class="refsect2" lang="en"><a name="method-gtkcombobox--set-active"></a><h3>gtk.ComboBox.set_active</h3><table border="0" bgcolor="#E0E0E0" width="100%"><tr><td><pre class="programlisting"><code class="methodsynopsis">    def <span class="methodname">set_active</span>(<span class="methodparam"><span class="parameter"><b class="parameter"><tt>index</tt></b></span></span>)</code></pre></td></tr></table><table border="0" width="100%" bgcolor="#FFECCE"><col align="left" valign="top" width="0*"><tbody><tr><td><span class="term"><b class="parameter"><tt>index</tt></b>:</span></td><td>An index in the model passed during
	  construction, or -1 to have no active item.</td></tr></tbody></table><div class="note" style="margin-left: 0.5in; margin-right: 0.5in;"><h3 class="title">Note</h3><p>This method is available in PyGTK 2.4 and above.</p></div><p>The <tt class="methodname">set_active</tt>() method sets the active
item of the combo_box to the item with the model index specified by
<i class="parameter"><tt>index</tt></i>. If <i class="parameter"><tt>index</tt></i> is -1 the
combo box will have no active item. The "active" property is also set to the
value of <i class="parameter"><tt>index</tt></i>.</p></div><div class="refsect2" lang="en"><a name="method-gtkcombobox--get-active-iter"></a><h3>gtk.ComboBox.get_active_iter</h3><table border="0" bgcolor="#E0E0E0" width="100%"><tr><td><pre class="programlisting"><code class="methodsynopsis">    def <span class="methodname">get_active_iter</span>(<span class="methodparam"></span>)</code></pre></td></tr></table><table border="0" width="100%" bgcolor="#FFECCE"><col align="left" valign="top" width="0*"><tbody><tr><td><span class="term"><span class="emphasis"><em>Returns</em></span>:</span></td><td>A <a href="class-gtktreeiter.html" title="gtk.TreeIter"><tt class="classname">gtk.TreeIter</tt></a>
	  that points at the active item or <tt class="literal">None</tt> if there
	  is no active item.</td></tr></tbody></table><div class="note" style="margin-left: 0.5in; margin-right: 0.5in;"><h3 class="title">Note</h3><p>This method is available in PyGTK 2.4 and above.</p></div><p>The <tt class="methodname">get_active_iter</tt>() method returns a
      <a href="class-gtktreeiter.html" title="gtk.TreeIter"><tt class="classname">gtk.TreeIter</tt></a>
      that points to the current active item or <tt class="literal">None</tt> if
      there is no active item.</p></div><div class="refsect2" lang="en"><a name="method-gtkcombobox--set-active-iter"></a><h3>gtk.ComboBox.set_active_iter</h3><table border="0" bgcolor="#E0E0E0" width="100%"><tr><td><pre class="programlisting"><code class="methodsynopsis">    def <span class="methodname">set_active_iter</span>(<span class="methodparam"><span class="parameter"><b class="parameter"><tt>iter</tt></b></span></span>)</code></pre></td></tr></table><table border="0" width="100%" bgcolor="#FFECCE"><col align="left" valign="top" width="0*"><tbody><tr><td><span class="term"><b class="parameter"><tt>iter</tt></b>:</span></td><td>A valid <a href="class-gtktreeiter.html" title="gtk.TreeIter"><tt class="classname">gtk.TreeIter</tt></a>
	  pointing at an item in the associated <a href="class-gtktreemodel.html" title="gtk.TreeModel"><tt class="classname">gtk.TreeModel</tt></a>.</td></tr></tbody></table><div class="note" style="margin-left: 0.5in; margin-right: 0.5in;"><h3 class="title">Note</h3><p>This method is available in PyGTK 2.4 and above.</p></div><p>The <tt class="methodname">set_active_iter</tt>() method sets the
current active item to be the one referenced by <i class="parameter"><tt>iter</tt></i>
in the associated <a href="class-gtktreemodel.html" title="gtk.TreeModel"><tt class="classname">gtk.TreeModel</tt></a>.
<i class="parameter"><tt>iter</tt></i> must correspond to a path of depth one. The
"active" property is also set by this method.</p></div><div class="refsect2" lang="en"><a name="method-gtkcombobox--set-model"></a><h3>gtk.ComboBox.set_model</h3><table border="0" bgcolor="#E0E0E0" width="100%"><tr><td><pre class="programlisting"><code class="methodsynopsis">    def <span class="methodname">set_model</span>(<span class="methodparam"><span class="parameter"><b class="parameter"><tt>model</tt></b></span><span class="initializer">=None</span></span>)</code></pre></td></tr></table><table border="0" width="100%" bgcolor="#FFECCE"><col align="left" valign="top" width="0*"><tbody><tr><td><span class="term"><b class="parameter"><tt>model</tt></b>:</span></td><td>A <a href="class-gtktreemodel.html" title="gtk.TreeModel"><tt class="classname">gtk.TreeModel</tt></a>.</td></tr></tbody></table><div class="note" style="margin-left: 0.5in; margin-right: 0.5in;"><h3 class="title">Note</h3><p>This method is available in PyGTK 2.4 and above.</p></div><p>The <tt class="methodname">set_model</tt>() method sets the model
used by the combo box to the value specified by
<i class="parameter"><tt>model</tt></i>. The "model" property will also be set to the
value of <i class="parameter"><tt>model</tt></i>. A previously set model will be
unset. If <i class="parameter"><tt>model</tt></i> is <tt class="literal">None</tt> or not
specified, the old model will be unset.</p><div class="note" style="margin-left: 0.5in; margin-right: 0.5in;"><h3 class="title">Note</h3><p>In PyGTK 2.4.0 the model could not be <tt class="literal">None</tt>
and did not default to <tt class="literal">None</tt>.</p></div></div><div class="refsect2" lang="en"><a name="method-gtkcombobox--get-model"></a><h3>gtk.ComboBox.get_model</h3><table border="0" bgcolor="#E0E0E0" width="100%"><tr><td><pre class="programlisting"><code class="methodsynopsis">    def <span class="methodname">get_model</span>(<span class="methodparam"></span>)</code></pre></td></tr></table><table border="0" width="100%" bgcolor="#FFECCE"><col align="left" valign="top" width="0*"><tbody><tr><td><span class="term"><span class="emphasis"><em>Returns</em></span>:</span></td><td>A <a href="class-gtktreemodel.html" title="gtk.TreeModel"><tt class="classname">gtk.TreeModel</tt></a>
	  or <tt class="literal">None</tt>.</td></tr></tbody></table><div class="note" style="margin-left: 0.5in; margin-right: 0.5in;"><h3 class="title">Note</h3><p>This method is available in PyGTK 2.4 and above.</p></div><p>The <tt class="methodname">get_model</tt>() method returns the
value of the "model" property which contains the <a href="class-gtktreemodel.html" title="gtk.TreeModel"><tt class="classname">gtk.TreeModel</tt></a>
that is acting as data source for the combo_box or <tt class="literal">None</tt>
if no <a href="class-gtktreemodel.html" title="gtk.TreeModel"><tt class="classname">gtk.TreeModel</tt></a> is
associated with the combo box.</p></div><div class="refsect2" lang="en"><a name="method-gtkcombobox--append-text"></a><h3>gtk.ComboBox.append_text</h3><table border="0" bgcolor="#E0E0E0" width="100%"><tr><td><pre class="programlisting"><code class="methodsynopsis">    def <span class="methodname">append_text</span>(<span class="methodparam"><span class="parameter"><b class="parameter"><tt>text</tt></b></span></span>)</code></pre></td></tr></table><table border="0" width="100%" bgcolor="#FFECCE"><col align="left" valign="top" width="0*"><tbody><tr><td><span class="term"><b class="parameter"><tt>text</tt></b>:</span></td><td>A string.</td></tr></tbody></table><div class="note" style="margin-left: 0.5in; margin-right: 0.5in;"><h3 class="title">Note</h3><p>This method is available in PyGTK 2.4 and above.</p></div><p>The <tt class="methodname">append_text</tt>() method appends the
string specified by <i class="parameter"><tt>text</tt></i> to the list of strings
stored in the combo box <a href="class-gtkliststore.html" title="gtk.ListStore"><tt class="classname">gtk.ListStore</tt></a>. Note
that you can only use this method with combo boxes constructed with the
<a href="class-gtkcombobox.html#function-gtk--combo-box-new-text" title="gtk.combo_box_new_text"><tt class="function">gtk.combo_box_new_text</tt>()</a>
function.</p></div><div class="refsect2" lang="en"><a name="method-gtkcombobox--insert-text"></a><h3>gtk.ComboBox.insert_text</h3><table border="0" bgcolor="#E0E0E0" width="100%"><tr><td><pre class="programlisting"><code class="methodsynopsis">    def <span class="methodname">insert_text</span>(<span class="methodparam"><span class="parameter"><b class="parameter"><tt>position</tt></b></span></span>, <span class="methodparam"><span class="parameter"><b class="parameter"><tt>text</tt></b></span></span>)</code></pre></td></tr></table><table border="0" width="100%" bgcolor="#FFECCE"><col align="left" valign="top" width="0*"><tbody><tr><td><span class="term"><b class="parameter"><tt>position</tt></b>:</span></td><td>A model index where the
	  <i class="parameter"><tt>text</tt></i> should be
	  inserted.</td></tr><tr><td><span class="term"><b class="parameter"><tt>text</tt></b>:</span></td><td>A string.</td></tr></tbody></table><div class="note" style="margin-left: 0.5in; margin-right: 0.5in;"><h3 class="title">Note</h3><p>This method is available in PyGTK 2.4 and above.</p></div><p>The <tt class="methodname">insert_text</tt>() method inserts the
string specified by <i class="parameter"><tt>text</tt></i> in the combo box <a href="class-gtkliststore.html" title="gtk.ListStore"><tt class="classname">gtk.ListStore</tt></a> at
the index specified by <i class="parameter"><tt>position</tt></i>. Note that you can
only use this method with combo boxes constructed with the <a href="class-gtkcombobox.html#function-gtk--combo-box-new-text" title="gtk.combo_box_new_text"><tt class="function">gtk.combo_box_new_text</tt>()</a>
function.</p></div><div class="refsect2" lang="en"><a name="method-gtkcombobox--prepend-text"></a><h3>gtk.ComboBox.prepend_text</h3><table border="0" bgcolor="#E0E0E0" width="100%"><tr><td><pre class="programlisting"><code class="methodsynopsis">    def <span class="methodname">prepend_text</span>(<span class="methodparam"><span class="parameter"><b class="parameter"><tt>text</tt></b></span></span>)</code></pre></td></tr></table><table border="0" width="100%" bgcolor="#FFECCE"><col align="left" valign="top" width="0*"><tbody><tr><td><span class="term"><b class="parameter"><tt>text</tt></b>:</span></td><td>A string.</td></tr></tbody></table><div class="note" style="margin-left: 0.5in; margin-right: 0.5in;"><h3 class="title">Note</h3><p>This method is available in PyGTK 2.4 and above.</p></div><p>The <tt class="methodname">prepend_text</tt>() method prepends the
string specified by <i class="parameter"><tt>text</tt></i> to the list of strings
stored in the <a href="class-gtkliststore.html" title="gtk.ListStore"><tt class="classname">gtk.ListStore</tt></a>
associated with the combo_box. Note that you can only use this method with
combo boxes constructed with the <a href="class-gtkcombobox.html#function-gtk--combo-box-new-text" title="gtk.combo_box_new_text"><tt class="function">gtk.combo_box_new_text</tt>()</a>
function.</p></div><div class="refsect2" lang="en"><a name="method-gtkcombobox--remove-text"></a><h3>gtk.ComboBox.remove_text</h3><table border="0" bgcolor="#E0E0E0" width="100%"><tr><td><pre class="programlisting"><code class="methodsynopsis">    def <span class="methodname">remove_text</span>(<span class="methodparam"><span class="parameter"><b class="parameter"><tt>position</tt></b></span></span>)</code></pre></td></tr></table><table border="0" width="100%" bgcolor="#FFECCE"><col align="left" valign="top" width="0*"><tbody><tr><td><span class="term"><b class="parameter"><tt>position</tt></b>:</span></td><td>Index of the item to remove.</td></tr></tbody></table><div class="note" style="margin-left: 0.5in; margin-right: 0.5in;"><h3 class="title">Note</h3><p>This method is available in PyGTK 2.4 and above.</p></div><p>The <tt class="methodname">remove_text</tt>() method removes the
string at the index specified by <i class="parameter"><tt>position</tt></i> in the
associated <a href="class-gtkliststore.html" title="gtk.ListStore"><tt class="classname">gtk.ListStore</tt></a>. Note
that you can only use this function with combo boxes constructed with the
<a href="class-gtkcombobox.html#function-gtk--combo-box-new-text" title="gtk.combo_box_new_text"><tt class="function">gtk.combo_box_new_text</tt>()</a>
function.</p></div><div class="refsect2" lang="en"><a name="method-gtkcombobox--get-active-text"></a><h3>gtk.ComboBox.get_active_text</h3><table border="0" bgcolor="#E0E0E0" width="100%"><tr><td><pre class="programlisting"><code class="methodsynopsis">    def <span class="methodname">get_active_text</span>(<span class="methodparam"></span>)</code></pre></td></tr></table><table border="0" width="100%" bgcolor="#FFECCE"><col align="left" valign="top" width="0*"><tbody><tr><td><span class="term"><span class="emphasis"><em>Returns</em></span>:</span></td><td>The currently active text.</td></tr></tbody></table><div class="note" style="margin-left: 0.5in; margin-right: 0.5in;"><h3 class="title">Note</h3><p>This method is available in PyGTK 2.6 and above.</p></div><p>The <tt class="methodname">get_active_text</tt>() method returns
the currently active string or <tt class="literal">None</tt> if no entry is
selected. Note that you can only use this function with combo boxes
constructed with the <a href="class-gtkcombobox.html#function-gtk--combo-box-new-text" title="gtk.combo_box_new_text"><tt class="function">gtk.combo_box_new_text</tt>()</a>
function.</p></div><div class="refsect2" lang="en"><a name="method-gtkcombobox--popup"></a><h3>gtk.ComboBox.popup</h3><table border="0" bgcolor="#E0E0E0" width="100%"><tr><td><pre class="programlisting"><code class="methodsynopsis">    def <span class="methodname">popup</span>(<span class="methodparam"></span>)</code></pre></td></tr></table><div class="note" style="margin-left: 0.5in; margin-right: 0.5in;"><h3 class="title">Note</h3><p>This method is available in PyGTK 2.4 and above.</p></div><p>The <tt class="methodname">popup</tt>() method pops up the menu or
      dropdown list of the combo box. This method is mostly intended for use
      by accessibility technologies; applications should have little use for
      it.</p></div><div class="refsect2" lang="en"><a name="method-gtkcombobox--popdown"></a><h3>gtk.ComboBox.popdown</h3><table border="0" bgcolor="#E0E0E0" width="100%"><tr><td><pre class="programlisting"><code class="methodsynopsis">    def <span class="methodname">popdown</span>(<span class="methodparam"></span>)</code></pre></td></tr></table><div class="note" style="margin-left: 0.5in; margin-right: 0.5in;"><h3 class="title">Note</h3><p>This method is available in PyGTK 2.4 and above.</p></div><p>The <tt class="methodname">popdown</tt>() method hides the menu or
dropdown list of the combo box. This method is mostly intended for use by
accessibility technologies; applications should have little use for
it.</p></div><div class="refsect2" lang="en"><a name="method-gtkcombobox--get-popup-accessible"></a><h3>gtk.ComboBox.get_popup_accessible</h3><table border="0" bgcolor="#E0E0E0" width="100%"><tr><td><pre class="programlisting"><code class="methodsynopsis">    def <span class="methodname">get_popup_accessible</span>(<span class="methodparam"></span>)</code></pre></td></tr></table><table border="0" width="100%" bgcolor="#FFECCE"><col align="left" valign="top" width="0*"><tbody><tr><td><span class="term"><span class="emphasis"><em>Returns</em></span>:</span></td><td>the accessible object corresponding to the
popup.</td></tr></tbody></table><div class="note" style="margin-left: 0.5in; margin-right: 0.5in;"><h3 class="title">Note</h3><p>This method is available in PyGTK 2.6 and above.</p></div><p>The <tt class="methodname">get_popup_accessible</tt>() method gets
the accessible object corresponding to the popup. This method is mostly
intended for use by accessibility technologies; applications should have
little use for it.</p></div><div class="refsect2" lang="en"><a name="method-gtkcombobox--set-row-separator-func"></a><h3>gtk.ComboBox.set_row_separator_func</h3><table border="0" bgcolor="#E0E0E0" width="100%"><tr><td><pre class="programlisting"><code class="methodsynopsis">    def <span class="methodname">set_row_separator_func</span>(<span class="methodparam"><span class="parameter"><b class="parameter"><tt>func</tt></b></span><span class="initializer">=None</span></span>, <span class="methodparam"><span class="parameter"><b class="parameter"><tt>data</tt></b></span><span class="initializer">=None</span></span>)</code></pre></td></tr></table><table border="0" width="100%" bgcolor="#FFECCE"><col align="left" valign="top" width="0*"><tbody><tr><td><span class="term"><b class="parameter"><tt>func</tt></b>:</span></td><td>a function or
<tt class="literal">None</tt></td></tr><tr><td><span class="term"><b class="parameter"><tt>data</tt></b>:</span></td><td>user data to pass to
<i class="parameter"><tt>func</tt></i></td></tr></tbody></table><div class="note" style="margin-left: 0.5in; margin-right: 0.5in;"><h3 class="title">Note</h3><p>This method is available in PyGTK 2.6 and above.</p></div><p>The <tt class="methodname">set_row_separator_func</tt>() method
sets the row separator function to <i class="parameter"><tt>func</tt></i>, which is
used to determine if a row should be drawn as a separator. If func is
<tt class="literal">None</tt>, no separators are drawn. This is the default
value.</p><p>The signature of <i class="parameter"><tt>func</tt></i> is:</p><table border="0" bgcolor="#E0E0E0" width="100%"><tr><td><pre class="programlisting">
  def func(model, iter, user_data):
</pre></td></tr></table><p>where <i class="parameter"><tt>model</tt></i> is the <a href="class-gtktreemodel.html" title="gtk.TreeModel"><tt class="classname">gtk.TreeModel</tt></a>
used by the combo box, <i class="parameter"><tt>iter</tt></i> is a <a href="class-gtktreeiter.html" title="gtk.TreeIter"><tt class="classname">gtk.TreeIter</tt></a>
pointing at a row in <i class="parameter"><tt>model</tt></i> and
<i class="parameter"><tt>user_data</tt></i> is
<i class="parameter"><tt>data</tt></i>. <i class="parameter"><tt>func</tt></i> returns
<tt class="literal">TRUE</tt> if the row is a separator. A common way to implement
<i class="parameter"><tt>func</tt></i> is to have a boolean column in
<i class="parameter"><tt>model</tt></i>, that indicates if the row is a
separator.</p></div><div class="refsect2" lang="en"><a name="method-gtkcombobox--get-add-tearoffs"></a><h3>gtk.ComboBox.get_add_tearoffs</h3><table border="0" bgcolor="#E0E0E0" width="100%"><tr><td><pre class="programlisting"><code class="methodsynopsis">    def <span class="methodname">get_add_tearoffs</span>(<span class="methodparam"></span>)</code></pre></td></tr></table><table border="0" width="100%" bgcolor="#FFECCE"><col align="left" valign="top" width="0*"><tbody><tr><td><span class="term"><span class="emphasis"><em>Returns</em></span>:</span></td><td><tt class="literal">TRUE</tt> if menus should have a
tearoff menuitem.</td></tr></tbody></table><div class="note" style="margin-left: 0.5in; margin-right: 0.5in;"><h3 class="title">Note</h3><p>This method is available in PyGTK 2.6 and above.</p></div><p>The <tt class="methodname">get_add_tearoffs</tt>() method returns the
value of the "add-tearoffs" property.</p></div><div class="refsect2" lang="en"><a name="method-gtkcombobox--set-add-tearoffs"></a><h3>gtk.ComboBox.set_add_tearoffs</h3><table border="0" bgcolor="#E0E0E0" width="100%"><tr><td><pre class="programlisting"><code class="methodsynopsis">    def <span class="methodname">set_add_tearoffs</span>(<span class="methodparam"><span class="parameter"><b class="parameter"><tt>add_tearoffs</tt></b></span></span>)</code></pre></td></tr></table><table border="0" width="100%" bgcolor="#FFECCE"><col align="left" valign="top" width="0*"><tbody><tr><td><span class="term"><b class="parameter"><tt>add_tearoffs</tt></b>:</span></td><td>if <tt class="literal">TRUE</tt> add tearoff menu items</td></tr></tbody></table><div class="note" style="margin-left: 0.5in; margin-right: 0.5in;"><h3 class="title">Note</h3><p>This method is available in PyGTK 2.6 and above.</p></div><p>The <tt class="methodname">set_add_tearoffs</tt>() method sets the
"add-tearoffs" property to the value of
<i class="parameter"><tt>add_tearoffs</tt></i>. If <i class="parameter"><tt>add_tearoffs</tt></i>
is <tt class="literal">TRUE</tt>, the popup menu should have a tearoff menu
item.</p></div><div class="refsect2" lang="en"><a name="method-gtkcombobox--get-focus-on-click"></a><h3>gtk.ComboBox.get_focus_on_click</h3><table border="0" bgcolor="#E0E0E0" width="100%"><tr><td><pre class="programlisting"><code class="methodsynopsis">    def <span class="methodname">get_focus_on_click</span>(<span class="methodparam"></span>)</code></pre></td></tr></table><table border="0" width="100%" bgcolor="#FFECCE"><col align="left" valign="top" width="0*"><tbody><tr><td><span class="term"><span class="emphasis"><em>Returns</em></span>:</span></td><td><tt class="literal">TRUE</tt> if the combo box grabs
focus when it is clicked with the mouse.</td></tr></tbody></table><div class="note" style="margin-left: 0.5in; margin-right: 0.5in;"><h3 class="title">Note</h3><p>This method is available in PyGTK 2.6 and above.</p></div><p>The <tt class="methodname">get_focus_on_click</tt>() method returns
the value of the "focus-on-click" property.</p></div><div class="refsect2" lang="en"><a name="method-gtkcombobox--set-focus-on-click"></a><h3>gtk.ComboBox.set_focus_on_click</h3><table border="0" bgcolor="#E0E0E0" width="100%"><tr><td><pre class="programlisting"><code class="methodsynopsis">    def <span class="methodname">set_focus_on_click</span>(<span class="methodparam"><span class="parameter"><b class="parameter"><tt>focus_on_click</tt></b></span></span>)</code></pre></td></tr></table><table border="0" width="100%" bgcolor="#FFECCE"><col align="left" valign="top" width="0*"><tbody><tr><td><span class="term"><b class="parameter"><tt>focus_on_click</tt></b>:</span></td><td>if <tt class="literal">TRUE</tt> the combo box grabs
focus when clicked with the mouse.</td></tr></tbody></table><div class="note" style="margin-left: 0.5in; margin-right: 0.5in;"><h3 class="title">Note</h3><p>This method is available in PyGTK 2.6 and above.</p></div><p>The <tt class="methodname">set_focus_on_click</tt>() method sets the
value of the "focus-on-click" property to the value of
<i class="parameter"><tt>focus_on_click</tt></i>. If
<i class="parameter"><tt>focus_on_click</tt></i> is <tt class="literal">TRUE</tt> the combo
box grabs focus when clicked with the mouse.</p></div></div><div class="refsect1" lang="en"><a name="id3394673"></a><h2>Functions</h2><div class="refsect2" lang="en"><a name="function-gtk--combo-box-new-text"></a><h3>gtk.combo_box_new_text</h3><table border="0" bgcolor="#E0E0E0" width="100%"><tr><td><pre class="programlisting"><code class="methodsynopsis">    def <span class="methodname">gtk.combo_box_new_text</span>(<span class="methodparam"></span>)</code></pre></td></tr></table><table border="0" width="100%" bgcolor="#FFECCE"><col align="left" valign="top" width="0*"><tbody><tr><td><span class="term"><span class="emphasis"><em>Returns</em></span>:</span></td><td>A new <a href="class-gtkcombobox.html" title="gtk.ComboBox"><tt class="classname">gtk.ComboBox</tt></a>
	  for text items.</td></tr></tbody></table><div class="note" style="margin-left: 0.5in; margin-right: 0.5in;"><h3 class="title">Note</h3><p>This function is available in PyGTK 2.4 and above.</p></div><p>The <tt class="function">gtk.combo_box_new_text</tt>() function is a
convenience function that constructs a new text combo box, which is a <a href="class-gtkcombobox.html" title="gtk.ComboBox"><tt class="classname">gtk.ComboBox</tt></a> just
displaying strings. If you use this function to create a text combo box, you
should only manipulate its data source with the following convenience
methods: <a href="class-gtkcombobox.html#method-gtkcombobox--append-text" title="gtk.ComboBox.append_text"><tt class="methodname">append_text</tt>()</a>,
<a href="class-gtkcombobox.html#method-gtkcombobox--insert-text" title="gtk.ComboBox.insert_text"><tt class="methodname">insert_text</tt>()</a>,
<a href="class-gtkcombobox.html#method-gtkcombobox--prepend-text" title="gtk.ComboBox.prepend_text"><tt class="methodname">prepend_text</tt>()</a>
and <a href="class-gtkcombobox.html#method-gtkcombobox--remove-text" title="gtk.ComboBox.remove_text"><tt class="methodname">remove_text</tt>()</a>.</p></div></div><div class="refsect1" lang="en"><a name="id3394775"></a><h2>Signals</h2><div class="refsect2" lang="en"><a name="signal-gtkcombobox--changed"></a><h3>The "changed" gtk.ComboBox Signal</h3><table border="0" bgcolor="#E0E0E0" width="100%"><tr><td><pre class="programlisting"><code class="methodsynopsis">    def <span class="methodname">callback</span>(<span class="methodparam"><span class="parameter"><i class="parameter"><tt>combobox</tt></i></span></span>, <span class="methodparam"><span class="parameter"><i class="parameter"><tt>user_param1</tt></i></span></span>, <span class="methodparam"><span class="parameter"><i class="parameter"><tt>...</tt></i></span></span>)</code></pre></td></tr></table><table border="0" width="100%" bgcolor="#FFECCE"><col align="left" valign="top" width="0*"><tbody><tr><td><span class="term"><i class="parameter"><tt>combobox</tt></i>:</span></td><td>the combo box that received the
signal</td></tr><tr><td><span class="term"><i class="parameter"><tt>user_param1</tt></i>:</span></td><td>the first user parameter (if any) specified
with the <a href="class-gobject.html#method-gobject--connect" title="gobject.GObject.connect"><tt class="methodname">connect</tt>()</a>
method</td></tr><tr><td><span class="term"><i class="parameter"><tt>...</tt></i>:</span></td><td>additional user parameters (if
any)</td></tr></tbody></table><div class="note" style="margin-left: 0.5in; margin-right: 0.5in;"><h3 class="title">Note</h3><p>This signal is available in PyGTK 2.4 and above.</p></div><p>The "changed" signal is emitted when a new item in the combo box
is selected.</p></div></div></div><div class="navfooter"><hr><table width="100%" summary="Navigation footer"><tr><td width="40%" align="left"><a accesskey="p" href="class-gtkcombo.html">Prev</a></td><td width="20%" align="center"><a accesskey="u" href="gtk-class-reference.html">Up</a></td><td width="40%" align="right"><a accesskey="n" href="class-gtkcomboboxentry.html">Next</a></td></tr><tr><td width="40%" align="left" valign="top">gtk.Combo</td><td width="20%" align="center"><a accesskey="h" href="index.html">Home</a></td><td width="40%" align="right" valign="top">gtk.ComboBoxEntry</td></tr></table></div></body></html>