Beispiel #1
0
    def __init__(self, label="", defaultValue=0, minimum=0, maximum=100):
        self._min = minimum
        self._max = maximum
        ControlBase.__init__(self, label, defaultValue)

        self._label = label
        self._value = defaultValue
Beispiel #2
0
    def __init__(self, label=''):
        ControlBase.__init__(self, label)
        QtGui.QWidget.__init__(self)

        layout = QtGui.QVBoxLayout()
        layout.setMargin(0)
        self.form.setLayout(layout)
Beispiel #3
0
 def init_form(self):
     """
     Load Control and initiate the events
     """
     ControlBase.init_form(self)
     if self._value: QWebView.load(self, QUrl(self._value))
     if self.help: self.form.setToolTip(self.help)
Beispiel #4
0
	def __init__(self, label="", defaultValue="", plusFunction=None,
				 minusFunction=None):
		QWidget.__init__(self)

		self._plusFunction = plusFunction
		self._minusFunction = minusFunction
		ControlBase.__init__(self, label, defaultValue)
Beispiel #5
0
    def __init__(self, label="", defaultValue="", plusFunction=None,
                 minusFunction=None):
        QWidget.__init__(self)

        self._plusFunction = plusFunction
        self._minusFunction = minusFunction
        ControlBase.__init__(self, label, defaultValue)
    def __init__(self, label="", defaultValue=0, min=0, max=100, **kwargs):
        QtGui.QWidget.__init__(self)
        ControlBase.__init__(self, label, defaultValue, **kwargs)
        self._max = 100
        self._graphs_properties_win = None

        # Popup menus that only show when clicking on a TIMELINEDELTA object
        self._deltaLockAction = self.addPopupMenuOption("Lock", self.__lockSelected, key='L')
        self._deltaColorAction = self.addPopupMenuOption("Pick a color", self.__pickColor)
        self._deltaRemoveAction = self.addPopupMenuOption("Remove", self.__removeSelected, key='Delete')
        self._deltaActions = [self._deltaLockAction, self._deltaColorAction, self._deltaRemoveAction]
        for action in self._deltaActions:
            action.setVisible(False)

        self.addPopupMenuOption("-")

        # General righ click popup menus
        self.addPopupMenuOption("Set track properties...", self.__setLinePropertiesEvent)
        self.addPopupMenuOption("Set graphs properties", self.__set_graphs_properties)
        self.addPopupMenuOption("-")
        self.addPopupSubMenuOption("Import/Export", {
            'Export to CSV': self.__export,
            'Import to CSV': self.__import
        })
        self.addPopupMenuOption("-")
        self.addPopupSubMenuOption("Clean", {
            'Current line': self.__cleanLine,
            'Everything': self.__clean,
            'Charts': self.__cleanCharts
        })
Beispiel #7
0
	def __init__(self, label = "", defaultValue = 0, min = 0, max = 100):
		self._min = min
		self._max = max
		ControlBase.__init__(self, label, defaultValue)
		
		
		self._label = label
		self._value = defaultValue
Beispiel #8
0
    def __init__(self, label='', tabbed=False):
        ControlBase.__init__(self, label)
        QtGui.QWidget.__init__(self)

        self.tabbed = tabbed
        layout = QtGui.QVBoxLayout()
        layout.setMargin(0)
        self.form.setLayout(layout)
Beispiel #9
0
    def __init__(self, label="", defaultValue=0, min=0, max=100):
        self._updateSlider = True
        self._min = min
        self._max = max

        ControlBase.__init__(self, label, defaultValue)
        self._form.value.setText(str(defaultValue))
        self._form.horizontalSlider.valueChanged.connect(self.valueChanged)
Beispiel #10
0
    def __init__(self, label=""):
        QMdiArea.__init__(self)
        ControlBase.__init__(self, label)
        self._value = []
        self._showCloseButton = True
        self._openWindows = []

        self.logger = logging.getLogger(__name__)
Beispiel #11
0
	def __init__(self, label = "", defaultValue = 0, min = 0, max = 100):
		self._updateSlider = True
		self._min = min
		self._max = max
		
		ControlBase.__init__(self, label, defaultValue)
		self._form.value.setText( str(defaultValue) )
		self._form.horizontalSlider.valueChanged.connect( self.valueChanged )
Beispiel #12
0
    def __init__(self, *args):
        QFrame.__init__(self)
        ControlBase.__init__(self, *args)

        self._speed = 1
        self.logger = logging.getLogger('pyforms')

        self._updateVideoFrame = True
