schrodinger.ui.qt.structure2d module

2D structures drawing

schrodinger.ui.qt.structure2d.get_qpicture_protected(renderer, chmmol, gen_coord=True)

Generate a QPicture for the given molecule. If the picture couldn’t be generated (e.g. the molecule is too large), then a QPicture will contain the failure message text.

Parameters:
  • renderer (Chm2DRenderer intance) – The renderer to use for generating the QPicture
  • chmmol (ChmMol instance.) – Structure to generate the picture for.
  • gen_coord (bool) – if True (default) generate new coordinates; if False, use existing 2D coordinates.
Return type:

QPicture

Returns:

The generated picture.

schrodinger.ui.qt.structure2d.generate_qimage_from_chmmol(chmmol, width, height, renderer=None, bg_color=None, max_scale=None, gen_coord=True)

“Generate a 2D image in QImage format of a ChmMol molecule.”

Parameters:
  • chmmol (ChmMol instance.) – Structure to generate the picture for.
  • width (int) – width in pixels of the generated QImage.
  • height (int) – height in pixels of the generated QImage.
  • renderer (Chm2DRenderer intance or None) – The renderer to use for generating the QImage. If None, a new renderer will be created.
  • bg_color (PyQt5.QtGui.QColor or None) – background color filling the image around the scaled molecule.
  • max_scale (float or None) – maximum scaling of the structure image.
  • gen_coord (bool) – if True (default) generate new coordinates; if False, use existing 2D coordinates.
Return type:

QImage

Returns:

The generated QImage.

schrodinger.ui.qt.structure2d.generate_qimage_from_structure(st, width, height, renderer=None, bg_color=None, max_scale=None, stereo_mode=6, gen_coord=True)

Generate a 2D image in QImage format of a schrodinger.structure.Structure. An intermediate ChmMol will be generated with stereochemstry deduced according to the stereo_mode parameter.

Parameters:
  • st (Structure instance.) – Structure to generate the picture for.
  • width (int) – width in pixels of the generated QImage.
  • height (int) – height in pixels of the generated QImage.
  • renderer (Chm2DRenderer intance or None) – The renderer to use for generating the QImage.
  • bg_color (PyQt5.QtGui.QColor or None) – background color filling the image around the scaled molecule.
  • max_scale (float or None) – maximum scaling of the structure image.
  • stereo_mode (schrodinger.infra._canvas2d.ChmMmctAdaptor.StereoType) – stereo source for internal transformation to ChmMol.
  • gen_coord (bool) – if True generate coordinates for chmmol.
Return type:

QImage

Returns:

The generated QImage.

schrodinger.ui.qt.structure2d.get_qpicture_highlight(renderer, chmmol, atoms, bonds, color, gen_coord=False)

Generate a QPicture for the given molecule and highlight given atoms and bonds. If the picture couldn’t be generated (e.g. the molecule is too large), then a QPicture will contain the failure message text.

Parameters:
  • renderer (Chm2DRenderer intance) – The renderer to use for generating the QPicture
  • chmmol (ChmMol instance.) – Structure to generate the picture for.
  • atoms (list) – list of atoms that should be highlighted
  • bonds (list) – list of bonds that should be highlighted
  • color (QtGui.QColor) – color that is used to highlight atoms and bonds
  • gen_coord (bool) – if True generate coordinates.
Return type:

QPicture

Returns:

The generated picture.

schrodinger.ui.qt.structure2d.get_chmmol_bonds_from_atoms(chmmol, atoms)

This function returns a list of bonds that connect atoms in a given list.

Parameters:
  • chmmol (canvas2d.ChmMol) – molecule structure
  • atoms (list) – list of atom indices
schrodinger.ui.qt.structure2d.get_aligned_pictures(sts, renderer=None, atomTyping=11, core_color=None)

Calculate the maximum common substructure (MCS) between the given ligands, and generate 2D images, aligned by the core. If no MCS was detected, the images will be unaligned.

NOTE: This function becomes exponentioally slow with larger number of structures. Recommened maximum around 30 structures.

Parameters:
  • sts (Iterable of structure.Structure objects) – Structures to average
  • renderer (Chm2DRenderer intance) – The renderer to use for generating the QPicture (optional)
  • atomTyping (int) – Atom typing scheme to use. Default is 11. For list of available schemes, see $SCHRODINGER/utilities/canvasMCS -h
  • highlight_color – Optional Color to highlight the common substructure.
Return type:

List of QPicture objects.

Returns:

QPictures for the aligned 2D images.

schrodinger.ui.qt.structure2d.get_ligand(st)

Return a substructure that can be rendered in a 2D image (the first ligand in st, unless it’s also has too many atoms).

Parameters:st (structure.Structure) – the structure
Returns:the ligand structure or None if the structure has too many atoms
Return type:structure.Structure or None
class schrodinger.ui.qt.structure2d.StructurePicture(parent=None, layout=None, height=200, width=200, background='white', annotators=None)

Bases: PyQt5.QtWidgets.QLabel

This is the label that normally stores the picture of the molecule. It can also store a text message.

We make sure that this stays the same size, no matter what data (if any) is stored in it.

__init__(parent=None, layout=None, height=200, width=200, background='white', annotators=None)
Parameters:
  • parent (QWidget) – the widget that owns this widget
  • layout (QLayout) – The layout that this widget should be placed in
  • height (int) – the height of this label in pixels
  • width (int) – the width of this label in pixels
  • annotators (list) – Each item of the list should be a canvas2d.ChemViewAnnotator object that will be applied to the canvas2d.ChmRender2DModel when generating the image
sizeHint(self) → QSize
drawStructure(structure, StereoType=6, hydrogenTreatment=1, wantProperties=True, wantMMStereoProps=True, readAtomBondProperties=True, allowRadicals=False)

Makes a 2-D rendering of the structure

Parameters:
  • structure (schrodinger.structure.Structure class object) – structure to be drawn on the canvas
  • StereoType (canvas2d.ChmMmctAdaptor.StereoType) – Stereochemistry option to use. Available options: # Does not include stereochemistry info: canvas2d.ChmMmctAdaptor.NoStereo # Ignores mmstereo annotations: canvas2d.ChmMmctAdaptor.StereoFromGeometry # Silently ignores stereo information that Canvas doesn’t agree with: canvas2d.ChmMmctAdaptor.StereoFromGeometry_Safe # Ignores 3d geometry: canvas2d.ChmMmctAdaptor.StereoFromAnnotation # Silently ignores stereo information that Canvas doesn’t agree with: canvas2d.ChmMmctAdaptor.StereoFromAnnotation_Safe # Uses mmstereo annotaions with 3D geometry as a backup: canvas2d.ChmMmctAdaptor.StereoFromAnnotationAndGeometry # Silently ignores stereo information that Canvas doesn’t agree with: canvas2d.ChmMmctAdaptor.StereoFromAnnotationAndGeometry_Safe
  • hydrogenTreatment (canvas2d.ChmAtomOption.H) – Hydrogen treatment method. Available options: canvas2d.ChmAtomOption.H_Never canvas2d.ChmAtomOption.H_ExplicitOnly canvas2d.ChmAtomOption.H_Polar canvas2d.ChmAtomOption.H_ExplicitPolar canvas2d.ChmAtomOption.H_Chiral canvas2d.ChmAtomOption.H_ExplicitChiral canvas2d.ChmAtomOption.H_ExplicitPolarAndChiral canvas2d.ChmAtomOption.H_All
  • wantProperties (bool) – Whether properties should be copied.
  • wantMMStereoProps (bool) – Whether to copy mmstereo properties.
  • readAtomBondProperties (bool) – Whether to copy atom and bond-level properties.
  • allowRadicals (bool) – Whether to assume that valence deficiencies represent unpaired electrons.
drawChmmol(chmmol, atoms=[], bonds=[], color=<PyQt5.QtGui.QColor object>, gen_coord=False)

Makes a 2-D rendering of the chmmol object with optional atoms and bonds highlighting.

Parameters:
  • chmmol (ChmMol instance.) – Structure to generate the picture for.
  • atoms (list) – list of atoms that should be highlighted
  • bonds (list) – list of bonds that should be highlighted
  • color (QtGui.QColor) – color that is used to highlight atoms and bonds
  • gen_coord (bool) – if True generate coordinates.
setAnnotators(annotators)

This function allows to reset annotators between renderning 2-D structures.

Parameters:annotators (list) – Each item of the list should be a canvas2d.ChemViewAnnotator object that will be applied to the canvas2d.ChmRender2DModel when generating the image
Box = 1
DrawChildren = 2
DrawWindowBackground = 1
HLine = 4
IgnoreMask = 4
NoFrame = 0
class PaintDeviceMetric

Bases: int

__init__ = <method-wrapper '__init__' of sip.enumtype object at 0x1e51628>
Panel = 2
PdmDepth = 6
PdmDevicePixelRatio = 11
PdmDevicePixelRatioScaled = 12
PdmDpiX = 7
PdmDpiY = 8
PdmHeight = 2
PdmHeightMM = 4
PdmNumColors = 5
PdmPhysicalDpiX = 9
PdmPhysicalDpiY = 10
PdmWidth = 1
PdmWidthMM = 3
Plain = 16
Raised = 32
class RenderFlag

Bases: int

__init__ = <method-wrapper '__init__' of sip.enumtype object at 0x1e8d8a8>
class RenderFlags

Bases: sip.simplewrapper

QWidget.RenderFlags(Union[QWidget.RenderFlags, QWidget.RenderFlag]) QWidget.RenderFlags(QWidget.RenderFlags)

__init__

Initialize self. See help(type(self)) for accurate signature.

class Shadow

Bases: int

__init__ = <method-wrapper '__init__' of sip.enumtype object at 0x1e08da8>
Shadow_Mask = 240
class Shape

Bases: int

__init__ = <method-wrapper '__init__' of sip.enumtype object at 0x1e09158>
Shape_Mask = 15
class StyleMask

Bases: int

__init__ = <method-wrapper '__init__' of sip.enumtype object at 0x1e09508>
StyledPanel = 6
Sunken = 48
VLine = 5
WinPanel = 3
acceptDrops(self) → bool
accessibleDescription(self) → str
accessibleName(self) → str
actionEvent(self, QActionEvent)
actions(self) → List[QAction]
activateWindow(self)
addAction(self, QAction)
addActions(self, Iterable[QAction])
adjustSize(self)
alignment(self) → Qt.Alignment
autoFillBackground(self) → bool
backgroundRole(self) → QPalette.ColorRole
baseSize(self) → QSize
blockSignals(self, bool) → bool
buddy(self) → QWidget
changeEvent(self, QEvent)
childAt(self, QPoint) → QWidget

childAt(self, int, int) -> QWidget

childEvent(self, QChildEvent)
children(self) → List[QObject]
childrenRect(self) → QRect
childrenRegion(self) → QRegion
clear(self)
clearFocus(self)
clearMask(self)
close(self) → bool
closeEvent(self, QCloseEvent)
colorCount(self) → int
connectNotify(self, QMetaMethod)
contentsMargins(self) → QMargins
contentsRect(self) → QRect
contextMenuEvent(self, QContextMenuEvent)
contextMenuPolicy(self) → Qt.ContextMenuPolicy
create(self, window: sip.voidptr = 0, initializeWindow: bool = True, destroyOldWindow: bool = True)
createWindowContainer(QWindow, parent: QWidget = None, flags: Union[Qt.WindowFlags, Qt.WindowType] = 0) → QWidget
cursor(self) → QCursor
customContextMenuRequested

customContextMenuRequested(self, QPoint) [signal]

customEvent(self, QEvent)
deleteLater(self)
depth(self) → int
destroy(self, destroyWindow: bool = True, destroySubWindows: bool = True)
destroyed

destroyed(self, object: QObject = None) [signal]

devType(self) → int
devicePixelRatio(self) → int
devicePixelRatioF(self) → float
devicePixelRatioFScale() → float
disconnect(self)
disconnectNotify(self, QMetaMethod)
dragEnterEvent(self, QDragEnterEvent)
dragLeaveEvent(self, QDragLeaveEvent)
dragMoveEvent(self, QDragMoveEvent)
drawFrame(self, QPainter)
dropEvent(self, QDropEvent)
dumpObjectInfo(self)
dumpObjectTree(self)
dynamicPropertyNames(self) → List[QByteArray]
effectiveWinId(self) → sip.voidptr
ensurePolished(self)
enterEvent(self, QEvent)
event(self, QEvent) → bool
eventFilter(self, QObject, QEvent) → bool
find(sip.voidptr) → QWidget
findChild(self, type, name: str = '', options: Union[Qt.FindChildOptions, Qt.FindChildOption] = Qt.FindChildrenRecursively) → QObject

findChild(self, Tuple, name: str = ‘’, options: Union[Qt.FindChildOptions, Qt.FindChildOption] = Qt.FindChildrenRecursively) -> QObject

findChildren(self, type, name: str = '', options: Union[Qt.FindChildOptions, Qt.FindChildOption] = Qt.FindChildrenRecursively) → List[QObject]

findChildren(self, Tuple, name: str = ‘’, options: Union[Qt.FindChildOptions, Qt.FindChildOption] = Qt.FindChildrenRecursively) -> List[QObject] findChildren(self, type, QRegExp, options: Union[Qt.FindChildOptions, Qt.FindChildOption] = Qt.FindChildrenRecursively) -> List[QObject] findChildren(self, Tuple, QRegExp, options: Union[Qt.FindChildOptions, Qt.FindChildOption] = Qt.FindChildrenRecursively) -> List[QObject] findChildren(self, type, QRegularExpression, options: Union[Qt.FindChildOptions, Qt.FindChildOption] = Qt.FindChildrenRecursively) -> List[QObject] findChildren(self, Tuple, QRegularExpression, options: Union[Qt.FindChildOptions, Qt.FindChildOption] = Qt.FindChildrenRecursively) -> List[QObject]

focusInEvent(self, QFocusEvent)
focusNextChild(self) → bool
focusNextPrevChild(self, bool) → bool
focusOutEvent(self, QFocusEvent)
focusPolicy(self) → Qt.FocusPolicy
focusPreviousChild(self) → bool
focusProxy(self) → QWidget
focusWidget(self) → QWidget
font(self) → QFont
fontInfo(self) → QFontInfo
fontMetrics(self) → QFontMetrics
foregroundRole(self) → QPalette.ColorRole
frameGeometry(self) → QRect
frameRect(self) → QRect
frameShadow(self) → QFrame.Shadow
frameShape(self) → QFrame.Shape
frameSize(self) → QSize
frameStyle(self) → int
frameWidth(self) → int
geometry(self) → QRect
getContentsMargins(self) → Tuple[int, int, int, int]
grab(self, rectangle: QRect = QRect(QPoint(0, 0), QSize(-1, -1))) → QPixmap
grabGesture(self, Qt.GestureType, flags: Union[Qt.GestureFlags, Qt.GestureFlag] = Qt.GestureFlags())
grabKeyboard(self)
grabMouse(self)

grabMouse(self, Union[QCursor, Qt.CursorShape])

grabShortcut(self, Union[QKeySequence, QKeySequence.StandardKey, str, int], context: Qt.ShortcutContext = Qt.WindowShortcut) → int
graphicsEffect(self) → QGraphicsEffect
graphicsProxyWidget(self) → QGraphicsProxyWidget
hasFocus(self) → bool
hasHeightForWidth(self) → bool
hasMouseTracking(self) → bool
hasScaledContents(self) → bool
hasSelectedText(self) → bool
hasTabletTracking(self) → bool
height(self) → int
heightForWidth(self, int) → int
heightMM(self) → int
hide(self)
hideEvent(self, QHideEvent)
indent(self) → int
inherits(self, str) → bool
initPainter(self, QPainter)
initStyleOption(self, QStyleOptionFrame)
inputMethodEvent(self, QInputMethodEvent)
inputMethodHints(self) → Qt.InputMethodHints
inputMethodQuery(self, Qt.InputMethodQuery) → Any
insertAction(self, QAction, QAction)
insertActions(self, QAction, Iterable[QAction])
installEventFilter(self, QObject)
isActiveWindow(self) → bool
isAncestorOf(self, QWidget) → bool
isEnabled(self) → bool
isEnabledTo(self, QWidget) → bool
isFullScreen(self) → bool
isHidden(self) → bool
isLeftToRight(self) → bool
isMaximized(self) → bool
isMinimized(self) → bool
isModal(self) → bool
isRightToLeft(self) → bool
isSignalConnected(self, QMetaMethod) → bool
isVisible(self) → bool
isVisibleTo(self, QWidget) → bool
isWidgetType(self) → bool
isWindow(self) → bool
isWindowModified(self) → bool
isWindowType(self) → bool
keyPressEvent(self, QKeyEvent)
keyReleaseEvent(self, QKeyEvent)
keyboardGrabber() → QWidget
killTimer(self, int)
layout(self) → QLayout
layoutDirection(self) → Qt.LayoutDirection
leaveEvent(self, QEvent)
lineWidth(self) → int
linkActivated

linkActivated(self, str) [signal]

linkHovered

linkHovered(self, str) [signal]

locale(self) → QLocale
logicalDpiX(self) → int
logicalDpiY(self) → int
lower(self)
mapFrom(self, QWidget, QPoint) → QPoint
mapFromGlobal(self, QPoint) → QPoint
mapFromParent(self, QPoint) → QPoint
mapTo(self, QWidget, QPoint) → QPoint
mapToGlobal(self, QPoint) → QPoint
mapToParent(self, QPoint) → QPoint
margin(self) → int
mask(self) → QRegion
maximumHeight(self) → int
maximumSize(self) → QSize
maximumWidth(self) → int
metaObject(self) → QMetaObject
metric(self, QPaintDevice.PaintDeviceMetric) → int
midLineWidth(self) → int
minimumHeight(self) → int
minimumSize(self) → QSize
minimumSizeHint(self) → QSize
minimumWidth(self) → int
mouseDoubleClickEvent(self, QMouseEvent)
mouseGrabber() → QWidget
mouseMoveEvent(self, QMouseEvent)
mousePressEvent(self, QMouseEvent)
mouseReleaseEvent(self, QMouseEvent)
move(self, QPoint)

move(self, int, int)

moveEvent(self, QMoveEvent)
moveToThread(self, QThread)
movie(self) → QMovie
nativeEvent(self, Union[QByteArray, bytes, bytearray], sip.voidptr) → Tuple[bool, int]
nativeParentWidget(self) → QWidget
nextInFocusChain(self) → QWidget
normalGeometry(self) → QRect
objectName(self) → str
objectNameChanged

objectNameChanged(self, str) [signal]

overrideWindowFlags(self, Union[Qt.WindowFlags, Qt.WindowType])
overrideWindowState(self, Union[Qt.WindowStates, Qt.WindowState])
paintEngine(self) → QPaintEngine
paintEvent(self, QPaintEvent)
paintingActive(self) → bool
palette(self) → QPalette
parent(self) → QObject
parentWidget(self) → QWidget
physicalDpiX(self) → int
physicalDpiY(self) → int
picture(self) → QPicture
pixmap(self) → QPixmap
pos(self) → QPoint
previousInFocusChain(self) → QWidget
property(self, str) → Any
pyqtConfigure(...)

Each keyword argument is either the name of a Qt property or a Qt signal. For properties the property is set to the given value which should be of an appropriate type. For signals the signal is connected to the given value which should be a callable.

