Beispiel #1
0
 def Activated(self):
     V = getDrawingPageGUIVars()
     d.activate(V, dialogTitle='Add Center Lines', dialogIconPath=os.path.join( iconPath , 'centerLine.svg' ), endFunction=self.Activated )
     d.SVGFun = centerLineSVG
     maskBrush  =   QtGui.QBrush( QtGui.QColor(0,160,0,100) )
     maskPen =      QtGui.QPen( QtGui.QColor(0,160,0,100) )
     maskPen.setWidth(0.0)
     maskHoverPen = QtGui.QPen( QtGui.QColor(0,255,0,255) )
     maskHoverPen.setWidth(0.0)
     selectionOverlay.generateSelectionGraphicsItems( 
         [obj for obj in V.page.Group  if not obj.Name.startswith('dim') and not obj.Name.startswith('center')], 
         selectFun,
         transform = V.transform,
         sceneToAddTo = V.graphicsScene, 
         doPoints=True, doMidPoints=True,
         pointWid=1.0,
         maskPen=maskPen, 
         maskHoverPen=maskHoverPen, 
         maskBrush = maskBrush
         )
     selectionOverlay.generateSelectionGraphicsItems( 
         [obj for obj in V.page.Group  if not obj.Name.startswith('dim') and not obj.Name.startswith('center')],
         clearPreviousSelectionItems = False,
         doLines=True, 
         onClickFun=selectFun,
         transform = V.transform,
         sceneToAddTo = V.graphicsScene, 
         maskPen= line_maskPen, 
         maskHoverPen= line_maskHoverPen, 
         maskBrush = line_maskBrush
         )
     selectionOverlay.addProxyRectToRescaleGraphicsSelectionItems( V.graphicsScene, V.graphicsView, V.width, V.height)
 def Activated(self):
     V = getDrawingPageGUIVars()
     dimensioning.activate( V, ['strokeWidth','arrowL1','arrowL2','arrowW','gap_datum_points', 'dimension_line_overshoot'], ['lineColor'], ['textRenderer'] )
     commonArgs = dict( 
         onClickFun=selectDimensioningPoint,
         transform = V.transform,
         sceneToAddTo = V.graphicsScene, 
         pointWid=1.0,
         maskPen=maskPen, 
         maskHoverPen=maskHoverPen, 
         maskBrush = maskBrush
         )
     selectionOverlay.generateSelectionGraphicsItems( 
         [obj for obj in V.page.Group  if not obj.Name.startswith('dim') and not obj.Name.startswith('center')],
         doPoints=True, 
         **commonArgs
         )
     selectionOverlay.generateSelectionGraphicsItems( 
         [obj for obj in V.page.Group if obj.Name.startswith('center')], 
         clearPreviousSelectionItems = False,
         doPathEndPoints=True, 
         **commonArgs
         )
     selectionOverlay.generateSelectionGraphicsItems( 
         [obj for obj in V.page.Group  if not obj.Name.startswith('dim') and not obj.Name.startswith('center')],
         clearPreviousSelectionItems = False,
         doLines=True, 
         onClickFun=selectDimensioningPoint,
         transform = V.transform,
         sceneToAddTo = V.graphicsScene, 
         maskPen= line_maskPen, 
         maskHoverPen= line_maskHoverPen, 
         maskBrush = line_maskBrush
         )
     selectionOverlay.addProxyRectToRescaleGraphicsSelectionItems( V.graphicsScene, V.graphicsView, V.width, V.height)
 def Activated(self):
     V = getDrawingPageGUIVars()
     dimensioning.activate(V, [
         'strokeWidth', 'arrowL1', 'arrowL2', 'arrowW', 'gap_datum_points',
         'dimension_line_overshoot'
     ], ['lineColor'], ['textRenderer'])
     selectionOverlay.generateSelectionGraphicsItems(
         [obj for obj in V.page.Group if not obj.Name.startswith('dim')],
         selectFun,
         transform=V.transform,
         sceneToAddTo=V.graphicsScene,
         doLines=True,
         maskPen=line_maskPen,
         maskHoverPen=line_maskHoverPen,
         maskBrush=line_maskBrush)
     selectionOverlay.generateSelectionGraphicsItems(
         [obj for obj in V.page.Group if not obj.Name.startswith('dim')],
         selectFun,
         transform=V.transform,
         sceneToAddTo=V.graphicsScene,
         doPoints=True,
         maskPen=point_maskPen,
         maskHoverPen=point_maskHoverPen,
         maskBrush=point_maskBrush,  #clear
         clearPreviousSelectionItems=False,
     )
     selectionOverlay.addProxyRectToRescaleGraphicsSelectionItems(
         V.graphicsScene, V.graphicsView, V.width, V.height)
 def Activated(self):
     V = getDrawingPageGUIVars()
     d.activate( V, dialogTitle='Add Linear Dimension Stack', dialogIconPath = self.iconPath, endFunction = self.Activated )
     commonArgs = dict( 
         onClickFun=stack_selectDimensioningPoint,
         transform = V.transform,
         sceneToAddTo = V.graphicsScene, 
         pointWid=1.0,
         maskPen=maskPen, 
         maskHoverPen=maskHoverPen, 
         maskBrush = maskBrush
         )
     selectionOverlay.generateSelectionGraphicsItems( 
         [obj for obj in V.page.Group  if not obj.Name.startswith('dim') and not obj.Name.startswith('center')],
         doPoints=True, 
         **commonArgs
         )
     selectionOverlay.generateSelectionGraphicsItems( 
         [obj for obj in V.page.Group if obj.Name.startswith('center')], 
         clearPreviousSelectionItems = False,
         doPathEndPoints=True, 
         **commonArgs
         )
     selectionOverlay.generateSelectionGraphicsItems( 
         [obj for obj in V.page.Group  if not obj.Name.startswith('dim') and not obj.Name.startswith('center')],
         clearPreviousSelectionItems = False,
         doLines=True, 
         onClickFun=stack_selectDimensioningPoint,
         transform = V.transform,
         sceneToAddTo = V.graphicsScene, 
         maskPen= line_maskPen, 
         maskHoverPen= line_maskHoverPen, 
         maskBrush = line_maskBrush
         )
     selectionOverlay.addProxyRectToRescaleGraphicsSelectionItems( V.graphicsScene, V.graphicsView, V.width, V.height)
 def Activated(self):
     V = getDrawingPageGUIVars()
     d.activate(V,
                dialogTitle='Add Welding Note',
                dialogIconPath=self.generateIcon(),
                endFunction=self.Activated)
     d.proxy_svgFun = Command_svg_fun_wrapper(self)
     from grabPointAdd import Proxy_grabPoint
     selectionOverlay.generateSelectionGraphicsItems(
         dimensionableObjects(V.page) + [
             obj for obj in V.page.Group if hasattr(obj, 'Proxy')
             and isinstance(obj.Proxy, Proxy_grabPoint)
         ],
         self.selectFun,
         transform=V.transform,
         sceneToAddTo=V.graphicsScene,
         doPoints=True,
         doMidPoints=True,
         pointWid=1.0,
         maskPen=maskPen,
         maskHoverPen=maskHoverPen,
         maskBrush=maskBrush  #clear
     )
     selectionOverlay.addProxyRectToRescaleGraphicsSelectionItems(
         V.graphicsScene, V.graphicsView, V.width, V.height)
