Scott Frankel wrote:
Hi,
Does a QMainWindow, or an app based on, one contain a list of default
action names?
I'm trying to add an action called "Settings" to my app. The
addAction() method silently fails unless I rename or misspell the
action, like "Foo" or "Setttings."
Actions named "Settings", "Preferences", "Configuration" all silently fail.
Trying to find what names may already be claimed, my invocations of the
actions() method always return an empty list.
Thanks
Scott
self.settingsEditAct = QtGui.QAction(self.tr("Foo..."), self)
self.settingsEditAct.setStatusTip(self.tr("Settings Form..."))
self.connect(self.settingsEditAct, QtCore.SIGNAL("triggered()"),
self.settingsEdit)
print "actions: ", self.actions()
it would help if you posted a complete example that demonstrates the
problem. the above code snippet doesn't show the action being added to
anything. are you trying add actions to a menu in the menubar, or are
you trying to create a context menu?
_______________________________________________
PyQt mailing list [email protected]
http://www.riverbankcomputing.com/mailman/listinfo/pyqt