Package Pmv :: Module selectionCommands :: Class MVInvertSelection
[hide private]
[frames] | no frames]

Class MVInvertSelection

source code

ViewerFramework.VFCommand.Command --+    
                                    |    
                  mvCommand.MVCommand --+
                                        |
                                       MVInvertSelection

Inverts current selection. If there is None, the user is given 
       the option of setting the level to Atom and selecting all the atoms
    
Package : Pmv
    
Module  : selectionCommands
    
Class   : MVInvertSelection
    
Command : invertSelection
    
Synopsis:
   
         None <- invertSelection(invertLevel, **kw)
    
Required Arguments:
      
         invertLevel --- 'all' or 'molecule'  
     



Instance Methods [hide private]
  __init__(self)
  onAddCmdToViewer(self)
method called when an instance of this command is added to the viewer.
  setupUndoBefore(self, invertLevel)
This method builds the self.undoCmds string.
  doit(self, invertLevel)
virtual method.
  __call__(self, invertLevel, **kw)
None <--- invertSelection(invertLevel, **kw)
  guiCallback(self)

Inherited from mvCommand.MVCommand: strArg

Inherited from mvCommand.MVCommand (private): _strArg

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


Class Variables [hide private]

Inherited from ViewerFramework.VFCommand.Command: negateKw, objArgOnly


Method Details [hide private]

__init__(self)
(Constructor)

source code 
None
Overrides: mvCommand.MVCommand.__init__

onAddCmdToViewer(self)

source code 
method called when an instance of this command is added to the viewer. This enable viewer-addition time initializations
Overrides: ViewerFramework.VFCommand.Command.onAddCmdToViewer
(inherited documentation)

setupUndoBefore(self, invertLevel)

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, invertLevel)

source code 
virtual method. Has to be implemented by the sub classes
Overrides: ViewerFramework.VFCommand.Command.doit
(inherited documentation)

__call__(self, invertLevel, **kw)
(Call operator)

source code 

None <--- invertSelection(invertLevel, **kw)

invertLevel --- 'all' or 'molecule'
Overrides: ViewerFramework.VFCommand.Command.__call__

guiCallback(self)

source code 
None
Overrides: mvCommand.MVCommand.guiCallback