Package Pmv :: Module traceCommands :: Class DisplayTraceCommand
[hide private]
[frames] | no frames]

Class DisplayTraceCommand

source code

 ViewerFramework.VFCommand.Command --+        
                                     |        
                   mvCommand.MVCommand --+    
                                         |    
ViewerFramework.VFCommand.ICOM --+       |    
                                 |       |    
                  mvCommand.MVICOM --+   |    
                                     |   |    
                  mvCommand.MVAtomICOM --+    
                                         |    
            displayCommands.DisplayCommand --+
                                             |
                                            DisplayTraceCommand

This command allows the user to display, undisplay or display only the current selection using the extruded trace representation of the given
    traceName.
    
Package : Pmv
    
Module  : traceCommands
    
Class   : DisplayTraceCommand
    
Command : displayTrace
    
keywords: display trace CA...
    
Synopsis:

        None <- displayTrace(nodes, traceName, negate=0, only=0, **kw)
    
Required Arguments:
    
        nodes --- any set of MolKit nodes describing molecular components.
    
Optional Arguments:
   
        traceName --- string representing the extruded trace to be displayed,
                    undisplayed or displayed only
        
negate --- flag when set to 1 undisplay the trace corresponding to
                    the current selection
        
only --- flag when set to 1 the part of the trace geometry
                    corresponding to the current selection will be displayed
                    only.
     



Instance Methods [hide private]
  onAddCmdToViewer(self)
method called when an instance of this command is added to the viewer.
  setupUndoBefore(self, nodes, traceName='CATrace', only=False, negate=False)
This method builds the self.undoCmds string.
  doit(self, nodes, traceName='CATrace', only=False, negate=False)
displays the secondary structure for the selected treenodes
  buildFormDescr(self, formName)
descr <- buildFormDescr(self, formName): this virtual method is implemented in the classes derived from Command.
  guiCallback(self)
Default callback function called by the gui
  __call__(self, nodes, traceName='CATrace', only=False, negate=False, **kw)
None <- displayTrace(nodes, traceName, negate=False, only=False, **kw) Required Arguments: nodes --- any set of MolKit nodes describing molecular components.

Inherited from displayCommands.DisplayCommand: __init__, getFormValues, getLastUsedValues, getNodes, handleDisplayValue, handleNegateOnly, setLastUsedValues, updateGeom

Inherited from mvCommand.MVCommand: strArg

Inherited from mvCommand.MVCommand (private): _strArg

Inherited from ViewerFramework.VFCommand.Command: __repr__, addCallbackAfter, addCallbackBefore, addUndoCall, afterDoit, beforeDoit, buildLogArgList, checkDependencies, cleanup, customizeGUI, doitWrapper, getArguments, getHelp, getLogArgs, getValNamedArgs, log, logString, onAddNewCmd, onCmdRun, setupUndoAfter, showForm, tkCb, warningMsg

Inherited from mvCommand.MVAtomICOM: getObjects

Inherited from ViewerFramework.VFCommand.ICOM: initICOM, startICOM, stopICOM


Class Variables [hide private]

Inherited from ViewerFramework.VFCommand.Command: negateKw, objArgOnly


Method Details [hide private]

onAddCmdToViewer(self)

source code 
method called when an instance of this command is added to the viewer. This enable viewer-addition time initializations
Overrides: displayCommands.DisplayCommand.onAddCmdToViewer

setupUndoBefore(self, nodes, traceName='CATrace', only=False, negate=False)

source code 
This method builds the self.undoCmds string. This method should have the same signature than the __call__. When this string is executed it should undo the actions of this command. This string will be appended to the undoCmdStack list if the command is successfuly carried out. This method handles only commands with the negateKw. Other commands have to overwrite it.
Overrides: ViewerFramework.VFCommand.Command.setupUndoBefore
(inherited documentation)

doit(self, nodes, traceName='CATrace', only=False, negate=False)

source code 
displays the secondary structure for the selected treenodes
Overrides: ViewerFramework.VFCommand.Command.doit

buildFormDescr(self, formName)

source code 
descr <- buildFormDescr(self, formName): this virtual method is implemented in the classes derived from Command. This is where the inputFormDescr is created and the description of the widgets appended. If a command has several inputForm buildFormDescr should build all the inputFormDescr and you do a if / elif check to know which one to create. formName : string name of the form corresponding to this descr.
Overrides: displayCommands.DisplayCommand.buildFormDescr

guiCallback(self)

source code 
Default callback function called by the gui
Overrides: displayCommands.DisplayCommand.guiCallback

__call__(self, nodes, traceName='CATrace', only=False, negate=False, **kw)
(Call operator)

source code 
None <- displayTrace(nodes, traceName, negate=False, only=False, **kw)
        
Required Arguments:

            nodes --- any set of MolKit nodes describing molecular components.
        
Optional Arguments:

            traceName --- string representing the extruded trace to be displayed,
                    undisplayed or displayed only
            
negate --- flag when set to True undisplay the trace corresponding to
                    the current selection
            
only --- flag when set to True the part of the trace geometry
                    corresponding to the current selection will be displayed
                    only.
        

Overrides: ViewerFramework.VFCommand.Command.__call__