def connect_action(action, fn):
 action.triggered[bool].connect((lambda x: fn()))

def connect_action ( action , fn ) : action . triggered [ bool ] . connect ( ( lambda x : fn ( ) ) )
connect an action to a function .