raise_(self)
receivers(self, PYQT_SIGNAL) → int
rect(self) → QRect
releaseKeyboard(self)
releaseMouse(self)
releaseShortcut(self, int)
removeAction(self, QAction)
removeEventFilter(self, QObject)
render(self, QPaintDevice, targetOffset: QPoint = QPoint(), sourceRegion: QRegion = QRegion(), flags: Union[QWidget.RenderFlags, QWidget.RenderFlag] = QWidget.RenderFlags(QWidget.DrawWindowBackground|QWidget.DrawChildren))

render(self, QPainter, targetOffset: QPoint = QPoint(), sourceRegion: QRegion = QRegion(), flags: Union[QWidget.RenderFlags, QWidget.RenderFlag] = QWidget.RenderFlags(QWidget.DrawWindowBackground|QWidget.DrawChildren))

repaint(self)

repaint(self, int, int, int, int) repaint(self, QRect) repaint(self, QRegion)

resize(self, QSize)

resize(self, int, int)

resizeEvent(self, QResizeEvent)
restoreGeometry(self, Union[QByteArray, bytes, bytearray]) → bool
saveGeometry(self) → QByteArray
scroll(self, int, int)

scroll(self, int, int, QRect)

selectedText(self) → str
selectionStart(self) → int
sender(self) → QObject
senderSignalIndex(self) → int
setAcceptDrops(self, bool)
setAccessibleDescription(self, str)
setAccessibleName(self, str)
setAlignment(self, Union[Qt.Alignment, Qt.AlignmentFlag])
setAttribute(self, Qt.WidgetAttribute, on: bool = True)
setAutoFillBackground(self, bool)
setBackgroundRole(self, QPalette.ColorRole)
setBaseSize(self, int, int)

setBaseSize(self, QSize)

setBuddy(self, QWidget)
setContentsMargins(self, int, int, int, int)

setContentsMargins(self, QMargins)

setContextMenuPolicy(self, Qt.ContextMenuPolicy)
setCursor(self, Union[QCursor, Qt.CursorShape])
setDisabled(self, bool)
setEnabled(self, bool)
setFixedHeight(self, int)
setFixedSize(self, QSize)

setFixedSize(self, int, int)

setFixedWidth(self, int)
setFocus(self)

setFocus(self, Qt.FocusReason)

setFocusPolicy(self, Qt.FocusPolicy)
setFocusProxy(self, QWidget)
setFont(self, QFont)
setForegroundRole(self, QPalette.ColorRole)
setFrameRect(self, QRect)
setFrameShadow(self, QFrame.Shadow)
setFrameShape(self, QFrame.Shape)
setFrameStyle(self, int)
setGeometry(self, QRect)

setGeometry(self, int, int, int, int)

setGraphicsEffect(self, QGraphicsEffect)
setHidden(self, bool)
setIndent(self, int)
setInputMethodHints(self, Union[Qt.InputMethodHints, Qt.InputMethodHint])
setLayout(self, QLayout)
setLayoutDirection(self, Qt.LayoutDirection)
setLineWidth(self, int)
setLocale(self, QLocale)
setMargin(self, int)
setMask(self, QBitmap)

setMask(self, QRegion)

setMaximumHeight(self, int)
setMaximumSize(self, int, int)

setMaximumSize(self, QSize)

setMaximumWidth(self, int)
setMidLineWidth(self, int)
setMinimumHeight(self, int)
setMinimumSize(self, int, int)

setMinimumSize(self, QSize)

setMinimumWidth(self, int)
setMouseTracking(self, bool)
setMovie(self, QMovie)
setNum(self, float)

setNum(self, int)

setObjectName(self, str)
setPalette(self, QPalette)
setParent(self, QWidget)

setParent(self, QWidget, Union[Qt.WindowFlags, Qt.WindowType])

setPicture(self, QPicture)
setPixmap(self, QPixmap)
setProperty(self, str, Any) → bool
setScaledContents(self, bool)
setSelection(self, int, int)
setShortcutAutoRepeat(self, int, enabled: bool = True)
setShortcutEnabled(self, int, enabled: bool = True)
setSizeIncrement(self, int, int)

setSizeIncrement(self, QSize)

setSizePolicy(self, QSizePolicy)

setSizePolicy(self, QSizePolicy.Policy, QSizePolicy.Policy)

setStatusTip(self, str)
setStyle(self, QStyle)
setStyleSheet(self, str)
setTabOrder(QWidget, QWidget)
setTabletTracking(self, bool)
setText(self, str)
setTextFormat(self, Qt.TextFormat)
setTextInteractionFlags(self, Union[Qt.TextInteractionFlags, Qt.TextInteractionFlag])
setToolTip(self, str)
setToolTipDuration(self, int)
setUpdatesEnabled(self, bool)
setVisible(self, bool)
setWhatsThis(self, str)
setWindowFilePath(self, str)
setWindowFlag(self, Qt.WindowType, on: bool = True)
setWindowFlags(self, Union[Qt.WindowFlags, Qt.WindowType])
setWindowIcon(self, QIcon)
setWindowIconText(self, str)
setWindowModality(self, Qt.WindowModality)
setWindowModified(self, bool)
setWindowOpacity(self, float)
setWindowRole(self, str)
setWindowState(self, Union[Qt.WindowStates, Qt.WindowState])
setWindowTitle(self, str)
setWordWrap(self, bool)
sharedPainter(self) → QPainter
show(self)
showEvent(self, QShowEvent)
showFullScreen(self)
showMaximized(self)
showMinimized(self)
showNormal(self)
signalsBlocked(self) → bool
size(self) → QSize
sizeIncrement(self) → QSize
sizePolicy(self) → QSizePolicy
stackUnder(self, QWidget)
startTimer(self, int, timerType: Qt.TimerType = Qt.CoarseTimer) → int
staticMetaObject = <PyQt5.QtCore.QMetaObject object>
statusTip(self) → str
style(self) → QStyle
styleSheet(self) → str
tabletEvent(self, QTabletEvent)
testAttribute(self, Qt.WidgetAttribute) → bool
text(self) → str
textFormat(self) → Qt.TextFormat
textInteractionFlags(self) → Qt.TextInteractionFlags
thread(self) → QThread
timerEvent(self, QTimerEvent)
toolTip(self) → str
toolTipDuration(self) → int
tr(self, str, disambiguation: str = None, n: int = -1) → str
underMouse(self) → bool
ungrabGesture(self, Qt.GestureType)
unsetCursor(self)
unsetLayoutDirection(self)
unsetLocale(self)
update(self)

update(self, QRect) update(self, QRegion) update(self, int, int, int, int)

updateGeometry(self)
updateMicroFocus(self)
updatesEnabled(self) → bool
visibleRegion(self) → QRegion
whatsThis(self) → str
wheelEvent(self, QWheelEvent)
width(self) → int
widthMM(self) → int
winId(self) → sip.voidptr
window(self) → QWidget
windowFilePath(self) → str
windowFlags(self) → Qt.WindowFlags
windowHandle(self) → QWindow
windowIcon(self) → QIcon
windowIconChanged

windowIconChanged(self, QIcon) [signal]

windowIconText(self) → str
windowIconTextChanged

windowIconTextChanged(self, str) [signal]

windowModality(self) → Qt.WindowModality
windowOpacity(self) → float
windowRole(self) → str
windowState(self) → Qt.WindowStates
windowTitle(self) → str
windowTitleChanged

windowTitleChanged(self, str) [signal]

windowType(self) → Qt.WindowType
wordWrap(self) → bool
x(self) → int
y(self) → int
class schrodinger.ui.qt.structure2d.StructureToolTip(structure=None, offset=(10, 10), global_position=None, height=200, width=200, **kwargs)

Bases: schrodinger.ui.qt.structure2d.StructurePicture

A tooltip that shows a chemical structure

__init__(structure=None, offset=(10, 10), global_position=None, height=200, width=200, **kwargs)
Parameters:
  • structure (structure object that canvas2d.ChmMmctAdaptor.create() accepts.) – the structure to draw in the cell. This can be given at instantiation time if the structure will always be the same, or it can be given a show time if the structure will change dynamically.
  • offset (tuple(int, int)) – x and y pixel offset from the mouse pointer position to draw the upper left corner of the tooltip window
  • global_position (tuple(int, int)) – global position relative to the screen to to draw the upper left corner of the tooltip window. This parameter overrides the offset parameter.
  • height (int) – the height of this tooltip in pixels
  • width (int) – the width of this tooltip in pixels

This class is designed to be created once and shown/hidden as often as needed. However, there seems to be an issue with PyQt that eventually (in an unreproducible fashion) the tooltip window may simply showing up. It will claim to be visible with self.isVisible() and return the full window size using self.visibleRegion(), but it won’t be visible. Therefore it is probably best to create a new instance each time. Instances of this class are lightweight, quick to create, and garbage collect without any apparent memory leaks.

protein_present_image = None
paintEvent(event)

Reimplmented the paint event to draw text on top of the image, using the value of self.top_left_text

setOffset(offset)

Sets the x and y offset in pixels of the tooltip from the mouse pointer

Parameters:offset (tuple(int, int)) – x and y pixel offset from the mouse pointer position to draw the upper left corner of the tooltip window
setGlobalPosition(global_position)

Sets the x and y global position relative to the screen at which to draw the top left corner of the tooltip window.

Parameters:global_position (tuple(int, int)) – global position relative to the screen to draw the upper left corner of the tooltip window. This parameter overrides the offset parameter.
show(structure=None, pic=None, top_left_text=None)

Show the tooltip

Parameters:structure (structure object that canvas2d.ChmMmctAdaptor.create() accepts.) – the structure to draw in the cell. This can be given at instantiation time if the structure will always be the same, or it can be given a show time if the structure will change dynamically.
finish()

Hide ourselves. This slot should be connected to a signal that is emitted when the parent widget receives a leaveEvent, or called directly from the widget’s leaveEvent routine.

Don’t destroy ourselves here even if we are being used in one-time use mode, because bus errors can result if we are created/destroyed in too short a timeframe - as can happen with tooltips.

Box = 1
DrawChildren = 2
DrawWindowBackground = 1
HLine = 4
IgnoreMask = 4
NoFrame = 0
class PaintDeviceMetric

Bases: int

__init__ = <method-wrapper '__init__' of sip.enumtype object at 0x1e51628>
Panel = 2
PdmDepth = 6
PdmDevicePixelRatio = 11
PdmDevicePixelRatioScaled = 12
PdmDpiX = 7
PdmDpiY = 8
PdmHeight = 2
PdmHeightMM = 4
PdmNumColors = 5
PdmPhysicalDpiX = 9
PdmPhysicalDpiY = 10
PdmWidth = 1
PdmWidthMM = 3
Plain = 16
Raised = 32
class RenderFlag

Bases: int

__init__ = <method-wrapper '__init__' of sip.enumtype object at 0x1e8d8a8>
class RenderFlags

Bases: sip.simplewrapper

QWidget.RenderFlags(Union[QWidget.RenderFlags, QWidget.RenderFlag]) QWidget.RenderFlags(QWidget.RenderFlags)

__init__

Initialize self. See help(type(self)) for accurate signature.

class Shadow

Bases: int

__init__ = <method-wrapper '__init__' of sip.enumtype object at 0x1e08da8>
Shadow_Mask = 240
class Shape

Bases: int

__init__ = <method-wrapper '__init__' of sip.enumtype object at 0x1e09158>
Shape_Mask = 15
class StyleMask

Bases: int

__init__ = <method-wrapper '__init__' of sip.enumtype object at 0x1e09508>
StyledPanel = 6
Sunken = 48
VLine = 5
WinPanel = 3
acceptDrops(self) → bool
accessibleDescription(self) → str
accessibleName(self) → str
actionEvent(self, QActionEvent)
actions(self) → List[QAction]
activateWindow(self)
addAction(self, QAction)
addActions(self, Iterable[QAction])
adjustSize(self)
alignment(self) → Qt.Alignment
autoFillBackground(self) → bool
backgroundRole(self) → QPalette.ColorRole
baseSize(self) → QSize
blockSignals(self, bool) → bool
buddy(self) → QWidget
changeEvent(self, QEvent)
childAt(self, QPoint) → QWidget

childAt(self, int, int) -> QWidget

childEvent(self, QChildEvent)
children(self) → List[QObject]
childrenRect(self) → QRect
childrenRegion(self) → QRegion
clear(self)
clearFocus(self)
clearMask(self)
close(self) → bool
closeEvent(self, QCloseEvent)
colorCount(self) → int
connectNotify(self, QMetaMethod)
contentsMargins(self) → QMargins
contentsRect(self) → QRect
contextMenuEvent(self, QContextMenuEvent)
contextMenuPolicy(self) → Qt.ContextMenuPolicy
create(self, window: sip.voidptr = 0, initializeWindow: bool = True, destroyOldWindow: bool = True)
createWindowContainer(QWindow, parent: QWidget = None, flags: Union[Qt.WindowFlags, Qt.WindowType] = 0) → QWidget
cursor(self) → QCursor
customContextMenuRequested

customContextMenuRequested(self, QPoint) [signal]

customEvent(self, QEvent)
deleteLater(self)
depth(self) → int
destroy(self, destroyWindow: bool = True, destroySubWindows: bool = True)
destroyed

destroyed(self, object: QObject = None) [signal]

devType(self) → int
devicePixelRatio(self) → int
devicePixelRatioF(self) → float
devicePixelRatioFScale() → float
disconnect(self)
disconnectNotify(self, QMetaMethod)
dragEnterEvent(self, QDragEnterEvent)
dragLeaveEvent(self, QDragLeaveEvent)
dragMoveEvent(self, QDragMoveEvent)
drawChmmol(chmmol, atoms=[], bonds=[], color=<PyQt5.QtGui.QColor object>, gen_coord=False)

Makes a 2-D rendering of the chmmol object with optional atoms and bonds highlighting.

Parameters:
  • chmmol (ChmMol instance.) – Structure to generate the picture for.
  • atoms (list) – list of atoms that should be highlighted
  • bonds (list) – list of bonds that should be highlighted
  • color (QtGui.QColor) – color that is used to highlight atoms and bonds
  • gen_coord (bool) – if True generate coordinates.
drawFrame(self, QPainter)
drawStructure(structure, StereoType=6, hydrogenTreatment=1, wantProperties=True, wantMMStereoProps=True, readAtomBondProperties=True, allowRadicals=False)

Makes a 2-D rendering of the structure

Parameters:
  • structure (schrodinger.structure.Structure class object) – structure to be drawn on the canvas
  • StereoType (canvas2d.ChmMmctAdaptor.StereoType) – Stereochemistry option to use. Available options: # Does not include stereochemistry info: canvas2d.ChmMmctAdaptor.NoStereo # Ignores mmstereo annotations: canvas2d.ChmMmctAdaptor.StereoFromGeometry # Silently ignores stereo information that Canvas doesn’t agree with: canvas2d.ChmMmctAdaptor.StereoFromGeometry_Safe # Ignores 3d geometry: canvas2d.ChmMmctAdaptor.StereoFromAnnotation # Silently ignores stereo information that Canvas doesn’t agree with: canvas2d.ChmMmctAdaptor.StereoFromAnnotation_Safe # Uses mmstereo annotaions with 3D geometry as a backup: canvas2d.ChmMmctAdaptor.StereoFromAnnotationAndGeometry # Silently ignores stereo information that Canvas doesn’t agree with: canvas2d.ChmMmctAdaptor.StereoFromAnnotationAndGeometry_Safe
  • hydrogenTreatment (canvas2d.ChmAtomOption.H) – Hydrogen treatment method. Available options: canvas2d.ChmAtomOption.H_Never canvas2d.ChmAtomOption.H_ExplicitOnly canvas2d.ChmAtomOption.H_Polar canvas2d.ChmAtomOption.H_ExplicitPolar canvas2d.ChmAtomOption.H_Chiral canvas2d.ChmAtomOption.H_ExplicitChiral canvas2d.ChmAtomOption.H_ExplicitPolarAndChiral canvas2d.ChmAtomOption.H_All
  • wantProperties (bool) – Whether properties should be copied.
  • wantMMStereoProps (bool) – Whether to copy mmstereo properties.
  • readAtomBondProperties (bool) – Whether to copy atom and bond-level properties.
  • allowRadicals (bool) – Whether to assume that valence deficiencies represent unpaired electrons.
dropEvent(self, QDropEvent)
dumpObjectInfo(self)
dumpObjectTree(self)
dynamicPropertyNames(self) → List[QByteArray]
effectiveWinId(self) → sip.voidptr
ensurePolished(self)
enterEvent(self, QEvent)
event(self, QEvent) → bool
eventFilter(self, QObject, QEvent) → bool
find(sip.voidptr) → QWidget
findChild(self, type, name: str = '', options: Union[Qt.FindChildOptions, Qt.FindChildOption] = Qt.FindChildrenRecursively) → QObject

findChild(self, Tuple, name: str = ‘’, options: Union[Qt.FindChildOptions, Qt.FindChildOption] = Qt.FindChildrenRecursively) -> QObject

findChildren(self, type, name: str = '', options: Union[Qt.FindChildOptions, Qt.FindChildOption] = Qt.FindChildrenRecursively) → List[QObject]

findChildren(self, Tuple, name: str = ‘’, options: Union[Qt.FindChildOptions, Qt.FindChildOption] = Qt.FindChildrenRecursively) -> List[QObject] findChildren(self, type, QRegExp, options: Union[Qt.FindChildOptions, Qt.FindChildOption] = Qt.FindChildrenRecursively) -> List[QObject] findChildren(self, Tuple, QRegExp, options: Union[Qt.FindChildOptions, Qt.FindChildOption] = Qt.FindChildrenRecursively) -> List[QObject] findChildren(self, type, QRegularExpression, options: Union[Qt.FindChildOptions, Qt.FindChildOption] = Qt.FindChildrenRecursively) -> List[QObject] findChildren(self, Tuple, QRegularExpression, options: Union[Qt.FindChildOptions, Qt.FindChildOption] = Qt.FindChildrenRecursively) -> List[QObject]

focusInEvent(self, QFocusEvent)
focusNextChild(self) → bool
focusNextPrevChild(self, bool) → bool
focusOutEvent(self, QFocusEvent)
focusPolicy(self) → Qt.FocusPolicy
focusPreviousChild(self) → bool
focusProxy(self) → QWidget
focusWidget(self) → QWidget
font(self) → QFont
fontInfo(self) → QFontInfo
fontMetrics(self) → QFontMetrics
foregroundRole(self) → QPalette.ColorRole
frameGeometry(self) → QRect
frameRect(self) → QRect
frameShadow(self) → QFrame.Shadow
frameShape(self) → QFrame.Shape
frameSize(self) → QSize
frameStyle(self) → int
frameWidth(self) → int
geometry(self) → QRect
getContentsMargins(self) → Tuple[int, int, int, int]
grab(self, rectangle: QRect = QRect(QPoint(0, 0), QSize(-1, -1))) → QPixmap
grabGesture(self, Qt.GestureType, flags: Union[Qt.GestureFlags, Qt.GestureFlag] = Qt.GestureFlags())
grabKeyboard(self)
grabMouse(self)

grabMouse(self, Union[QCursor, Qt.CursorShape])