Beispiel #13
0
	def __init__(self, *args, **kwargs):
		self._updateSlider = True
		self._min = kwargs.get('minimum', 0)
		self._max = kwargs.get('maximum', 100)
		if 'default' not in kwargs: kwargs['default'] = 0
		ControlBase.__init__(self, *args, **kwargs)
		
		self._form.value.setText(str(kwargs['default']))
		self._form.horizontalSlider.valueChanged.connect(self.valueChanged)
Beispiel #14
0
 def __init__(self,
              label="",
              defaultValue=[20, 40],
              min=0,
              max=100,
              horizontal=False,
              **kwargs):
     self._horizontal = horizontal
     ControlBase.__init__(self, label, defaultValue, **kwargs)
    def __init__(self, *args, **kwargs):
        self._horizontal = kwargs.get('horizontal', True)
        self._show_spinboxes = kwargs.get('show_spinboxes', True)
        ControlBase.__init__(self, *args, **kwargs)

        self.min = kwargs.get('min', kwargs.get('minimum', 0))
        self.max = kwargs.get('max', kwargs.get('maximum', 100))
        self.value = kwargs.get('default', [10, 20])
        self.__update()
Beispiel #16
0
    def __init__(self,
                 label="",
                 default="",
                 add_function=None,
                 remove_function=None):
        QWidget.__init__(self)

        self._plusFunction = add_function
        self._minusFunction = remove_function
        ControlBase.__init__(self, label, default)
 def __init__(self,
              label="",
              default=0,
              minimum=0,
              maximum=100,
              decimals=0):
     self._min = minimum
     self._max = maximum
     self._decimals = decimals
     self._updateSpinner = True
     ControlBase.__init__(self, label, default)
    def __init__(self,
                 label="",
                 default="",
                 add_function=None,
                 remove_function=None,
                 auto_resize=True):
        QWidget.__init__(self)

        self._plusFunction = add_function
        self._minusFunction = remove_function
        self._resizeColumns = auto_resize
        ControlBase.__init__(self, label, default)
Beispiel #19
0
	def __init__(self, label="", default=0, min=0, max=100, **kwargs):
		"""
		
		:param label: 
		:param default: 
		:param min: 
		:param max: 
		:param kwargs: 
		"""
		QWidget.__init__(self)
		ControlBase.__init__(self, label, default, **kwargs)
		self.add_popup_menu_option('Export to CSV', self.__export)
    def __init__(self, label='', default=None):
        QWidget.__init__(self)
        layout = QVBoxLayout()

        if conf.PYFORMS_USE_QT5:
            layout.setContentsMargins(0, 0, 0, 0)
        else:
            layout.setMargin(0)

        self.form.setLayout(layout)

        ControlBase.__init__(self, label)
        self.value = default
Beispiel #21
0
    def __init__(self, *args, **kwargs):
        QWidget.__init__(self)
        layout = QVBoxLayout()

        if conf.PYFORMS_USE_QT5:
            layout.setContentsMargins(0, 0, 0, 0)
        else:
            layout.setMargin(0)

        self.form.setLayout(layout)

        ControlBase.__init__(self, *args, **kwargs)
        self.value = kwargs.get('default', None)
Beispiel #22
0
    def __init__(self, *args, **kwargs):
        ControlBase.__init__(self, *args, **kwargs)
        QtGui.QWidget.__init__(self)

        self.setMouseTracking(True)
        self.setMinimumWidth(30)

        self._lower = 0
        self._higher = 100
        self._minVal = 0
        self._maxVal = 75
        self._lastMouseY = None
        self._moving = False
        self._resizingBottom = False
        self._resizingTop = False
