qgeoshape.sip 2.4 KB

12345678910111213141516171819202122232425262728293031323334353637383940414243444546474849505152535455565758596061626364656667686970717273747576777879808182838485868788899091929394
  1. // qgeoshape.sip generated by MetaSIP
  2. //
  3. // This file is part of the QtPositioning Python extension module.
  4. //
  5. // Copyright (c) 2026 Riverbank Computing Limited <info@riverbankcomputing.com>
  6. //
  7. // This file is part of PyQt6.
  8. //
  9. // This file may be used under the terms of the GNU General Public License
  10. // version 3.0 as published by the Free Software Foundation and appearing in
  11. // the file LICENSE included in the packaging of this file. Please review the
  12. // following information to ensure the GNU General Public License version 3.0
  13. // requirements will be met: http://www.gnu.org/copyleft/gpl.html.
  14. //
  15. // If you do not wish to use this file under the terms of the GPL version 3.0
  16. // then you may purchase a commercial license. For more information contact
  17. // info@riverbankcomputing.com.
  18. //
  19. // This file is provided AS IS with NO WARRANTY OF ANY KIND, INCLUDING THE
  20. // WARRANTY OF DESIGN, MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE.
  21. %If (Qt_6_2_0 -)
  22. class QGeoShape
  23. {
  24. %TypeHeaderCode
  25. #include <qgeoshape.h>
  26. %End
  27. %ConvertToSubClassCode
  28. switch (sipCpp->type())
  29. {
  30. case QGeoShape::CircleType:
  31. sipType = sipType_QGeoCircle;
  32. break;
  33. case QGeoShape::RectangleType:
  34. sipType = sipType_QGeoRectangle;
  35. break;
  36. case QGeoShape::PathType:
  37. sipType = sipType_QGeoPath;
  38. break;
  39. case QGeoShape::PolygonType:
  40. sipType = sipType_QGeoPolygon;
  41. break;
  42. default:
  43. sipType = 0;
  44. }
  45. %End
  46. public:
  47. QGeoShape();
  48. QGeoShape(const QGeoShape &other);
  49. ~QGeoShape();
  50. enum ShapeType
  51. {
  52. UnknownType,
  53. RectangleType,
  54. CircleType,
  55. PathType,
  56. PolygonType,
  57. };
  58. QGeoShape::ShapeType type() const;
  59. bool isValid() const;
  60. bool isEmpty() const;
  61. bool contains(const QGeoCoordinate &coordinate) const;
  62. QGeoCoordinate center() const;
  63. QString toString() const;
  64. QGeoRectangle boundingGeoRectangle() const;
  65. Py_hash_t __hash__() const;
  66. %MethodCode
  67. sipRes = qHash(*sipCpp);
  68. %End
  69. };
  70. %End
  71. %If (Qt_6_2_0 -)
  72. QDataStream &operator<<(QDataStream &stream, const QGeoShape &shape);
  73. %End
  74. %If (Qt_6_2_0 -)
  75. QDataStream &operator>>(QDataStream &stream, QGeoShape &shape /Constrained/);
  76. %End
  77. %If (Qt_6_2_0 -)
  78. bool operator==(const QGeoShape &lhs, const QGeoShape &rhs);
  79. %End
  80. %If (Qt_6_2_0 -)
  81. bool operator!=(const QGeoShape &lhs, const QGeoShape &rhs);
  82. %End