grabShortcut(self, Union[QKeySequence, QKeySequence.StandardKey, str, int], context: Qt.ShortcutContext = Qt.WindowShortcut) → int
graphicsEffect(self) → QGraphicsEffect
graphicsProxyWidget(self) → QGraphicsProxyWidget
hasFocus(self) → bool
hasHeightForWidth(self) → bool
hasMouseTracking(self) → bool
hasScaledContents(self) → bool
hasSelectedText(self) → bool
hasTabletTracking(self) → bool
height(self) → int
heightForWidth(self, int) → int
heightMM(self) → int
hide(self)
hideEvent(self, QHideEvent)
indent(self) → int
inherits(self, str) → bool
initPainter(self, QPainter)
initStyleOption(self, QStyleOptionFrame)
inputMethodEvent(self, QInputMethodEvent)
inputMethodHints(self) → Qt.InputMethodHints
inputMethodQuery(self, Qt.InputMethodQuery) → Any
insertAction(self, QAction, QAction)
insertActions(self, QAction, Iterable[QAction])
installEventFilter(self, QObject)
isActiveWindow(self) → bool
isAncestorOf(self, QWidget) → bool
isEnabled(self) → bool
isEnabledTo(self, QWidget) → bool
isFullScreen(self) → bool
isHidden(self) → bool
isLeftToRight(self) → bool
isMaximized(self) → bool
isMinimized(self) → bool
isModal(self) → bool
isRightToLeft(self) → bool
isSignalConnected(self, QMetaMethod) → bool
isVisible(self) → bool
isVisibleTo(self, QWidget) → bool
isWidgetType(self) → bool
isWindow(self) → bool
isWindowModified(self) → bool
isWindowType(self) → bool
keyPressEvent(self, QKeyEvent)
keyReleaseEvent(self, QKeyEvent)
keyboardGrabber() → QWidget
killTimer(self, int)
layout(self) → QLayout
layoutDirection(self) → Qt.LayoutDirection
leaveEvent(self, QEvent)
lineWidth(self) → int
linkActivated

linkActivated(self, str) [signal]

linkHovered

linkHovered(self, str) [signal]

locale(self) → QLocale
logicalDpiX(self) → int
logicalDpiY(self) → int
lower(self)
mapFrom(self, QWidget, QPoint) → QPoint
mapFromGlobal(self, QPoint) → QPoint
mapFromParent(self, QPoint) → QPoint
mapTo(self, QWidget, QPoint) → QPoint
mapToGlobal(self, QPoint) → QPoint
mapToParent(self, QPoint) → QPoint
margin(self) → int
mask(self) → QRegion
maximumHeight(self) → int
maximumSize(self) → QSize
maximumWidth(self) → int
metaObject(self) → QMetaObject
metric(self, QPaintDevice.PaintDeviceMetric) → int
midLineWidth(self) → int
minimumHeight(self) → int
minimumSize(self) → QSize
minimumSizeHint(self) → QSize
minimumWidth(self) → int
mouseDoubleClickEvent(self, QMouseEvent)
mouseGrabber() → QWidget
mouseMoveEvent(self, QMouseEvent)
mousePressEvent(self, QMouseEvent)
mouseReleaseEvent(self, QMouseEvent)
move(self, QPoint)

move(self, int, int)

moveEvent(self, QMoveEvent)
moveToThread(self, QThread)
movie(self) → QMovie
nativeEvent(self, Union[QByteArray, bytes, bytearray], sip.voidptr) → Tuple[bool, int]
nativeParentWidget(self) → QWidget
nextInFocusChain(self) → QWidget
normalGeometry(self) → QRect
objectName(self) → str
objectNameChanged

objectNameChanged(self, str) [signal]

overrideWindowFlags(self, Union[Qt.WindowFlags, Qt.WindowType])
overrideWindowState(self, Union[Qt.WindowStates, Qt.WindowState])
paintEngine(self) → QPaintEngine
paintingActive(self) → bool
palette(self) → QPalette
parent(self) → QObject
parentWidget(self) → QWidget
physicalDpiX(self) → int
physicalDpiY(self) → int
picture(self) → QPicture
pixmap(self) → QPixmap
pos(self) → QPoint
previousInFocusChain(self) → QWidget
property(self, str) → Any
pyqtConfigure(...)

Each keyword argument is either the name of a Qt property or a Qt signal. For properties the property is set to the given value which should be of an appropriate type. For signals the signal is connected to the given value which should be a callable.

raise_(self)
receivers(self, PYQT_SIGNAL) → int
rect(self) → QRect
releaseKeyboard(self)
releaseMouse(self)
releaseShortcut(self, int)
removeAction(self, QAction)
removeEventFilter(self, QObject)
render(self, QPaintDevice, targetOffset: QPoint = QPoint(), sourceRegion: QRegion = QRegion(), flags: Union[QWidget.RenderFlags, QWidget.RenderFlag] = QWidget.RenderFlags(QWidget.DrawWindowBackground|QWidget.DrawChildren))

render(self, QPainter, targetOffset: QPoint = QPoint(), sourceRegion: QRegion = QRegion(), flags: Union[QWidget.RenderFlags, QWidget.RenderFlag] = QWidget.RenderFlags(QWidget.DrawWindowBackground|QWidget.DrawChildren))

repaint(self)

repaint(self, int, int, int, int) repaint(self, QRect) repaint(self, QRegion)

resize(self, QSize)

resize(self, int, int)

resizeEvent(self, QResizeEvent)
restoreGeometry(self, Union[QByteArray, bytes, bytearray]) → bool
saveGeometry(self) → QByteArray
scroll(self, int, int)

scroll(self, int, int, QRect)

selectedText(self) → str
selectionStart(self) → int
sender(self) → QObject
senderSignalIndex(self) → int
setAcceptDrops(self, bool)
setAccessibleDescription(self, str)
setAccessibleName(self, str)
setAlignment(self, Union[Qt.Alignment, Qt.AlignmentFlag])
setAnnotators(annotators)

This function allows to reset annotators between renderning 2-D structures.

Parameters:annotators (list) – Each item of the list should be a canvas2d.ChemViewAnnotator object that will be applied to the canvas2d.ChmRender2DModel when generating the image
setAttribute(self, Qt.WidgetAttribute, on: bool = True)
setAutoFillBackground(self, bool)
setBackgroundRole(self, QPalette.ColorRole)
setBaseSize(self, int, int)

setBaseSize(self, QSize)

setBuddy(self, QWidget)
setContentsMargins(self, int, int, int, int)

setContentsMargins(self, QMargins)

setContextMenuPolicy(self, Qt.ContextMenuPolicy)
setCursor(self, Union[QCursor, Qt.CursorShape])
setDisabled(self, bool)
setEnabled(self, bool)
setFixedHeight(self, int)
setFixedSize(self, QSize)

setFixedSize(self, int, int)

setFixedWidth(self, int)
setFocus(self)

setFocus(self, Qt.FocusReason)

setFocusPolicy(self, Qt.FocusPolicy)
setFocusProxy(self, QWidget)
setFont(self, QFont)
setForegroundRole(self, QPalette.ColorRole)
setFrameRect(self, QRect)
setFrameShadow(self, QFrame.Shadow)
setFrameShape(self, QFrame.Shape)
setFrameStyle(self, int)
setGeometry(self, QRect)

setGeometry(self, int, int, int, int)

setGraphicsEffect(self, QGraphicsEffect)
setHidden(self, bool)
setIndent(self, int)
setInputMethodHints(self, Union[Qt.InputMethodHints, Qt.InputMethodHint])
setLayout(self, QLayout)
setLayoutDirection(self, Qt.LayoutDirection)
setLineWidth(self, int)
setLocale(self, QLocale)
setMargin(self, int)
setMask(self, QBitmap)

setMask(self, QRegion)

setMaximumHeight(self, int)
setMaximumSize(self, int, int)

setMaximumSize(self, QSize)

setMaximumWidth(self, int)
setMidLineWidth(self, int)
setMinimumHeight(self, int)
setMinimumSize(self, int, int)

setMinimumSize(self, QSize)

setMinimumWidth(self, int)
setMouseTracking(self, bool)
setMovie(self, QMovie)
setNum(self, float)

setNum(self, int)

setObjectName(self, str)
setPalette(self, QPalette)
setParent(self, QWidget)

setParent(self, QWidget, Union[Qt.WindowFlags, Qt.WindowType])

setPicture(self, QPicture)
setPixmap(self, QPixmap)
setProperty(self, str, Any) → bool
setScaledContents(self, bool)
setSelection(self, int, int)
setShortcutAutoRepeat(self, int, enabled: bool = True)
setShortcutEnabled(self, int, enabled: bool = True)
setSizeIncrement(self, int, int)

setSizeIncrement(self, QSize)

setSizePolicy(self, QSizePolicy)

setSizePolicy(self, QSizePolicy.Policy, QSizePolicy.Policy)

setStatusTip(self, str)
setStyle(self, QStyle)
setStyleSheet(self, str)
setTabOrder(QWidget, QWidget)
setTabletTracking(self, bool)
setText(self, str)
setTextFormat(self, Qt.TextFormat)
setTextInteractionFlags(self, Union[Qt.TextInteractionFlags, Qt.TextInteractionFlag])
setToolTip(self, str)
setToolTipDuration(self, int)
setUpdatesEnabled(self, bool)
setVisible(self, bool)
setWhatsThis(self, str)
setWindowFilePath(self, str)
setWindowFlag(self, Qt.WindowType, on: bool = True)
setWindowFlags(self, Union[Qt.WindowFlags, Qt.WindowType])
setWindowIcon(self, QIcon)
setWindowIconText(self, str)
setWindowModality(self, Qt.WindowModality)
setWindowModified(self, bool)
setWindowOpacity(self, float)
setWindowRole(self, str)
setWindowState(self, Union[Qt.WindowStates, Qt.WindowState])
setWindowTitle(self, str)
setWordWrap(self, bool)
sharedPainter(self) → QPainter
showEvent(self, QShowEvent)
showFullScreen(self)
showMaximized(self)
showMinimized(self)
showNormal(self)
signalsBlocked(self) → bool
size(self) → QSize
sizeHint(self) → QSize
sizeIncrement(self) → QSize
sizePolicy(self) → QSizePolicy
stackUnder(self, QWidget)
startTimer(self, int, timerType: Qt.TimerType = Qt.CoarseTimer) → int
staticMetaObject = <PyQt5.QtCore.QMetaObject object>
statusTip(self) → str
style(self) → QStyle
styleSheet(self) → str
tabletEvent(self, QTabletEvent)
testAttribute(self, Qt.WidgetAttribute) → bool
text(self) → str
textFormat(self) → Qt.TextFormat
textInteractionFlags(self) → Qt.TextInteractionFlags
thread(self) → QThread
timerEvent(self, QTimerEvent)
toolTip(self) → str
toolTipDuration(self) → int
tr(self, str, disambiguation: str = None, n: int = -1) → str
underMouse(self) → bool
ungrabGesture(self, Qt.GestureType)
unsetCursor(self)
unsetLayoutDirection(self)
unsetLocale(self)
update(self)

update(self, QRect) update(self, QRegion) update(self, int, int, int, int)

updateGeometry(self)
updateMicroFocus(self)
updatesEnabled(self) → bool
visibleRegion(self) → QRegion
whatsThis(self) → str
wheelEvent(self, QWheelEvent)
width(self) → int
widthMM(self) → int
winId(self) → sip.voidptr
window(self) → QWidget
windowFilePath(self) → str
windowFlags(self) → Qt.WindowFlags
windowHandle(self) → QWindow
windowIcon(self) → QIcon
windowIconChanged

windowIconChanged(self, QIcon) [signal]

windowIconText(self) → str
windowIconTextChanged

windowIconTextChanged(self, str) [signal]

windowModality(self) → Qt.WindowModality
windowOpacity(self) → float
windowRole(self) → str
windowState(self) → Qt.WindowStates
windowTitle(self) → str
windowTitleChanged

windowTitleChanged(self, str) [signal]

windowType(self) → Qt.WindowType
wordWrap(self) → bool
x(self) → int
y(self) → int
class schrodinger.ui.qt.structure2d.LabeledStructureToolTip(structure=None, offset=(2, 16), global_position=None, height=200, width=200, **kwargs)

Bases: PyQt5.QtWidgets.QFrame

Class that creates a tooltip with a 2d structure picture. An arbitrary number of labels can be added that will be displayed beneath the picture.

__init__(structure=None, offset=(2, 16), global_position=None, height=200, width=200, **kwargs)
Parameters:
  • structure (structure.Structure or canvas2d.ChmMol) – the structure to draw in the cell. This can be given at instantiation time if the structure will always be the same, or it can be given a show time if the structure will change dynamically.
  • offset (tuple of 2 ints) – x and y pixel offset from the mouse pointer position to draw the upper left corner of the tooltip window
  • global_position (tuple of 2 ints) – global position relative to the screen to to draw the upper left corner of the tooltip window. This parameter overrides the offset parameter.
  • height (int) – the height of this tooltip in pixels
  • width (int) – the width of this tooltip in pixels
layout(self) → QLayout
draw2DPicture(structure)

Draws 2D picture of the structure.

Parameters:structure (structure.Structure or canvas2d.ChmMol) – Structure to draw
setGlobalPosition(global_position)

Sets the x and y global position relative to the screen at which to draw the top left corner of the tooltip window.

Parameters:global_position (tuple(int, int)) – global position relative to the screen to draw the upper left corner of the tooltip window. This parameter overrides the offset parameter.
show(structure=None)

Show the tooltip

Parameters:structure (structure.Structure or canvas2d.ChmMol) – the structure to draw in the cell. This can be given at instantiation time if the structure will always be the same, or it can be given a show time if the structure will change dynamically.
addLabel(text)

Add a label containing the specified text underneath the structure picture.

Parameters:text (str) – Text to be included in the label
Box = 1
DrawChildren = 2
DrawWindowBackground = 1
HLine = 4
IgnoreMask = 4
NoFrame = 0
class PaintDeviceMetric

Bases: int

__init__ = <method-wrapper '__init__' of sip.enumtype object at 0x1e51628>
Panel = 2
PdmDepth = 6
PdmDevicePixelRatio = 11
PdmDevicePixelRatioScaled = 12
PdmDpiX = 7
PdmDpiY = 8
PdmHeight = 2
PdmHeightMM = 4
PdmNumColors = 5
PdmPhysicalDpiX = 9
PdmPhysicalDpiY = 10
PdmWidth = 1
PdmWidthMM = 3
Plain = 16
Raised = 32
class RenderFlag

Bases: int

__init__ = <method-wrapper '__init__' of sip.enumtype object at 0x1e8d8a8>
class RenderFlags

Bases: sip.simplewrapper

QWidget.RenderFlags(Union[QWidget.RenderFlags, QWidget.RenderFlag]) QWidget.RenderFlags(QWidget.RenderFlags)

__init__

Initialize self. See help(type(self)) for accurate signature.

class Shadow

Bases: int

__init__ = <method-wrapper '__init__' of sip.enumtype object at 0x1e08da8>
Shadow_Mask = 240
class Shape

Bases: int

__init__ = <method-wrapper '__init__' of sip.enumtype object at 0x1e09158>
Shape_Mask = 15
class StyleMask

Bases: int

__init__ = <method-wrapper '__init__' of sip.enumtype object at 0x1e09508>
StyledPanel = 6
Sunken = 48
VLine = 5
WinPanel = 3
acceptDrops(self) → bool
accessibleDescription(self) → str
accessibleName(self) → str
actionEvent(self, QActionEvent)
actions(self) → List[QAction]
activateWindow(self)
addAction(self, QAction)
addActions(self, Iterable[QAction])
adjustSize(self)
autoFillBackground(self) → bool
backgroundRole(self) → QPalette.ColorRole
baseSize(self) → QSize
blockSignals(self, bool) → bool
changeEvent(self, QEvent)
childAt(self, QPoint) → QWidget

childAt(self, int, int) -> QWidget

childEvent(self, QChildEvent)
children(self) → List[QObject]
childrenRect(self) → QRect
childrenRegion(self) → QRegion
clearFocus(self)
clearMask(self)
close(self) → bool
closeEvent(self, QCloseEvent)
colorCount(self) → int
connectNotify(self, QMetaMethod)
contentsMargins(self) → QMargins
contentsRect(self) → QRect
contextMenuEvent(self, QContextMenuEvent)
contextMenuPolicy(self) → Qt.ContextMenuPolicy
create(self, window: sip.voidptr = 0, initializeWindow: bool = True, destroyOldWindow: bool = True)
createWindowContainer(QWindow, parent: QWidget = None, flags: Union[Qt.WindowFlags, Qt.WindowType] = 0) → QWidget
cursor(self) → QCursor
customContextMenuRequested

customContextMenuRequested(self, QPoint) [signal]

customEvent(self, QEvent)
deleteLater(self)
depth(self) → int
destroy(self, destroyWindow: bool = True, destroySubWindows: bool = True)
destroyed

destroyed(self, object: QObject = None) [signal]

devType(self) → int
devicePixelRatio(self) → int
devicePixelRatioF(self) → float
devicePixelRatioFScale() → float
disconnect(self)
disconnectNotify(self, QMetaMethod)
dragEnterEvent(self, QDragEnterEvent)
dragLeaveEvent(self, QDragLeaveEvent)
dragMoveEvent(self, QDragMoveEvent)
drawFrame(self, QPainter)
dropEvent(self, QDropEvent)
dumpObjectInfo(self)
dumpObjectTree(self)
dynamicPropertyNames(self) → List[QByteArray]
effectiveWinId(self) → sip.voidptr
ensurePolished(self)
enterEvent(self, QEvent)
event(self, QEvent) → bool
eventFilter(self, QObject, QEvent) → bool
find(sip.voidptr) → QWidget
findChild(self, type, name: str = '', options: Union[Qt.FindChildOptions, Qt.FindChildOption] = Qt.FindChildrenRecursively) → QObject

findChild(self, Tuple, name: str = ‘’, options: Union[Qt.FindChildOptions, Qt.FindChildOption] = Qt.FindChildrenRecursively) -> QObject

findChildren(self, type, name: str = '', options: Union[Qt.FindChildOptions, Qt.FindChildOption] = Qt.FindChildrenRecursively) → List[QObject]

findChildren(self, Tuple, name: str = ‘’, options: Union[Qt.FindChildOptions, Qt.FindChildOption] = Qt.FindChildrenRecursively) -> List[QObject] findChildren(self, type, QRegExp, options: Union[Qt.FindChildOptions, Qt.FindChildOption] = Qt.FindChildrenRecursively) -> List[QObject] findChildren(self, Tuple, QRegExp, options: Union[Qt.FindChildOptions, Qt.FindChildOption] = Qt.FindChildrenRecursively) -> List[QObject] findChildren(self, type, QRegularExpression, options: Union[Qt.FindChildOptions, Qt.FindChildOption] = Qt.FindChildrenRecursively) -> List[QObject] findChildren(self, Tuple, QRegularExpression, options: Union[Qt.FindChildOptions, Qt.FindChildOption] = Qt.FindChildrenRecursively) -> List[QObject]

