pyworkflow.project.config module

class pyworkflow.project.config.Label(labelId=None, name='', color=None)[source]

Bases: pyworkflow.object.Scalar

Store Label information

get()[source]

Get the value, if internal value is None the default argument passed is returned.

getColor()[source]
getId()[source]
getName()[source]
getObjValue()[source]

Return the internal value for storage. This is a good place to do some update of the internal value before been stored

setColor(color)[source]
setName(newName)[source]
class pyworkflow.project.config.LabelsList[source]

Bases: pyworkflow.object.List

Store all labels information

addLabel(label)[source]
clear()[source]

Remove all items from list.

deleteLabel(label)[source]
getLabel(name)[source]
updateDict()[source]
class pyworkflow.project.config.MenuConfig(text=None, value=None, icon=None, tag=None, **kwargs)[source]

Bases: object

Menu configuration in a tree fashion. Each menu can contains submenus. Leaf elements can contain actions

addSubMenu(text, value=None, **args)[source]
isEmpty()[source]
class pyworkflow.project.config.NodeConfig(nodeId=0, x=None, y=None, selected=False, expanded=True, visible=True)[source]

Bases: pyworkflow.object.Scalar

Store Graph node information such as x, y.

get()[source]

Get the value, if internal value is None the default argument passed is returned.

getId()[source]
getLabels()[source]
getObjValue()[source]

Return the internal value for storage. This is a good place to do some update of the internal value before been stored

getPosition()[source]
getX()[source]
getY()[source]
isExpanded()[source]
isSelected()[source]
isVisible()[source]
setExpanded(expanded)[source]
setLabels(labels)[source]
setPosition(x, y)[source]
setSelected(selected)[source]
setVisible(visible)[source]
setX(x)[source]
setY(y)[source]
class pyworkflow.project.config.NodeConfigList[source]

Bases: pyworkflow.object.List

Store all nodes information items and also store a dictionary for quick access to nodes query.

addNode(nodeId, **kwargs)[source]
clear()[source]

Remove all items from list.

getNode(nodeId)[source]
updateDict()[source]
class pyworkflow.project.config.ProjectConfig(**args)[source]

Bases: pyworkflow.object.Object

A simple base class to store ordered parameters

class pyworkflow.project.config.ProjectSettings(confs={}, **kwargs)[source]

Bases: pyworkflow.object.Object

Store settings related to a project.

COLOR_MODES = (0, 1, 2)
COLOR_MODE_AGE = 2
COLOR_MODE_LABELS = 1
COLOR_MODE_STATUS = 0
addNode(nodeId, **kwargs)[source]
ageColorMode()[source]
commit()[source]

Commit changes made.

getColorMode()[source]
getConfig()[source]
getCreationTime()[source]
getLabels()[source]
getLifeTime()[source]
getNodeById(nodeId)[source]
getNodes()[source]
getProtocolView()[source]
getReadOnly()[source]
getRunsView()[source]
labelsColorMode()[source]
classmethod load(dbPath)[source]

Load a ProjectSettings from dbPath.

setColorMode(colorMode)[source]

Set the color mode to use when drawing the graph.

setCreationTime(value)[source]
setLifeTime(value)[source]
setProtocolView(protocolView)[source]

Set the new protocol Menu given its index. The new ProtocolMenu will be returned.

setReadOnly(value)[source]
setRunsView(value)[source]
statusColorMode()[source]
write(dbPath=None)[source]