Beispiel #6
0
 def Activated(self):
     V = getDrawingPageGUIVars()
     d.activate(V, dialogTitle='Add Angular Dimension', dialogIconPath=':/dd/icons/angularDimension.svg', endFunction=self.Activated )
     selectionOverlay.generateSelectionGraphicsItems( 
         dimensionableObjects( V.page ), 
         selectFun ,
         transform = V.transform,
         sceneToAddTo = V.graphicsScene, 
         doLines=True,
         maskPen= line_maskPen, 
         maskHoverPen= line_maskHoverPen, 
         maskBrush = line_maskBrush
         )
     selectionOverlay.generateSelectionGraphicsItems( 
         dimensionableObjects( V.page ),
         selectFun ,
         transform = V.transform,
         sceneToAddTo = V.graphicsScene, 
         doPoints=True, 
         maskPen= point_maskPen, 
         maskHoverPen= point_maskHoverPen, 
         maskBrush = point_maskBrush, #clear
         clearPreviousSelectionItems = False,
         )
     selectionOverlay.addProxyRectToRescaleGraphicsSelectionItems(V.graphicsScene, V.graphicsView, V.width, V.height)
 def Activated(self):
     V = getDrawingPageGUIVars()
     d.activate(V, dialogTitle='Add Angular Dimension', dialogIconPath=os.path.join( iconPath , 'angularDimension.svg' ), endFunction=self.Activated )
     selectionOverlay.generateSelectionGraphicsItems( 
         [obj for obj in V.page.Group  if not obj.Name.startswith('dim')], 
         selectFun ,
         transform = V.transform,
         sceneToAddTo = V.graphicsScene, 
         doLines=True,
         maskPen= line_maskPen, 
         maskHoverPen= line_maskHoverPen, 
         maskBrush = line_maskBrush
         )
     selectionOverlay.generateSelectionGraphicsItems( 
         [obj for obj in V.page.Group  if not obj.Name.startswith('dim')], 
         selectFun ,
         transform = V.transform,
         sceneToAddTo = V.graphicsScene, 
         doPoints=True, 
         maskPen= point_maskPen, 
         maskHoverPen= point_maskHoverPen, 
         maskBrush = point_maskBrush, #clear
         clearPreviousSelectionItems = False,
         )
     selectionOverlay.addProxyRectToRescaleGraphicsSelectionItems( V.graphicsScene, V.graphicsView, V.width, V.height)