focusInEvent(self, QFocusEvent)
focusNextChild(self) → bool
focusNextPrevChild(self, bool) → bool
focusOutEvent(self, QFocusEvent)
focusPolicy(self) → Qt.FocusPolicy
focusPreviousChild(self) → bool
focusProxy(self) → QWidget
focusWidget(self) → QWidget
font(self) → QFont
fontInfo(self) → QFontInfo
fontMetrics(self) → QFontMetrics
foregroundRole(self) → QPalette.ColorRole
frameGeometry(self) → QRect
frameRect(self) → QRect
frameShadow(self) → QFrame.Shadow
frameShape(self) → QFrame.Shape
frameSize(self) → QSize
frameStyle(self) → int
frameWidth(self) → int
geometry(self) → QRect
getContentsMargins(self) → Tuple[int, int, int, int]
grab(self, rectangle: QRect = QRect(QPoint(0, 0), QSize(-1, -1))) → QPixmap
grabGesture(self, Qt.GestureType, flags: Union[Qt.GestureFlags, Qt.GestureFlag] = Qt.GestureFlags())
grabKeyboard(self)
grabMouse(self)

grabMouse(self, Union[QCursor, Qt.CursorShape])

grabShortcut(self, Union[QKeySequence, QKeySequence.StandardKey, str, int], context: Qt.ShortcutContext = Qt.WindowShortcut) → int
graphicsEffect(self) → QGraphicsEffect
graphicsProxyWidget(self) → QGraphicsProxyWidget
hasFocus(self) → bool
hasHeightForWidth(self) → bool
hasMouseTracking(self) → bool
hasTabletTracking(self) → bool
height(self) → int
heightForWidth(self, int) → int
heightMM(self) → int
hide(self)
hideEvent(self, QHideEvent)
inherits(self, str) → bool
initPainter(self, QPainter)
initStyleOption(self, QStyleOptionFrame)
inputMethodEvent(self, QInputMethodEvent)
inputMethodHints(self) → Qt.InputMethodHints
inputMethodQuery(self, Qt.InputMethodQuery) → Any
insertAction(self, QAction, QAction)
insertActions(self, QAction, Iterable[QAction])
installEventFilter(self, QObject)
isActiveWindow(self) → bool
isAncestorOf(self, QWidget) → bool
isEnabled(self) → bool
isEnabledTo(self, QWidget) → bool
isFullScreen(self) → bool
isHidden(self) → bool
isLeftToRight(self) → bool
isMaximized(self) → bool
isMinimized(self) → bool
isModal(self) → bool
isRightToLeft(self) → bool
isSignalConnected(self, QMetaMethod) → bool
isVisible(self) → bool
isVisibleTo(self, QWidget) → bool
isWidgetType(self) → bool
isWindow(self) → bool
isWindowModified(self) → bool
isWindowType(self) → bool
keyPressEvent(self, QKeyEvent)
keyReleaseEvent(self, QKeyEvent)
keyboardGrabber() → QWidget
killTimer(self, int)
layoutDirection(self) → Qt.LayoutDirection
leaveEvent(self, QEvent)
lineWidth(self) → int
locale(self) → QLocale
logicalDpiX(self) → int
logicalDpiY(self) → int
lower(self)
mapFrom(self, QWidget, QPoint) → QPoint
mapFromGlobal(self, QPoint) → QPoint
mapFromParent(self, QPoint) → QPoint
mapTo(self, QWidget, QPoint) → QPoint
mapToGlobal(self, QPoint) → QPoint
mapToParent(self, QPoint) → QPoint
mask(self) → QRegion
maximumHeight(self) → int
maximumSize(self) → QSize
maximumWidth(self) → int
metaObject(self) → QMetaObject
metric(self, QPaintDevice.PaintDeviceMetric) → int
midLineWidth(self) → int
minimumHeight(self) → int
minimumSize(self) → QSize
minimumSizeHint(self) → QSize
minimumWidth(self) → int
mouseDoubleClickEvent(self, QMouseEvent)
mouseGrabber() → QWidget
mouseMoveEvent(self, QMouseEvent)
mousePressEvent(self, QMouseEvent)
mouseReleaseEvent(self, QMouseEvent)
move(self, QPoint)

move(self, int, int)

moveEvent(self, QMoveEvent)
moveToThread(self, QThread)
nativeEvent(self, Union[QByteArray, bytes, bytearray], sip.voidptr) → Tuple[bool, int]
nativeParentWidget(self) → QWidget
nextInFocusChain(self) → QWidget
normalGeometry(self) → QRect
objectName(self) → str
objectNameChanged

objectNameChanged(self, str) [signal]

overrideWindowFlags(self, Union[Qt.WindowFlags, Qt.WindowType])
overrideWindowState(self, Union[Qt.WindowStates, Qt.WindowState])
paintEngine(self) → QPaintEngine
paintEvent(self, QPaintEvent)
paintingActive(self) → bool
palette(self) → QPalette
parent(self) → QObject
parentWidget(self) → QWidget
physicalDpiX(self) → int
physicalDpiY(self) → int
pos(self) → QPoint
previousInFocusChain(self) → QWidget
property(self, str) → Any
pyqtConfigure(...)

Each keyword argument is either the name of a Qt property or a Qt signal. For properties the property is set to the given value which should be of an appropriate type. For signals the signal is connected to the given value which should be a callable.

raise_(self)
receivers(self, PYQT_SIGNAL) → int
rect(self) → QRect
releaseKeyboard(self)
releaseMouse(self)
releaseShortcut(self, int)
removeAction(self, QAction)
removeEventFilter(self, QObject)
render(self, QPaintDevice, targetOffset: QPoint = QPoint(), sourceRegion: QRegion = QRegion(), flags: Union[QWidget.RenderFlags, QWidget.RenderFlag] = QWidget.RenderFlags(QWidget.DrawWindowBackground|QWidget.DrawChildren))

render(self, QPainter, targetOffset: QPoint = QPoint(), sourceRegion: QRegion = QRegion(), flags: Union[QWidget.RenderFlags, QWidget.RenderFlag] = QWidget.RenderFlags(QWidget.DrawWindowBackground|QWidget.DrawChildren))

repaint(self)

repaint(self, int, int, int, int) repaint(self, QRect) repaint(self, QRegion)

resize(self, QSize)

resize(self, int, int)

resizeEvent(self, QResizeEvent)
restoreGeometry(self, Union[QByteArray, bytes, bytearray]) → bool
saveGeometry(self) → QByteArray
scroll(self, int, int)

scroll(self, int, int, QRect)

sender(self) → QObject
senderSignalIndex(self) → int
setAcceptDrops(self, bool)
setAccessibleDescription(self, str)
setAccessibleName(self, str)
setAttribute(self, Qt.WidgetAttribute, on: bool = True)
setAutoFillBackground(self, bool)
setBackgroundRole(self, QPalette.ColorRole)
setBaseSize(self, int, int)

setBaseSize(self, QSize)

setContentsMargins(self, int, int, int, int)

setContentsMargins(self, QMargins)

setContextMenuPolicy(self, Qt.ContextMenuPolicy)
setCursor(self, Union[QCursor, Qt.CursorShape])
setDisabled(self, bool)
setEnabled(self, bool)
setFixedHeight(self, int)
setFixedSize(self, QSize)

setFixedSize(self, int, int)

setFixedWidth(self, int)
setFocus(self)

setFocus(self, Qt.FocusReason)

setFocusPolicy(self, Qt.FocusPolicy)
setFocusProxy(self, QWidget)
setFont(self, QFont)
setForegroundRole(self, QPalette.ColorRole)
setFrameRect(self, QRect)
setFrameShadow(self, QFrame.Shadow)
setFrameShape(self, QFrame.Shape)
setFrameStyle(self, int)
setGeometry(self, QRect)

setGeometry(self, int, int, int, int)

setGraphicsEffect(self, QGraphicsEffect)
setHidden(self, bool)
setInputMethodHints(self, Union[Qt.InputMethodHints, Qt.InputMethodHint])
setLayout(self, QLayout)
setLayoutDirection(self, Qt.LayoutDirection)
setLineWidth(self, int)
setLocale(self, QLocale)
setMask(self, QBitmap)

setMask(self, QRegion)

setMaximumHeight(self, int)
setMaximumSize(self, int, int)

setMaximumSize(self, QSize)

setMaximumWidth(self, int)
setMidLineWidth(self, int)
setMinimumHeight(self, int)
setMinimumSize(self, int, int)

setMinimumSize(self, QSize)

setMinimumWidth(self, int)
setMouseTracking(self, bool)
setObjectName(self, str)
setPalette(self, QPalette)
setParent(self, QWidget)

setParent(self, QWidget, Union[Qt.WindowFlags, Qt.WindowType])

setProperty(self, str, Any) → bool
setShortcutAutoRepeat(self, int, enabled: bool = True)
setShortcutEnabled(self, int, enabled: bool = True)
setSizeIncrement(self, int, int)

setSizeIncrement(self, QSize)

setSizePolicy(self, QSizePolicy)

setSizePolicy(self, QSizePolicy.Policy, QSizePolicy.Policy)

setStatusTip(self, str)
setStyle(self, QStyle)
setStyleSheet(self, str)
setTabOrder(QWidget, QWidget)
setTabletTracking(self, bool)
setToolTip(self, str)
setToolTipDuration(self, int)
setUpdatesEnabled(self, bool)
setVisible(self, bool)
setWhatsThis(self, str)
setWindowFilePath(self, str)
setWindowFlag(self, Qt.WindowType, on: bool = True)
setWindowFlags(self, Union[Qt.WindowFlags, Qt.WindowType])
setWindowIcon(self, QIcon)
setWindowIconText(self, str)
setWindowModality(self, Qt.WindowModality)
setWindowModified(self, bool)
setWindowOpacity(self, float)
setWindowRole(self, str)
setWindowState(self, Union[Qt.WindowStates, Qt.WindowState])
setWindowTitle(self, str)
sharedPainter(self) → QPainter
showEvent(self, QShowEvent)
showFullScreen(self)
showMaximized(self)
showMinimized(self)
showNormal(self)
signalsBlocked(self) → bool
size(self) → QSize
sizeHint(self) → QSize
sizeIncrement(self) → QSize
sizePolicy(self) → QSizePolicy
stackUnder(self, QWidget)
startTimer(self, int, timerType: Qt.TimerType = Qt.CoarseTimer) → int
staticMetaObject = <PyQt5.QtCore.QMetaObject object>
statusTip(self) → str
style(self) → QStyle
styleSheet(self) → str
tabletEvent(self, QTabletEvent)
testAttribute(self, Qt.WidgetAttribute) → bool
thread(self) → QThread
timerEvent(self, QTimerEvent)
toolTip(self) → str
toolTipDuration(self) → int
tr(self, str, disambiguation: str = None, n: int = -1) → str
underMouse(self) → bool
ungrabGesture(self, Qt.GestureType)
unsetCursor(self)
unsetLayoutDirection(self)
unsetLocale(self)
update(self)

update(self, QRect) update(self, QRegion) update(self, int, int, int, int)

updateGeometry(self)
updateMicroFocus(self)
updatesEnabled(self) → bool
visibleRegion(self) → QRegion
whatsThis(self) → str
wheelEvent(self, QWheelEvent)
width(self) → int
widthMM(self) → int
winId(self) → sip.voidptr
window(self) → QWidget
windowFilePath(self) → str
windowFlags(self) → Qt.WindowFlags
windowHandle(self) → QWindow
windowIcon(self) → QIcon
windowIconChanged

windowIconChanged(self, QIcon) [signal]

windowIconText(self) → str
windowIconTextChanged

windowIconTextChanged(self, str) [signal]

windowModality(self) → Qt.WindowModality
windowOpacity(self) → float
windowRole(self) → str
windowState(self) → Qt.WindowStates
windowTitle(self) → str
windowTitleChanged

windowTitleChanged(self, str) [signal]

windowType(self) → Qt.WindowType
x(self) → int
y(self) → int
class schrodinger.ui.qt.structure2d.structure_scene

Bases: PyQt5.QtWidgets.QGraphicsScene

Scene which holds the structure_view object

AllLayers = 65535
BackgroundLayer = 2
BspTreeIndex = 0
ForegroundLayer = 4
class ItemIndexMethod

Bases: int

__init__ = <method-wrapper '__init__' of sip.enumtype object at 0x1e14918>
ItemLayer = 1
NoIndex = -1
class SceneLayer

Bases: int

__init__ = <method-wrapper '__init__' of sip.enumtype object at 0x1e14cc8>
class SceneLayers

Bases: sip.simplewrapper

QGraphicsScene.SceneLayers(Union[QGraphicsScene.SceneLayers, QGraphicsScene.SceneLayer]) QGraphicsScene.SceneLayers(QGraphicsScene.SceneLayers)

__init__

Initialize self. See help(type(self)) for accurate signature.

__init__

Initialize self. See help(type(self)) for accurate signature.

activePanel(self) → QGraphicsItem
activeWindow(self) → QGraphicsWidget
addEllipse(self, QRectF, pen: Union[QPen, QColor, Qt.GlobalColor, QGradient] = QPen(), brush: Union[QBrush, QColor, Qt.GlobalColor, QGradient] = QBrush()) → QGraphicsEllipseItem

addEllipse(self, float, float, float, float, pen: Union[QPen, QColor, Qt.GlobalColor, QGradient] = QPen(), brush: Union[QBrush, QColor, Qt.GlobalColor, QGradient] = QBrush()) -> QGraphicsEllipseItem

addItem(self, QGraphicsItem)
addLine(self, QLineF, pen: Union[QPen, QColor, Qt.GlobalColor, QGradient] = QPen()) → QGraphicsLineItem

addLine(self, float, float, float, float, pen: Union[QPen, QColor, Qt.GlobalColor, QGradient] = QPen()) -> QGraphicsLineItem

addPath(self, QPainterPath, pen: Union[QPen, QColor, Qt.GlobalColor, QGradient] = QPen(), brush: Union[QBrush, QColor, Qt.GlobalColor, QGradient] = QBrush()) → QGraphicsPathItem
addPixmap(self, QPixmap) → QGraphicsPixmapItem
addPolygon(self, QPolygonF, pen: Union[QPen, QColor, Qt.GlobalColor, QGradient] = QPen(), brush: Union[QBrush, QColor, Qt.GlobalColor, QGradient] = QBrush()) → QGraphicsPolygonItem
addRect(self, QRectF, pen: Union[QPen, QColor, Qt.GlobalColor, QGradient] = QPen(), brush: Union[QBrush, QColor, Qt.GlobalColor, QGradient] = QBrush()) → QGraphicsRectItem

addRect(self, float, float, float, float, pen: Union[QPen, QColor, Qt.GlobalColor, QGradient] = QPen(), brush: Union[QBrush, QColor, Qt.GlobalColor, QGradient] = QBrush()) -> QGraphicsRectItem

addSimpleText(self, str, font: QFont = QFont()) → QGraphicsSimpleTextItem
addText(self, str, font: QFont = QFont()) → QGraphicsTextItem
addWidget(self, QWidget, flags: Union[Qt.WindowFlags, Qt.WindowType] = Qt.WindowFlags()) → QGraphicsProxyWidget
advance(self)
backgroundBrush(self) → QBrush
blockSignals(self, bool) → bool
bspTreeDepth(self) → int
changed

changed(self, Iterable[QRectF]) [signal]

childEvent(self, QChildEvent)
children(self) → List[QObject]
clear(self)
clearFocus(self)
clearSelection(self)
collidingItems(self, QGraphicsItem, mode: Qt.ItemSelectionMode = Qt.IntersectsItemShape) → List[QGraphicsItem]
connectNotify(self, QMetaMethod)
contextMenuEvent(self, QGraphicsSceneContextMenuEvent)
createItemGroup(self, Iterable[QGraphicsItem]) → QGraphicsItemGroup
customEvent(self, QEvent)
deleteLater(self)
destroyItemGroup(self, QGraphicsItemGroup)
destroyed

destroyed(self, object: QObject = None) [signal]

disconnect(self)
disconnectNotify(self, QMetaMethod)
dragEnterEvent(self, QGraphicsSceneDragDropEvent)
dragLeaveEvent(self, QGraphicsSceneDragDropEvent)
dragMoveEvent(self, QGraphicsSceneDragDropEvent)
drawBackground(self, QPainter, QRectF)
drawForeground(self, QPainter, QRectF)
dropEvent(self, QGraphicsSceneDragDropEvent)
dumpObjectInfo(self)
dumpObjectTree(self)
dynamicPropertyNames(self) → List[QByteArray]
event(self, QEvent) → bool
eventFilter(self, QObject, QEvent) → bool
findChild(self, type, name: str = '', options: Union[Qt.FindChildOptions, Qt.FindChildOption] = Qt.FindChildrenRecursively) → QObject

findChild(self, Tuple, name: str = ‘’, options: Union[Qt.FindChildOptions, Qt.FindChildOption] = Qt.FindChildrenRecursively) -> QObject

findChildren(self, type, name: str = '', options: Union[Qt.FindChildOptions, Qt.FindChildOption] = Qt.FindChildrenRecursively) → List[QObject]

findChildren(self, Tuple, name: str = ‘’, options: Union[Qt.FindChildOptions, Qt.FindChildOption] = Qt.FindChildrenRecursively) -> List[QObject] findChildren(self, type, QRegExp, options: Union[Qt.FindChildOptions, Qt.FindChildOption] = Qt.FindChildrenRecursively) -> List[QObject] findChildren(self, Tuple, QRegExp, options: Union[Qt.FindChildOptions, Qt.FindChildOption] = Qt.FindChildrenRecursively) -> List[QObject] findChildren(self, type, QRegularExpression, options: Union[Qt.FindChildOptions, Qt.FindChildOption] = Qt.FindChildrenRecursively) -> List[QObject] findChildren(self, Tuple, QRegularExpression, options: Union[Qt.FindChildOptions, Qt.FindChildOption] = Qt.FindChildrenRecursively) -> List[QObject]

focusInEvent(self, QFocusEvent)
focusItem(self) → QGraphicsItem
focusItemChanged

focusItemChanged(self, QGraphicsItem, QGraphicsItem, Qt.FocusReason) [signal]

focusNextPrevChild(self, bool) → bool
focusOnTouch(self) → bool
focusOutEvent(self, QFocusEvent)
font(self) → QFont
foregroundBrush(self) → QBrush
hasFocus(self) → bool
height(self) → float
helpEvent(self, QGraphicsSceneHelpEvent)
inherits(self, str) → bool
inputMethodEvent(self, QInputMethodEvent)
inputMethodQuery(self, Qt.InputMethodQuery) → Any
installEventFilter(self, QObject)
invalidate(self, rect: QRectF = QRectF(), layers: Union[QGraphicsScene.SceneLayers, QGraphicsScene.SceneLayer] = QGraphicsScene.AllLayers)

invalidate(self, float, float, float, float, layers: Union[QGraphicsScene.SceneLayers, QGraphicsScene.SceneLayer] = QGraphicsScene.AllLayers)

isActive(self) → bool
isSignalConnected(self, QMetaMethod) → bool
isWidgetType(self) → bool
isWindowType(self) → bool
itemAt(self, Union[QPointF, QPoint], QTransform) → QGraphicsItem

itemAt(self, float, float, QTransform) -> QGraphicsItem

itemIndexMethod(self) → QGraphicsScene.ItemIndexMethod
items(self, order: Qt.SortOrder = Qt.DescendingOrder) → List[QGraphicsItem]

