def _do_connection(self, wgt, sig, func):
        """
        Make a connection between a GUI widget and a callable.

        wgt and sig are strings with widget and signal name
        func is a callable for that signal
        """
        #new style  (we use this)
        #self.btn_name.clicked.connect(self.on_btn_name_clicked)
        #old style
        #self.connect(self.btn_name, SIGNAL('clicked()'), self.on_btn_name_clicked)

        if hasattr(self, wgt):
            wgtobj = getattr(self, wgt)
            if hasattr(wgtobj, sig):
                sigobj = getattr(wgtobj, sig)
                if isinstance(sigobj, Signal):
                    sigobj.connect(func)
                    return 0
        return 1
Make a connection between a GUI widget and a callable.

        wgt and sig are strings with widget and signal name
        func is a callable for that signal