Package schrodinger :: Package application :: Package matsci :: Module mswidgets :: Class MultiStageArea
[hide private]
[frames] | no frames]

Class MultiStageArea

       object --+                            
                |                            
sip.simplewrapper --+                        
                    |                        
          sip.wrapper --+                    
                        |                    
     PyQt4.QtCore.QObject --+                
                            |                
           object --+       |                
                    |       |                
    sip.simplewrapper --+   |                
                        |   |                
 PyQt4.QtGui.QPaintDevice --+                
                            |                
          PyQt4.QtGui.QWidget --+            
                                |            
               PyQt4.QtGui.QFrame --+        
                                    |        
      PyQt4.QtGui.QAbstractScrollArea --+    
                                        |    
                  PyQt4.QtGui.QScrollArea --+
                                            |
                                           MultiStageArea

A scrollable frame meant to hold multiple stages. See the MatSci Desmond Multistage Simulation Workflow as one example.

Nested Classes [hide private]

Inherited from PyQt4.QtGui.QFrame: Shadow, Shape, StyleMask

Inherited from PyQt4.QtGui.QWidget: RenderFlag, RenderFlags

Inherited from PyQt4.QtGui.QPaintDevice: PaintDeviceMetric

Instance Methods [hide private]
 
__init__(self, layout=None, append_button=True, append_stretch=True, stage_class=<class 'schrodinger.application.matsci.mswidgets.StageFrame'>)
Create a MultiStageArea instance
StageFrame
addStage(self, copy_stage=None, stage_type=None, **kwargs)
Add a new stage
int
getStageIndex(self, stage)
Return which stage number this is
 
moveStageUp(self, stage)
Shift the given stage up one stage
 
moveStageDown(self, stage)
Shift the given stage down one stage
 
moveStage(self, current, new)
Move the a stage
 
copyStage(self, stage)
Create a copy of stage and add it directly below stage
 
deleteStage(self, stage, update=True)
Delete a stage
 
updateStageLabels(self, start_at=0)
Update stage labels - usually due to a change in stage numbering
 
reset(self)
Reset the stage area
 
expandAll(self)
Expand all stages
 
collapseAll(self)
Collapse all stages

Inherited from PyQt4.QtGui.QScrollArea: alignment, ensureVisible, ensureWidgetVisible, event, eventFilter, focusNextPrevChild, resizeEvent, scrollContentsBy, setAlignment, setWidget, setWidgetResizable, sizeHint, takeWidget, widget, widgetResizable

Inherited from PyQt4.QtGui.QAbstractScrollArea: addScrollBarWidget, contextMenuEvent, cornerWidget, dragEnterEvent, dragLeaveEvent, dragMoveEvent, dropEvent, horizontalScrollBar, horizontalScrollBarPolicy, keyPressEvent, maximumViewportSize, minimumSizeHint, mouseDoubleClickEvent, mouseMoveEvent, mousePressEvent, mouseReleaseEvent, paintEvent, scrollBarWidgets, setCornerWidget, setHorizontalScrollBar, setHorizontalScrollBarPolicy, setVerticalScrollBar, setVerticalScrollBarPolicy, setViewport, setViewportMargins, setupViewport, verticalScrollBar, verticalScrollBarPolicy, viewport, viewportEvent, wheelEvent

Inherited from PyQt4.QtGui.QFrame: changeEvent, drawFrame, frameRect, frameShadow, frameShape, frameStyle, frameWidth, lineWidth, midLineWidth, setFrameRect, setFrameShadow, setFrameShape, setFrameStyle, setLineWidth, setMidLineWidth

Inherited from PyQt4.QtGui.QWidget: acceptDrops, accessibleDescription, accessibleName, actionEvent, actions, activateWindow, addAction, addActions, adjustSize, autoFillBackground, backgroundRole, baseSize, childAt, childrenRect, childrenRegion, clearFocus, clearMask, close, closeEvent, contentsMargins, contentsRect, contextMenuPolicy, create, cursor, customContextMenuRequested, destroy, devType, effectiveWinId, enabledChange, ensurePolished, enterEvent, find, focusInEvent, focusNextChild, focusOutEvent, focusPolicy, focusPreviousChild, focusProxy, focusWidget, font, fontChange, fontInfo, fontMetrics, foregroundRole, frameGeometry, frameSize, geometry, getContentsMargins, grabGesture, grabKeyboard, grabMouse, grabShortcut, graphicsEffect, graphicsProxyWidget, handle, hasFocus, hasMouseTracking, height, heightForWidth, hide, hideEvent, inputContext, inputMethodEvent, inputMethodHints, inputMethodQuery, insertAction, insertActions, isActiveWindow, isAncestorOf, isEnabled, isEnabledTo, isEnabledToTLW, isFullScreen, isHidden, isLeftToRight, isMaximized, isMinimized, isModal, isRightToLeft, isTopLevel, isVisible, isVisibleTo, isWindow, isWindowModified, keyReleaseEvent, keyboardGrabber, languageChange, layout, layoutDirection, leaveEvent, locale, lower, mapFrom, mapFromGlobal, mapFromParent, mapTo, mapToGlobal, mapToParent, mask, maximumHeight, maximumSize, maximumWidth, metric, minimumHeight, minimumSize, minimumWidth, mouseGrabber, move, moveEvent, nativeParentWidget, nextInFocusChain, normalGeometry, overrideWindowFlags, overrideWindowState, paintEngine, palette, paletteChange, parentWidget, pos, previousInFocusChain, raise_, rect, releaseKeyboard, releaseMouse, releaseShortcut, removeAction, render, repaint, resetInputContext, resize, restoreGeometry, saveGeometry, scroll, setAcceptDrops, setAccessibleDescription, setAccessibleName, setAttribute, setAutoFillBackground, setBackgroundRole, setBaseSize, setContentsMargins, setContextMenuPolicy, setCursor, setDisabled, setEnabled, setFixedHeight, setFixedSize, setFixedWidth, setFocus, setFocusPolicy, setFocusProxy, setFont, setForegroundRole, setGeometry, setGraphicsEffect, setHidden, setInputContext, setInputMethodHints, setLayout, setLayoutDirection, setLocale, setMask, setMaximumHeight, setMaximumSize, setMaximumWidth, setMinimumHeight, setMinimumSize, setMinimumWidth, setMouseTracking, setPalette, setParent, setShortcutAutoRepeat, setShortcutEnabled, setShown, setSizeIncrement, setSizePolicy, setStatusTip, setStyle, setStyleSheet, setTabOrder, setToolTip, setUpdatesEnabled, setVisible, setWhatsThis, setWindowFilePath, setWindowFlags, setWindowIcon, setWindowIconText, setWindowModality, setWindowModified, setWindowOpacity, setWindowRole, setWindowState, setWindowTitle, show, showEvent, showFullScreen, showMaximized, showMinimized, showNormal, size, sizeIncrement, sizePolicy, stackUnder, statusTip, style, styleSheet, tabletEvent, testAttribute, toolTip, topLevelWidget, underMouse, ungrabGesture, unsetCursor, unsetLayoutDirection, unsetLocale, update, updateGeometry, updateMicroFocus, updatesEnabled, visibleRegion, whatsThis, width, winId, window, windowActivationChange, windowFilePath, windowFlags, windowIcon, windowIconText, windowModality, windowOpacity, windowRole, windowState, windowTitle, windowType, x, x11Info, x11PictureHandle, y