items(self, Union[QPointF, QPoint], mode: Qt.ItemSelectionMode = Qt.IntersectsItemShape, order: Qt.SortOrder = Qt.DescendingOrder, deviceTransform: QTransform = QTransform()) -> List[QGraphicsItem] items(self, QRectF, mode: Qt.ItemSelectionMode = Qt.IntersectsItemShape, order: Qt.SortOrder = Qt.DescendingOrder, deviceTransform: QTransform = QTransform()) -> List[QGraphicsItem] items(self, QPolygonF, mode: Qt.ItemSelectionMode = Qt.IntersectsItemShape, order: Qt.SortOrder = Qt.DescendingOrder, deviceTransform: QTransform = QTransform()) -> List[QGraphicsItem] items(self, QPainterPath, mode: Qt.ItemSelectionMode = Qt.IntersectsItemShape, order: Qt.SortOrder = Qt.DescendingOrder, deviceTransform: QTransform = QTransform()) -> List[QGraphicsItem] items(self, float, float, float, float, Qt.ItemSelectionMode, Qt.SortOrder, deviceTransform: QTransform = QTransform()) -> List[QGraphicsItem]

itemsBoundingRect(self) → QRectF
keyPressEvent(self, QKeyEvent)
keyReleaseEvent(self, QKeyEvent)
killTimer(self, int)
metaObject(self) → QMetaObject
minimumRenderSize(self) → float
mouseDoubleClickEvent(self, QGraphicsSceneMouseEvent)
mouseGrabberItem(self) → QGraphicsItem
mouseMoveEvent(self, QGraphicsSceneMouseEvent)
mousePressEvent(self, QGraphicsSceneMouseEvent)
mouseReleaseEvent(self, QGraphicsSceneMouseEvent)
moveToThread(self, QThread)
objectName(self) → str
objectNameChanged

objectNameChanged(self, str) [signal]

palette(self) → QPalette
parent(self) → QObject
property(self, str) → Any
pyqtConfigure(...)

Each keyword argument is either the name of a Qt property or a Qt signal. For properties the property is set to the given value which should be of an appropriate type. For signals the signal is connected to the given value which should be a callable.

receivers(self, PYQT_SIGNAL) → int
removeEventFilter(self, QObject)
removeItem(self, QGraphicsItem)
render(self, QPainter, target: QRectF = QRectF(), source: QRectF = QRectF(), mode: Qt.AspectRatioMode = Qt.KeepAspectRatio)
sceneRect(self) → QRectF
sceneRectChanged

sceneRectChanged(self, QRectF) [signal]

selectedItems(self) → List[QGraphicsItem]
selectionArea(self) → QPainterPath
selectionChanged

selectionChanged(self) [signal]

sendEvent(self, QGraphicsItem, QEvent) → bool
sender(self) → QObject
senderSignalIndex(self) → int
setActivePanel(self, QGraphicsItem)
setActiveWindow(self, QGraphicsWidget)
setBackgroundBrush(self, Union[QBrush, QColor, Qt.GlobalColor, QGradient])
setBspTreeDepth(self, int)
setFocus(self, focusReason: Qt.FocusReason = Qt.OtherFocusReason)
setFocusItem(self, QGraphicsItem, focusReason: Qt.FocusReason = Qt.OtherFocusReason)
setFocusOnTouch(self, bool)
setFont(self, QFont)
setForegroundBrush(self, Union[QBrush, QColor, Qt.GlobalColor, QGradient])
setItemIndexMethod(self, QGraphicsScene.ItemIndexMethod)
setMinimumRenderSize(self, float)
setObjectName(self, str)
setPalette(self, QPalette)
setParent(self, QObject)
setProperty(self, str, Any) → bool
setSceneRect(self, QRectF)

setSceneRect(self, float, float, float, float)

setSelectionArea(self, QPainterPath, QTransform)

setSelectionArea(self, QPainterPath, mode: Qt.ItemSelectionMode = Qt.IntersectsItemShape, deviceTransform: QTransform = QTransform()) setSelectionArea(self, QPainterPath, Qt.ItemSelectionOperation, mode: Qt.ItemSelectionMode = Qt.IntersectsItemShape, deviceTransform: QTransform = QTransform())

setStickyFocus(self, bool)
setStyle(self, QStyle)
signalsBlocked(self) → bool
startTimer(self, int, timerType: Qt.TimerType = Qt.CoarseTimer) → int
staticMetaObject = <PyQt5.QtCore.QMetaObject object>
stickyFocus(self) → bool
style(self) → QStyle
thread(self) → QThread
timerEvent(self, QTimerEvent)
tr(self, str, disambiguation: str = None, n: int = -1) → str
update(self, rect: QRectF = QRectF())

update(self, float, float, float, float)

views(self) → List[QGraphicsView]
wheelEvent(self, QGraphicsSceneWheelEvent)
width(self) → float
class schrodinger.ui.qt.structure2d.structure_view(scene)

Bases: PyQt5.QtWidgets.QGraphicsView

View which holds a structure_item object

atom_clicked
bond_clicked
__init__(scene)

Initialize self. See help(type(self)) for accurate signature.

wheelEvent(self, QWheelEvent)
resizeEvent(self, QResizeEvent)
AdjustIgnored = 0
AdjustToContents = 2
AdjustToContentsOnFirstShow = 1
AnchorUnderMouse = 2
AnchorViewCenter = 1
BoundingRectViewportUpdate = 4
Box = 1
CacheBackground = 1
class CacheMode

Bases: sip.simplewrapper

QGraphicsView.CacheMode(Union[QGraphicsView.CacheMode, QGraphicsView.CacheModeFlag]) QGraphicsView.CacheMode(QGraphicsView.CacheMode)

__init__

Initialize self. See help(type(self)) for accurate signature.

class CacheModeFlag

Bases: int

__init__ = <method-wrapper '__init__' of sip.enumtype object at 0x1e19ce8>
CacheNone = 0
DontAdjustForAntialiasing = 4
DontClipPainter = 1
DontSavePainterState = 2
class DragMode

Bases: int

__init__ = <method-wrapper '__init__' of sip.enumtype object at 0x1e1a098>
DrawChildren = 2
DrawWindowBackground = 1
FullViewportUpdate = 0
HLine = 4
IgnoreMask = 4
MinimalViewportUpdate = 1
NoAnchor = 0
NoDrag = 0
NoFrame = 0
NoViewportUpdate = 3
class OptimizationFlag

Bases: int

__init__ = <method-wrapper '__init__' of sip.enumtype object at 0x1e1a448>
class OptimizationFlags

Bases: sip.simplewrapper

QGraphicsView.OptimizationFlags(Union[QGraphicsView.OptimizationFlags, QGraphicsView.OptimizationFlag]) QGraphicsView.OptimizationFlags(QGraphicsView.OptimizationFlags)

__init__

Initialize self. See help(type(self)) for accurate signature.

class PaintDeviceMetric

Bases: int

__init__ = <method-wrapper '__init__' of sip.enumtype object at 0x1e51628>
Panel = 2
PdmDepth = 6
PdmDevicePixelRatio = 11
PdmDevicePixelRatioScaled = 12
PdmDpiX = 7
PdmDpiY = 8
PdmHeight = 2
PdmHeightMM = 4
PdmNumColors = 5
PdmPhysicalDpiX = 9
PdmPhysicalDpiY = 10
PdmWidth = 1
PdmWidthMM = 3
Plain = 16
Raised = 32
class RenderFlag

Bases: int

__init__ = <method-wrapper '__init__' of sip.enumtype object at 0x1e8d8a8>
class RenderFlags

Bases: sip.simplewrapper

QWidget.RenderFlags(Union[QWidget.RenderFlags, QWidget.RenderFlag]) QWidget.RenderFlags(QWidget.RenderFlags)

__init__

Initialize self. See help(type(self)) for accurate signature.

RubberBandDrag = 2
ScrollHandDrag = 1
class Shadow

Bases: int

__init__ = <method-wrapper '__init__' of sip.enumtype object at 0x1e08da8>
Shadow_Mask = 240
class Shape

Bases: int

__init__ = <method-wrapper '__init__' of sip.enumtype object at 0x1e09158>
Shape_Mask = 15
class SizeAdjustPolicy

Bases: int

__init__ = <method-wrapper '__init__' of sip.enumtype object at 0x1bc1378>
SmartViewportUpdate = 2
class StyleMask

Bases: int

__init__ = <method-wrapper '__init__' of sip.enumtype object at 0x1e09508>
StyledPanel = 6
Sunken = 48
VLine = 5
class ViewportAnchor

Bases: int

__init__ = <method-wrapper '__init__' of sip.enumtype object at 0x1e1b028>
class ViewportUpdateMode

Bases: int

__init__ = <method-wrapper '__init__' of sip.enumtype object at 0x1e1b3d8>
WinPanel = 3
acceptDrops(self) → bool
accessibleDescription(self) → str
accessibleName(self) → str
actionEvent(self, QActionEvent)
actions(self) → List[QAction]
activateWindow(self)
addAction(self, QAction)
addActions(self, Iterable[QAction])
addScrollBarWidget(self, QWidget, Union[Qt.Alignment, Qt.AlignmentFlag])
adjustSize(self)
alignment(self) → Qt.Alignment
autoFillBackground(self) → bool
backgroundBrush(self) → QBrush
backgroundRole(self) → QPalette.ColorRole
baseSize(self) → QSize
blockSignals(self, bool) → bool
cacheMode(self) → QGraphicsView.CacheMode
centerOn(self, Union[QPointF, QPoint])

centerOn(self, QGraphicsItem) centerOn(self, float, float)

changeEvent(self, QEvent)
childAt(self, QPoint) → QWidget

childAt(self, int, int) -> QWidget

childEvent(self, QChildEvent)
children(self) → List[QObject]
childrenRect(self) → QRect
childrenRegion(self) → QRegion
clearFocus(self)
clearMask(self)
close(self) → bool
closeEvent(self, QCloseEvent)
colorCount(self) → int
connectNotify(self, QMetaMethod)
contentsMargins(self) → QMargins
contentsRect(self) → QRect
contextMenuEvent(self, QContextMenuEvent)
contextMenuPolicy(self) → Qt.ContextMenuPolicy
cornerWidget(self) → QWidget
create(self, window: sip.voidptr = 0, initializeWindow: bool = True, destroyOldWindow: bool = True)
createWindowContainer(QWindow, parent: QWidget = None, flags: Union[Qt.WindowFlags, Qt.WindowType] = 0) → QWidget
cursor(self) → QCursor
customContextMenuRequested

customContextMenuRequested(self, QPoint) [signal]

customEvent(self, QEvent)
deleteLater(self)
depth(self) → int
destroy(self, destroyWindow: bool = True, destroySubWindows: bool = True)
destroyed

destroyed(self, object: QObject = None) [signal]

devType(self) → int
devicePixelRatio(self) → int
devicePixelRatioF(self) → float
devicePixelRatioFScale() → float
disconnect(self)
disconnectNotify(self, QMetaMethod)
dragEnterEvent(self, QDragEnterEvent)
dragLeaveEvent(self, QDragLeaveEvent)
dragMode(self) → QGraphicsView.DragMode
dragMoveEvent(self, QDragMoveEvent)
drawBackground(self, QPainter, QRectF)
drawForeground(self, QPainter, QRectF)
drawFrame(self, QPainter)
dropEvent(self, QDropEvent)
dumpObjectInfo(self)
dumpObjectTree(self)
dynamicPropertyNames(self) → List[QByteArray]
effectiveWinId(self) → sip.voidptr
ensurePolished(self)
ensureVisible(self, QRectF, xMargin: int = 50, yMargin: int = 50)

ensureVisible(self, QGraphicsItem, xMargin: int = 50, yMargin: int = 50) ensureVisible(self, float, float, float, float, xMargin: int = 50, yMargin: int = 50)

enterEvent(self, QEvent)
event(self, QEvent) → bool
eventFilter(self, QObject, QEvent) → bool
find(sip.voidptr) → QWidget
findChild(self, type, name: str = '', options: Union[Qt.FindChildOptions, Qt.FindChildOption] = Qt.FindChildrenRecursively) → QObject

findChild(self, Tuple, name: str = ‘’, options: Union[Qt.FindChildOptions, Qt.FindChildOption] = Qt.FindChildrenRecursively) -> QObject

findChildren(self, type, name: str = '', options: Union[Qt.FindChildOptions, Qt.FindChildOption] = Qt.FindChildrenRecursively) → List[QObject]

findChildren(self, Tuple, name: str = ‘’, options: Union[Qt.FindChildOptions, Qt.FindChildOption] = Qt.FindChildrenRecursively) -> List[QObject] findChildren(self, type, QRegExp, options: Union[Qt.FindChildOptions, Qt.FindChildOption] = Qt.FindChildrenRecursively) -> List[QObject] findChildren(self, Tuple, QRegExp, options: Union[Qt.FindChildOptions, Qt.FindChildOption] = Qt.FindChildrenRecursively) -> List[QObject] findChildren(self, type, QRegularExpression, options: Union[Qt.FindChildOptions, Qt.FindChildOption] = Qt.FindChildrenRecursively) -> List[QObject] findChildren(self, Tuple, QRegularExpression, options: Union[Qt.FindChildOptions, Qt.FindChildOption] = Qt.FindChildrenRecursively) -> List[QObject]

fitInView(self, QRectF, mode: Qt.AspectRatioMode = Qt.IgnoreAspectRatio)

fitInView(self, QGraphicsItem, mode: Qt.AspectRatioMode = Qt.IgnoreAspectRatio) fitInView(self, float, float, float, float, mode: Qt.AspectRatioMode = Qt.IgnoreAspectRatio)

focusInEvent(self, QFocusEvent)
focusNextChild(self) → bool
focusNextPrevChild(self, bool) → bool
focusOutEvent(self, QFocusEvent)
focusPolicy(self) → Qt.FocusPolicy
focusPreviousChild(self) → bool
focusProxy(self) → QWidget
focusWidget(self) → QWidget
font(self) → QFont
fontInfo(self) → QFontInfo
fontMetrics(self) → QFontMetrics
foregroundBrush(self) → QBrush
foregroundRole(self) → QPalette.ColorRole
frameGeometry(self) → QRect
frameRect(self) → QRect
frameShadow(self) → QFrame.Shadow
frameShape(self) → QFrame.Shape
frameSize(self) → QSize
frameStyle(self) → int
frameWidth(self) → int
geometry(self) → QRect
getContentsMargins(self) → Tuple[int, int, int, int]
grab(self, rectangle: QRect = QRect(QPoint(0, 0), QSize(-1, -1))) → QPixmap
grabGesture(self, Qt.GestureType, flags: Union[Qt.GestureFlags, Qt.GestureFlag] = Qt.GestureFlags())
grabKeyboard(self)
grabMouse(self)

grabMouse(self, Union[QCursor, Qt.CursorShape])

grabShortcut(self, Union[QKeySequence, QKeySequence.StandardKey, str, int], context: Qt.ShortcutContext = Qt.WindowShortcut) → int
graphicsEffect(self) → QGraphicsEffect
graphicsProxyWidget(self) → QGraphicsProxyWidget
hasFocus(self) → bool
hasHeightForWidth(self) → bool
hasMouseTracking(self) → bool
hasTabletTracking(self) → bool
height(self) → int
heightForWidth(self, int) → int
heightMM(self) → int
hide(self)
hideEvent(self, QHideEvent)
horizontalScrollBar(self) → QScrollBar
horizontalScrollBarPolicy(self) → Qt.ScrollBarPolicy
inherits(self, str) → bool
initPainter(self, QPainter)
initStyleOption(self, QStyleOptionFrame)
inputMethodEvent(self, QInputMethodEvent)
inputMethodHints(self) → Qt.InputMethodHints
inputMethodQuery(self, Qt.InputMethodQuery) → Any
insertAction(self, QAction, QAction)
insertActions(self, QAction, Iterable[QAction])
installEventFilter(self, QObject)
invalidateScene(self, rect: QRectF = QRectF(), layers: Union[QGraphicsScene.SceneLayers, QGraphicsScene.SceneLayer] = QGraphicsScene.AllLayers)
isActiveWindow(self) → bool
isAncestorOf(self, QWidget) → bool
isEnabled(self) → bool
isEnabledTo(self, QWidget) → bool
isFullScreen(self) → bool
isHidden(self) → bool
isInteractive(self) → bool
isLeftToRight(self) → bool
isMaximized(self) → bool
isMinimized(self) → bool
isModal(self) → bool
isRightToLeft(self) → bool
isSignalConnected(self, QMetaMethod) → bool
isTransformed(self) → bool
isVisible(self) → bool
isVisibleTo(self, QWidget) → bool
isWidgetType(self) → bool
isWindow(self) → bool
isWindowModified(self) → bool
isWindowType(self) → bool
itemAt(self, QPoint) → QGraphicsItem

itemAt(self, int, int) -> QGraphicsItem

items(self) → List[QGraphicsItem]

items(self, QPoint) -> List[QGraphicsItem] items(self, int, int) -> List[QGraphicsItem] items(self, int, int, int, int, mode: Qt.ItemSelectionMode = Qt.IntersectsItemShape) -> List[QGraphicsItem] items(self, QRect, mode: Qt.ItemSelectionMode = Qt.IntersectsItemShape) -> List[QGraphicsItem] items(self, QPolygon, mode: Qt.ItemSelectionMode = Qt.IntersectsItemShape) -> List[QGraphicsItem] items(self, QPainterPath, mode: Qt.ItemSelectionMode = Qt.IntersectsItemShape) -> List[QGraphicsItem]

keyPressEvent(self, QKeyEvent)
keyReleaseEvent(self, QKeyEvent)
keyboardGrabber() → QWidget
killTimer(self, int)
layout(self) → QLayout
layoutDirection(self) → Qt.LayoutDirection
leaveEvent(self, QEvent)
lineWidth(self) → int
locale(self) → QLocale
logicalDpiX(self) → int
logicalDpiY(self) → int
lower(self)
mapFrom(self, QWidget, QPoint) → QPoint
mapFromGlobal(self, QPoint) → QPoint
mapFromParent(self, QPoint) → QPoint
mapFromScene(self, Union[QPointF, QPoint]) → QPoint

mapFromScene(self, QRectF) -> QPolygon mapFromScene(self, QPolygonF) -> QPolygon mapFromScene(self, QPainterPath) -> QPainterPath mapFromScene(self, float, float) -> QPoint mapFromScene(self, float, float, float, float) -> QPolygon

mapTo(self, QWidget, QPoint) → QPoint
mapToGlobal(self, QPoint) → QPoint
mapToParent(self, QPoint) → QPoint
mapToScene(self, QPoint) → QPointF

mapToScene(self, QRect) -> QPolygonF mapToScene(self, QPolygon) -> QPolygonF mapToScene(self, QPainterPath) -> QPainterPath mapToScene(self, int, int) -> QPointF mapToScene(self, int, int, int, int) -> QPolygonF

mask(self) → QRegion
maximumHeight(self) → int
maximumSize(self) → QSize
maximumViewportSize(self) → QSize
maximumWidth(self) → int
metaObject(self) → QMetaObject
metric(self, QPaintDevice.PaintDeviceMetric) → int
midLineWidth(self) → int
minimumHeight(self) → int
minimumSize(self) → QSize
minimumSizeHint(self) → QSize
minimumWidth(self) → int
mouseDoubleClickEvent(self, QMouseEvent)
mouseGrabber() → QWidget
mouseMoveEvent(self, QMouseEvent)
mousePressEvent(self, QMouseEvent)
mouseReleaseEvent(self, QMouseEvent)
move(self, QPoint)