Beispiel #8
0
 def Activated(self):
     V = getDrawingPageGUIVars()
     d.activate(V,
                dialogTitle='Add Angular Dimension',
                dialogIconPath=':/dd/icons/angularDimension.svg',
                endFunction=self.Activated)
     selectionOverlay.generateSelectionGraphicsItems(
         dimensionableObjects(V.page),
         selectFun,
         transform=V.transform,
         sceneToAddTo=V.graphicsScene,
         doLines=True,
         maskPen=line_maskPen,
         maskHoverPen=line_maskHoverPen,
         maskBrush=line_maskBrush)
     selectionOverlay.generateSelectionGraphicsItems(
         dimensionableObjects(V.page),
         selectFun,
         transform=V.transform,
         sceneToAddTo=V.graphicsScene,
         doPoints=True,
         maskPen=point_maskPen,
         maskHoverPen=point_maskHoverPen,
         maskBrush=point_maskBrush,  #clear
         clearPreviousSelectionItems=False,
     )
     selectionOverlay.addProxyRectToRescaleGraphicsSelectionItems(
         V.graphicsScene, V.graphicsView, V.width, V.height)
 def Activated(self):
     V = getDrawingPageGUIVars()
     d.activate(V, dialogTitle='Add Center Lines', dialogIconPath=':/dd/icons/centerLine.svg', endFunction=self.Activated )
     d.SVGFun = centerLineSVG
     d.ProxyClass = Proxy_CenterLines
     d.proxy_svgFun = centerLineSVG
     maskBrush  =   QtGui.QBrush( QtGui.QColor(0,160,0,100) )
     maskPen =      QtGui.QPen( QtGui.QColor(0,160,0,100) )
     maskPen.setWidth(0.0)
     maskHoverPen = QtGui.QPen( QtGui.QColor(0,255,0,255) )
     maskHoverPen.setWidth(0.0)
     selectionOverlay.generateSelectionGraphicsItems( 
         dimensionableObjects( V.page ), 
         selectFun,
         transform = V.transform,
         sceneToAddTo = V.graphicsScene, 
         doPoints=True, doMidPoints=True,
         pointWid=1.0,
         maskPen=maskPen, 
         maskHoverPen=maskHoverPen, 
         maskBrush = maskBrush
         )
     selectionOverlay.generateSelectionGraphicsItems( 
         dimensionableObjects( V.page ),
         clearPreviousSelectionItems = False,
         doLines=True, 
         onClickFun=selectFun,
         transform = V.transform,
         sceneToAddTo = V.graphicsScene, 
         maskPen= line_maskPen, 
         maskHoverPen= line_maskHoverPen, 
         maskBrush = line_maskBrush
         )
     selectionOverlay.addProxyRectToRescaleGraphicsSelectionItems( V.graphicsScene, V.graphicsView, V.width, V.height)
 def Activated(self):
     V = getDrawingPageGUIVars()
     d.activate(V,
                dialogTitle='Add Angular Dimension',
                dialogIconPath=os.path.join(iconPath,
                                            'angularDimension.svg'),
                endFunction=self.Activated)
     selectionOverlay.generateSelectionGraphicsItems(
         [obj for obj in V.page.Group if not obj.Name.startswith('dim')],
         selectFun,
         transform=V.transform,
         sceneToAddTo=V.graphicsScene,
         doLines=True,
         maskPen=line_maskPen,
         maskHoverPen=line_maskHoverPen,
         maskBrush=line_maskBrush)
     selectionOverlay.generateSelectionGraphicsItems(
         [obj for obj in V.page.Group if not obj.Name.startswith('dim')],
         selectFun,
         transform=V.transform,
         sceneToAddTo=V.graphicsScene,
         doPoints=True,
         maskPen=point_maskPen,
         maskHoverPen=point_maskHoverPen,
         maskBrush=point_maskBrush,  #clear
         clearPreviousSelectionItems=False,
     )
     selectionOverlay.addProxyRectToRescaleGraphicsSelectionItems(
         V.graphicsScene, V.graphicsView, V.width, V.height)
 def Activated(self):
     V = getDrawingPageGUIVars()
     dimensioning.activate(V, ['strokeWidth','arrowL1','arrowL2','arrowW','gap_datum_points', 'dimension_line_overshoot'], ['lineColor'], ['textRenderer'] )
     selectionOverlay.generateSelectionGraphicsItems( 
         [obj for obj in V.page.Group  if not obj.Name.startswith('dim')], 
         selectFun ,
         transform = V.transform,
         sceneToAddTo = V.graphicsScene, 
         doLines=True,
         maskPen= line_maskPen, 
         maskHoverPen= line_maskHoverPen, 
         maskBrush = line_maskBrush
         )
     selectionOverlay.generateSelectionGraphicsItems( 
         [obj for obj in V.page.Group  if not obj.Name.startswith('dim')], 
         selectFun ,
         transform = V.transform,
         sceneToAddTo = V.graphicsScene, 
         doPoints=True, 
         maskPen= point_maskPen, 
         maskHoverPen= point_maskHoverPen, 
         maskBrush = point_maskBrush, #clear
         clearPreviousSelectionItems = False,
         )
     selectionOverlay.addProxyRectToRescaleGraphicsSelectionItems( V.graphicsScene, V.graphicsView, V.width, V.height)
