当前位置: 首页>>代码示例>>Python>>正文


Python EditCommand_PM.EditCommand_PM类代码示例

本文整理汇总了Python中command_support.EditCommand_PM.EditCommand_PM的典型用法代码示例。如果您正苦于以下问题:Python EditCommand_PM类的具体用法?Python EditCommand_PM怎么用?Python EditCommand_PM使用的例子?那么恭喜您, 这里精选的类代码示例或许可以为您提供帮助。


在下文中一共展示了EditCommand_PM类的15个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的Python代码示例。

示例1: update_props_if_needed_before_closing

    def update_props_if_needed_before_closing(self):
        """
        This updates some cosmetic properties of the Plane (e.g. fill color,
        border color, etc.) before closing the Property Manager.
        """

        # Example: The Plane Property Manager is open and the user is
        # 'previewing' the plane. Now the user clicks on "Build > Atoms"
        # to invoke the next command (without clicking "Done").
        # This calls openPropertyManager() which replaces the current PM
        # with the Build Atoms PM.  Thus, it creates and inserts the Plane
        # that was being previewed. Before the plane is permanently inserted
        # into the part, it needs to change some of its cosmetic properties
        # (e.g. fill color, border color, etc.) which distinguishes it as
        # a new plane in the part. This function changes those properties.
        # ninad 2007-06-13

        #called in updatePropertyManager in MWsemeantics.py --(Partwindow class)

        EditCommand_PM.update_props_if_needed_before_closing(self)

        #Don't draw the direction arrow when the object is finalized.
        if self.command.struct and \
           self.command.struct.offsetParentGeometry:

            dirArrow = self.command.struct.offsetParentGeometry.directionArrow
            dirArrow.setDrawRequested(False)
开发者ID:alaindomissy,项目名称:nanoengineer,代码行数:27,代码来源:PlanePropertyManager.py

示例2: close

 def close(self):
     """
     Close this Property manager.
     """
     if self.attachedAtomsListWidget:
         self.attachedAtomsListWidget.clearTags()
     EditCommand_PM.close(self)
开发者ID:elfion,项目名称:nanoengineer,代码行数:7,代码来源:MotorPropertyManager.py

示例3: __init__

    def __init__( self, win, editCommand ):
        """
        Constructor for the Build DNA property manager.
        """
        
        #For model changed signal
        self.previousSelectionParams = None
         
        #Urmi 20080713: set the protein chunk name and its length
        #for the first available chunk and not the selected one, that's
        #not implemented as yet
        
        #self.showProteinParametersAndSequenceEditorForInit(win)
        
        #see self.connect_or_disconnect_signals for comment about this flag
        self.isAlreadyConnected = False
        self.isAlreadyDisconnected = False           
        
        EditCommand_PM.__init__( self, 
                                    win,
                                    editCommand)


        DebugMenuMixin._init1( self )

        self.showTopRowButtons( PM_DONE_BUTTON | \
                                PM_CANCEL_BUTTON | \
                                PM_WHATS_THIS_BUTTON)
开发者ID:ematvey,项目名称:NanoEngineer-1,代码行数:28,代码来源:BuildProtein_PropertyManager.py

示例4: show

 def show(self):
     """
     Show this PM 
     As of 2007-11-20, it also shows the Sequence Editor widget and hides 
     the history widget. This implementation may change in the near future
     """
     EditCommand_PM.show(self) 
     self.updateListWidgets()    
开发者ID:ematvey,项目名称:NanoEngineer-1,代码行数:8,代码来源:BuildDna_PropertyManager.py

示例5: close

 def close(self):
     """
     Overrides superclass close method
     """
     self.sequenceEditor.hide()
     env.history.statusbar_msg("")
     EditCommand_PM.close(self)
     return
开发者ID:alaindomissy,项目名称:nanoengineer,代码行数:8,代码来源:BuildProtein_PropertyManager.py

示例6: close

 def close(self):
     """
     Closes the Property Manager. Overrides EditCommand_PM.close()
     """
     #Clear tags, if any, due to the selection in the self.strandListWidget.
     #self.nanotubeListWidget.clear()
     env.history.statusbar_msg("")
     EditCommand_PM.close(self)
     return
开发者ID:elfion,项目名称:nanoengineer,代码行数:9,代码来源:BuildNanotube_PropertyManager.py

示例7: close

 def close(self):
     """
     Closes the Property Manager. Overrides EditCommand_PM.close()
     """
     #Clear tags, if any, due to the selection in the self.strandListWidget.        
     if self.segmentListWidget:
         self.segmentListWidget.clear()
                
     EditCommand_PM.close(self)
开发者ID:ematvey,项目名称:NanoEngineer-1,代码行数:9,代码来源:BuildNanotube_PropertyManager.py

示例8: show

 def show(self):
     """
     Overrides superclass show method
     """
     env.history.statusbar_msg("")
     self._updateProteinListForShow()
     self._showProteinParametersAndSequenceEditor()
     EditCommand_PM.show(self)
     self.updateMessage()
     return