move(self, int, int)

moveEvent(self, QMoveEvent)
moveToThread(self, QThread)
nativeEvent(self, Union[QByteArray, bytes, bytearray], sip.voidptr) → Tuple[bool, int]
nativeParentWidget(self) → QWidget
nextInFocusChain(self) → QWidget
normalGeometry(self) → QRect
objectName(self) → str
objectNameChanged

objectNameChanged(self, str) [signal]

optimizationFlags(self) → QGraphicsView.OptimizationFlags
overrideWindowFlags(self, Union[Qt.WindowFlags, Qt.WindowType])
overrideWindowState(self, Union[Qt.WindowStates, Qt.WindowState])
paintEngine(self) → QPaintEngine
paintEvent(self, QPaintEvent)
paintingActive(self) → bool
palette(self) → QPalette
parent(self) → QObject
parentWidget(self) → QWidget
physicalDpiX(self) → int
physicalDpiY(self) → int
pos(self) → QPoint
previousInFocusChain(self) → QWidget
property(self, str) → Any
pyqtConfigure(...)

Each keyword argument is either the name of a Qt property or a Qt signal. For properties the property is set to the given value which should be of an appropriate type. For signals the signal is connected to the given value which should be a callable.

raise_(self)
receivers(self, PYQT_SIGNAL) → int
rect(self) → QRect
releaseKeyboard(self)
releaseMouse(self)
releaseShortcut(self, int)
removeAction(self, QAction)
removeEventFilter(self, QObject)
render(self, QPainter, target: QRectF = QRectF(), source: QRect = QRect(), mode: Qt.AspectRatioMode = Qt.KeepAspectRatio)
renderHints(self) → QPainter.RenderHints
repaint(self)

repaint(self, int, int, int, int) repaint(self, QRect) repaint(self, QRegion)

resetCachedContent(self)
resetTransform(self)
resize(self, QSize)

resize(self, int, int)

resizeAnchor(self) → QGraphicsView.ViewportAnchor
restoreGeometry(self, Union[QByteArray, bytes, bytearray]) → bool
rotate(self, float)
rubberBandChanged

rubberBandChanged(self, QRect, Union[QPointF, QPoint], Union[QPointF, QPoint]) [signal]

rubberBandRect(self) → QRect
rubberBandSelectionMode(self) → Qt.ItemSelectionMode
saveGeometry(self) → QByteArray
scale(self, float, float)
scene(self) → QGraphicsScene
sceneRect(self) → QRectF
scroll(self, int, int)

scroll(self, int, int, QRect)

scrollBarWidgets(self, Union[Qt.Alignment, Qt.AlignmentFlag]) → List[QWidget]
scrollContentsBy(self, int, int)
sender(self) → QObject
senderSignalIndex(self) → int
setAcceptDrops(self, bool)
setAccessibleDescription(self, str)
setAccessibleName(self, str)
setAlignment(self, Union[Qt.Alignment, Qt.AlignmentFlag])
setAttribute(self, Qt.WidgetAttribute, on: bool = True)
setAutoFillBackground(self, bool)
setBackgroundBrush(self, Union[QBrush, QColor, Qt.GlobalColor, QGradient])
setBackgroundRole(self, QPalette.ColorRole)
setBaseSize(self, int, int)

setBaseSize(self, QSize)

setCacheMode(self, Union[QGraphicsView.CacheMode, QGraphicsView.CacheModeFlag])
setContentsMargins(self, int, int, int, int)

setContentsMargins(self, QMargins)

setContextMenuPolicy(self, Qt.ContextMenuPolicy)
setCornerWidget(self, QWidget)
setCursor(self, Union[QCursor, Qt.CursorShape])
setDisabled(self, bool)
setDragMode(self, QGraphicsView.DragMode)
setEnabled(self, bool)
setFixedHeight(self, int)
setFixedSize(self, QSize)

setFixedSize(self, int, int)

setFixedWidth(self, int)
setFocus(self)

setFocus(self, Qt.FocusReason)

setFocusPolicy(self, Qt.FocusPolicy)
setFocusProxy(self, QWidget)
setFont(self, QFont)
setForegroundBrush(self, Union[QBrush, QColor, Qt.GlobalColor, QGradient])
setForegroundRole(self, QPalette.ColorRole)
setFrameRect(self, QRect)
setFrameShadow(self, QFrame.Shadow)
setFrameShape(self, QFrame.Shape)
setFrameStyle(self, int)
setGeometry(self, QRect)

setGeometry(self, int, int, int, int)

setGraphicsEffect(self, QGraphicsEffect)
setHidden(self, bool)
setHorizontalScrollBar(self, QScrollBar)
setHorizontalScrollBarPolicy(self, Qt.ScrollBarPolicy)
setInputMethodHints(self, Union[Qt.InputMethodHints, Qt.InputMethodHint])
setInteractive(self, bool)
setLayout(self, QLayout)
setLayoutDirection(self, Qt.LayoutDirection)
setLineWidth(self, int)
setLocale(self, QLocale)
setMask(self, QBitmap)

setMask(self, QRegion)

setMaximumHeight(self, int)
setMaximumSize(self, int, int)

setMaximumSize(self, QSize)

setMaximumWidth(self, int)
setMidLineWidth(self, int)
setMinimumHeight(self, int)
setMinimumSize(self, int, int)

setMinimumSize(self, QSize)

setMinimumWidth(self, int)
setMouseTracking(self, bool)
setObjectName(self, str)
setOptimizationFlag(self, QGraphicsView.OptimizationFlag, enabled: bool = True)
setOptimizationFlags(self, Union[QGraphicsView.OptimizationFlags, QGraphicsView.OptimizationFlag])
setPalette(self, QPalette)
setParent(self, QWidget)

setParent(self, QWidget, Union[Qt.WindowFlags, Qt.WindowType])

setProperty(self, str, Any) → bool
setRenderHint(self, QPainter.RenderHint, on: bool = True)
setRenderHints(self, Union[QPainter.RenderHints, QPainter.RenderHint])
setResizeAnchor(self, QGraphicsView.ViewportAnchor)
setRubberBandSelectionMode(self, Qt.ItemSelectionMode)
setScene(self, QGraphicsScene)
setSceneRect(self, QRectF)

setSceneRect(self, float, float, float, float)

setShortcutAutoRepeat(self, int, enabled: bool = True)
setShortcutEnabled(self, int, enabled: bool = True)
setSizeAdjustPolicy(self, QAbstractScrollArea.SizeAdjustPolicy)
setSizeIncrement(self, int, int)

setSizeIncrement(self, QSize)

setSizePolicy(self, QSizePolicy)

setSizePolicy(self, QSizePolicy.Policy, QSizePolicy.Policy)

setStatusTip(self, str)
setStyle(self, QStyle)
setStyleSheet(self, str)
setTabOrder(QWidget, QWidget)
setTabletTracking(self, bool)
setToolTip(self, str)
setToolTipDuration(self, int)
setTransform(self, QTransform, combine: bool = False)
setTransformationAnchor(self, QGraphicsView.ViewportAnchor)
setUpdatesEnabled(self, bool)
setVerticalScrollBar(self, QScrollBar)
setVerticalScrollBarPolicy(self, Qt.ScrollBarPolicy)
setViewport(self, QWidget)
setViewportMargins(self, int, int, int, int)

setViewportMargins(self, QMargins)

setViewportUpdateMode(self, QGraphicsView.ViewportUpdateMode)
setVisible(self, bool)
setWhatsThis(self, str)
setWindowFilePath(self, str)
setWindowFlag(self, Qt.WindowType, on: bool = True)
setWindowFlags(self, Union[Qt.WindowFlags, Qt.WindowType])
setWindowIcon(self, QIcon)
setWindowIconText(self, str)
setWindowModality(self, Qt.WindowModality)
setWindowModified(self, bool)
setWindowOpacity(self, float)
setWindowRole(self, str)
setWindowState(self, Union[Qt.WindowStates, Qt.WindowState])
setWindowTitle(self, str)
setupViewport(self, QWidget)
sharedPainter(self) → QPainter
shear(self, float, float)
show(self)
showEvent(self, QShowEvent)
showFullScreen(self)
showMaximized(self)
showMinimized(self)
showNormal(self)
signalsBlocked(self) → bool
size(self) → QSize
sizeAdjustPolicy(self) → QAbstractScrollArea.SizeAdjustPolicy
sizeHint(self) → QSize
sizeIncrement(self) → QSize
sizePolicy(self) → QSizePolicy
stackUnder(self, QWidget)
startTimer(self, int, timerType: Qt.TimerType = Qt.CoarseTimer) → int
staticMetaObject = <PyQt5.QtCore.QMetaObject object>
statusTip(self) → str
style(self) → QStyle
styleSheet(self) → str
tabletEvent(self, QTabletEvent)
testAttribute(self, Qt.WidgetAttribute) → bool
thread(self) → QThread
timerEvent(self, QTimerEvent)
toolTip(self) → str
toolTipDuration(self) → int
tr(self, str, disambiguation: str = None, n: int = -1) → str
transform(self) → QTransform
transformationAnchor(self) → QGraphicsView.ViewportAnchor
translate(self, float, float)
underMouse(self) → bool
ungrabGesture(self, Qt.GestureType)
unsetCursor(self)
unsetLayoutDirection(self)
unsetLocale(self)
update(self)

update(self, QRect) update(self, QRegion) update(self, int, int, int, int)

updateGeometry(self)
updateMicroFocus(self)
updateScene(self, Iterable[QRectF])
updateSceneRect(self, QRectF)
updatesEnabled(self) → bool
verticalScrollBar(self) → QScrollBar
verticalScrollBarPolicy(self) → Qt.ScrollBarPolicy
viewport(self) → QWidget
viewportEvent(self, QEvent) → bool
viewportMargins(self) → QMargins
viewportSizeHint(self) → QSize
viewportTransform(self) → QTransform
viewportUpdateMode(self) → QGraphicsView.ViewportUpdateMode
visibleRegion(self) → QRegion
whatsThis(self) → str
width(self) → int
widthMM(self) → int
winId(self) → sip.voidptr
window(self) → QWidget
windowFilePath(self) → str
windowFlags(self) → Qt.WindowFlags
windowHandle(self) → QWindow
windowIcon(self) → QIcon
windowIconChanged

windowIconChanged(self, QIcon) [signal]

windowIconText(self) → str
windowIconTextChanged

windowIconTextChanged(self, str) [signal]

windowModality(self) → Qt.WindowModality
windowOpacity(self) → float
windowRole(self) → str
windowState(self) → Qt.WindowStates
windowTitle(self) → str
windowTitleChanged

windowTitleChanged(self, str) [signal]

windowType(self) → Qt.WindowType
x(self) → int
y(self) → int
class schrodinger.ui.qt.structure2d.structure_item(rect=None)

Bases: PyQt5.QtWidgets.QGraphicsItem

__init__(rect=None)
Parameters:rect (QRectF) – Size of the rect of the bounding box.
boundingRect(self) → QRectF
clear()

Clear picture from item.

generate_picture(gen_coord=True)

Generates a QPicture of the structure. This should be called after setting the structure and the accompaning annotators.

Parameters:gen_coord (bool) – if True generate coordinates.
paint(painter, option, widget=0)

Overrides the paint function to draw the picture that has already been generated. This should never be called manually.

set_colormap(colormap)

Sets the colormap for the atom and bond coloring. Otherwise, the coloring used will be that coming from the ct and/or chmmol.

set_structure(struct, StereoType=6, hydrogenTreatment=1, wantProperties=True, wantMMStereoProps=True, readAtomBondProperties=True, allowRadicals=False)

Set the structure to the given Structure object.

Parameters:
  • struct (schrodinger.structure.Structure class object) – structure to be drawn on the canvas
  • StereoType (ChmMmctAdaptor.StereoType) – Stereochemistry option to use. Avialable options: # Does not include stereochemistry info: canvas2d.ChmMmctAdaptor.NoStereo # Ignores mmstereo annotations: canvas2d.ChmMmctAdaptor.StereoFromGeometry # Silently ignores stereo information that Canvas doesn’t agree with: canvas2d.ChmMmctAdaptor.StereoFromGeometry_Safe # Ignores 3d geometry: canvas2d.ChmMmctAdaptor.StereoFromAnnotation # Silently ignores stereo information that Canvas doesn’t agree with: canvas2d.ChmMmctAdaptor.StereoFromAnnotation_Safe # Uses mmstereo annotaions with 3D geometry as a backup: canvas2d.ChmMmctAdaptor.StereoFromAnnotationAndGeometry # Silently ignores stereo information that Canvas doesn’t agree with: canvas2d.ChmMmctAdaptor.StereoFromAnnotationAndGeometry_Safe
  • hydrogenTreatment (canvas2d.ChmAtomOption.H) – Hydrogen treatment method. canvas2d.ChmAtomOption.H_Never canvas2d.ChmAtomOption.H_ExplicitOnly canvas2d.ChmAtomOption.H_Polar canvas2d.ChmAtomOption.H_ExplicitPolar canvas2d.ChmAtomOption.H_Chiral canvas2d.ChmAtomOption.H_ExplicitChiral canvas2d.ChmAtomOption.H_ExplicitPolarAndChiral canvas2d.ChmAtomOption.H_All
  • wantProperties (bool) – Whether properties should be copied.
  • wantMMStereoProps (bool) – Whether to copy mmstereo properties.
  • readAtomBondProperties (bool) – Whether to copy atom and bond-level properties.
  • allowRadicals (bool) – Whether to assume that valence deficiencies represent unpaired electrons.
set_rect(rect)
Parameters:rect (QRect) – size of bounding box
set_text(text, alignment=None)

Sets text in the view. This is useful if you display text in place of a structure, in places where no structure is available.

Parameters:
  • text (string) – text to be displayed
  • alignment (Qt.AlignmentFlags) – alignment flags of text, defaults to QtCore.Qt.AlignVCenter|QtCore.Qt.AlignCenter
add_annotator(annotator)

Adds annotator to stack. The order that these functions get added is the order that they will be applied to the picture.

Parameters:annotator (schrodinger.infra.canvas2d.ChemViewAnnotator) – Annotator which draws on top an image
add_annotator_function_return(function)

Add functions that need to get returned after the structure is rendered on the screen. An example of this would be a function that returns drawmol coordinates.

clear_annotators()

Clears all annotators

mousePressEvent(event)

Emit a signal if the user left-clicked on an atom or a bond

getBondAtLocation(pos)

Return the bond at the specified coordinates

Parameters:pos (PyQt5.QtCore.QPoint) – The specified coordinates
Returns:If there is a bond at the specified coordinates, return a list of the chmmol atom indices for the two bound atoms. (Note that the chmmol atom indices are zero-indexed, so you should add one to each index if you want the schrodinger.structure.Structure atom indices). If there is no bond at the specified coordinates, return an empty list.
Return type:list
class CacheMode

Bases: int

__init__ = <method-wrapper '__init__' of sip.enumtype object at 0x1e0f548>
DeviceCoordinateCache = 2
class GraphicsItemChange

Bases: int

__init__ = <method-wrapper '__init__' of sip.enumtype object at 0x1e0f8f8>
class GraphicsItemFlag

Bases: int

__init__ = <method-wrapper '__init__' of sip.enumtype object at 0x1e0fca8>
class GraphicsItemFlags

Bases: sip.simplewrapper

QGraphicsItem.GraphicsItemFlags(Union[QGraphicsItem.GraphicsItemFlags, QGraphicsItem.GraphicsItemFlag]) QGraphicsItem.GraphicsItemFlags(QGraphicsItem.GraphicsItemFlags)

__init__

Initialize self. See help(type(self)) for accurate signature.

ItemAcceptsInputMethod = 4096
ItemChildAddedChange = 6
ItemChildRemovedChange = 7
ItemClipsChildrenToShape = 16
ItemClipsToShape = 8
ItemContainsChildrenInShape = 524288
ItemCoordinateCache = 1
ItemCursorChange = 17
ItemCursorHasChanged = 18
ItemDoesntPropagateOpacityToChildren = 128
ItemEnabledChange = 3
ItemEnabledHasChanged = 13
ItemFlagsChange = 21
ItemFlagsHaveChanged = 22
ItemHasNoContents = 1024
ItemIgnoresParentOpacity = 64
ItemIgnoresTransformations = 32
ItemIsFocusable = 4
ItemIsMovable = 1
ItemIsPanel = 16384
ItemIsSelectable = 2
ItemMatrixChange = 1
ItemNegativeZStacksBehindParent = 8192
ItemOpacityChange = 25
ItemOpacityHasChanged = 26
ItemParentChange = 5
ItemParentHasChanged = 15
ItemPositionChange = 0
ItemPositionHasChanged = 9
ItemRotationChange = 28
ItemRotationHasChanged = 29
ItemScaleChange = 30
ItemScaleHasChanged = 31
ItemSceneChange = 11
ItemSceneHasChanged = 16
ItemScenePositionHasChanged = 27
ItemSelectedChange = 4
ItemSelectedHasChanged = 14
ItemSendsGeometryChanges = 2048
ItemSendsScenePositionChanges = 65536
ItemStacksBehindParent = 256
ItemToolTipChange = 19
ItemToolTipHasChanged = 20
ItemTransformChange = 8
ItemTransformHasChanged = 10
ItemTransformOriginPointChange = 32
ItemTransformOriginPointHasChanged = 33
ItemUsesExtendedStyleOption = 512
ItemVisibleChange = 2
ItemVisibleHasChanged = 12
ItemZValueChange = 23
ItemZValueHasChanged = 24
NoCache = 0
NonModal = 0
PanelModal = 1
class PanelModality

Bases: int

__init__ = <method-wrapper '__init__' of sip.enumtype object at 0x1e10888>
SceneModal = 2
Type = 1
UserType = 65536
acceptDrops(self) → bool
acceptHoverEvents(self) → bool
acceptTouchEvents(self) → bool
acceptedMouseButtons(self) → Qt.MouseButtons
advance(self, int)
boundingRegion(self, QTransform) → QRegion
boundingRegionGranularity(self) → float
cacheMode(self) → QGraphicsItem.CacheMode
childItems(self) → List[QGraphicsItem]
childrenBoundingRect(self) → QRectF
clearFocus(self)
clipPath(self) → QPainterPath
collidesWithItem(self, QGraphicsItem, mode: Qt.ItemSelectionMode = Qt.IntersectsItemShape) → bool
collidesWithPath(self, QPainterPath, mode: Qt.ItemSelectionMode = Qt.IntersectsItemShape) → bool
collidingItems(self, mode: Qt.ItemSelectionMode = Qt.IntersectsItemShape) → List[QGraphicsItem]
commonAncestorItem(self, QGraphicsItem) → QGraphicsItem
contains(self, Union[QPointF, QPoint]) → bool
contextMenuEvent(self, QGraphicsSceneContextMenuEvent)
cursor(self) → QCursor
data(self, int) → Any
deviceTransform(self, QTransform) → QTransform
dragEnterEvent(self, QGraphicsSceneDragDropEvent)
dragLeaveEvent(self, QGraphicsSceneDragDropEvent)
dragMoveEvent(self, QGraphicsSceneDragDropEvent)
dropEvent(self, QGraphicsSceneDragDropEvent)
effectiveOpacity(self) → float
ensureVisible(self, rect: QRectF = QRectF(), xMargin: int = 50, yMargin: int = 50)