Beispiel #12
0
 def Activated(self):
     V = getDrawingPageGUIVars()
     d.activate(V, 'Add Radial Dimension', dialogIconPath=':/dd/icons/radiusDimension.svg', endFunction=self.Activated)
     selectionOverlay.generateSelectionGraphicsItems(
         dimensionableObjects( V.page ),
         selectFun ,
         transform = V.transform,
         sceneToAddTo = V.graphicsScene,
         doCircles=True, doFittedCircles=True,
         maskPen=maskPen,
         maskHoverPen=maskHoverPen,
         maskBrush = QtGui.QBrush() #clear
         )
     selectionOverlay.addProxyRectToRescaleGraphicsSelectionItems( V.graphicsScene, V.graphicsView, V.width, V.height)
 def Activated(self):
     V = getDrawingPageGUIVars()
     d.activate(V, 'Add Radial Dimension', dialogIconPath=os.path.join( iconPath , 'radiusDimension.svg' ), endFunction=self.Activated)
     selectionOverlay.generateSelectionGraphicsItems(
         [obj for obj in V.page.Group  if not obj.Name.startswith('dim')],
         selectFun ,
         transform = V.transform,
         sceneToAddTo = V.graphicsScene,
         doCircles=True, doFittedCircles=True,
         maskPen=maskPen,
         maskHoverPen=maskHoverPen,
         maskBrush = QtGui.QBrush() #clear
         )
     selectionOverlay.addProxyRectToRescaleGraphicsSelectionItems( V.graphicsScene, V.graphicsView, V.width, V.height)
 def Activated(self):
     V = getDrawingPageGUIVars()
     d.activate(V, dialogTitle='Add Welding Note', dialogIconPath=self.generateIcon(), endFunction=self.Activated )
     selectionOverlay.generateSelectionGraphicsItems( 
         [obj for obj in V.page.Group  if not obj.Name.startswith('dim') and not obj.Name.startswith('center')], 
         self.selectFun ,
         transform = V.transform,
         sceneToAddTo = V.graphicsScene, 
         doPoints=True, doMidPoints=True,
         pointWid=1.0,
         maskPen=maskPen, 
         maskHoverPen=maskHoverPen, 
         maskBrush = maskBrush #clear
         )
     selectionOverlay.addProxyRectToRescaleGraphicsSelectionItems( V.graphicsScene, V.graphicsView, V.width, V.height)
