parameters: (self,  txt, slot, isCheckable=False, \
                             ttip=None, iconpath=None, shortcut=None)
return_statement: return theAction
docstring: Modeled from the "Rapid GUI Programming with Python and Qt" book, page 174
docstring_summary: Modeled from the "Rapid GUI Programming with Python and Qt" book, page 174
docstring_tokens: Modeled from the Rapid GUI Programming with Python and Qt book page 174
function: def createAction(self,  txt, slot, isCheckable=False, \
                             ttip=None, iconpath=None, shortcut=None):
        """
        Modeled from the "Rapid GUI Programming with Python and Qt" book, page 174
        """
        icon = QIcon()
        if iconpath:
           icon = QIcon(iconpath)
  
        theAction = QAction(icon, txt, self)
  
        if isCheckable:
           theAction.setCheckable(True)
           self.connect(theAction, SIGNAL('toggled(bool)'), slot)
        else:
           self.connect(theAction, SIGNAL('triggered()'), slot)
  
        if ttip:
           theAction.setToolTip(ttip)
           theAction.setStatusTip(ttip)
  
        if shortcut:
           theAction.setShortcut(shortcut)
  
        return theAction
function_tokens: def createAction ( self , txt , slot , isCheckable = False , ttip = None , iconpath = None , shortcut = None ) : icon = QIcon ( ) if iconpath : icon = QIcon ( iconpath ) theAction = QAction ( icon , txt , self ) if isCheckable : theAction . setCheckable ( True ) self . connect ( theAction , SIGNAL ( 'toggled(bool)' ) , slot ) else : self . connect ( theAction , SIGNAL ( 'triggered()' ) , slot ) if ttip : theAction . setToolTip ( ttip ) theAction . setStatusTip ( ttip ) if shortcut : theAction . setShortcut ( shortcut ) return theAction