ensureVisible(self, float, float, float, float, xMargin: int = 50, yMargin: int = 50)

filtersChildEvents(self) → bool
flags(self) → QGraphicsItem.GraphicsItemFlags
focusInEvent(self, QFocusEvent)
focusItem(self) → QGraphicsItem
focusOutEvent(self, QFocusEvent)
focusProxy(self) → QGraphicsItem
grabKeyboard(self)
grabMouse(self)
graphicsEffect(self) → QGraphicsEffect
group(self) → QGraphicsItemGroup
hasCursor(self) → bool
hasFocus(self) → bool
hide(self)
hoverEnterEvent(self, QGraphicsSceneHoverEvent)
hoverLeaveEvent(self, QGraphicsSceneHoverEvent)
hoverMoveEvent(self, QGraphicsSceneHoverEvent)
inputMethodEvent(self, QInputMethodEvent)
inputMethodHints(self) → Qt.InputMethodHints
inputMethodQuery(self, Qt.InputMethodQuery) → Any
installSceneEventFilter(self, QGraphicsItem)
isActive(self) → bool
isAncestorOf(self, QGraphicsItem) → bool
isBlockedByModalPanel(self) → Tuple[bool, QGraphicsItem]
isClipped(self) → bool
isEnabled(self) → bool
isObscured(self, rect: QRectF = QRectF()) → bool

isObscured(self, float, float, float, float) -> bool

isObscuredBy(self, QGraphicsItem) → bool
isPanel(self) → bool
isSelected(self) → bool
isUnderMouse(self) → bool
isVisible(self) → bool
isVisibleTo(self, QGraphicsItem) → bool
isWidget(self) → bool
isWindow(self) → bool
itemChange(self, QGraphicsItem.GraphicsItemChange, Any) → Any
itemTransform(self, QGraphicsItem) → Tuple[QTransform, bool]
keyPressEvent(self, QKeyEvent)
keyReleaseEvent(self, QKeyEvent)
mapFromItem(self, QGraphicsItem, Union[QPointF, QPoint]) → QPointF

mapFromItem(self, QGraphicsItem, QRectF) -> QPolygonF mapFromItem(self, QGraphicsItem, QPolygonF) -> QPolygonF mapFromItem(self, QGraphicsItem, QPainterPath) -> QPainterPath mapFromItem(self, QGraphicsItem, float, float) -> QPointF mapFromItem(self, QGraphicsItem, float, float, float, float) -> QPolygonF

mapFromParent(self, Union[QPointF, QPoint]) → QPointF

mapFromParent(self, QRectF) -> QPolygonF mapFromParent(self, QPolygonF) -> QPolygonF mapFromParent(self, QPainterPath) -> QPainterPath mapFromParent(self, float, float) -> QPointF mapFromParent(self, float, float, float, float) -> QPolygonF

mapFromScene(self, Union[QPointF, QPoint]) → QPointF

mapFromScene(self, QRectF) -> QPolygonF mapFromScene(self, QPolygonF) -> QPolygonF mapFromScene(self, QPainterPath) -> QPainterPath mapFromScene(self, float, float) -> QPointF mapFromScene(self, float, float, float, float) -> QPolygonF

mapRectFromItem(self, QGraphicsItem, QRectF) → QRectF

mapRectFromItem(self, QGraphicsItem, float, float, float, float) -> QRectF

mapRectFromParent(self, QRectF) → QRectF

mapRectFromParent(self, float, float, float, float) -> QRectF

mapRectFromScene(self, QRectF) → QRectF

mapRectFromScene(self, float, float, float, float) -> QRectF

mapRectToItem(self, QGraphicsItem, QRectF) → QRectF

mapRectToItem(self, QGraphicsItem, float, float, float, float) -> QRectF

mapRectToParent(self, QRectF) → QRectF

mapRectToParent(self, float, float, float, float) -> QRectF

mapRectToScene(self, QRectF) → QRectF

mapRectToScene(self, float, float, float, float) -> QRectF

mapToItem(self, QGraphicsItem, Union[QPointF, QPoint]) → QPointF

mapToItem(self, QGraphicsItem, QRectF) -> QPolygonF mapToItem(self, QGraphicsItem, QPolygonF) -> QPolygonF mapToItem(self, QGraphicsItem, QPainterPath) -> QPainterPath mapToItem(self, QGraphicsItem, float, float) -> QPointF mapToItem(self, QGraphicsItem, float, float, float, float) -> QPolygonF

mapToParent(self, Union[QPointF, QPoint]) → QPointF

mapToParent(self, QRectF) -> QPolygonF mapToParent(self, QPolygonF) -> QPolygonF mapToParent(self, QPainterPath) -> QPainterPath mapToParent(self, float, float) -> QPointF mapToParent(self, float, float, float, float) -> QPolygonF

mapToScene(self, Union[QPointF, QPoint]) → QPointF

mapToScene(self, QRectF) -> QPolygonF mapToScene(self, QPolygonF) -> QPolygonF mapToScene(self, QPainterPath) -> QPainterPath mapToScene(self, float, float) -> QPointF mapToScene(self, float, float, float, float) -> QPolygonF

mouseDoubleClickEvent(self, QGraphicsSceneMouseEvent)
mouseMoveEvent(self, QGraphicsSceneMouseEvent)
mouseReleaseEvent(self, QGraphicsSceneMouseEvent)
moveBy(self, float, float)
opacity(self) → float
opaqueArea(self) → QPainterPath
panel(self) → QGraphicsItem
panelModality(self) → QGraphicsItem.PanelModality
parentItem(self) → QGraphicsItem
parentObject(self) → QGraphicsObject
parentWidget(self) → QGraphicsWidget
pos(self) → QPointF
prepareGeometryChange(self)
removeSceneEventFilter(self, QGraphicsItem)
resetTransform(self)
rotation(self) → float
scale(self) → float
scene(self) → QGraphicsScene
sceneBoundingRect(self) → QRectF
sceneEvent(self, QEvent) → bool
sceneEventFilter(self, QGraphicsItem, QEvent) → bool
scenePos(self) → QPointF
sceneTransform(self) → QTransform
scroll(self, float, float, rect: QRectF = QRectF())
setAcceptDrops(self, bool)
setAcceptHoverEvents(self, bool)
setAcceptTouchEvents(self, bool)
setAcceptedMouseButtons(self, Union[Qt.MouseButtons, Qt.MouseButton])
setActive(self, bool)
setBoundingRegionGranularity(self, float)
setCacheMode(self, QGraphicsItem.CacheMode, logicalCacheSize: QSize = QSize())
setCursor(self, Union[QCursor, Qt.CursorShape])
setData(self, int, Any)
setEnabled(self, bool)
setFiltersChildEvents(self, bool)
setFlag(self, QGraphicsItem.GraphicsItemFlag, enabled: bool = True)
setFlags(self, Union[QGraphicsItem.GraphicsItemFlags, QGraphicsItem.GraphicsItemFlag])
setFocus(self, focusReason: Qt.FocusReason = Qt.OtherFocusReason)
setFocusProxy(self, QGraphicsItem)
setGraphicsEffect(self, QGraphicsEffect)
setGroup(self, QGraphicsItemGroup)
setInputMethodHints(self, Union[Qt.InputMethodHints, Qt.InputMethodHint])
setOpacity(self, float)
setPanelModality(self, QGraphicsItem.PanelModality)
setParentItem(self, QGraphicsItem)
setPos(self, Union[QPointF, QPoint])

setPos(self, float, float)

setRotation(self, float)
setScale(self, float)
setSelected(self, bool)
setToolTip(self, str)
setTransform(self, QTransform, combine: bool = False)
setTransformOriginPoint(self, Union[QPointF, QPoint])

setTransformOriginPoint(self, float, float)

setTransformations(self, Iterable[QGraphicsTransform])
setVisible(self, bool)
setX(self, float)
setY(self, float)
setZValue(self, float)
shape(self) → QPainterPath
show(self)
stackBefore(self, QGraphicsItem)
toGraphicsObject(self) → QGraphicsObject
toolTip(self) → str
topLevelItem(self) → QGraphicsItem
topLevelWidget(self) → QGraphicsWidget
transform(self) → QTransform
transformOriginPoint(self) → QPointF
transformations(self) → List[QGraphicsTransform]
type(self) → int
ungrabKeyboard(self)
ungrabMouse(self)
unsetCursor(self)
update(self, rect: QRectF = QRectF())

update(self, float, float, float, float)

updateMicroFocus(self)
wheelEvent(self, QGraphicsSceneWheelEvent)
window(self) → QGraphicsWidget
x(self) → float
y(self) → float
zValue(self) → float
class schrodinger.ui.qt.structure2d.ColoredArrowAnnotator(mol, bond_info=None, draw_arrowhead=True)

Bases: schrodinger.infra._canvas2d.ChemViewAnnotator

This annotator allows you to add colored arrows to bonds in 2d renderings.

This is a slightly less terrible port from C++. Most of the logic still keeps C++-style syntax, simply because rewriting it is not worth the effort. The interface is now more pythonic, at least.

__init__(mol, bond_info=None, draw_arrowhead=True)
Parameters:
  • mol – is a chmmol
  • bond_info – is a list containing individual lists of: (atom1, atom2, outlined, QColor)

These lists are composed of:

  • atom1 is a ct-atom index
  • atom2 is a ct-atom index
  • outlined (0/1) is whether you want the arrow to have a black outline
  • qc is a qcolor for the bond
add_bond_arrow(atom1, atom2, outlined, qc)

atom1 is a ct-atom index atom2 is a ct-atom index outlined (0/1) is whether you want the arrow to have a black outline qc is the qcolor of the bond

clear_bond_arrows()

Clear all bond markers in this annotator

annotate(view, dm)

This function annotates the specified arrows.

class schrodinger.ui.qt.structure2d.CgCoreAnnotator(bond_info, colors, atoms, atomColors, mol)

Bases: schrodinger.ui.qt.structure2d.ColoredArrowAnnotator

This is the original ColoredArrowAnnotator class name. When that class had the format of its input changed, it became incompatible with the original class.

This class will remain to preserve backwards compatability.

__init__(bond_info, colors, atoms, atomColors, mol)

bond_info is a list of size 3N, (atom1 idx, a2 idx, outline) colors is a list of size 3N (R, G, B) atoms/atomColors are deprecated mol is a chmmol

add_bond_arrow(atom1, atom2, outlined, qc)

atom1 is a ct-atom index atom2 is a ct-atom index outlined (0/1) is whether you want the arrow to have a black outline qc is the qcolor of the bond

annotate(view, dm)

This function annotates the specified arrows.

clear_bond_arrows()

Clear all bond markers in this annotator

class schrodinger.ui.qt.structure2d.BaseSquareAnnotator

Bases: schrodinger.infra._canvas2d.ChemViewAnnotator

Base class for annotators that draw a square around atoms

annotate(view, dm)

Add this sphere to the list of things in the picture

Parameters:
  • view (Chemview) – the View this item goes in
  • dm (ChmDrawMol) – object that contains the list of atom and bond graphics
__init__

Initialize self. See help(type(self)) for accurate signature.

class schrodinger.ui.qt.structure2d.RedSquareAnnotator(atom=None, size=100, color=7)

Bases: schrodinger.ui.qt.structure2d.BaseSquareAnnotator

Create a square around the specified atom.

__init__(atom=None, size=100, color=7)

Instantiate a RedSquareAnnotator instance.

Parameters:
  • atom (int) – the atom number to which square applies. Note that this expects the first atom to be atom 1, not 0.
  • size (float) – the size of one side of the square in pixels.
  • color (QColor) – the color used to draw annotator. Default is red.
setAtom(atom, color=None)

Set the atom number to which the square applies

Parameters:
  • atom (int) – the atom number to which square applies. Note that this expects the first atom to be atom 1, not 0. If 0 is passed in, no atom will be annotated.
  • color (QColor) – the color used to draw annotator. If not given, the previously set color for this annotator will be used.
clearAtom()

Remove the current atom so no atoms are annotated

getAtom()

Return the atom index current annotated

Return type:int or None
Returns:The index (1-based) of the atom annotated, or None if no atoms are annotated
setColor(color)

Set the color of the square

Parameters:color (QColor) – the color used to draw annotator.
annotate(view, dm)

Add this sphere to the list of things in the picture

Parameters:
  • view (Chemview) – the View this item goes in
  • dm (ChmDrawMol) – object that contains the list of atom and bond graphics
class schrodinger.ui.qt.structure2d.MultiSquareAnnotator(atom_dict, size=100)

Bases: schrodinger.ui.qt.structure2d.BaseSquareAnnotator

Create a square around each specified atom.

__init__(atom_dict, size=100)

Instantiate a MultiSquareAnnotator instance.

Parameters:
  • atom_dict (dict) – A dictionary of {atom number: QColor} specifying the appropriate color for each atom
  • size (float) – The size of one side of the square in pixels. Defaults to 100 pixels.
annotate(view, dm)

Add this sphere to the list of things in the picture

Parameters:
  • view (Chemview) – the View this item goes in
  • dm (ChmDrawMol) – object that contains the list of atom and bond graphics
class schrodinger.ui.qt.structure2d.AtomNumberAnnotator

Bases: schrodinger.infra._canvas2d.ChemViewAnnotator

Show the atom number of each atom rather than a vertex or atomic symbol

annotate(view, dm)

Add atom number to each atom

Parameters:
  • view (Chemview) – the View this item goes in
  • dm (ChmDrawMol) – object that contains the list of atom and bond graphics
__init__

Initialize self. See help(type(self)) for accurate signature.

class schrodinger.ui.qt.structure2d.AtomLabelAnnotator(atom_labels)

Bases: schrodinger.infra._canvas2d.ChemViewAnnotator

Changes the label displayed for an atom. The label can have subscripts.

__init__(atom_labels)

Instantiate a AtomLabelAnnotator instance.

Parameters:atom_labels (dict) – A dictionary of {atom number: label} specifying the label for each atom to be custom labeled. Each label may either be a string or a (str, str) tuple. In the latter case, the first string is the main label and the second string is the subscript. Note the atom numbers used here should be 1-based (first atom number = 1)
annotate(view, drawmol)

Add a label to each atom specified in the atom_labels property

Parameters:
  • view (Chemview) – the View this item goes in
  • drawmol (ChmDrawMol) – object that contains the list of atom and bond graphics
class schrodinger.ui.qt.structure2d.CircleAnnotator(atom=None, radius=75.0, color=8, gradient=False, fill=False, width=4)

Bases: schrodinger.infra._canvas2d.ChemViewAnnotator

Creates a circle behind one or more atoms.

__init__(atom=None, radius=75.0, color=8, gradient=False, fill=False, width=4)

Instantiate a ColorCircleAnnotator instance.

Parameters:
  • atom (int) – the atom number to which radius applies. Note that this expects the first atom to be atom 1, not 0.
  • radius (float) – the radius of the sphere in pixels. Default is 75.
  • color (QColor) – The color of the circle fill
  • gradient (bool) – If True, the circle is filled with a gradient that goes from white at the center to the defined color. gradient is exclusive with fill.
  • fill (bool) – If True, the circle is given a constant fill. fill is exclusive with gradient.
  • width (int) – The width of the pen if fill and gradient are both False. Default is 4.
addAtom(atom_num, radius=None, color=None)

Add another sphere to this annotator

Parameters:
  • atom_num (int) – the atom number to which radius applies. Note that this expects the first atom to be atom 1, not 0.
  • radius (float) – the radius of the sphere in pixels. If not given, the radius given at the time of instance creation is used.
  • color (QColor) – The color of the circle fill. If not given, the color given at the time of instance creation is used.
removeAtom(atom_num)

Remove an atom from the annotator

Parameters:atom_num (int) – the atom number to which radius applies. Note that this expects the first atom to be atom 1, not 0.
clearAtoms()

Remove all atoms from the annotator

setColor(color, reset_colors=False)

Set the default color for this annotator

Parameters:
  • color (QColor) – The color of the circle fill.
  • reset_colors (bool) – If True, all existing circles will have their color reset to this value
setRadius(radius, reset_radii=False)

Set the default radius for this annotator

Parameters:
  • radius (float) – The radius of the circle
  • reset_radii (bool) – If True, all existing circles will have their radius reset to this value
annotate(view, dm)

Add this sphere to the list of things in the picture

Parameters:
  • view (Chemview) – the View this item goes in
  • dm (ChmDrawMol) – object that contains the list of atom and bond graphics
class schrodinger.ui.qt.structure2d.ResizableStructurePicture(parent=None, layout=None, height=200, width=200, margin=10, background='white', annotators=None)

Bases: schrodinger.ui.qt.structure2d.StructurePicture

StructurePicture widget that resizes the structure image with the widget.

__init__(parent=None, layout=None, height=200, width=200, margin=10, background='white', annotators=None)

See StructurePicture for all arguments, except:

Parameters:margin (int) – the margin to use around the image
drawChmmol(chmmol, atoms=[], bonds=[], color=<PyQt5.QtGui.QColor object>, gen_coord=False)

Makes a 2-D rendering of the chmmol object with optional atoms and bonds highlighting.

Parameters:
  • chmmol (ChmMol instance.) – Structure to generate the picture for.
  • atoms (list) – list of atoms that should be highlighted
  • bonds (list) – list of bonds that should be highlighted
  • color (QtGui.QColor) – color that is used to highlight atoms and bonds
  • gen_coord (bool) – if True generate coordinates.
Box = 1
DrawChildren = 2
DrawWindowBackground = 1
HLine = 4
IgnoreMask = 4
NoFrame = 0
class PaintDeviceMetric

Bases: int

__init__ = <method-wrapper '__init__' of sip.enumtype object at 0x1e51628>
Panel = 2
PdmDepth = 6
PdmDevicePixelRatio = 11
PdmDevicePixelRatioScaled = 12
PdmDpiX = 7
PdmDpiY = 8
PdmHeight = 2
PdmHeightMM = 4
PdmNumColors = 5
PdmPhysicalDpiX = 9
PdmPhysicalDpiY = 10
PdmWidth = 1
PdmWidthMM = 3
Plain = 16
Raised = 32
class RenderFlag

Bases: int

__init__ = <method-wrapper '__init__' of sip.enumtype object at 0x1e8d8a8>
class RenderFlags

Bases: sip.simplewrapper

QWidget.RenderFlags(Union[QWidget.RenderFlags, QWidget.RenderFlag]) QWidget.RenderFlags(QWidget.RenderFlags)

__init__

Initialize self. See help(type(self)) for accurate signature.

class Shadow

Bases: int

__init__ = <method-wrapper '__init__' of sip.enumtype object at 0x1e08da8>
Shadow_Mask = 240
class Shape

Bases: int

__init__ = <method-wrapper '__init__' of sip.enumtype object at 0x1e09158>
Shape_Mask = 15
class StyleMask

Bases: int