Beispiel #15
0
 def Activated(self):
     V = getDrawingPageGUIVars()
     d.activate(V, dialogTitle='Delete Dimension', dialogIconPath=':/dd/icons/deleteDimension.svg' , endFunction=self.Activated, grid=False)
     selectionOverlay.generateSelectionGraphicsItems( 
         [obj for obj in V.page.Group  if hasattr(obj,'Proxy') and isinstance(obj.Proxy, Proxy_DimensionObject_prototype)], 
         doSelectViewObjectPoints = True, 
         onClickFun=deleteDimension,
         sceneToAddTo = V.graphicsScene, 
         transform = V.transform,
         pointWid=1.0,
         maskPen=maskPen, 
         maskHoverPen=maskHoverPen, 
         maskBrush = maskBrush
         )
     selectionOverlay.addProxyRectToRescaleGraphicsSelectionItems(V.graphicsScene, V.graphicsView, V.width, V.height)
 def Activated(self):
     V = getDrawingPageGUIVars()
     d.activate(V, dialogTitle='Add Welding Note', dialogIconPath=self.generateIcon(), endFunction=self.Activated )
     selectionOverlay.generateSelectionGraphicsItems( 
         [obj for obj in V.page.Group  if not obj.Name.startswith('dim') and not obj.Name.startswith('center')], 
         self.selectFun ,
         transform = V.transform,
         sceneToAddTo = V.graphicsScene, 
         doPoints=True, doMidPoints=True,
         pointWid=1.0,
         maskPen=maskPen, 
         maskHoverPen=maskHoverPen, 
         maskBrush = maskBrush #clear
         )
     selectionOverlay.addProxyRectToRescaleGraphicsSelectionItems( V.graphicsScene, V.graphicsView, V.width, V.height)
 def Activated(self):
     V = getDrawingPageGUIVars()
     d.activate(V, dialogTitle='Delete Dimension', dialogIconPath=':/dd/icons/deleteDimension.svg' , endFunction=self.Activated, grid=False)
     selectionOverlay.generateSelectionGraphicsItems( 
         [obj for obj in V.page.Group  if hasattr(obj,'Proxy') and isinstance(obj.Proxy, Proxy_DimensionObject_prototype)], 
         doSelectViewObjectPoints = True, 
         onClickFun=deleteDimension,
         sceneToAddTo = V.graphicsScene, 
         transform = V.transform,
         pointWid=1.0,
         maskPen=maskPen, 
         maskHoverPen=maskHoverPen, 
         maskBrush = maskBrush
         )
     selectionOverlay.addProxyRectToRescaleGraphicsSelectionItems( V.graphicsScene, V.graphicsView, V.width, V.height)
 def Activated(self):
     V = getDrawingPageGUIVars()
     dimensioning.activate(V, ['strokeWidth','arrowL1','arrowL2','arrowW'], ['lineColor'], ['textRenderer'] )
     selectionOverlay.generateSelectionGraphicsItems( 
         [obj for obj in V.page.Group  if not obj.Name.startswith('dim') and not obj.Name.startswith('center')], 
         self.selectFun ,
         transform = V.transform,
         sceneToAddTo = V.graphicsScene, 
         doPoints=True, doMidPoints=True,
         pointWid=1.0,
         maskPen=maskPen, 
         maskHoverPen=maskHoverPen, 
         maskBrush = maskBrush #clear
         )
     selectionOverlay.addProxyRectToRescaleGraphicsSelectionItems( V.graphicsScene, V.graphicsView, V.width, V.height)
Beispiel #19
0
 def Activated(self):
     V = getDrawingPageGUIVars()
     d.activate(V, dialogTitle='Add Note Circle', dialogIconPath=':/dd/icons/noteCircle.svg', endFunction=self.Activated )
     from grabPointAdd import  Proxy_grabPoint
     selectionOverlay.generateSelectionGraphicsItems(
         dimensionableObjects( V.page ) + [obj for obj in V.page.Group if hasattr(obj,'Proxy') and isinstance( obj.Proxy, Proxy_grabPoint) ],
         selectFun,
         transform = V.transform,
         sceneToAddTo = V.graphicsScene,
         doPoints=True, doMidPoints=True, doSelectViewObjectPoints = True, 
         pointWid=1.0,
         maskPen=maskPen,
         maskHoverPen=maskHoverPen,
         maskBrush = maskBrush
         )
     selectionOverlay.addProxyRectToRescaleGraphicsSelectionItems(V.graphicsScene, V.graphicsView, V.width, V.height)
 def Activated(self):
     V = getDrawingPageGUIVars()
     dimensioning.activate(V, ['strokeWidth','centerPointDia'], ['lineColor'], ['textRenderer'])
     #dimensioning.SVGFun = noteCircleSVG
     selectionOverlay.generateSelectionGraphicsItems(
         [obj for obj in V.page.Group  if not obj.Name.startswith('dim') and not obj.Name.startswith('center')],
         selectFun,
         transform = V.transform,
         sceneToAddTo = V.graphicsScene,
         doPoints=True, doMidPoints=True,
         pointWid=1.0,
         maskPen=maskPen,
         maskHoverPen=maskHoverPen,
         maskBrush = maskBrush
         )
     selectionOverlay.addProxyRectToRescaleGraphicsSelectionItems( V.graphicsScene, V.graphicsView, V.width, V.height)