Inherited from PyQt4.QtCore.QObject: __getattr__, blockSignals, childEvent, children, connect, connectNotify, customEvent, deleteLater, destroyed, disconnect, disconnectNotify, dumpObjectInfo, dumpObjectTree, dynamicPropertyNames, emit, findChild, findChildren, inherits, installEventFilter, isWidgetType, killTimer, metaObject, moveToThread, objectName, parent, property, pyqtConfigure, receivers, removeEventFilter, sender, senderSignalIndex, setObjectName, setProperty, signalsBlocked, startTimer, thread, timerEvent, tr, trUtf8

Inherited from PyQt4.QtGui.QPaintDevice: colorCount, depth, heightMM, logicalDpiX, logicalDpiY, numColors, paintingActive, physicalDpiX, physicalDpiY, widthMM

Inherited from sip.simplewrapper: __new__

Inherited from object: __delattr__, __format__, __getattribute__, __hash__, __reduce__, __reduce_ex__, __repr__, __setattr__, __sizeof__, __str__, __subclasshook__

Class Variables [hide private]

Inherited from PyQt4.QtGui.QFrame: Box, HLine, NoFrame, Panel, Plain, Raised, Shadow_Mask, Shape_Mask, StyledPanel, Sunken, VLine, WinPanel

Inherited from PyQt4.QtGui.QWidget: DrawChildren, DrawWindowBackground, IgnoreMask

Inherited from PyQt4.QtCore.QObject: staticMetaObject

Inherited from PyQt4.QtGui.QPaintDevice: PdmDepth, PdmDpiX, PdmDpiY, PdmHeight, PdmHeightMM, PdmNumColors, PdmPhysicalDpiX, PdmPhysicalDpiY, PdmWidth, PdmWidthMM

Properties [hide private]

Inherited from object: __class__

Method Details [hide private]

__init__(self, layout=None, append_button=True, append_stretch=True, stage_class=<class 'schrodinger.application.matsci.mswidgets.StageFrame'>)
(Constructor)

 

Create a MultiStageArea instance

Parameters:
  • layout (QBoxLayout) - The layout to place this Area into
  • append_button (bool) - Whether to add an "Append Stage" button to a Horizontal layout below the scrolling area
  • append_button (bool) - Whether to add a QSpacer to the layout containing the append button. Use False if additional widgets will be added after creating the area.
  • stage_class (StageFrame) - The class used to create new stages
  • append_stretch (bool)
Overrides: object.__init__

addStage(self, copy_stage=None, stage_type=None, **kwargs)

 

Add a new stage

Parameters:
  • copy_stage (StageFrame) - The stage to copy. The default is None, which will create a new default stage.
  • stage_type - What type of stage to add. Must be dealt with in the StageFrame subclass
Returns: StageFrame
The newly created stage

Note: All other keyword arguments are passed to the stage class

getStageIndex(self, stage)

 

Return which stage number this is

Parameters:
  • stage (StageFrame) - Returns the index for this stage in the stage list
Returns: int
The stage number (starting at 0)

moveStageUp(self, stage)

 

Shift the given stage up one stage

Parameters:
  • stage (StageFrame) - The stage to move up

moveStageDown(self, stage)

 

Shift the given stage down one stage

Parameters:
  • stage (StageFrame) - The stage to move down

moveStage(self, current, new)

 

Move the a stage

Parameters:
  • current (int) - The current position of the stage
  • new (int) - The desired new position of the stage

copyStage(self, stage)

 

Create a copy of stage and add it directly below stage

Parameters:
  • stage (StageFrame) - The stage to copy

deleteStage(self, stage, update=True)

 

Delete a stage

Parameters:
  • stage (StageFrame) - The stage to be deleted
  • update (bool) - True if stage labels should be updated, False if not (use False if all stages are being deleted)

updateStageLabels(self, start_at=0)

 

Update stage labels - usually due to a change in stage numbering

Parameters:
  • start_at (int) - All stages from this stage to the end of the stage list will be updated