def _selectObject(self, pobj): obj = pobj.get() self._selected = obj self._infoText.setReadOnly(False) self._infoText.setText('*Label:* ' + getObjectLabel(pobj, self.project.mapper)) self._infoText.addText('*Info:* ' + str(obj)) self._infoText.addText('*Created by:*') self._infoText.addText( ' - ' + pobj.getObjValue().getObjectTag(pobj.getObjValue()) + ' (' + obj.getObjCreation() + ')') # Get the consumers (this will get the data!!) derivedData = self.project.getSourceChilds(pobj.getObjValue()) if derivedData is not None and len(derivedData) > 0: self._infoText.addText('*Consumed by:*') for data in derivedData: # Get the protocol protocol = self.project.getObject(data.getObjParentId()) self._infoText.addText(' - ' + protocol.getObjectTag(protocol)) if obj.getObjComment(): self._infoText.addText('*Comments:* ' + obj.getObjComment()) self._infoText.setReadOnly(True)
def _selectObject(self, pobj): obj = pobj.get() self._selected = obj self._infoText.setReadOnly(False) self._infoText.setText('*Label:* ' + getObjectLabel(pobj, self.project.mapper)) self._infoText.addText('*Info:* ' + str(obj)) self._infoText.addText('*Created by:*') self._infoText.addText(' - ' + pobj.getObjValue().getObjectTag(pobj.getObjValue()) + ' (' + obj.getObjCreation() + ')') # Get the consumers (this will get the data!!) derivedData = self.project.getSourceChilds(pobj.getObjValue()) if derivedData is not None and len(derivedData) > 0: self._infoText.addText('*Consumed by:*') for data in derivedData: # Get the protocol protocol = self.project.getObject(data.getObjParentId()) self._infoText.addText(' - ' + protocol.getObjectTag(protocol)) if obj.getObjComment(): self._infoText.addText('*Comments:* ' + obj.getObjComment()) self._infoText.setReadOnly(True)
def _selectObject(self, obj): self._selected = obj self._infoText.setReadOnly(False) self._infoText.setText('*Label:* ' + getObjectLabel(obj, self.project.mapper)) self._infoText.addText('*Info:* ' + str(obj)) self._infoText.addText('*Created:* ' + '2014-11-22') if obj.getObjComment(): self._infoText.addText('*Comments:* ' + obj.getObjComment()) self._infoText.setReadOnly(True)
def _selectObject(self, pobj): obj = pobj.get() self._selected = obj self._infoText.setReadOnly(False) self._infoText.setText('*Label:* ' + getObjectLabel(pobj, self.project.mapper)) self._infoText.addText('*Info:* ' + str(obj)) self._infoText.addText('*Created:* ' + '2014-11-22') if obj.getObjComment(): self._infoText.addText('*Comments:* ' + obj.getObjComment()) self._infoText.setReadOnly(True)
def _createDataItem(self, canvas, node, y): if node.object is None: nodeText = "Project" else: label = getObjectLabel(node.object, self.project.mapper) nodeText = (label[:25]+'...') if len(label) > 25 else label textColor = 'black' color = '#ADD8E6' #Lightblue item = self._dataCanvas.createTextbox(nodeText, 100, y, bgColor=color, textColor=textColor) return item
def _createDataItem(self, canvas, node, y): if node.pointer is None: nodeText = "Project" else: label = getObjectLabel(node.pointer, self.project.mapper) nodeText = (label[:25] + '...') if len(label) > 25 else label textColor = 'black' color = '#ADD8E6' #Lightblue item = self._dataCanvas.createTextbox(nodeText, 100, y, bgColor=color, textColor=textColor) return item
def _createDataItem(self, canvas, node, y): if node.pointer is None: nodeText = "Project" else: label = getObjectLabel(node.pointer, self.project.mapper) nodeText = (label[:25]+'...') if len(label) > 25 else label textColor = 'black' color = '#ADD8E6' #Lightblue item = self._dataCanvas.createTextbox(nodeText, 100, y, bgColor=color, textColor=textColor) # Get the dataId if not node.isRoot(): dataId = node.pointer.get().getObjId() if dataId in self.settings.dataSelection: item.setSelected(True) return item
def _createDataItem(self, canvas, node, y): if node.pointer is None: nodeText = "Project" else: label = getObjectLabel(node.pointer, self.project.mapper) nodeText = (label[:25] + '...') if len(label) > 25 else label textColor = 'black' color = '#ADD8E6' #Lightblue item = self._dataCanvas.createTextbox(nodeText, 100, y, bgColor=color, textColor=textColor) # Get the dataId if not node.isRoot(): dataId = node.pointer.get().getObjId() if dataId in self.settings.dataSelection: item.setSelected(True) return item