Did I find the right examples for you? yes no      Crawl my project      Python Jobs

All Samples(104)  |  Call(104)  |  Derive(0)  |  Import(0)

src/p/i/PipelineConstructionSet-HEAD/maya/plugins/2014/win64/AM_Ribbon.py   PipelineConstructionSet(Download)
            if selection.length() < 1:
                # if in create mode, use the argument specified with the -curve flag as the selected curve
                if not argData.isQuery() and not argData.isEdit() and argData.isFlagSet(AM_RibbonsCmd.kCurveFlag):
                    selection.add(argData.flagArgumentString(AM_RibbonsCmd.kCurveFlag, 0))
                else:
            if not argData.isQuery():
                # manually specifying a -curve argument will override the selection list in create mode
                if argData.isFlagSet(AM_RibbonsCmd.kCurveFlag):
                    selection.clear()
                    selection.add(argData.flagArgumentString(AM_RibbonsCmd.kCurveFlag, 0))
                # store the curves if command is in create mode or -curve has been specified
                if not argData.isEdit() or (argData.isEdit() and argData.isFlagSet(AM_RibbonsCmd.kCurveFlag)):
            # perform the query
            if argData.isQuery():
                self.__curveArg = argData.isFlagSet(AM_RibbonsCmd.kCurveFlag)
                self.__widthArg = argData.isFlagSet(AM_RibbonsCmd.kWidthFlag)
                self.__divisionsArg = argData.isFlagSet(AM_RibbonsCmd.kDivisionsFlag)

src/p/i/PipelineConstructionSet-HEAD/maya/plugins/2014/win64/AM_ExposeTransform.py   PipelineConstructionSet(Download)
                # if in create mode, use the argument specified with the -object flag as the exposed object
                if not argData.isEdit() and not argData.isQuery() and argData.isFlagSet(
                        AM_ExposeTransformCmd.kExposedObjectFlag):
                    sel.add(argData.flagArgumentString(AM_ExposeTransformCmd.kExposedObjectFlag, 0))
                    sel.getDagPath(sel.length() - 1, self.__exposedObjectArg)
            # perform the query
            if argData.isQuery():
                self.__exposedObjectArg = argData.isFlagSet(AM_ExposeTransformCmd.kExposedObjectFlag)
                self.__referenceObjectArg = argData.isFlagSet(AM_ExposeTransformCmd.kReferenceObjectFlag)
                self.__rotateOrderArg = argData.isFlagSet(AM_ExposeTransformCmd.kRotateOrderFlag)
                self.__normalizeArg = argData.isFlagSet(AM_ExposeTransformCmd.kNormalizeFlag)