Beispiel #21
0
 def Activated(self):
     V = getDrawingPageGUIVars()
     d.activate(V, dialogTitle='Add Note Circle', dialogIconPath=':/dd/icons/noteCircle.svg', endFunction=self.Activated )
     from grabPointAdd import  Proxy_grabPoint
     selectionOverlay.generateSelectionGraphicsItems(
         dimensionableObjects( V.page ) + [obj for obj in V.page.Group if hasattr(obj,'Proxy') and isinstance( obj.Proxy, Proxy_grabPoint) ],
         selectFun,
         transform = V.transform,
         sceneToAddTo = V.graphicsScene,
         doPoints=True, doMidPoints=True, doSelectViewObjectPoints = True, 
         pointWid=1.0,
         maskPen=maskPen,
         maskHoverPen=maskHoverPen,
         maskBrush = maskBrush
         )
     selectionOverlay.addProxyRectToRescaleGraphicsSelectionItems( V.graphicsScene, V.graphicsView, V.width, V.height)
 def Activated(self):
     V = getDrawingPageGUIVars()
     d.activate(V, dialogTitle='Add Welding Note', dialogIconPath=self.generateIcon(), endFunction=self.Activated )
     d.proxy_svgFun = Command_svg_fun_wrapper(self)
     from grabPointAdd import  Proxy_grabPoint
     selectionOverlay.generateSelectionGraphicsItems( 
         dimensionableObjects( V.page ) + [obj for obj in V.page.Group if hasattr(obj,'Proxy') and isinstance( obj.Proxy, Proxy_grabPoint) ],
         self.selectFun ,
         transform = V.transform,
         sceneToAddTo = V.graphicsScene, 
         doPoints=True, doMidPoints=True,
         pointWid=1.0,
         maskPen=maskPen, 
         maskHoverPen=maskHoverPen, 
         maskBrush = maskBrush #clear
         )
     selectionOverlay.addProxyRectToRescaleGraphicsSelectionItems( V.graphicsScene, V.graphicsView, V.width, V.height)
 def Activated(self):
     V = self.Activated_common()
     dimensioning.SVGFun = centerLinesSVG
     maskPen =      QtGui.QPen( QtGui.QColor(0,255,0,100) )
     maskPen.setWidth(2.0)
     maskHoverPen = QtGui.QPen( QtGui.QColor(0,255,0,255) )
     maskHoverPen.setWidth(2.0)
     selectionOverlay.generateSelectionGraphicsItems( 
         [obj for obj in V.page.Group  if not obj.Name.startswith('dim')], 
         selectFun ,
         transform = V.transform,
         sceneToAddTo = V.graphicsScene, 
         doCircles=True, doFittedCircles=True, 
         maskPen=maskPen, 
         maskHoverPen=maskHoverPen, 
         maskBrush = QtGui.QBrush() #clear
         )
     selectionOverlay.addProxyRectToRescaleGraphicsSelectionItems( V.graphicsScene, V.graphicsView, V.width, V.height)
Beispiel #24
0
 def Activated(self):
     V = getDrawingPageGUIVars()
     d.activate(V, dialogTitle='Add Center Lines', dialogIconPath=os.path.join( iconPath , 'centerLines.svg' ), endFunction=self.Activated )
     d.SVGFun = centerLinesSVG
     maskPen =      QtGui.QPen( QtGui.QColor(0,255,0,100) )
     maskPen.setWidth(2.0)
     maskHoverPen = QtGui.QPen( QtGui.QColor(0,255,0,255) )
     maskHoverPen.setWidth(2.0)
     selectionOverlay.generateSelectionGraphicsItems( 
         [obj for obj in V.page.Group  if not obj.Name.startswith('dim')], 
         selectFun ,
         transform = V.transform,
         sceneToAddTo = V.graphicsScene, 
         doCircles=True, doFittedCircles=True, 
         maskPen=maskPen, 
         maskHoverPen=maskHoverPen, 
         maskBrush = QtGui.QBrush() #clear
         )
     selectionOverlay.addProxyRectToRescaleGraphicsSelectionItems( V.graphicsScene, V.graphicsView, V.width, V.height)
 def Activated(self):
     V = getDrawingPageGUIVars()
     dimensioning.activate(
         V,
         ['strokeWidth', 'arrowL1', 'arrowL2', 'arrowW', 'centerPointDia'],
         ['lineColor'], ['textRenderer'])
     selectionOverlay.generateSelectionGraphicsItems(
         [obj for obj in V.page.Group if not obj.Name.startswith('dim')],
         selectFun,
         transform=V.transform,
         sceneToAddTo=V.graphicsScene,
         doCircles=True,
         doFittedCircles=True,
         maskPen=maskPen,
         maskHoverPen=maskHoverPen,
         maskBrush=QtGui.QBrush()  #clear
     )
     selectionOverlay.addProxyRectToRescaleGraphicsSelectionItems(
         V.graphicsScene, V.graphicsView, V.width, V.height)
 def Activated(self):
     V = getDrawingPageGUIVars()
     d.activate(V,
                'Add Radial Dimension',
                dialogIconPath=os.path.join(iconPath,
                                            'radiusDimension.svg'),
                endFunction=self.Activated)
     selectionOverlay.generateSelectionGraphicsItems(
         [obj for obj in V.page.Group if not obj.Name.startswith('dim')],
         selectFun,
         transform=V.transform,
         sceneToAddTo=V.graphicsScene,
         doCircles=True,
         doFittedCircles=True,
         maskPen=maskPen,
         maskHoverPen=maskHoverPen,
         maskBrush=QtGui.QBrush()  #clear
     )
     selectionOverlay.addProxyRectToRescaleGraphicsSelectionItems(
         V.graphicsScene, V.graphicsView, V.width, V.height)
