pyworkflow.gui.project.viewprotocols module

pyworkflow.gui.project.viewprotocols.INIT_REFRESH_SECONDS = 5

View with the protocols inside the main project window.

class pyworkflow.gui.project.viewprotocols.ProtocolsView(parent, windows, **args)[source]

Bases: Frame

What you see when the “Protocols” tab is selected.

In the main project window there are three tabs: “Protocols | Data | Hosts”. This extended tk.Frame is what will appear when Protocols is on.

RUNS_CANVAS_NAME = 'runs_canvas'
cleanInfo()[source]
createActionToolbar()[source]

Prepare the buttons that will be available for protocol actions.

createContent()[source]

Create the Protocols View for the Project. It has two panes:

Left: containing the Protocol classes tree Right: containing the Runs list

createRunItem(canvas, node)[source]
createRunsGraph(parent)[source]
createRunsTree(parent)[source]
drawRunsGraph(reorganize=False)[source]
executeProtocol(prot)[source]

Function to execute a protocol called not directly from the Form “Execute” button.

getCurrentProtocolView()[source]

Select the view that is currently selected. Read from the settings the last selected view and get the information from the self._protocolViews dict.

getProtocolViews()[source]
getSelectedProtocol()[source]
hasParentHidden(node)[source]
info(message)[source]

Return information about the packing options for this widget.

keyPressed(event)[source]
populateTree(tree, treeItems, prefix, obj, subclassedDict, level=0)[source]
refreshDisplayedRuns(e=None, initRefreshCounter=True, checkPids=False)[source]

Refresh the status of displayed runs. Params:

e: Tk event input initRefreshCounter: if True the refresh counter will be set to 3 secs

then only case when False is from _automaticRefreshRuns where the refresh time is doubled each time to avoid refreshing too often.

refreshRuns(e=None, initRefreshCounter=True, checkPids=False)[source]

Refresh the protocol runs workflow. If the variable REFRESH_WITH_THREADS exits, then use a threads to refresh, i.o.c use normal behavior

setVisibleNodes(node, visible=True)[source]
switchRunsView()[source]
toggleDataSelection(prot, append)[source]
updateProtocolsTree(protCfg)[source]
updateRunsGraph(refresh=False, reorganize=False, checkPids=False)[source]
updateRunsTree(refresh=False)[source]
updateRunsTreeSelection()[source]
class pyworkflow.gui.project.viewprotocols.RunBox(nodeInfo, canvas, text, x, y, bgColor, textColor)[source]

Bases: TextBox

Just override TextBox move method to keep track of position changes in the graph.

move(dx, dy)[source]
moveTo(x, y)[source]

Move TextBox to a new position (x,y)

class pyworkflow.gui.project.viewprotocols.ScipionLogWindow(parentWindow, **kwargs)[source]

Bases: Window

Class that create a windows where the system log is display