src/p/i/PipelineConstructionSet-HEAD/maya/plugins/2014/win64/AM_ShoulderConstraint.py   PipelineConstructionSet(Download)
                # create mode supports a variety of patterns
                else:
                    isShoulderSpecified = argData.isFlagSet(AM_ShoulderConstraintCmd.kShoulderObjectFlag)
                    isSpineSpecified = argData.isFlagSet(AM_ShoulderConstraintCmd.kSpineObjectFlag)
                    # selection list is either [spine, constraintObject] with shoulder flag, or [shoulder, constrainedObject] with spine flag
                            raise Exception('%s is not a valid transform node.' % selectedObjectFn.name())
                        # verify that a shoulder and spine have been specified
                        if not argData.isFlagSet(AM_ShoulderConstraintCmd.kShoulderObjectFlag) or not argData.isFlagSet(
                                AM_ShoulderConstraintCmd.kSpineObjectFlag):
                            raise Exception(
            # perform the query
            if argData.isQuery():
                self.__shoulderObjectArg = argData.isFlagSet(AM_ShoulderConstraintCmd.kShoulderObjectFlag)
                self.__spineObjectArg = argData.isFlagSet(AM_ShoulderConstraintCmd.kSpineObjectFlag)
                self.__raisedAngleArg = argData.isFlagSet(AM_ShoulderConstraintCmd.kRaisedAngleFlag)

src/p/i/PipelineConstructionSet-HEAD/python/maya/site-packages/pymel-1.0.5/pymel/tools/scriptEditor/pymelScrollFieldReporter.py   PipelineConstructionSet(Download)
            reporter = reporters[name]
            for key,data in filterFlags.items():
                if argData.isFlagSet( key ):
                    self.setResult( reporter.filters[ key ] )
                    return
 
            for key,data in globalFilterFlags.items():
                if argData.isFlagSet( key ):
                    return
 
            if argData.isFlagSet( kCmdReporter[0] ):
                self.setResult( reporter.cmdReporter )
 
        else:
            filters = {}
            for key,data in filterFlags.items():
                if argData.isFlagSet( key ):
            globalFilters = {}
            for key,data in globalFilterFlags.items():
                if argData.isFlagSet( key ):
                    if data[1] == OpenMaya.MSyntax.kBoolean:
                        globalFilters[key] = argData.flagArgumentBool( key, 0 )

src/p/i/PipelineConstructionSet-HEAD/python/maya/site-packages/pymel-1.0.3/pymel/tools/scriptEditor/pymelScrollFieldReporter.py   PipelineConstructionSet(Download)
            reporter = reporters[name]
            for key,data in filterFlags.items():
                if argData.isFlagSet( key ):
                    self.setResult( reporter.filters[ key ] )
                    return
 
            for key,data in globalFilterFlags.items():
                if argData.isFlagSet( key ):
                    return
 
            if argData.isFlagSet( kCmdReporter[0] ):
                self.setResult( reporter.cmdReporter )
 
        else:
            filters = {}
            for key,data in filterFlags.items():
                if argData.isFlagSet( key ):
            globalFilters = {}
            for key,data in globalFilterFlags.items():
                if argData.isFlagSet( key ):
                    if data[1] == OpenMaya.MSyntax.kBoolean:
                        globalFilters[key] = argData.flagArgumentBool( key, 0 )

src/p/i/PipelineConstructionSet-HEAD/maya/plugins/2014/win64/AM_HipConstraint.py   PipelineConstructionSet(Download)
                # create mode supports a variety of patterns
                else:
                    isHipSpecified = argData.isFlagSet(AM_HipConstraintCmd.kHipObjectFlag)
                    isPelvisSpecified = argData.isFlagSet(AM_HipConstraintCmd.kPelvisObjectFlag)
                    # selection list is either [pelvis, constraintObject] with hip flag, or [hip, constrainedObject] with pelvis flag
            # perform the query
            if argData.isQuery():
                self.__hipObjectArg = argData.isFlagSet(AM_HipConstraintCmd.kHipObjectFlag)
                self.__pelvisObjectArg = argData.isFlagSet(AM_HipConstraintCmd.kPelvisObjectFlag)
                self.__hipAimAxisArg = argData.isFlagSet(AM_HipConstraintCmd.kHipAimFlag)

src/p/y/pymel-HEAD/pymel/tools/scriptEditor/pymelScrollFieldReporter.py   pymel(Download)
            reporter = reporters[name]
            for key,data in filterFlags.items():
                if argData.isFlagSet( key ):
                    self.setResult( reporter.filters[ key ] )
                    return
 
            for key,data in globalFilterFlags.items():
                if argData.isFlagSet( key ):
                    return
 
            if argData.isFlagSet( kCmdReporter[0] ):
                self.setResult( reporter.cmdReporter )
 
        else:
            filters = {}
            for key,data in filterFlags.items():
                if argData.isFlagSet( key ):
            globalFilters = {}
            for key,data in globalFilterFlags.items():
                if argData.isFlagSet( key ):
                    if data[1] == OpenMaya.MSyntax.kBoolean:
                        globalFilters[key] = argData.flagArgumentBool( key, 0 )

src/p/i/PipelineConstructionSet-HEAD/maya/plugins/2014/win64/AM_InsertParentsCmd.py   PipelineConstructionSet(Download)
                iter.next()
            self.__selection = newSelectionList  # at this point, the selection list consists of only DAG nodes
            if argData.isFlagSet(AM_InsertParentsCmd.kPrefixFlag):
                self.__suffix = ''
                self.__prefix = argData.flagArgumentString(AM_InsertParentsCmd.kPrefixFlag, 0)
                self.validateAffix(self.__prefix)
            if argData.isFlagSet(AM_InsertParentsCmd.kSuffixFlag):
                self.__suffix = argData.flagArgumentString(AM_InsertParentsCmd.kSuffixFlag, 0)
                self.validateAffix(self.__suffix)
            if argData.isFlagSet(AM_InsertParentsCmd.kScaleFlag):

src/r/e/Red9_StudioPack-HEAD/plug-ins/SnapRuntime.py   Red9_StudioPack(Download)
        #do this as when called this object is in the API world not Python
        argData = OpenMaya.MArgDatabase(self.syntax(), args)
        if argData.isFlagSet(self.kSourceFlag):
            Source=argData.flagArgumentString(self.kSourceFlag, 0)
        if argData.isFlagSet(self.kDestinationFlag):
            Destin=argData.flagArgumentString(self.kDestinationFlag, 0)
        if argData.isFlagSet(self.kTimeFlag):
            self.TimeEnabled=argData.flagArgumentBool(self.kTimeFlag, 0)  
        if argData.isFlagSet(self.kTransFlag):
        if argData.isFlagSet(self.kTransFlag):
            self.snapTranslation=argData.flagArgumentBool(self.kTransFlag, 0)  
        if argData.isFlagSet(self.kRotsFlag):
            self.snapRotation=argData.flagArgumentBool(self.kRotsFlag, 0)  
            #print ('timeEnabled',self.TimeEnabled)