Beispiel #27
0
 def Activated(self):
     V = self.Activated_common()
     dimensioning.SVGFun = centerLinesSVG
     maskPen = QtGui.QPen(QtGui.QColor(0, 255, 0, 100))
     maskPen.setWidth(2.0)
     maskHoverPen = QtGui.QPen(QtGui.QColor(0, 255, 0, 255))
     maskHoverPen.setWidth(2.0)
     selectionOverlay.generateSelectionGraphicsItems(
         [obj for obj in V.page.Group if not obj.Name.startswith('dim')],
         selectFun,
         transform=V.transform,
         sceneToAddTo=V.graphicsScene,
         doCircles=True,
         doFittedCircles=True,
         maskPen=maskPen,
         maskHoverPen=maskHoverPen,
         maskBrush=QtGui.QBrush()  #clear
     )
     selectionOverlay.addProxyRectToRescaleGraphicsSelectionItems(
         V.graphicsScene, V.graphicsView, V.width, V.height)
 def Activated(self):
     V = getDrawingPageGUIVars()
     d.activate(V, dialogTitle='Add Center Lines', dialogIconPath=':/dd/icons/centerLines.svg', endFunction=self.Activated )
     d.SVGFun = centerLinesSVG
     d.ProxyClass = Proxy_CenterLines
     d.proxy_svgFun = centerLinesSVG
     maskPen =      QtGui.QPen( QtGui.QColor(0,255,0,100) )
     maskPen.setWidth(2.0)
     maskHoverPen = QtGui.QPen( QtGui.QColor(0,255,0,255) )
     maskHoverPen.setWidth(2.0)
     selectionOverlay.generateSelectionGraphicsItems( 
         dimensionableObjects( V.page ),
         selectFun ,
         transform = V.transform,
         sceneToAddTo = V.graphicsScene, 
         doCircles=True, doFittedCircles=True, 
         maskPen=maskPen, 
         maskHoverPen=maskHoverPen, 
         maskBrush = QtGui.QBrush() #clear
         )
     selectionOverlay.addProxyRectToRescaleGraphicsSelectionItems( V.graphicsScene, V.graphicsView, V.width, V.height)