__init__ = <method-wrapper '__init__' of sip.enumtype object at 0x1e09508>
StyledPanel = 6
Sunken = 48
VLine = 5
WinPanel = 3
acceptDrops(self) → bool
accessibleDescription(self) → str
accessibleName(self) → str
actionEvent(self, QActionEvent)
actions(self) → List[QAction]
activateWindow(self)
addAction(self, QAction)
addActions(self, Iterable[QAction])
adjustSize(self)
alignment(self) → Qt.Alignment
autoFillBackground(self) → bool
backgroundRole(self) → QPalette.ColorRole
baseSize(self) → QSize
blockSignals(self, bool) → bool
buddy(self) → QWidget
changeEvent(self, QEvent)
childAt(self, QPoint) → QWidget

childAt(self, int, int) -> QWidget

childEvent(self, QChildEvent)
children(self) → List[QObject]
childrenRect(self) → QRect
childrenRegion(self) → QRegion
clear(self)
clearFocus(self)
clearMask(self)
close(self) → bool
closeEvent(self, QCloseEvent)
colorCount(self) → int
connectNotify(self, QMetaMethod)
contentsMargins(self) → QMargins
contentsRect(self) → QRect
contextMenuEvent(self, QContextMenuEvent)
contextMenuPolicy(self) → Qt.ContextMenuPolicy
create(self, window: sip.voidptr = 0, initializeWindow: bool = True, destroyOldWindow: bool = True)
createWindowContainer(QWindow, parent: QWidget = None, flags: Union[Qt.WindowFlags, Qt.WindowType] = 0) → QWidget
cursor(self) → QCursor
customContextMenuRequested

customContextMenuRequested(self, QPoint) [signal]

customEvent(self, QEvent)
deleteLater(self)
depth(self) → int
destroy(self, destroyWindow: bool = True, destroySubWindows: bool = True)
destroyed

destroyed(self, object: QObject = None) [signal]

devType(self) → int
devicePixelRatio(self) → int
devicePixelRatioF(self) → float
devicePixelRatioFScale() → float
disconnect(self)
disconnectNotify(self, QMetaMethod)
dragEnterEvent(self, QDragEnterEvent)
dragLeaveEvent(self, QDragLeaveEvent)
dragMoveEvent(self, QDragMoveEvent)
drawFrame(self, QPainter)
drawStructure(structure, StereoType=6, hydrogenTreatment=1, wantProperties=True, wantMMStereoProps=True, readAtomBondProperties=True, allowRadicals=False)

Makes a 2-D rendering of the structure

Parameters:
  • structure (schrodinger.structure.Structure class object) – structure to be drawn on the canvas
  • StereoType (canvas2d.ChmMmctAdaptor.StereoType) – Stereochemistry option to use. Available options: # Does not include stereochemistry info: canvas2d.ChmMmctAdaptor.NoStereo # Ignores mmstereo annotations: canvas2d.ChmMmctAdaptor.StereoFromGeometry # Silently ignores stereo information that Canvas doesn’t agree with: canvas2d.ChmMmctAdaptor.StereoFromGeometry_Safe # Ignores 3d geometry: canvas2d.ChmMmctAdaptor.StereoFromAnnotation # Silently ignores stereo information that Canvas doesn’t agree with: canvas2d.ChmMmctAdaptor.StereoFromAnnotation_Safe # Uses mmstereo annotaions with 3D geometry as a backup: canvas2d.ChmMmctAdaptor.StereoFromAnnotationAndGeometry # Silently ignores stereo information that Canvas doesn’t agree with: canvas2d.ChmMmctAdaptor.StereoFromAnnotationAndGeometry_Safe
  • hydrogenTreatment (canvas2d.ChmAtomOption.H) – Hydrogen treatment method. Available options: canvas2d.ChmAtomOption.H_Never canvas2d.ChmAtomOption.H_ExplicitOnly canvas2d.ChmAtomOption.H_Polar canvas2d.ChmAtomOption.H_ExplicitPolar canvas2d.ChmAtomOption.H_Chiral canvas2d.ChmAtomOption.H_ExplicitChiral canvas2d.ChmAtomOption.H_ExplicitPolarAndChiral canvas2d.ChmAtomOption.H_All
  • wantProperties (bool) – Whether properties should be copied.
  • wantMMStereoProps (bool) – Whether to copy mmstereo properties.
  • readAtomBondProperties (bool) – Whether to copy atom and bond-level properties.
  • allowRadicals (bool) – Whether to assume that valence deficiencies represent unpaired electrons.
dropEvent(self, QDropEvent)
dumpObjectInfo(self)
dumpObjectTree(self)
dynamicPropertyNames(self) → List[QByteArray]
effectiveWinId(self) → sip.voidptr
ensurePolished(self)
enterEvent(self, QEvent)
event(self, QEvent) → bool
eventFilter(self, QObject, QEvent) → bool
find(sip.voidptr) → QWidget
findChild(self, type, name: str = '', options: Union[Qt.FindChildOptions, Qt.FindChildOption] = Qt.FindChildrenRecursively) → QObject

findChild(self, Tuple, name: str = ‘’, options: Union[Qt.FindChildOptions, Qt.FindChildOption] = Qt.FindChildrenRecursively) -> QObject

findChildren(self, type, name: str = '', options: Union[Qt.FindChildOptions, Qt.FindChildOption] = Qt.FindChildrenRecursively) → List[QObject]

findChildren(self, Tuple, name: str = ‘’, options: Union[Qt.FindChildOptions, Qt.FindChildOption] = Qt.FindChildrenRecursively) -> List[QObject] findChildren(self, type, QRegExp, options: Union[Qt.FindChildOptions, Qt.FindChildOption] = Qt.FindChildrenRecursively) -> List[QObject] findChildren(self, Tuple, QRegExp, options: Union[Qt.FindChildOptions, Qt.FindChildOption] = Qt.FindChildrenRecursively) -> List[QObject] findChildren(self, type, QRegularExpression, options: Union[Qt.FindChildOptions, Qt.FindChildOption] = Qt.FindChildrenRecursively) -> List[QObject] findChildren(self, Tuple, QRegularExpression, options: Union[Qt.FindChildOptions, Qt.FindChildOption] = Qt.FindChildrenRecursively) -> List[QObject]

focusInEvent(self, QFocusEvent)
focusNextChild(self) → bool
focusNextPrevChild(self, bool) → bool
focusOutEvent(self, QFocusEvent)
focusPolicy(self) → Qt.FocusPolicy
focusPreviousChild(self) → bool
focusProxy(self) → QWidget
focusWidget(self) → QWidget
font(self) → QFont
fontInfo(self) → QFontInfo
fontMetrics(self) → QFontMetrics
foregroundRole(self) → QPalette.ColorRole
frameGeometry(self) → QRect
frameRect(self) → QRect
frameShadow(self) → QFrame.Shadow
frameShape(self) → QFrame.Shape
frameSize(self) → QSize
frameStyle(self) → int
frameWidth(self) → int
geometry(self) → QRect
getContentsMargins(self) → Tuple[int, int, int, int]
grab(self, rectangle: QRect = QRect(QPoint(0, 0), QSize(-1, -1))) → QPixmap
grabGesture(self, Qt.GestureType, flags: Union[Qt.GestureFlags, Qt.GestureFlag] = Qt.GestureFlags())
grabKeyboard(self)
grabMouse(self)

grabMouse(self, Union[QCursor, Qt.CursorShape])

grabShortcut(self, Union[QKeySequence, QKeySequence.StandardKey, str, int], context: Qt.ShortcutContext = Qt.WindowShortcut) → int
graphicsEffect(self) → QGraphicsEffect
graphicsProxyWidget(self) → QGraphicsProxyWidget
hasFocus(self) → bool
hasHeightForWidth(self) → bool
hasMouseTracking(self) → bool
hasScaledContents(self) → bool
hasSelectedText(self) → bool
hasTabletTracking(self) → bool
height(self) → int
heightForWidth(self, int) → int
heightMM(self) → int
hide(self)
hideEvent(self, QHideEvent)
indent(self) → int
inherits(self, str) → bool
initPainter(self, QPainter)
initStyleOption(self, QStyleOptionFrame)
inputMethodEvent(self, QInputMethodEvent)
inputMethodHints(self) → Qt.InputMethodHints
inputMethodQuery(self, Qt.InputMethodQuery) → Any
insertAction(self, QAction, QAction)
insertActions(self, QAction, Iterable[QAction])
installEventFilter(self, QObject)
isActiveWindow(self) → bool
isAncestorOf(self, QWidget) → bool
isEnabled(self) → bool
isEnabledTo(self, QWidget) → bool
isFullScreen(self) → bool
isHidden(self) → bool
isLeftToRight(self) → bool
isMaximized(self) → bool
isMinimized(self) → bool
isModal(self) → bool
isRightToLeft(self) → bool
isSignalConnected(self, QMetaMethod) → bool
isVisible(self) → bool
isVisibleTo(self, QWidget) → bool
isWidgetType(self) → bool
isWindow(self) → bool
isWindowModified(self) → bool
isWindowType(self) → bool
keyPressEvent(self, QKeyEvent)
keyReleaseEvent(self, QKeyEvent)
keyboardGrabber() → QWidget
killTimer(self, int)
layout(self) → QLayout
layoutDirection(self) → Qt.LayoutDirection
leaveEvent(self, QEvent)
lineWidth(self) → int
linkActivated

linkActivated(self, str) [signal]

linkHovered

linkHovered(self, str) [signal]

locale(self) → QLocale
logicalDpiX(self) → int
logicalDpiY(self) → int
lower(self)
mapFrom(self, QWidget, QPoint) → QPoint
mapFromGlobal(self, QPoint) → QPoint
mapFromParent(self, QPoint) → QPoint
mapTo(self, QWidget, QPoint) → QPoint
mapToGlobal(self, QPoint) → QPoint
mapToParent(self, QPoint) → QPoint
margin(self) → int
mask(self) → QRegion
maximumHeight(self) → int
maximumSize(self) → QSize
maximumWidth(self) → int
metaObject(self) → QMetaObject
metric(self, QPaintDevice.PaintDeviceMetric) → int
midLineWidth(self) → int
minimumHeight(self) → int
minimumSize(self) → QSize
minimumSizeHint(self) → QSize
minimumWidth(self) → int
mouseDoubleClickEvent(self, QMouseEvent)
mouseGrabber() → QWidget
mouseMoveEvent(self, QMouseEvent)
mousePressEvent(self, QMouseEvent)
mouseReleaseEvent(self, QMouseEvent)
move(self, QPoint)

move(self, int, int)

moveEvent(self, QMoveEvent)
moveToThread(self, QThread)
movie(self) → QMovie
nativeEvent(self, Union[QByteArray, bytes, bytearray], sip.voidptr) → Tuple[bool, int]
nativeParentWidget(self) → QWidget
nextInFocusChain(self) → QWidget
normalGeometry(self) → QRect
objectName(self) → str
objectNameChanged

objectNameChanged(self, str) [signal]

overrideWindowFlags(self, Union[Qt.WindowFlags, Qt.WindowType])
overrideWindowState(self, Union[Qt.WindowStates, Qt.WindowState])
paintEngine(self) → QPaintEngine
paintEvent(self, QPaintEvent)
paintingActive(self) → bool
palette(self) → QPalette
parent(self) → QObject
parentWidget(self) → QWidget
physicalDpiX(self) → int
physicalDpiY(self) → int
picture(self) → QPicture
pixmap(self) → QPixmap
pos(self) → QPoint
previousInFocusChain(self) → QWidget
property(self, str) → Any
pyqtConfigure(...)

Each keyword argument is either the name of a Qt property or a Qt signal. For properties the property is set to the given value which should be of an appropriate type. For signals the signal is connected to the given value which should be a callable.

raise_(self)
receivers(self, PYQT_SIGNAL) → int
rect(self) → QRect
releaseKeyboard(self)
releaseMouse(self)
releaseShortcut(self, int)
removeAction(self, QAction)
removeEventFilter(self, QObject)
render(self, QPaintDevice, targetOffset: QPoint = QPoint(), sourceRegion: QRegion = QRegion(), flags: Union[QWidget.RenderFlags, QWidget.RenderFlag] = QWidget.RenderFlags(QWidget.DrawWindowBackground|QWidget.DrawChildren))

render(self, QPainter, targetOffset: QPoint = QPoint(), sourceRegion: QRegion = QRegion(), flags: Union[QWidget.RenderFlags, QWidget.RenderFlag] = QWidget.RenderFlags(QWidget.DrawWindowBackground|QWidget.DrawChildren))

repaint(self)

repaint(self, int, int, int, int) repaint(self, QRect) repaint(self, QRegion)

resize(self, QSize)

resize(self, int, int)

resizeEvent(self, QResizeEvent)
restoreGeometry(self, Union[QByteArray, bytes, bytearray]) → bool
saveGeometry(self) → QByteArray
scroll(self, int, int)

scroll(self, int, int, QRect)

selectedText(self) → str
selectionStart(self) → int
sender(self) → QObject
senderSignalIndex(self) → int
setAcceptDrops(self, bool)
setAccessibleDescription(self, str)
setAccessibleName(self, str)
setAlignment(self, Union[Qt.Alignment, Qt.AlignmentFlag])
setAnnotators(annotators)

This function allows to reset annotators between renderning 2-D structures.

Parameters:annotators (list) – Each item of the list should be a canvas2d.ChemViewAnnotator object that will be applied to the canvas2d.ChmRender2DModel when generating the image
setAttribute(self, Qt.WidgetAttribute, on: bool = True)
setAutoFillBackground(self, bool)
setBackgroundRole(self, QPalette.ColorRole)
setBaseSize(self, int, int)

setBaseSize(self, QSize)

setBuddy(self, QWidget)
setContentsMargins(self, int, int, int, int)

setContentsMargins(self, QMargins)

setContextMenuPolicy(self, Qt.ContextMenuPolicy)
setCursor(self, Union[QCursor, Qt.CursorShape])
setDisabled(self, bool)
setEnabled(self, bool)
setFixedHeight(self, int)
setFixedSize(self, QSize)

setFixedSize(self, int, int)

setFixedWidth(self, int)
setFocus(self)

setFocus(self, Qt.FocusReason)

setFocusPolicy(self, Qt.FocusPolicy)
setFocusProxy(self, QWidget)
setFont(self, QFont)
setForegroundRole(self, QPalette.ColorRole)
setFrameRect(self, QRect)
setFrameShadow(self, QFrame.Shadow)
setFrameShape(self, QFrame.Shape)
setFrameStyle(self, int)
setGeometry(self, QRect)

setGeometry(self, int, int, int, int)

setGraphicsEffect(self, QGraphicsEffect)
setHidden(self, bool)
setIndent(self, int)
setInputMethodHints(self, Union[Qt.InputMethodHints, Qt.InputMethodHint])
setLayout(self, QLayout)
setLayoutDirection(self, Qt.LayoutDirection)
setLineWidth(self, int)
setLocale(self, QLocale)
setMargin(self, int)
setMask(self, QBitmap)

setMask(self, QRegion)

setMaximumHeight(self, int)
setMaximumSize(self, int, int)

setMaximumSize(self, QSize)

setMaximumWidth(self, int)
setMidLineWidth(self, int)
setMinimumHeight(self, int)
setMinimumSize(self, int, int)

setMinimumSize(self, QSize)

setMinimumWidth(self, int)
setMouseTracking(self, bool)
setMovie(self, QMovie)
setNum(self, float)

setNum(self, int)

setObjectName(self, str)
setPalette(self, QPalette)
setParent(self, QWidget)

setParent(self, QWidget, Union[Qt.WindowFlags, Qt.WindowType])

setPicture(self, QPicture)
setPixmap(self, QPixmap)
setProperty(self, str, Any) → bool
setScaledContents(self, bool)
setSelection(self, int, int)
setShortcutAutoRepeat(self, int, enabled: bool = True)
setShortcutEnabled(self, int, enabled: bool = True)
setSizeIncrement(self, int, int)

setSizeIncrement(self, QSize)

setSizePolicy(self, QSizePolicy)

setSizePolicy(self, QSizePolicy.Policy, QSizePolicy.Policy)

setStatusTip(self, str)
setStyle(self, QStyle)
setStyleSheet(self, str)
setTabOrder(QWidget, QWidget)
setTabletTracking(self, bool)
setText(self, str)
setTextFormat(self, Qt.TextFormat)
setTextInteractionFlags(self, Union[Qt.TextInteractionFlags, Qt.TextInteractionFlag])
setToolTip(self, str)
setToolTipDuration(self, int)
setUpdatesEnabled(self, bool)
setVisible(self, bool)
setWhatsThis(self, str)
setWindowFilePath(self, str)
setWindowFlag(self, Qt.WindowType, on: bool = True)
setWindowFlags(self, Union[Qt.WindowFlags, Qt.WindowType])
setWindowIcon(self, QIcon)
setWindowIconText(self, str)
setWindowModality(self, Qt.WindowModality)
setWindowModified(self, bool)
setWindowOpacity(self, float)
setWindowRole(self, str)
setWindowState(self, Union[Qt.WindowStates, Qt.WindowState])
setWindowTitle(self, str)
setWordWrap(self, bool)
sharedPainter(self) → QPainter
show(self)
showEvent(self, QShowEvent)
showFullScreen(self)
showMaximized(self)
showMinimized(self)
showNormal(self)
signalsBlocked(self) → bool
size(self) → QSize
sizeHint(self) → QSize
sizeIncrement(self) → QSize
sizePolicy(self) → QSizePolicy
stackUnder(self, QWidget)
startTimer(self, int, timerType: Qt.TimerType = Qt.CoarseTimer) → int
staticMetaObject = <PyQt5.QtCore.QMetaObject object>
statusTip(self) → str
style(self) → QStyle
styleSheet(self) → str
tabletEvent(self, QTabletEvent)
testAttribute(self, Qt.WidgetAttribute) → bool
text(self) → str
textFormat(self) → Qt.TextFormat
textInteractionFlags(self) → Qt.TextInteractionFlags
thread(self) → QThread
timerEvent(self, QTimerEvent)
toolTip(self) → str
toolTipDuration(self) → int
tr(self, str, disambiguation: str = None, n: int = -1) → str
underMouse(self) → bool
ungrabGesture(self, Qt.GestureType)
unsetCursor(self)
unsetLayoutDirection(self)
unsetLocale(self)
update(self)

update(self, QRect) update(self, QRegion) update(self, int, int, int, int)

updateGeometry(self)
updateMicroFocus(self)
updatesEnabled(self) → bool
visibleRegion(self) → QRegion
whatsThis(self) → str
wheelEvent(self, QWheelEvent)
width(self) → int
widthMM(self) → int
winId(self) → sip.voidptr
window(self) → QWidget
windowFilePath(self) → str
windowFlags(self) → Qt.WindowFlags
windowHandle(self) → QWindow
windowIcon(self) → QIcon
windowIconChanged

windowIconChanged(self, QIcon) [signal]

windowIconText(self) → str
windowIconTextChanged

windowIconTextChanged(self, str) [signal]

windowModality(self) → Qt.WindowModality
windowOpacity(self) → float
windowRole(self) → str
windowState(self) → Qt.WindowStates
windowTitle(self) → str
windowTitleChanged

windowTitleChanged(self, str) [signal]

windowType(self) → Qt.WindowType
wordWrap(self) → bool
x(self) → int
y(self) → int
resizeImage()