Package schrodinger :: Package application :: Package jaguar :: Package gui :: Package tabs :: Package input_sub_tabs :: Module charge_constraints :: Class ChargeConstraintsSubTab
[hide private]
[frames] | no frames]

Class ChargeConstraintsSubTab

PyQt4.QtGui.QWidget --+    
                      |    
base_sub_tab.BaseSubTab --+
                          |
                         ChargeConstraintsSubTab

An Input tab sub-tab for charge constraints.

See parent class for documentation on the class variables

Nested Classes [hide private]
type TABLE_MODEL_CLASS
The class of the table model.

Inherited from base_sub_tab.BaseSubTab: PROXY_MODEL_CLASS

Instance Methods [hide private]
 
setup(self)
Sub-tab-specific initialization.
 
addNewConstraint(self)
Add a blank row for a new constraint
 
saveSettings(self, jag_input, eid)
Save sub-tab settings for the specified entry into the given Jaguar handle.
 
loadSettings(self, jag_input, eid, title, struc)
Restore sub-tab settings from the Jaguar handle.
 
emitAddMarker(self, atoms, settings)
Pass along addMarker signals received from the table model or charge_constraints_widgets.AtomSelectionDelegate.
 
emitRemoveMarker(self, atoms)
Pass along removeMarker signals received from the table model or charge_constraints_widgets.AtomSelectionDelegate.
 
_getAtomHash(self, atom)
Convert the given atom into something hashable that depends on the atom entry id and index

Inherited from base_sub_tab.BaseSubTab: __init__, activate, deactivate, emitCountChanged, emitSetMarkerHighlighting, reset, setActive, setDisplayedEids, updateEntryTitles, validate, warning

Class Variables [hide private]
str NAME = "Charge Constraints"
The name of the tab.
module UI_MODULE = sub_tabs_ui.charge_constraints_ui
A module containing a Ui_Form for the sub tab
Instance Variables [hide private]

Inherited from base_sub_tab.BaseSubTab: addMarker, countChanged, removeMarker, setMarkerHighlighting

Method Details [hide private]

setup(self)

 

Sub-tab-specific initialization. This function may be redefined in subclasses.

Overrides: base_sub_tab.BaseSubTab.setup
(inherited documentation)

saveSettings(self, jag_input, eid)

 

Save sub-tab settings for the specified entry into the given Jaguar handle. This function should be redefined in subclasses.

Parameters:
  • jag_input - The Jaguar handle to save settings into
  • eid - The entry id of the structure to save settings for
Overrides: base_sub_tab.BaseSubTab.saveSettings
(inherited documentation)

loadSettings(self, jag_input, eid, title, struc)

 

Restore sub-tab settings from the Jaguar handle. This function should be redefined in subclasses. Note that existing settings for the given entry id should be cleared before the new settings are loaded.

Parameters:
  • jag_input - The Jaguar handle to load settings from
  • eid - The entry id of the structure to load settings for
  • title - The title of the structure
  • struc - The structure that settings are being loaded for. Primarily intended for looking up atom names.
Overrides: base_sub_tab.BaseSubTab.loadSettings
(inherited documentation)

emitAddMarker(self, atoms, settings)

 

Pass along addMarker signals received from the table model or charge_constraints_widgets.AtomSelectionDelegate.

Since this sub-tab allows overlapping charge constraint groups, it's possible to have more than one marker for an atom. Since the panel code can't handle multiple markers per atom, we use "marker counting" to ensure that markers are created and deleted appropriately.

See parent class for argument documentation.

Parameters:
  • atoms - A list of atoms to add the marker for
  • settings - The marker settings
Overrides: base_sub_tab.BaseSubTab.emitAddMarker

emitRemoveMarker(self, atoms)

 

Pass along removeMarker signals received from the table model or charge_constraints_widgets.AtomSelectionDelegate.

Since this sub-tab allows overlapping charge constraint groups, it's possible to have more than one marker for an atom. Since the panel code can't handle multiple markers per atom, we use "marker counting" to ensure that markers are created and deleted appropriately.

See parent class for argument documentation.

Parameters:
  • atoms - A list of atoms to remove the marker for
Overrides: base_sub_tab.BaseSubTab.emitRemoveMarker

_getAtomHash(self, atom)

 

Convert the given atom into something hashable that depends on the atom
entry id and index

@param atom: The atom to convert
@type atom: L{schrodinger.structure._StructureAtom

@return: A hashable object.  (Specifically, a tuple of entry id and atom
index.)
@rtype: tuple