Beispiel #29
0
    def Activated(self):
        V = getDrawingPageGUIVars()
        d.activate(V,
                   dialogTitle='Add Linear Dimension',
                   dialogIconPath=self.iconPath,
                   endFunction=self.Activated)

        commonArgs = dict(onClickFun=selectDimensioningPoint,
                          transform=V.transform,
                          sceneToAddTo=V.graphicsScene,
                          pointWid=1.0,
                          maskPen=maskPen,
                          maskHoverPen=maskHoverPen,
                          maskBrush=maskBrush)
        selectionOverlay.generateSelectionGraphicsItems([
            obj for obj in V.page.Group if not obj.Name.startswith('dim')
            and not obj.Name.startswith('center')
        ],
                                                        doPoints=True,
                                                        **commonArgs)
        selectionOverlay.generateSelectionGraphicsItems(
            [obj for obj in V.page.Group if obj.Name.startswith('center')],
            clearPreviousSelectionItems=False,
            doPathEndPoints=True,
            **commonArgs)
        selectionOverlay.generateSelectionGraphicsItems(
            [
                obj for obj in V.page.Group if not obj.Name.startswith('dim')
                and not obj.Name.startswith('center')
            ],
            clearPreviousSelectionItems=False,
            doLines=True,
            onClickFun=selectDimensioningPoint,
            transform=V.transform,
            sceneToAddTo=V.graphicsScene,
            maskPen=line_maskPen,
            maskHoverPen=line_maskHoverPen,
            maskBrush=line_maskBrush)
        selectionOverlay.addProxyRectToRescaleGraphicsSelectionItems(
            V.graphicsScene, V.graphicsView, V.width, V.height)
 def Activated(self):
     V = getDrawingPageGUIVars()
     dimensioning.activate(V)
     commonArgs = dict( 
         onClickFun=deleteDimension,
         sceneToAddTo = V.graphicsScene, 
         transform = V.transform,
         pointWid=1.0,
         maskPen=maskPen, 
         maskHoverPen=maskHoverPen, 
         maskBrush = maskBrush
         )
     selectionOverlay.generateSelectionGraphicsItems( 
         [obj for obj in V.page.Group  if obj.Name.startswith('dim')], 
         doSelectViewObjectPoints = True, 
         **commonArgs)
     selectionOverlay.generateSelectionGraphicsItems( 
         [obj for obj in V.page.Group  if obj.Name.startswith('center') or  obj.Name.startswith('unfold')], 
         clearPreviousSelectionItems = False,
         doSelectViewObjectPoints=True, 
         **commonArgs)
     selectionOverlay.addProxyRectToRescaleGraphicsSelectionItems( V.graphicsScene, V.graphicsView, V.width, V.height)
 def Activated(self):
     V = getDrawingPageGUIVars()
     d.activate(V, dialogTitle='Delete Dimension', dialogIconPath=os.path.join( iconPath , 'deleteDimension.svg' ), endFunction=self.Activated)
     commonArgs = dict( 
         onClickFun=deleteDimension,
         sceneToAddTo = V.graphicsScene, 
         transform = V.transform,
         pointWid=1.0,
         maskPen=maskPen, 
         maskHoverPen=maskHoverPen, 
         maskBrush = maskBrush
         )
     selectionOverlay.generateSelectionGraphicsItems( 
         [obj for obj in V.page.Group  if obj.Name.startswith('dim') or obj.Name.startswith('grabPoint')], 
         doSelectViewObjectPoints = True, 
         **commonArgs)
     selectionOverlay.generateSelectionGraphicsItems( 
         [obj for obj in V.page.Group  if obj.Name.startswith('center') or  obj.Name.startswith('unfold')], 
         clearPreviousSelectionItems = False,
         doSelectViewObjectPoints=True, 
         **commonArgs)
     selectionOverlay.addProxyRectToRescaleGraphicsSelectionItems( V.graphicsScene, V.graphicsView, V.width, V.height)
 def Activated(self):
     V = getDrawingPageGUIVars()
     self.d.activate( V, dialogTitle = self.toolTip, dialogIconPath = self.iconPath, endFunction = self.Activated )
     commonArgs = dict( 
         onClickFun= self.onClickFun,
         transform = V.transform,
         sceneToAddTo = V.graphicsScene, 
         pointWid=1.0,
         maskPen=maskPen, 
         maskHoverPen=maskHoverPen, 
         maskBrush = maskBrush
         )
     selectionOverlay.generateSelectionGraphicsItems( 
         dimensionableObjects( V.page ), 
         doPoints=True, 
         **commonArgs
         )
     from centerLines import Proxy_CenterLines
     selectionOverlay.generateSelectionGraphicsItems( 
         [ obj for obj in V.page.Group if hasattr(obj, 'Proxy') and isinstance( obj.Proxy, Proxy_CenterLines )], 
         clearPreviousSelectionItems = False,
         doPathEndPoints=True, 
         **commonArgs
         )
     selectionOverlay.generateSelectionGraphicsItems( 
         dimensionableObjects( V.page ), 
         clearPreviousSelectionItems = False,
         doLines=True, 
         onClickFun= self.onClickFun,
         transform = V.transform,
         sceneToAddTo = V.graphicsScene, 
         maskPen= line_maskPen, 
         maskHoverPen= line_maskHoverPen, 
         maskBrush = line_maskBrush
         )
     selectionOverlay.addProxyRectToRescaleGraphicsSelectionItems( V.graphicsScene, V.graphicsView, V.width, V.height)
Beispiel #33
0
 def Activated(self):
     V = getDrawingPageGUIVars()
     self.d.activate( V, dialogTitle = self.toolTip, dialogIconPath = self.iconPath, endFunction = self.Activated )
     commonArgs = dict( 
         onClickFun= self.onClickFun,
         transform = V.transform,
         sceneToAddTo = V.graphicsScene, 
         pointWid=1.0,
         maskPen=maskPen, 
         maskHoverPen=maskHoverPen, 
         maskBrush = maskBrush
         )
     selectionOverlay.generateSelectionGraphicsItems( 
         dimensionableObjects( V.page ), 
         doPoints=True, 
         **commonArgs
         )
     from centerLines import Proxy_CenterLines
     selectionOverlay.generateSelectionGraphicsItems( 
         [ obj for obj in V.page.Group if hasattr(obj, 'Proxy') and isinstance( obj.Proxy, Proxy_CenterLines )], 
         clearPreviousSelectionItems = False,
         doPathEndPoints=True, 
         **commonArgs
         )
     selectionOverlay.generateSelectionGraphicsItems( 
         dimensionableObjects( V.page ), 
         clearPreviousSelectionItems = False,
         doLines=True, 
         onClickFun= self.onClickFun,
         transform = V.transform,
         sceneToAddTo = V.graphicsScene, 
         maskPen= line_maskPen, 
         maskHoverPen= line_maskHoverPen, 
         maskBrush = line_maskBrush
         )
     selectionOverlay.addProxyRectToRescaleGraphicsSelectionItems(V.graphicsScene, V.graphicsView, V.width, V.height)