File: qaction.html

package info (click to toggle)
python-qt4 4.0.1-5
  • links: PTS
  • area: main
  • in suites: etch, etch-m68k
  • size: 18,632 kB
  • ctags: 2,639
  • sloc: python: 29,409; sh: 5,646; cpp: 3,168; xml: 149; makefile: 109
file content (89 lines) | stat: -rw-r--r-- 22,875 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
<?xml version="1.0" encoding="iso-8859-1"?>
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "DTD/xhtml1-strict.dtd">
<html><head><title>QAction Class Reference</title><style>h3.fn,span.fn { margin-left: 1cm; text-indent: -1cm }
a:link { color: #004faf; text-decoration: none }
a:visited { color: #672967; text-decoration: none }
td.postheader { font-family: sans-serif }
tr.address { font-family: sans-serif }
body { background: #ffffff; color: black; }
</style></head><body><table border="0" cellpadding="0" cellspacing="0" width="100%"><tr /><td align="left" valign="top" width="32"><img align="left" border="0" height="32" src="images/rb-logo.png" width="32" /></td><td width="1">&#160;&#160;</td><td class="postheader" valign="center"><a href="../pyqt4ref.html"><font color="#004faf">Home</font></a>&#160;&#183; <a href="classes.html"><font color="#004faf">All Classes</font></a>&#160;&#183; <a href="modules.html"><font color="#004faf">Modules</font></a></td></table><h1 align="center">QAction Class Reference<br /><sup><sup>[<a href="qtgui.html">QtGui</a> module]</sup></sup></h1><p>The QAction class provides an abstract user interface action that can be inserted into widgets. <a href="#details">More...</a></p>
<p>Inherits <a href="qobject.html">QObject</a>.</p><h3>Types</h3><ul><li><div class="fn" />enum <b><a href="qaction.html#ActionEvent-enum">ActionEvent</a></b> { Trigger, Hover }</li></ul><h3>Methods</h3><ul><li><div class="fn" /><b><a href="qaction.html#QAction">__init__</a></b> (<i>self</i>, QObject&#160;<i>parent</i>)</li><li><div class="fn" /><b><a href="qaction.html#QAction-2">__init__</a></b> (<i>self</i>, QString&#160;<i>text</i>, QObject&#160;<i>parent</i>)</li><li><div class="fn" /><b><a href="qaction.html#QAction-3">__init__</a></b> (<i>self</i>, QIcon&#160;<i>icon</i>, QString&#160;<i>text</i>, QObject&#160;<i>parent</i>)</li><li><div class="fn" />QActionGroup <b><a href="qaction.html#actionGroup">actionGroup</a></b> (<i>self</i>)</li><li><div class="fn" /><b><a href="qaction.html#activate">activate</a></b> (<i>self</i>, ActionEvent&#160;<i>event</i>)</li><li><div class="fn" />QVariant <b><a href="qaction.html#data">data</a></b> (<i>self</i>)</li><li><div class="fn" />bool <b><a href="qaction.html#event">event</a></b> (<i>self</i>, QEvent)</li><li><div class="fn" />QFont <b><a href="qaction.html#font">font</a></b> (<i>self</i>)</li><li><div class="fn" /><b><a href="qaction.html#hover">hover</a></b> (<i>self</i>)</li><li><div class="fn" />QIcon <b><a href="qaction.html#icon">icon</a></b> (<i>self</i>)</li><li><div class="fn" />QString <b><a href="qaction.html#iconText">iconText</a></b> (<i>self</i>)</li><li><div class="fn" />bool <b><a href="qaction.html#isCheckable">isCheckable</a></b> (<i>self</i>)</li><li><div class="fn" />bool <b><a href="qaction.html#isChecked">isChecked</a></b> (<i>self</i>)</li><li><div class="fn" />bool <b><a href="qaction.html#isEnabled">isEnabled</a></b> (<i>self</i>)</li><li><div class="fn" />bool <b><a href="qaction.html#isSeparator">isSeparator</a></b> (<i>self</i>)</li><li><div class="fn" />bool <b><a href="qaction.html#isVisible">isVisible</a></b> (<i>self</i>)</li><li><div class="fn" />QMenu <b><a href="qaction.html#menu">menu</a></b> (<i>self</i>)</li><li><div class="fn" />QWidget <b><a href="qaction.html#parentWidget">parentWidget</a></b> (<i>self</i>)</li><li><div class="fn" /><b><a href="qaction.html#setActionGroup">setActionGroup</a></b> (<i>self</i>, QActionGroup&#160;<i>group</i>)</li><li><div class="fn" /><b><a href="qaction.html#setCheckable">setCheckable</a></b> (<i>self</i>, bool)</li><li><div class="fn" /><b><a href="qaction.html#setChecked">setChecked</a></b> (<i>self</i>, bool)</li><li><div class="fn" /><b><a href="qaction.html#setData">setData</a></b> (<i>self</i>, QVariant&#160;<i>var</i>)</li><li><div class="fn" /><b><a href="qaction.html#setDisabled">setDisabled</a></b> (<i>self</i>, bool&#160;<i>b</i>)</li><li><div class="fn" /><b><a href="qaction.html#setEnabled">setEnabled</a></b> (<i>self</i>, bool)</li><li><div class="fn" /><b><a href="qaction.html#setFont">setFont</a></b> (<i>self</i>, QFont&#160;<i>font</i>)</li><li><div class="fn" /><b><a href="qaction.html#setIcon">setIcon</a></b> (<i>self</i>, QIcon&#160;<i>icon</i>)</li><li><div class="fn" /><b><a href="qaction.html#setIconText">setIconText</a></b> (<i>self</i>, QString&#160;<i>text</i>)</li><li><div class="fn" /><b><a href="qaction.html#setMenu">setMenu</a></b> (<i>self</i>, QMenu&#160;<i>menu</i>)</li><li><div class="fn" /><b><a href="qaction.html#setSeparator">setSeparator</a></b> (<i>self</i>, bool&#160;<i>b</i>)</li><li><div class="fn" /><b><a href="qaction.html#setShortcut">setShortcut</a></b> (<i>self</i>, QKeySequence&#160;<i>shortcut</i>)</li><li><div class="fn" /><b><a href="qaction.html#setShortcutContext">setShortcutContext</a></b> (<i>self</i>, Qt.ShortcutContext&#160;<i>context</i>)</li><li><div class="fn" /><b><a href="qaction.html#setStatusTip">setStatusTip</a></b> (<i>self</i>, QString&#160;<i>statusTip</i>)</li><li><div class="fn" /><b><a href="qaction.html#setText">setText</a></b> (<i>self</i>, QString&#160;<i>text</i>)</li><li><div class="fn" /><b><a href="qaction.html#setToolTip">setToolTip</a></b> (<i>self</i>, QString&#160;<i>tip</i>)</li><li><div class="fn" /><b><a href="qaction.html#setVisible">setVisible</a></b> (<i>self</i>, bool)</li><li><div class="fn" /><b><a href="qaction.html#setWhatsThis">setWhatsThis</a></b> (<i>self</i>, QString&#160;<i>what</i>)</li><li><div class="fn" />QKeySequence <b><a href="qaction.html#shortcut">shortcut</a></b> (<i>self</i>)</li><li><div class="fn" />Qt.ShortcutContext <b><a href="qaction.html#shortcutContext">shortcutContext</a></b> (<i>self</i>)</li><li><div class="fn" />bool <b><a href="qaction.html#showStatusText">showStatusText</a></b> (<i>self</i>, QWidget&#160;<i>widget</i>&#160;=&#160;None)</li><li><div class="fn" />QString <b><a href="qaction.html#statusTip">statusTip</a></b> (<i>self</i>)</li><li><div class="fn" />QString <b><a href="qaction.html#text">text</a></b> (<i>self</i>)</li><li><div class="fn" /><b><a href="qaction.html#toggle">toggle</a></b> (<i>self</i>)</li><li><div class="fn" />QString <b><a href="qaction.html#toolTip">toolTip</a></b> (<i>self</i>)</li><li><div class="fn" /><b><a href="qaction.html#trigger">trigger</a></b> (<i>self</i>)</li><li><div class="fn" />QString <b><a href="qaction.html#whatsThis">whatsThis</a></b> (<i>self</i>)</li></ul><h3>Qt Signals</h3><ul><li><div class="fn" />void <b><a href="qaction.html#changed">changed</a></b> ()</li><li><div class="fn" />void <b><a href="qaction.html#hovered">hovered</a></b> ()</li><li><div class="fn" />void <b><a href="qaction.html#toggled">toggled</a></b> (bool)</li><li><div class="fn" />void <b><a href="qaction.html#triggered">triggered</a></b> (bool = 0)</li></ul><a name="details" /><hr /><h2>Detailed Description</h2><p>The QAction class provides an abstract user interface action that can be inserted into widgets.</p>
<p>In applications many common commands can be invoked via menus, toolbar buttons, and keyboard shortcuts. Since the user expects each command to be performed in the same way, regardless of the user interface used, it is useful to represent each command as an <i>action</i>.</p>
<p>Actions can be added to menus and toolbars, and will automatically keep them in sync. For example, in a word processor, if the user presses a Bold toolbar button, the Bold menu item will automatically be checked.</p>
<p>Actions can be created as independent objects, but they may also be created during the construction of menus; the <a href="qmenu.html">QMenu</a> class contains convenience functions for creating actions suitable for use as menu items.</p>
<p>A QAction may contain an icon, menu text, a shortcut, status text, "What's This?" text, and a tooltip. Most of these can be set in the constructor. They can also be set independently with <a href="qaction.html#icon-prop">setIcon</a>(), <a href="qaction.html#text-prop">setText</a>(), <a href="qaction.html#iconText-prop">setIconText</a>(), <a href="qaction.html#shortcut-prop">setShortcut</a>(), <a href="qaction.html#statusTip-prop">setStatusTip</a>(), <a href="qaction.html#whatsThis-prop">setWhatsThis</a>(), and <a href="qaction.html#toolTip-prop">setToolTip</a>(). For menu items, it is possible to set an individual font with <a href="qaction.html#font-prop">setFont</a>().</p>
<p>Actions are added to widgets using <a href="qwidget.html#addAction">QWidget.addAction</a>().</p>
<p>Once a QAction has been created it should be added to the relevant menu and toolbar, then connected to the slot which will perform the action. For example:</p>
<pre>
        openAct = new QAction(QIcon(":/images/open.png"), tr("&amp;Open..."), this);
        openAct-&gt;setShortcut(tr("Ctrl+O"));
        openAct-&gt;setStatusTip(tr("Open an existing file"));
        connect(openAct, SIGNAL(triggered()), this, SLOT(open()));

        fileMenu-&gt;addAction(openAct);
        fileToolBar-&gt;addAction(openAct);
</pre>
<p>We recommend that actions are created as children of the window they are used in. In most cases actions will be children of the application's main window.</p>
<hr /><h2>Type Documentation</h2><h3 class="fn"><a name="ActionEvent-enum" />QAction.ActionEvent</h3><p>This enum type is used when calling <a href="qaction.html#activate">QAction.activate</a>()</p>
<table border="1" cellpadding="2" cellspacing="1" width="100%">
<tr>
<th width="25%">Constant</th>
<th width="15%">Value</th>
<th width="60%">Description</th>
</tr>
<tr>
<td valign="top"><tt>QAction.Trigger</tt></td>
<td align="center" valign="top"><tt>0</tt></td>
<td valign="top">this will cause the <a href="qaction.html#triggered">QAction.triggered</a>() signal to be emitted.</td>
</tr>
<tr>
<td valign="top"><tt>QAction.Hover</tt></td>
<td align="center" valign="top"><tt>1</tt></td>
<td valign="top">this will cause the <a href="qaction.html#hovered">QAction.hovered</a>() signal to be emitted.</td>
</tr>
</table>
<br />
<br />
<hr /><h2>Method Documentation</h2><h3 class="fn"><a name="QAction" />QAction.__init__ (<i>self</i>, <a href="qobject.html">QObject</a>&#160;<i>parent</i>)</h3><p>The <i>parent</i> argument, if not None, causes <i>self</i> to be owned by Qt instead of PyQt.</p><p>Constructs an action with <i>parent</i>. If <i>parent</i> is an action group the action will be automatically inserted into the group.</p>
<h3 class="fn"><a name="QAction-2" />QAction.__init__ (<i>self</i>, <a href="qstring.html">QString</a>&#160;<i>text</i>, <a href="qobject.html">QObject</a>&#160;<i>parent</i>)</h3><p>The <i>parent</i> argument, if not None, causes <i>self</i> to be owned by Qt instead of PyQt.</p><p>Constructs an action with some <i>text</i> and <i>parent</i>. If <i>parent</i> is an action group the action will be automatically inserted into the group.</p>
<p>The action uses a stripped version of <i>text</i> (e.g. "&amp;Menu Option..." becomes "Menu Option") as descriptive text for toolbuttons. You can override this by setting a specific description with <a href="qaction.html#text-prop">setText</a>(). The same text will be used for tooltips unless you specify a different test using <a href="qaction.html#toolTip-prop">setToolTip</a>().</p>
<h3 class="fn"><a name="QAction-3" />QAction.__init__ (<i>self</i>, <a href="qicon.html">QIcon</a>&#160;<i>icon</i>, <a href="qstring.html">QString</a>&#160;<i>text</i>, <a href="qobject.html">QObject</a>&#160;<i>parent</i>)</h3><p>The <i>parent</i> argument, if not None, causes <i>self</i> to be owned by Qt instead of PyQt.</p><p>Constructs an action with an <i>icon</i> and some <i>text</i> and <i>parent</i>. If <i>parent</i> is an action group the action will be automatically inserted into the group.</p>
<p>The action uses a stripped version of <i>text</i> (e.g. "&amp;Menu Option..." becomes "Menu Option") as descriptive text for toolbuttons. You can override this by setting a specific description with <a href="qaction.html#text-prop">setText</a>(). The same text will be used for tooltips unless you specify a different test using <a href="qaction.html#toolTip-prop">setToolTip</a>().</p>
<h3 class="fn"><a name="actionGroup" /><a href="qactiongroup.html">QActionGroup</a> QAction.actionGroup (<i>self</i>)</h3><p>Returns the action group for this action. If no action group manages this action then 0 will be returned.</p>
<p>See also <a href="qactiongroup.html">QActionGroup</a> and <a href="qaction.html#setActionGroup">QAction.setActionGroup</a>().</p>
<h3 class="fn"><a name="activate" />QAction.activate (<i>self</i>, <a href="qaction.html#ActionEvent-enum">ActionEvent</a>&#160;<i>event</i>)</h3><p>Sends the relevant signals for <a href="qaction.html#ActionEvent-enum">ActionEvent</a> <i>event</i>.</p>
<p>Action based widgets use this API to cause the <a href="qaction.html">QAction</a> to emit signals as well as emitting their own.</p>
<h3 class="fn"><a name="data" /><a href="qvariant.html">QVariant</a> QAction.data (<i>self</i>)</h3><p>Returns the user data as set in QAction.setData.</p>
<p>See also <a href="qaction.html#setData">setData</a>().</p>
<h3 class="fn"><a name="event" />bool QAction.event (<i>self</i>, <a href="qevent.html">QEvent</a>)</h3><h3 class="fn"><a name="font" /><a href="qfont.html">QFont</a> QAction.font (<i>self</i>)</h3><h3 class="fn"><a name="hover" />QAction.hover (<i>self</i>)</h3><p>This method is also a Qt slot with the C++ signature <tt>void hover()</tt>.</p><p>This is a convenience slot that calls activate(Hover).</p>
<h3 class="fn"><a name="icon" /><a href="qicon.html">QIcon</a> QAction.icon (<i>self</i>)</h3><h3 class="fn"><a name="iconText" /><a href="qstring.html">QString</a> QAction.iconText (<i>self</i>)</h3><h3 class="fn"><a name="isCheckable" />bool QAction.isCheckable (<i>self</i>)</h3><h3 class="fn"><a name="isChecked" />bool QAction.isChecked (<i>self</i>)</h3><h3 class="fn"><a name="isEnabled" />bool QAction.isEnabled (<i>self</i>)</h3><h3 class="fn"><a name="isSeparator" />bool QAction.isSeparator (<i>self</i>)</h3><p>Returns true if this action is a separator action; otherwise it returns false.</p>
<p>See also <a href="qaction.html#setSeparator">QAction.setSeparator</a>().</p>
<h3 class="fn"><a name="isVisible" />bool QAction.isVisible (<i>self</i>)</h3><h3 class="fn"><a name="menu" /><a href="qmenu.html">QMenu</a> QAction.menu (<i>self</i>)</h3><p>Returns the menu contained by this action. Actions that contain menus can be used to create menu items with submenus, or inserted into toolbars to create buttons with popup menus.</p>
<p>See also <a href="qaction.html#setMenu">setMenu</a>() and <a href="qmenu.html#addAction">QMenu.addAction</a>().</p>
<h3 class="fn"><a name="parentWidget" /><a href="qwidget.html">QWidget</a> QAction.parentWidget (<i>self</i>)</h3><p>Returns the parent widget.</p>
<h3 class="fn"><a name="setActionGroup" />QAction.setActionGroup (<i>self</i>, <a href="qactiongroup.html">QActionGroup</a>&#160;<i>group</i>)</h3><p>Sets this action group to <i>group</i>. The action will be automatically added to the group's list of actions.</p>
<p>Actions within the group will be mutually exclusive.</p>
<p>See also <a href="qactiongroup.html">QActionGroup</a> and <a href="qaction.html#actionGroup">QAction.actionGroup</a>().</p>
<h3 class="fn"><a name="setCheckable" />QAction.setCheckable (<i>self</i>, bool)</h3><h3 class="fn"><a name="setChecked" />QAction.setChecked (<i>self</i>, bool)</h3><p>This method is also a Qt slot with the C++ signature <tt>void setChecked(bool)</tt>.</p><h3 class="fn"><a name="setData" />QAction.setData (<i>self</i>, <a href="qvariant.html">QVariant</a>&#160;<i>var</i>)</h3><p>Sets internal data to <i>data</i>. This can be used for user data to store anything that a <a href="qvariant.html">QVariant</a> can store. The ownership of anything the the user data will remain with the variant and thus be referenced counted as appropriate.</p>
<p>See also <a href="qaction.html#data">data</a>().</p>
<h3 class="fn"><a name="setDisabled" />QAction.setDisabled (<i>self</i>, bool&#160;<i>b</i>)</h3><p>This method is also a Qt slot with the C++ signature <tt>void setDisabled(bool)</tt>.</p><p>This is a convenience function for the <a href="qaction.html#enabled-prop">enabled</a> property, that is useful for signals--slots connections. If <i>b</i> is true the action is disabled; otherwise it is enabled.</p>
<h3 class="fn"><a name="setEnabled" />QAction.setEnabled (<i>self</i>, bool)</h3><p>This method is also a Qt slot with the C++ signature <tt>void setEnabled(bool)</tt>.</p><h3 class="fn"><a name="setFont" />QAction.setFont (<i>self</i>, <a href="qfont.html">QFont</a>&#160;<i>font</i>)</h3><h3 class="fn"><a name="setIcon" />QAction.setIcon (<i>self</i>, <a href="qicon.html">QIcon</a>&#160;<i>icon</i>)</h3><h3 class="fn"><a name="setIconText" />QAction.setIconText (<i>self</i>, <a href="qstring.html">QString</a>&#160;<i>text</i>)</h3><h3 class="fn"><a name="setMenu" />QAction.setMenu (<i>self</i>, <a href="qmenu.html">QMenu</a>&#160;<i>menu</i>)</h3><p>Sets the menu contained by this action to the specified <i>menu</i>.</p>
<p>See also <a href="qaction.html#menu">menu</a>().</p>
<h3 class="fn"><a name="setSeparator" />QAction.setSeparator (<i>self</i>, bool&#160;<i>b</i>)</h3><p>If <i>b</i> is true then this action will be considered a separator.</p>
<p>How a separator is represented depends on the widget it is inserted into. Under most circumstances the text, submenu, and icon will be ignored for separator actions.</p>
<p>See also <a href="qaction.html#isSeparator">QAction.isSeparator</a>().</p>
<h3 class="fn"><a name="setShortcut" />QAction.setShortcut (<i>self</i>, <a href="qkeysequence.html">QKeySequence</a>&#160;<i>shortcut</i>)</h3><h3 class="fn"><a name="setShortcutContext" />QAction.setShortcutContext (<i>self</i>, <a href="qt.html#ShortcutContext-enum">Qt.ShortcutContext</a>&#160;<i>context</i>)</h3><h3 class="fn"><a name="setStatusTip" />QAction.setStatusTip (<i>self</i>, <a href="qstring.html">QString</a>&#160;<i>statusTip</i>)</h3><h3 class="fn"><a name="setText" />QAction.setText (<i>self</i>, <a href="qstring.html">QString</a>&#160;<i>text</i>)</h3><h3 class="fn"><a name="setToolTip" />QAction.setToolTip (<i>self</i>, <a href="qstring.html">QString</a>&#160;<i>tip</i>)</h3><h3 class="fn"><a name="setVisible" />QAction.setVisible (<i>self</i>, bool)</h3><p>This method is also a Qt slot with the C++ signature <tt>void setVisible(bool)</tt>.</p><h3 class="fn"><a name="setWhatsThis" />QAction.setWhatsThis (<i>self</i>, <a href="qstring.html">QString</a>&#160;<i>what</i>)</h3><h3 class="fn"><a name="shortcut" /><a href="qkeysequence.html">QKeySequence</a> QAction.shortcut (<i>self</i>)</h3><h3 class="fn"><a name="shortcutContext" /><a href="qt.html#ShortcutContext-enum">Qt.ShortcutContext</a> QAction.shortcutContext (<i>self</i>)</h3><h3 class="fn"><a name="showStatusText" />bool QAction.showStatusText (<i>self</i>, <a href="qwidget.html">QWidget</a>&#160;<i>widget</i>&#160;=&#160;None)</h3><p>Updates the status bar for <i>widget</i>. If widget is an appropriate <a href="qstatusbar.html">QStatusBar</a> found for for this action based on the parent heirarchy will be used.</p>
<p>See also <a href="qaction.html#statusTip-prop">statusTip</a>.</p>
<h3 class="fn"><a name="statusTip" /><a href="qstring.html">QString</a> QAction.statusTip (<i>self</i>)</h3><h3 class="fn"><a name="text" /><a href="qstring.html">QString</a> QAction.text (<i>self</i>)</h3><h3 class="fn"><a name="toggle" />QAction.toggle (<i>self</i>)</h3><p>This method is also a Qt slot with the C++ signature <tt>void toggle()</tt>.</p><p>This is a convenience function for the <a href="qaction.html#checked-prop">checked</a> property. Connect to it to change the checked state to its opposite state.</p>
<h3 class="fn"><a name="toolTip" /><a href="qstring.html">QString</a> QAction.toolTip (<i>self</i>)</h3><h3 class="fn"><a name="trigger" />QAction.trigger (<i>self</i>)</h3><p>This method is also a Qt slot with the C++ signature <tt>void trigger()</tt>.</p><p>This is a convenience slot that calls activate(Trigger).</p>
<h3 class="fn"><a name="whatsThis" /><a href="qstring.html">QString</a> QAction.whatsThis (<i>self</i>)</h3><hr /><h2>Qt Signal Documentation</h2><h3 class="fn"><a name="changed" />void changed ()</h3><p>This signal is emitted when an action has changed. If you are only interested in actions in a given widget, you can watch for <a href="qwidget.html#actionEvent">QWidget.actionEvent</a>() sent with an <a href="qevent.html#Type-enum">QEvent.ActionChanged</a>.</p>
<p>See also <a href="qwidget.html#actionEvent">QWidget.actionEvent</a>().</p>
<h3 class="fn"><a name="hovered" />void hovered ()</h3><p>This signal is emitted when an action is highlighted by the user; for example, when the user pauses with the cursor over a menu option, toolbar button, or presses an action's shortcut key combination.</p>
<p>See also <a href="qaction.html#activate">QAction.activate</a>().</p>
<h3 class="fn"><a name="toggled" />void toggled (bool)</h3><p>This signal is emitted whenever a checkable action changes its <a href="qaction.html#checked-prop">isChecked</a>() status. This can be the result of a user interaction, or because <a href="qaction.html#checked-prop">setChecked</a>() was called.</p>
<p><i>checked</i> is true if the action is checked, or false if the action is unchecked.</p>
<p>See also <a href="qaction.html#activate">QAction.activate</a>(), <a href="qaction.html#triggered">QAction.triggered</a>(), and <a href="qaction.html#checked-prop">checked</a>.</p>
<h3 class="fn"><a name="triggered" />void triggered (bool = 0)</h3><p>This signal is emitted when an action is activated by the user; for example, when the user clicks a menu option, toolbar button, or presses an action's shortcut key combination, or when <a href="qaction.html#trigger">trigger</a>() was called. Notably, it is <i>not</i> emitted when <a href="qaction.html#checked-prop">setChecked</a>() or <a href="qaction.html#toggle">toggle</a>() is called.</p>
<p>If the action is checkable, <i>checked</i> is true if the action is checked, or false if the action is unchecked.</p>
<p>See also <a href="qaction.html#activate">QAction.activate</a>(), <a href="qaction.html#toggled">QAction.toggled</a>(), and <a href="qaction.html#checked-prop">checked</a>.</p>
<address><hr /><div align="center"><table border="0" cellspacing="0" width="100%"><tr class="address"><td width="25%">PyQt&#160;4.0.1 for X11</td><td align="center" width="50%">Copyright &#169; <a href="http://www.riverbankcomputing.com">Riverbank&#160;Computing&#160;Ltd</a> and <a href="http://www.trolltech.com">Trolltech&#160;AS</a> 2006</td><td align="right" width="25%">Qt&#160;4.1.4</td></tr></table></div></address></body></html>