Beispiel #23
0
    def __init__(self,
                 label="",
                 defaultValue=0,
                 minimum=0,
                 maximum=100,
                 step=1,
                 decimals=0):
        self._min = minimum
        self._max = maximum
        self._step = step
        self._decimals = decimals
        ControlBase.__init__(self, label, defaultValue)

        self._label = label
        self._value = defaultValue
    def __init__(self,
                 label="",
                 default=[20, 40],
                 min=0,
                 max=100,
                 horizontal=False,
                 helptext=None,
                 show_spinboxes=True):
        self._horizontal = horizontal
        self._show_spinboxes = show_spinboxes
        ControlBase.__init__(self, label, default, helptext=helptext)

        self.min = min
        self.max = max
        self.value = default
        self.__update()
    def __init__(self, label="", defaultValue=0, min=0, max=100, **kwargs):
        QtGui.QWidget.__init__(self)
        ControlBase.__init__(self, label, defaultValue, **kwargs)
        self._max = 100
        self._graphs_prop_win = GraphsProperties(self._time, self)

        # Popup menus that only show when clicking on a TIMELINEDELTA object
        self._deltaLockAction = self.addPopupMenuOption("Lock", self.__lockSelected, key="L")
        self._deltaColorAction = self.addPopupMenuOption("Pick a color", self.__pickColor)
        self._deltaRemoveAction = self.addPopupMenuOption("Remove", self.__removeSelected, key="Delete")
        self._deltaActions = [self._deltaLockAction, self._deltaColorAction, self._deltaRemoveAction]
        for action in self._deltaActions:
            action.setVisible(False)

        self.addPopupMenuOption("-")

        # General righ click popup menus
        self.addPopupMenuOption("Set track properties...", self.__setLinePropertiesEvent)
        self.addPopupMenuOption("Set graphs properties", self.show_graphs_properties)
        self.addPopupMenuOption("-")
        self.addPopupSubMenuOption(
            "Clean", {"Current line": self.__cleanLine, "Everything": self.__clean, "Charts": self.__cleanCharts}
        )
	def __init__(self, label=''):
		ControlBase.__init__(self, label)
		QtGui.QWidget.__init__(self)

		layout = QtGui.QVBoxLayout(); layout.setMargin(0)
		self.form.setLayout( layout )
Beispiel #27
0
    def __init__(self, *args):
        QtGui.QFrame.__init__(self)
        ControlBase.__init__(self, *args)

        self.logger = logging.getLogger('pyforms')
Beispiel #28
0
 def __init__(self, label="", default=0, minimum=0, maximum=100):
     self._min = minimum
     self._max = maximum
     ControlBase.__init__(self, label, default)
Beispiel #29
0
    def __init__(self, label="%p%", defaultValue=0, min=0, max=100):
        self._updateSlider = True
        self._min = min
        self._max = max

        ControlBase.__init__(self, label, defaultValue)
 def __init__(self, label=""):
     QMdiArea.__init__(self)
     ControlBase.__init__(self, label)
     self._value = []
     self._showCloseButton = True
     self._openWindows = []
Beispiel #31
0
	def __init__(self, *args):
		QtGui.QFrame.__init__(self)
		ControlBase.__init__(self, *args)
Beispiel #32
0
 def __init__(self, *args, **kwargs):
     self._min = kwargs.get('minimum', 0)
     self._max = kwargs.get('maximum', 100)
     if 'default' not in kwargs: kwargs['default'] = 0
     ControlBase.__init__(self, *args, **kwargs)
     self.decimals = kwargs.get('decimals', 0)
Beispiel #33
0
 def __init__(self, label='', default=None, helptext=None):
     QWidget.__init__(self)
     ControlBase.__init__(self, label, default, helptext)
Beispiel #34
0
 def __init__(self, label=""):
     QWebView.__init__(self)
     ControlBase.__init__(self, label)
Beispiel #35
0
 def __init__(self, *args, **kwargs):
     QWebView.__init__(self)
     if 'load_finnished_event' in kwargs: 
         self.load_finnished_event=kwargs['load_finnished_event']
     self.loadFinished.connect(self.__load_finnished_evt)
     ControlBase.__init__(self, *args, **kwargs)
Beispiel #36
0
 def __init__(self, label="", defaultValue=0, min=0, max=100, **kwargs):
     QtGui.QWidget.__init__(self)
     ControlBase.__init__(self, label, defaultValue, **kwargs)
     self.addPopupMenuOption('Export to CSV', self.__export)
 def __init__(self, label = "%p%", defaultValue = 0, min = 0, max = 100):
     self._updateSlider = True
     self._min = min
     self._max = max
     
     ControlBase.__init__(self, label, defaultValue)
	def __init__(self, title='untitled'):
		QtGui.QTreeView.__init__(self)
		ControlBase.__init__(self, title)
Beispiel #39
0
 def __init__(self, label = ""):
     QtGui.QWidget.__init__(self)
     ControlBase.__init__(self, label)
Beispiel #40
0
 def __init__(self, label=""):
     QMdiArea.__init__(self)
     ControlBase.__init__(self, label)
     self._value = []
     self._showCloseButton = True
     self._openWindows = []
Beispiel #41
0
 def __init__(self, label='', default=''):
     QTreeWidget.__init__(self)
     ControlBase.__init__(self, label, default)
 def __init__(self, label = "", defaultValue = [20,40], min = 0, max = 100, horizontal=False, **kwargs):
     self._horizontal = horizontal
     ControlBase.__init__(self, label, defaultValue, **kwargs)
	def __init__(self, *args):
		QtGui.QFrame.__init__(self)
		ControlBase.__init__(self, *args)
		
		self.speed = 1
		self.logger = logging.getLogger('pyforms')