开发者ID:alaindomissy,项目名称:nanoengineer,代码行数:10,代码来源:BuildProtein_PropertyManager.py

示例9: show

    def show(self):
        """
        Show this PM
        As of 2007-11-20, it also shows the Sequence Editor widget and hides
        the history widget. This implementation may change in the near future
        """
        EditCommand_PM.show(self)

        self.updateMessage("Use appropriate command in the command "\
                               "toolbar to create or modify a DNA Object"\
                               "<br>" )
开发者ID:alaindomissy,项目名称:nanoengineer,代码行数:11,代码来源:BuildDna_PropertyManager.py

示例10: show

    def show(self):
        """
        Show the  motor Property Manager.
        """
        EditCommand_PM.show(self)
        #It turns out that if updateCosmeticProps is called before
        #EditCommand_PM.show, the 'preview' properties are not updated
        #when you are editing an existing R.Motor. Don't know the cause at this
        #time, issue is trivial. So calling it in the end -- Ninad 2007-10-03
        if self.command and self.command.struct:
            self.command.struct.updateCosmeticProps(previewing = True)

        self.updateAttachedAtomListWidget()
开发者ID:elfion,项目名称:nanoengineer,代码行数:13,代码来源:MotorPropertyManager.py

示例11: show

    def show(self):
        """
        Show the PM. Extends superclass method.
        @note: _update_UI_do_updates() gets called immediately after this and
               updates PM widgets with their correct values/settings.
        """

        env.history.statusbar_msg("")
        EditCommand_PM.show(self)

        # NOTE: Think about moving this msg to _update_UI_do_updates() where
        # custom msgs can be created based on the current selection, etc.
        # Mark 2008-12-14
        msg = "Select <b>Insert Nanotube</b> to create a nanotube or " "select an existing nantube to modify it."
        self.updateMessage(msg)
        return
开发者ID:alaindomissy,项目名称:nanoengineer,代码行数:16,代码来源:BuildNanotube_PropertyManager.py

示例12: connect_or_disconnect_signals

    def connect_or_disconnect_signals(self, isConnect):
        """
        Connect or disconnect widget signals sent to their slot methods.
        This can be overridden in subclasses. By default it does nothing.
        @param isConnect: If True the widget will send the signals to the slot
                          method.
        @type  isConnect: boolean
        """
        if isConnect:
            change_connect = self.win.connect
        else:
            change_connect = self.win.disconnect

        EditCommand_PM.connect_or_disconnect_signals(self, isConnect)

        self.attachedAtomsListWidget.connect_or_disconnect_signals(isConnect)
开发者ID:alaindomissy,项目名称:nanoengineer,代码行数:16,代码来源:MotorPropertyManager.py

示例13: __init__

    def __init__(self, command):
        """
        Construct the  Motor Property Manager.
        """

        EditCommand_PM.__init__( self, command)

        msg = "Attach a " + self.title + " to the selected atoms"

        # This causes the "Message" box to be displayed as well.
        self.updateMessage(msg)

        self.glpane = self.win.glpane

        # Hide Restore defaults button for Alpha9.
        self.hideTopRowButtons(PM_PREVIEW_BUTTON | PM_RESTORE_DEFAULTS_BUTTON)
开发者ID:elfion,项目名称:nanoengineer,代码行数:16,代码来源:MotorPropertyManager.py

示例14: __init__

    def __init__( self, command ):
        """
        Constructor for the Build DNA property manager.
        """

        self.current_protein = ""
        self.sequenceEditor = command.win.createProteinSequenceEditorIfNeeded()

        #see self.connect_or_disconnect_signals for comment about this flag
        self.isAlreadyConnected = False
        self.isAlreadyDisconnected = False

        EditCommand_PM.__init__( self, command)

        self.showTopRowButtons( PM_DONE_BUTTON | \
                                PM_CANCEL_BUTTON | \
                                PM_WHATS_THIS_BUTTON)
开发者ID:alaindomissy,项目名称:nanoengineer,代码行数:17,代码来源:BuildProtein_PropertyManager.py

示例15: show

    def show(self):
        """
        Show the Plane Property Manager.
        """
        EditCommand_PM.show(self)
        #It turns out that if updateCosmeticProps is called before 
        #EditCommand_PM.show, the 'preview' properties are not updated 
        #when you are editing an existing plane. Don't know the cause at this
        #time, issue is trivial. So calling it in the end -- Ninad 2007-10-03

        if self.editCommand.struct:

            plane = self.editCommand.struct 
            plane.updateCosmeticProps(previewing = True)
            if plane.imagePath:
                self.imageDisplayFileChooser.setText(plane.imagePath)
            self.imageDisplayCheckBox.setChecked(plane.display_image) 
开发者ID:ematvey,项目名称:NanoEngineer-1,代码行数:17,代码来源:PlanePropertyManager.py


注:本文中的command_support.EditCommand_PM.EditCommand_PM类示例由纯净天空整理自Github/MSDocs等开源代码及文档管理平台,相关代码片段筛选自各路编程大神贡献的开源项目,源码版权归原作者所有,传播和使用请参考对应项目的License;未经允许,请勿转载。