original_docstring: 
          Calculate the bounding rectangle for a symbol at position (0,0).
  
          :return: Bounding rectangle
          
docstring: Calculate the bounding rectangle for a symbol at position (0,0).
docstring_tokens: Calculate the bounding rectangle for a symbol at position ( 0 0 ) .
code: def boundingRect(self):
          """
          Calculate the bounding rectangle for a symbol at position (0,0).
  
          :return: Bounding rectangle
          """
          rect = QRectF()
          pinPointTranslation = False
          if self.__data.style in (QwtSymbol.Ellipse, QwtSymbol.Rect, QwtSymbol.Hexagon):
              pw = 0.0
              if self.__data.pen.style() != Qt.NoPen:
                  pw = max([self.__data.pen.widthF(), 1.0])
              rect.setSize(self.__data.size + QSizeF(pw, pw))
              rect.moveCenter(QPointF(0.0, 0.0))
          elif self.__data.style in (
              QwtSymbol.XCross,
              QwtSymbol.Diamond,
              QwtSymbol.Triangle,
              QwtSymbol.UTriangle,
              QwtSymbol.DTriangle,
              QwtSymbol.RTriangle,
              QwtSymbol.LTriangle,
              QwtSymbol.Star1,
              QwtSymbol.Star2,
          ):
              pw = 0.0
              if self.__data.pen.style() != Qt.NoPen:
                  pw = max([self.__data.pen.widthF(), 1.0])
              rect.setSize(QSizeF(self.__data.size) + QSizeF(2 * pw, 2 * pw))
              rect.moveCenter(QPointF(0.0, 0.0))
          elif self.__data.style == QwtSymbol.Path:
              if self.__data.path.graphic.isNull():
                  self.__data.path.graphic = qwtPathGraphic(
                      self.__data.path.path, self.__data.pen, self.__data.brush
                  )
              rect = qwtScaleBoundingRect(self.__data.path.graphic, self.__data.size)
              pinPointTranslation = True
          elif self.__data.style == QwtSymbol.Pixmap:
              if self.__data.size.isEmpty():
                  rect.setSize(self.__data.pixmap.pixmap.size())
              else:
                  rect.setSize(self.__data.size)
              pinPointTranslation = True
          elif self.__data.style == QwtSymbol.Graphic:
              rect = qwtScaleBoundingRect(self.__data.graphic.graphic, self.__data.size)
              pinPointTranslation = True
          elif self.__data.style == QwtSymbol.SvgDocument:
              if self.__data.svg.renderer is not None:
                  rect = self.__data.svg.renderer.viewBoxF()
              if self.__data.size.isValid() and not rect.isEmpty():
                  sz = QSizeF(rect.size())
                  sx = self.__data.size.width() / sz.width()
                  sy = self.__data.size.height() / sz.height()
                  transform = QTransform()
                  transform.scale(sx, sy)
                  rect = transform.mapRect(rect)
              pinPointTranslation = True
          else:
              rect.setSize(self.__data.size)
              rect.moveCenter(QPointF(0.0, 0.0))
          if pinPointTranslation:
              pinPoint = QPointF(0.0, 0.0)
              if self.__data.isPinPointEnabled:
                  pinPoint = rect.center() - self.__data.pinPoint
              rect.moveCenter(pinPoint)
          r = QRect()
          r.setLeft(np.floor(rect.left()))
          r.setTop(np.floor(rect.top()))
          r.setRight(np.floor(rect.right()))
          r.setBottom(np.floor(rect.bottom()))
          if self.__data.style != QwtSymbol.Pixmap:
              r.adjust(-1, -1, 1, 1)
          return r
code_tokens: def boundingRect ( self ) : rect = QRectF ( ) pinPointTranslation = False if self . __data . style in ( QwtSymbol . Ellipse , QwtSymbol . Rect , QwtSymbol . Hexagon ) : pw = 0.0 if self . __data . pen . style ( ) != Qt . NoPen : pw = max ( [ self . __data . pen . widthF ( ) , 1.0 ] ) rect . setSize ( self . __data . size + QSizeF ( pw , pw ) ) rect . moveCenter ( QPointF ( 0.0 , 0.0 ) ) elif self . __data . style in ( QwtSymbol . XCross , QwtSymbol . Diamond , QwtSymbol . Triangle , QwtSymbol . UTriangle , QwtSymbol . DTriangle , QwtSymbol . RTriangle , QwtSymbol . LTriangle , QwtSymbol . Star1 , QwtSymbol . Star2 , ) : pw = 0.0 if self . __data . pen . style ( ) != Qt . NoPen : pw = max ( [ self . __data . pen . widthF ( ) , 1.0 ] ) rect . setSize ( QSizeF ( self . __data . size ) + QSizeF ( 2 * pw , 2 * pw ) ) rect . moveCenter ( QPointF ( 0.0 , 0.0 ) ) elif self . __data . style == QwtSymbol . Path : if self . __data . path . graphic . isNull ( ) : self . __data . path . graphic = qwtPathGraphic ( self . __data . path . path , self . __data . pen , self . __data . brush ) rect = qwtScaleBoundingRect ( self . __data . path . graphic , self . __data . size ) pinPointTranslation = True elif self . __data . style == QwtSymbol . Pixmap : if self . __data . size . isEmpty ( ) : rect . setSize ( self . __data . pixmap . pixmap . size ( ) ) else : rect . setSize ( self . __data . size ) pinPointTranslation = True elif self . __data . style == QwtSymbol . Graphic : rect = qwtScaleBoundingRect ( self . __data . graphic . graphic , self . __data . size ) pinPointTranslation = True elif self . __data . style == QwtSymbol . SvgDocument : if self . __data . svg . renderer is not None : rect = self . __data . svg . renderer . viewBoxF ( ) if self . __data . size . isValid ( ) and not rect . isEmpty ( ) : sz = QSizeF ( rect . size ( ) ) sx = self . __data . size . width ( ) / sz . width ( ) sy = self . __data . size . height ( ) / sz . height ( ) transform = QTransform ( ) transform . scale ( sx , sy ) rect = transform . mapRect ( rect ) pinPointTranslation = True else : rect . setSize ( self . __data . size ) rect . moveCenter ( QPointF ( 0.0 , 0.0 ) ) if pinPointTranslation : pinPoint = QPointF ( 0.0 , 0.0 ) if self . __data . isPinPointEnabled : pinPoint = rect . center ( ) - self . __data . pinPoint rect . moveCenter ( pinPoint ) r = QRect ( ) r . setLeft ( np . floor ( rect . left ( ) ) ) r . setTop ( np . floor ( rect . top ( ) ) ) r . setRight ( np . floor ( rect . right ( ) ) ) r . setBottom ( np . floor ( rect . bottom ( ) ) ) if self . __data . style != QwtSymbol . Pixmap : r . adjust ( - 1 , - 1 , 1 , 1 ) return r
short_docstring: Calculate the bounding rectangle for a symbol at position (0,0).
short_docstring_tokens: Calculate the bounding rectangle for a symbol at position ( 0 0 ) .
comment: """
          Calculate the bounding rectangle for a symbol at position (0,0).
  
          :return: Bounding rectangle
          """