Fix tray visibility and message reception issues
Some checks failed
build / build-win64 (push) Waiting to run
build / build-macos (push) Waiting to run
build / build-pip (push) Failing after 16s

- Disable sound initialization to prevent hanging
- Add missing import re in utils.py
- Fix settings loading for QSettings
- Update file paths to use PROJECT_ROOT
- Revert to working API paths and listener from commit efdc63e
This commit is contained in:
kdusek
2025-12-07 22:39:07 +01:00
parent 7b695d7b7f
commit 5138303016
4060 changed files with 579123 additions and 23 deletions

View File

@@ -0,0 +1,6 @@
# Automatically generated configuration for PyQt6.QtPositioning.
sip-version = "6.14.0"
sip-abi-version = "13.8"
module-tags = ["Qt_6_10_0", "Linux"]
module-disabled-features = []

View File

@@ -0,0 +1,61 @@
// QtPositioningmod.sip generated by MetaSIP
//
// This file is part of the QtPositioning Python extension module.
//
// Copyright (c) 2025 Riverbank Computing Limited <info@riverbankcomputing.com>
//
// This file is part of PyQt6.
//
// This file may be used under the terms of the GNU General Public License
// version 3.0 as published by the Free Software Foundation and appearing in
// the file LICENSE included in the packaging of this file. Please review the
// following information to ensure the GNU General Public License version 3.0
// requirements will be met: http://www.gnu.org/copyleft/gpl.html.
//
// If you do not wish to use this file under the terms of the GPL version 3.0
// then you may purchase a commercial license. For more information contact
// info@riverbankcomputing.com.
//
// This file is provided AS IS with NO WARRANTY OF ANY KIND, INCLUDING THE
// WARRANTY OF DESIGN, MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE.
%Module(name=PyQt6.QtPositioning, keyword_arguments="Optional", use_limited_api=True)
%Import QtCore/QtCoremod.sip
%Copying
Copyright (c) 2025 Riverbank Computing Limited <info@riverbankcomputing.com>
This file is part of PyQt6.
This file may be used under the terms of the GNU General Public License
version 3.0 as published by the Free Software Foundation and appearing in
the file LICENSE included in the packaging of this file. Please review the
following information to ensure the GNU General Public License version 3.0
requirements will be met: http://www.gnu.org/copyleft/gpl.html.
If you do not wish to use this file under the terms of the GPL version 3.0
then you may purchase a commercial license. For more information contact
info@riverbankcomputing.com.
This file is provided AS IS with NO WARRANTY OF ANY KIND, INCLUDING THE
WARRANTY OF DESIGN, MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE.
%End
%Include qgeoaddress.sip
%Include qgeoareamonitorinfo.sip
%Include qgeoareamonitorsource.sip
%Include qgeocircle.sip
%Include qgeocoordinate.sip
%Include qgeolocation.sip
%Include qgeopath.sip
%Include qgeopolygon.sip
%Include qgeopositioninfo.sip
%Include qgeopositioninfosource.sip
%Include qgeorectangle.sip
%Include qgeosatelliteinfo.sip
%Include qgeosatelliteinfosource.sip
%Include qgeoshape.sip
%Include qnmeapositioninfosource.sip
%Include qnmeasatelliteinfosource.sip

View File

@@ -0,0 +1,71 @@
// qgeoaddress.sip generated by MetaSIP
//
// This file is part of the QtPositioning Python extension module.
//
// Copyright (c) 2025 Riverbank Computing Limited <info@riverbankcomputing.com>
//
// This file is part of PyQt6.
//
// This file may be used under the terms of the GNU General Public License
// version 3.0 as published by the Free Software Foundation and appearing in
// the file LICENSE included in the packaging of this file. Please review the
// following information to ensure the GNU General Public License version 3.0
// requirements will be met: http://www.gnu.org/copyleft/gpl.html.
//
// If you do not wish to use this file under the terms of the GPL version 3.0
// then you may purchase a commercial license. For more information contact
// info@riverbankcomputing.com.
//
// This file is provided AS IS with NO WARRANTY OF ANY KIND, INCLUDING THE
// WARRANTY OF DESIGN, MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE.
%If (Qt_6_2_0 -)
class QGeoAddress
{
%TypeHeaderCode
#include <qgeoaddress.h>
%End
public:
QGeoAddress();
QGeoAddress(const QGeoAddress &other);
~QGeoAddress();
QString text() const;
void setText(const QString &text);
QString country() const;
void setCountry(const QString &country);
QString countryCode() const;
void setCountryCode(const QString &countryCode);
QString state() const;
void setState(const QString &state);
QString county() const;
void setCounty(const QString &county);
QString city() const;
void setCity(const QString &city);
QString district() const;
void setDistrict(const QString &district);
QString postalCode() const;
void setPostalCode(const QString &postalCode);
QString street() const;
void setStreet(const QString &street);
bool isEmpty() const;
void clear();
bool isTextGenerated() const;
void swap(QGeoAddress &other /Constrained/);
QString streetNumber() const;
void setStreetNumber(const QString &streetNumber);
Py_hash_t __hash__() const;
%MethodCode
sipRes = qHash(*sipCpp);
%End
};
%End
%If (Qt_6_2_0 -)
bool operator==(const QGeoAddress &lhs, const QGeoAddress &rhs);
%End
%If (Qt_6_2_0 -)
bool operator!=(const QGeoAddress &lhs, const QGeoAddress &rhs);
%End

View File

@@ -0,0 +1,66 @@
// qgeoareamonitorinfo.sip generated by MetaSIP
//
// This file is part of the QtPositioning Python extension module.
//
// Copyright (c) 2025 Riverbank Computing Limited <info@riverbankcomputing.com>
//
// This file is part of PyQt6.
//
// This file may be used under the terms of the GNU General Public License
// version 3.0 as published by the Free Software Foundation and appearing in
// the file LICENSE included in the packaging of this file. Please review the
// following information to ensure the GNU General Public License version 3.0
// requirements will be met: http://www.gnu.org/copyleft/gpl.html.
//
// If you do not wish to use this file under the terms of the GPL version 3.0
// then you may purchase a commercial license. For more information contact
// info@riverbankcomputing.com.
//
// This file is provided AS IS with NO WARRANTY OF ANY KIND, INCLUDING THE
// WARRANTY OF DESIGN, MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE.
%If (Qt_6_2_0 -)
class QGeoAreaMonitorInfo
{
%TypeHeaderCode
#include <qgeoareamonitorinfo.h>
%End
public:
explicit QGeoAreaMonitorInfo(const QString &name = QString());
QGeoAreaMonitorInfo(const QGeoAreaMonitorInfo &other);
~QGeoAreaMonitorInfo();
QString name() const;
void setName(const QString &name);
QString identifier() const;
bool isValid() const;
QGeoShape area() const;
void setArea(const QGeoShape &newShape);
QDateTime expiration() const;
void setExpiration(const QDateTime &expiry);
bool isPersistent() const;
void setPersistent(bool isPersistent);
QVariantMap notificationParameters() const;
void setNotificationParameters(const QVariantMap &parameters);
void swap(QGeoAreaMonitorInfo &other);
Py_hash_t __hash__() const;
%MethodCode
sipRes = qHash(*sipCpp);
%End
};
%End
%If (Qt_6_2_0 -)
QDataStream &operator<<(QDataStream &, const QGeoAreaMonitorInfo &);
%End
%If (Qt_6_2_0 -)
QDataStream &operator>>(QDataStream &, QGeoAreaMonitorInfo & /Constrained/);
%End
%If (Qt_6_2_0 -)
bool operator==(const QGeoAreaMonitorInfo &lhs, const QGeoAreaMonitorInfo &rhs);
%End
%If (Qt_6_2_0 -)
bool operator!=(const QGeoAreaMonitorInfo &lhs, const QGeoAreaMonitorInfo &rhs);
%End

View File

@@ -0,0 +1,74 @@
// qgeoareamonitorsource.sip generated by MetaSIP
//
// This file is part of the QtPositioning Python extension module.
//
// Copyright (c) 2025 Riverbank Computing Limited <info@riverbankcomputing.com>
//
// This file is part of PyQt6.
//
// This file may be used under the terms of the GNU General Public License
// version 3.0 as published by the Free Software Foundation and appearing in
// the file LICENSE included in the packaging of this file. Please review the
// following information to ensure the GNU General Public License version 3.0
// requirements will be met: http://www.gnu.org/copyleft/gpl.html.
//
// If you do not wish to use this file under the terms of the GPL version 3.0
// then you may purchase a commercial license. For more information contact
// info@riverbankcomputing.com.
//
// This file is provided AS IS with NO WARRANTY OF ANY KIND, INCLUDING THE
// WARRANTY OF DESIGN, MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE.
%If (Qt_6_2_0 -)
class QGeoAreaMonitorSource : public QObject
{
%TypeHeaderCode
#include <qgeoareamonitorsource.h>
%End
public:
enum Error
{
AccessError,
InsufficientPositionInfo,
UnknownSourceError,
NoError,
};
enum AreaMonitorFeature /BaseType=Flag/
{
PersistentAreaMonitorFeature,
AnyAreaMonitorFeature,
};
typedef QFlags<QGeoAreaMonitorSource::AreaMonitorFeature> AreaMonitorFeatures;
explicit QGeoAreaMonitorSource(QObject *parent /TransferThis/);
virtual ~QGeoAreaMonitorSource();
static QGeoAreaMonitorSource *createDefaultSource(QObject *parent /TransferThis/) /Factory/;
static QGeoAreaMonitorSource *createSource(const QString &sourceName, QObject *parent /TransferThis/) /Factory/;
static QStringList availableSources();
virtual void setPositionInfoSource(QGeoPositionInfoSource *source /Transfer/);
virtual QGeoPositionInfoSource *positionInfoSource() const;
QString sourceName() const;
virtual QGeoAreaMonitorSource::Error error() const = 0;
virtual QGeoAreaMonitorSource::AreaMonitorFeatures supportedAreaMonitorFeatures() const = 0;
virtual bool startMonitoring(const QGeoAreaMonitorInfo &monitor) = 0;
virtual bool stopMonitoring(const QGeoAreaMonitorInfo &monitor) = 0;
virtual bool requestUpdate(const QGeoAreaMonitorInfo &monitor, const char *signal) = 0;
virtual QList<QGeoAreaMonitorInfo> activeMonitors() const = 0;
virtual QList<QGeoAreaMonitorInfo> activeMonitors(const QGeoShape &lookupArea) const = 0;
signals:
void areaEntered(const QGeoAreaMonitorInfo &monitor, const QGeoPositionInfo &update);
void areaExited(const QGeoAreaMonitorInfo &monitor, const QGeoPositionInfo &update);
void monitorExpired(const QGeoAreaMonitorInfo &monitor);
void errorOccurred(QGeoAreaMonitorSource::Error error);
public:
virtual bool setBackendProperty(const QString &name, const QVariant &value);
virtual QVariant backendProperty(const QString &name) const;
};
%End

View File

@@ -0,0 +1,53 @@
// qgeocircle.sip generated by MetaSIP
//
// This file is part of the QtPositioning Python extension module.
//
// Copyright (c) 2025 Riverbank Computing Limited <info@riverbankcomputing.com>
//
// This file is part of PyQt6.
//
// This file may be used under the terms of the GNU General Public License
// version 3.0 as published by the Free Software Foundation and appearing in
// the file LICENSE included in the packaging of this file. Please review the
// following information to ensure the GNU General Public License version 3.0
// requirements will be met: http://www.gnu.org/copyleft/gpl.html.
//
// If you do not wish to use this file under the terms of the GPL version 3.0
// then you may purchase a commercial license. For more information contact
// info@riverbankcomputing.com.
//
// This file is provided AS IS with NO WARRANTY OF ANY KIND, INCLUDING THE
// WARRANTY OF DESIGN, MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE.
%If (Qt_6_2_0 -)
class QGeoCircle : public QGeoShape
{
%TypeHeaderCode
#include <qgeocircle.h>
%End
public:
QGeoCircle();
QGeoCircle(const QGeoCoordinate &center, qreal radius = -1.);
QGeoCircle(const QGeoCircle &other);
QGeoCircle(const QGeoShape &other);
~QGeoCircle();
void setCenter(const QGeoCoordinate &center);
QGeoCoordinate center() const;
void setRadius(qreal radius);
qreal radius() const;
void translate(double degreesLatitude, double degreesLongitude);
QGeoCircle translated(double degreesLatitude, double degreesLongitude) const;
QString toString() const;
void extendCircle(const QGeoCoordinate &coordinate);
};
%End
%If (Qt_6_5_0 -)
QDataStream &operator<<(QDataStream &stream, const QGeoCircle &circle) /ReleaseGIL/;
%End
%If (Qt_6_5_0 -)
QDataStream &operator>>(QDataStream &stream, QGeoCircle &circle /Constrained/) /ReleaseGIL/;
%End

View File

@@ -0,0 +1,85 @@
// qgeocoordinate.sip generated by MetaSIP
//
// This file is part of the QtPositioning Python extension module.
//
// Copyright (c) 2025 Riverbank Computing Limited <info@riverbankcomputing.com>
//
// This file is part of PyQt6.
//
// This file may be used under the terms of the GNU General Public License
// version 3.0 as published by the Free Software Foundation and appearing in
// the file LICENSE included in the packaging of this file. Please review the
// following information to ensure the GNU General Public License version 3.0
// requirements will be met: http://www.gnu.org/copyleft/gpl.html.
//
// If you do not wish to use this file under the terms of the GPL version 3.0
// then you may purchase a commercial license. For more information contact
// info@riverbankcomputing.com.
//
// This file is provided AS IS with NO WARRANTY OF ANY KIND, INCLUDING THE
// WARRANTY OF DESIGN, MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE.
%If (Qt_6_2_0 -)
class QGeoCoordinate
{
%TypeHeaderCode
#include <qgeocoordinate.h>
%End
public:
enum CoordinateType
{
InvalidCoordinate,
Coordinate2D,
Coordinate3D,
};
enum CoordinateFormat
{
Degrees,
DegreesWithHemisphere,
DegreesMinutes,
DegreesMinutesWithHemisphere,
DegreesMinutesSeconds,
DegreesMinutesSecondsWithHemisphere,
};
QGeoCoordinate();
QGeoCoordinate(double latitude, double longitude);
QGeoCoordinate(double latitude, double longitude, double altitude);
QGeoCoordinate(const QGeoCoordinate &other);
~QGeoCoordinate();
bool isValid() const;
QGeoCoordinate::CoordinateType type() const;
void setLatitude(double latitude);
double latitude() const;
void setLongitude(double longitude);
double longitude() const;
void setAltitude(double altitude);
double altitude() const;
qreal distanceTo(const QGeoCoordinate &other) const;
qreal azimuthTo(const QGeoCoordinate &other) const;
QGeoCoordinate atDistanceAndAzimuth(qreal distance, qreal azimuth, qreal distanceUp = 0.) const;
QString toString(QGeoCoordinate::CoordinateFormat format = QGeoCoordinate::DegreesMinutesSecondsWithHemisphere) const;
void swap(QGeoCoordinate &other /Constrained/);
Py_hash_t __hash__() const;
%MethodCode
sipRes = qHash(*sipCpp);
%End
};
%End
%If (Qt_6_2_0 -)
QDataStream &operator<<(QDataStream &stream, const QGeoCoordinate &coordinate);
%End
%If (Qt_6_2_0 -)
QDataStream &operator>>(QDataStream &stream, QGeoCoordinate &coordinate /Constrained/);
%End
%If (Qt_6_2_0 -)
bool operator==(const QGeoCoordinate &lhs, const QGeoCoordinate &rhs);
%End
%If (Qt_6_2_0 -)
bool operator!=(const QGeoCoordinate &lhs, const QGeoCoordinate &rhs);
%End

View File

@@ -0,0 +1,57 @@
// qgeolocation.sip generated by MetaSIP
//
// This file is part of the QtPositioning Python extension module.
//
// Copyright (c) 2025 Riverbank Computing Limited <info@riverbankcomputing.com>
//
// This file is part of PyQt6.
//
// This file may be used under the terms of the GNU General Public License
// version 3.0 as published by the Free Software Foundation and appearing in
// the file LICENSE included in the packaging of this file. Please review the
// following information to ensure the GNU General Public License version 3.0
// requirements will be met: http://www.gnu.org/copyleft/gpl.html.
//
// If you do not wish to use this file under the terms of the GPL version 3.0
// then you may purchase a commercial license. For more information contact
// info@riverbankcomputing.com.
//
// This file is provided AS IS with NO WARRANTY OF ANY KIND, INCLUDING THE
// WARRANTY OF DESIGN, MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE.
%If (Qt_6_2_0 -)
class QGeoLocation
{
%TypeHeaderCode
#include <qgeolocation.h>
%End
public:
QGeoLocation();
QGeoLocation(const QGeoLocation &other);
~QGeoLocation();
QGeoAddress address() const;
void setAddress(const QGeoAddress &address);
QGeoCoordinate coordinate() const;
void setCoordinate(const QGeoCoordinate &position);
bool isEmpty() const;
QVariantMap extendedAttributes() const;
void setExtendedAttributes(const QVariantMap &data);
void swap(QGeoLocation &other /Constrained/);
QGeoShape boundingShape() const;
void setBoundingShape(const QGeoShape &shape);
Py_hash_t __hash__() const;
%MethodCode
sipRes = qHash(*sipCpp);
%End
};
%End
%If (Qt_6_2_0 -)
bool operator==(const QGeoLocation &lhs, const QGeoLocation &rhs);
%End
%If (Qt_6_2_0 -)
bool operator!=(const QGeoLocation &lhs, const QGeoLocation &rhs);
%End

View File

@@ -0,0 +1,62 @@
// qgeopath.sip generated by MetaSIP
//
// This file is part of the QtPositioning Python extension module.
//
// Copyright (c) 2025 Riverbank Computing Limited <info@riverbankcomputing.com>
//
// This file is part of PyQt6.
//
// This file may be used under the terms of the GNU General Public License
// version 3.0 as published by the Free Software Foundation and appearing in
// the file LICENSE included in the packaging of this file. Please review the
// following information to ensure the GNU General Public License version 3.0
// requirements will be met: http://www.gnu.org/copyleft/gpl.html.
//
// If you do not wish to use this file under the terms of the GPL version 3.0
// then you may purchase a commercial license. For more information contact
// info@riverbankcomputing.com.
//
// This file is provided AS IS with NO WARRANTY OF ANY KIND, INCLUDING THE
// WARRANTY OF DESIGN, MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE.
%If (Qt_6_2_0 -)
class QGeoPath : public QGeoShape
{
%TypeHeaderCode
#include <qgeopath.h>
%End
public:
QGeoPath();
QGeoPath(const QList<QGeoCoordinate> &path, const qreal &width = 0.);
QGeoPath(const QGeoPath &other);
QGeoPath(const QGeoShape &other);
~QGeoPath();
void setPath(const QList<QGeoCoordinate> &path);
const QList<QGeoCoordinate> &path() const;
void setWidth(const qreal &width);
qreal width() const;
void translate(double degreesLatitude, double degreesLongitude);
QGeoPath translated(double degreesLatitude, double degreesLongitude) const;
double length(qsizetype indexFrom = 0, qsizetype indexTo = -1) const;
void addCoordinate(const QGeoCoordinate &coordinate);
void insertCoordinate(qsizetype index, const QGeoCoordinate &coordinate);
void replaceCoordinate(qsizetype index, const QGeoCoordinate &coordinate);
QGeoCoordinate coordinateAt(qsizetype index) const;
bool containsCoordinate(const QGeoCoordinate &coordinate) const;
void removeCoordinate(const QGeoCoordinate &coordinate);
void removeCoordinate(qsizetype index);
QString toString() const;
qsizetype size() const;
void clearPath();
};
%End
%If (Qt_6_5_0 -)
QDataStream &operator<<(QDataStream &stream, const QGeoPath &path) /ReleaseGIL/;
%End
%If (Qt_6_5_0 -)
QDataStream &operator>>(QDataStream &stream, QGeoPath &path /Constrained/) /ReleaseGIL/;
%End

View File

@@ -0,0 +1,65 @@
// qgeopolygon.sip generated by MetaSIP
//
// This file is part of the QtPositioning Python extension module.
//
// Copyright (c) 2025 Riverbank Computing Limited <info@riverbankcomputing.com>
//
// This file is part of PyQt6.
//
// This file may be used under the terms of the GNU General Public License
// version 3.0 as published by the Free Software Foundation and appearing in
// the file LICENSE included in the packaging of this file. Please review the
// following information to ensure the GNU General Public License version 3.0
// requirements will be met: http://www.gnu.org/copyleft/gpl.html.
//
// If you do not wish to use this file under the terms of the GPL version 3.0
// then you may purchase a commercial license. For more information contact
// info@riverbankcomputing.com.
//
// This file is provided AS IS with NO WARRANTY OF ANY KIND, INCLUDING THE
// WARRANTY OF DESIGN, MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE.
%If (Qt_6_2_0 -)
class QGeoPolygon : public QGeoShape
{
%TypeHeaderCode
#include <qgeopolygon.h>
%End
public:
QGeoPolygon();
QGeoPolygon(const QList<QGeoCoordinate> &path);
QGeoPolygon(const QGeoPolygon &other);
QGeoPolygon(const QGeoShape &other);
~QGeoPolygon();
void translate(double degreesLatitude, double degreesLongitude);
QGeoPolygon translated(double degreesLatitude, double degreesLongitude) const;
double length(qsizetype indexFrom = 0, qsizetype indexTo = -1) const;
qsizetype size() const;
void addCoordinate(const QGeoCoordinate &coordinate);
void insertCoordinate(qsizetype index, const QGeoCoordinate &coordinate);
void replaceCoordinate(qsizetype index, const QGeoCoordinate &coordinate);
QGeoCoordinate coordinateAt(qsizetype index) const;
bool containsCoordinate(const QGeoCoordinate &coordinate) const;
void removeCoordinate(const QGeoCoordinate &coordinate);
void removeCoordinate(qsizetype index);
QString toString() const;
void addHole(const QList<QGeoCoordinate> &holePath);
void addHole(const QVariant &holePath);
const QVariantList hole(qsizetype index) const;
const QList<QGeoCoordinate> holePath(qsizetype index) const;
void removeHole(qsizetype index);
qsizetype holesCount() const;
void setPerimeter(const QList<QGeoCoordinate> &path);
const QList<QGeoCoordinate> &perimeter() const;
};
%End
%If (Qt_6_5_0 -)
QDataStream &operator<<(QDataStream &stream, const QGeoPolygon &polygon) /ReleaseGIL/;
%End
%If (Qt_6_5_0 -)
QDataStream &operator>>(QDataStream &stream, QGeoPolygon &polygon /Constrained/) /ReleaseGIL/;
%End

View File

@@ -0,0 +1,77 @@
// qgeopositioninfo.sip generated by MetaSIP
//
// This file is part of the QtPositioning Python extension module.
//
// Copyright (c) 2025 Riverbank Computing Limited <info@riverbankcomputing.com>
//
// This file is part of PyQt6.
//
// This file may be used under the terms of the GNU General Public License
// version 3.0 as published by the Free Software Foundation and appearing in
// the file LICENSE included in the packaging of this file. Please review the
// following information to ensure the GNU General Public License version 3.0
// requirements will be met: http://www.gnu.org/copyleft/gpl.html.
//
// If you do not wish to use this file under the terms of the GPL version 3.0
// then you may purchase a commercial license. For more information contact
// info@riverbankcomputing.com.
//
// This file is provided AS IS with NO WARRANTY OF ANY KIND, INCLUDING THE
// WARRANTY OF DESIGN, MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE.
%If (Qt_6_2_0 -)
class QGeoPositionInfo
{
%TypeHeaderCode
#include <qgeopositioninfo.h>
%End
public:
enum Attribute
{
Direction,
GroundSpeed,
VerticalSpeed,
MagneticVariation,
HorizontalAccuracy,
VerticalAccuracy,
%If (Qt_6_3_0 -)
DirectionAccuracy,
%End
};
QGeoPositionInfo();
QGeoPositionInfo(const QGeoCoordinate &coordinate, const QDateTime &updateTime);
QGeoPositionInfo(const QGeoPositionInfo &other);
~QGeoPositionInfo();
bool isValid() const;
void setTimestamp(const QDateTime &timestamp);
QDateTime timestamp() const;
void setCoordinate(const QGeoCoordinate &coordinate);
QGeoCoordinate coordinate() const;
void setAttribute(QGeoPositionInfo::Attribute attribute, qreal value);
qreal attribute(QGeoPositionInfo::Attribute attribute) const;
void removeAttribute(QGeoPositionInfo::Attribute attribute);
bool hasAttribute(QGeoPositionInfo::Attribute attribute) const;
void swap(QGeoPositionInfo &other /Constrained/);
Py_hash_t __hash__() const;
%MethodCode
sipRes = qHash(*sipCpp);
%End
};
%End
%If (Qt_6_2_0 -)
QDataStream &operator<<(QDataStream &stream, const QGeoPositionInfo &info);
%End
%If (Qt_6_2_0 -)
QDataStream &operator>>(QDataStream &stream, QGeoPositionInfo &info /Constrained/);
%End
%If (Qt_6_2_0 -)
bool operator==(const QGeoPositionInfo &lhs, const QGeoPositionInfo &rhs);
%End
%If (Qt_6_2_0 -)
bool operator!=(const QGeoPositionInfo &lhs, const QGeoPositionInfo &rhs);
%End

View File

@@ -0,0 +1,114 @@
// qgeopositioninfosource.sip generated by MetaSIP
//
// This file is part of the QtPositioning Python extension module.
//
// Copyright (c) 2025 Riverbank Computing Limited <info@riverbankcomputing.com>
//
// This file is part of PyQt6.
//
// This file may be used under the terms of the GNU General Public License
// version 3.0 as published by the Free Software Foundation and appearing in
// the file LICENSE included in the packaging of this file. Please review the
// following information to ensure the GNU General Public License version 3.0
// requirements will be met: http://www.gnu.org/copyleft/gpl.html.
//
// If you do not wish to use this file under the terms of the GPL version 3.0
// then you may purchase a commercial license. For more information contact
// info@riverbankcomputing.com.
//
// This file is provided AS IS with NO WARRANTY OF ANY KIND, INCLUDING THE
// WARRANTY OF DESIGN, MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE.
%If (Qt_6_2_0 -)
class QGeoPositionInfoSource : public QObject
{
%TypeHeaderCode
#include <qgeopositioninfosource.h>
%End
%ConvertToSubClassCode
static struct class_graph {
const char *name;
sipTypeDef **type;
int yes, no;
} graph[] = {
{sipName_QGeoAreaMonitorSource, &sipType_QGeoAreaMonitorSource, -1, 1},
{sipName_QGeoPositionInfoSource, &sipType_QGeoPositionInfoSource, 3, 2},
{sipName_QGeoSatelliteInfoSource, &sipType_QGeoSatelliteInfoSource, 4, -1},
{sipName_QNmeaPositionInfoSource, &sipType_QNmeaPositionInfoSource, -1, -1},
{sipName_QNmeaSatelliteInfoSource, &sipType_QNmeaSatelliteInfoSource, -1, -1},
};
int i = 0;
sipType = NULL;
do
{
struct class_graph *cg = &graph[i];
if (cg->name != NULL && sipCpp->inherits(cg->name))
{
sipType = *cg->type;
i = cg->yes;
}
else
i = cg->no;
}
while (i >= 0);
%End
public:
enum Error
{
AccessError,
ClosedError,
UnknownSourceError,
UpdateTimeoutError,
NoError,
};
enum PositioningMethod /BaseType=Flag/
{
NoPositioningMethods,
SatellitePositioningMethods,
NonSatellitePositioningMethods,
AllPositioningMethods,
};
typedef QFlags<QGeoPositionInfoSource::PositioningMethod> PositioningMethods;
explicit QGeoPositionInfoSource(QObject *parent /TransferThis/);
virtual ~QGeoPositionInfoSource();
virtual void setUpdateInterval(int msec);
int updateInterval() const;
virtual void setPreferredPositioningMethods(QGeoPositionInfoSource::PositioningMethods methods);
QGeoPositionInfoSource::PositioningMethods preferredPositioningMethods() const;
virtual QGeoPositionInfo lastKnownPosition(bool fromSatellitePositioningMethodsOnly = false) const = 0;
virtual QGeoPositionInfoSource::PositioningMethods supportedPositioningMethods() const = 0;
virtual int minimumUpdateInterval() const = 0;
QString sourceName() const;
static QGeoPositionInfoSource *createDefaultSource(QObject *parent /TransferThis/) /Factory/;
static QGeoPositionInfoSource *createDefaultSource(const QVariantMap &parameters, QObject *parent /TransferThis/) /Factory/;
static QGeoPositionInfoSource *createSource(const QString &sourceName, QObject *parent /TransferThis/) /Factory/;
static QGeoPositionInfoSource *createSource(const QString &sourceName, const QVariantMap &parameters, QObject *parent /TransferThis/) /Factory/;
static QStringList availableSources();
virtual QGeoPositionInfoSource::Error error() const = 0;
public slots:
virtual void startUpdates() = 0;
virtual void stopUpdates() = 0;
virtual void requestUpdate(int timeout = 0) = 0;
signals:
void positionUpdated(const QGeoPositionInfo &update);
void supportedPositioningMethodsChanged();
void errorOccurred(QGeoPositionInfoSource::Error);
public:
virtual bool setBackendProperty(const QString &name, const QVariant &value);
virtual QVariant backendProperty(const QString &name) const;
};
%End

View File

@@ -0,0 +1,70 @@
// qgeorectangle.sip generated by MetaSIP
//
// This file is part of the QtPositioning Python extension module.
//
// Copyright (c) 2025 Riverbank Computing Limited <info@riverbankcomputing.com>
//
// This file is part of PyQt6.
//
// This file may be used under the terms of the GNU General Public License
// version 3.0 as published by the Free Software Foundation and appearing in
// the file LICENSE included in the packaging of this file. Please review the
// following information to ensure the GNU General Public License version 3.0
// requirements will be met: http://www.gnu.org/copyleft/gpl.html.
//
// If you do not wish to use this file under the terms of the GPL version 3.0
// then you may purchase a commercial license. For more information contact
// info@riverbankcomputing.com.
//
// This file is provided AS IS with NO WARRANTY OF ANY KIND, INCLUDING THE
// WARRANTY OF DESIGN, MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE.
%If (Qt_6_2_0 -)
class QGeoRectangle : public QGeoShape
{
%TypeHeaderCode
#include <qgeorectangle.h>
%End
public:
QGeoRectangle();
QGeoRectangle(const QGeoCoordinate &center, double degreesWidth, double degreesHeight);
QGeoRectangle(const QGeoCoordinate &topLeft, const QGeoCoordinate &bottomRight);
QGeoRectangle(const QList<QGeoCoordinate> &coordinates);
QGeoRectangle(const QGeoRectangle &other);
QGeoRectangle(const QGeoShape &other);
~QGeoRectangle();
void setTopLeft(const QGeoCoordinate &topLeft);
QGeoCoordinate topLeft() const;
void setTopRight(const QGeoCoordinate &topRight);
QGeoCoordinate topRight() const;
void setBottomLeft(const QGeoCoordinate &bottomLeft);
QGeoCoordinate bottomLeft() const;
void setBottomRight(const QGeoCoordinate &bottomRight);
QGeoCoordinate bottomRight() const;
void setCenter(const QGeoCoordinate &center);
QGeoCoordinate center() const;
void setWidth(double degreesWidth);
double width() const;
void setHeight(double degreesHeight);
double height() const;
bool contains(const QGeoRectangle &rectangle) const;
bool intersects(const QGeoRectangle &rectangle) const;
void translate(double degreesLatitude, double degreesLongitude);
QGeoRectangle translated(double degreesLatitude, double degreesLongitude) const;
QGeoRectangle united(const QGeoRectangle &rectangle) const;
QGeoRectangle &operator|=(const QGeoRectangle &rectangle);
QGeoRectangle operator|(const QGeoRectangle &rectangle) const;
QString toString() const;
void extendRectangle(const QGeoCoordinate &coordinate);
};
%End
%If (Qt_6_5_0 -)
QDataStream &operator<<(QDataStream &stream, const QGeoRectangle &rectangle) /ReleaseGIL/;
%End
%If (Qt_6_5_0 -)
QDataStream &operator>>(QDataStream &stream, QGeoRectangle &rectangle /Constrained/) /ReleaseGIL/;
%End

View File

@@ -0,0 +1,76 @@
// qgeosatelliteinfo.sip generated by MetaSIP
//
// This file is part of the QtPositioning Python extension module.
//
// Copyright (c) 2025 Riverbank Computing Limited <info@riverbankcomputing.com>
//
// This file is part of PyQt6.
//
// This file may be used under the terms of the GNU General Public License
// version 3.0 as published by the Free Software Foundation and appearing in
// the file LICENSE included in the packaging of this file. Please review the
// following information to ensure the GNU General Public License version 3.0
// requirements will be met: http://www.gnu.org/copyleft/gpl.html.
//
// If you do not wish to use this file under the terms of the GPL version 3.0
// then you may purchase a commercial license. For more information contact
// info@riverbankcomputing.com.
//
// This file is provided AS IS with NO WARRANTY OF ANY KIND, INCLUDING THE
// WARRANTY OF DESIGN, MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE.
%If (Qt_6_2_0 -)
class QGeoSatelliteInfo
{
%TypeHeaderCode
#include <qgeosatelliteinfo.h>
%End
public:
enum Attribute
{
Elevation,
Azimuth,
};
enum SatelliteSystem
{
Undefined,
GPS,
GLONASS,
GALILEO,
BEIDOU,
QZSS,
Multiple,
CustomType,
};
QGeoSatelliteInfo();
QGeoSatelliteInfo(const QGeoSatelliteInfo &other);
~QGeoSatelliteInfo();
void setSatelliteSystem(QGeoSatelliteInfo::SatelliteSystem system);
QGeoSatelliteInfo::SatelliteSystem satelliteSystem() const;
void setSatelliteIdentifier(int satId);
int satelliteIdentifier() const;
void setSignalStrength(int signalStrength);
int signalStrength() const;
void setAttribute(QGeoSatelliteInfo::Attribute attribute, qreal value);
qreal attribute(QGeoSatelliteInfo::Attribute attribute) const;
void removeAttribute(QGeoSatelliteInfo::Attribute attribute);
bool hasAttribute(QGeoSatelliteInfo::Attribute attribute) const;
void swap(QGeoSatelliteInfo &other /Constrained/);
Py_hash_t __hash__() const;
%MethodCode
sipRes = qHash(*sipCpp);
%End
};
%End
%If (Qt_6_2_0 -)
QDataStream &operator<<(QDataStream &stream, const QGeoSatelliteInfo &info);
%End
%If (Qt_6_2_0 -)
QDataStream &operator>>(QDataStream &stream, QGeoSatelliteInfo &info /Constrained/);
%End

View File

@@ -0,0 +1,69 @@
// qgeosatelliteinfosource.sip generated by MetaSIP
//
// This file is part of the QtPositioning Python extension module.
//
// Copyright (c) 2025 Riverbank Computing Limited <info@riverbankcomputing.com>
//
// This file is part of PyQt6.
//
// This file may be used under the terms of the GNU General Public License
// version 3.0 as published by the Free Software Foundation and appearing in
// the file LICENSE included in the packaging of this file. Please review the
// following information to ensure the GNU General Public License version 3.0
// requirements will be met: http://www.gnu.org/copyleft/gpl.html.
//
// If you do not wish to use this file under the terms of the GPL version 3.0
// then you may purchase a commercial license. For more information contact
// info@riverbankcomputing.com.
//
// This file is provided AS IS with NO WARRANTY OF ANY KIND, INCLUDING THE
// WARRANTY OF DESIGN, MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE.
%If (Qt_6_2_0 -)
class QGeoSatelliteInfoSource : public QObject
{
%TypeHeaderCode
#include <qgeosatelliteinfosource.h>
%End
public:
enum Error
{
AccessError,
ClosedError,
NoError,
UnknownSourceError,
UpdateTimeoutError,
};
explicit QGeoSatelliteInfoSource(QObject *parent /TransferThis/);
virtual ~QGeoSatelliteInfoSource();
static QGeoSatelliteInfoSource *createDefaultSource(QObject *parent /TransferThis/) /Factory/;
static QGeoSatelliteInfoSource *createDefaultSource(const QVariantMap &parameters, QObject *parent /TransferThis/) /Factory/;
static QGeoSatelliteInfoSource *createSource(const QString &sourceName, QObject *parent /TransferThis/) /Factory/;
static QGeoSatelliteInfoSource *createSource(const QString &sourceName, const QVariantMap &parameters, QObject *parent /TransferThis/) /Factory/;
static QStringList availableSources();
QString sourceName() const;
virtual void setUpdateInterval(int msec);
int updateInterval() const;
virtual int minimumUpdateInterval() const = 0;
virtual QGeoSatelliteInfoSource::Error error() const = 0;
public slots:
virtual void startUpdates() = 0;
virtual void stopUpdates() = 0;
virtual void requestUpdate(int timeout = 0) = 0;
signals:
void satellitesInViewUpdated(const QList<QGeoSatelliteInfo> &satellites);
void satellitesInUseUpdated(const QList<QGeoSatelliteInfo> &satellites);
void errorOccurred(QGeoSatelliteInfoSource::Error);
public:
virtual bool setBackendProperty(const QString &name, const QVariant &value);
virtual QVariant backendProperty(const QString &name) const;
};
%End

View File

@@ -0,0 +1,94 @@
// qgeoshape.sip generated by MetaSIP
//
// This file is part of the QtPositioning Python extension module.
//
// Copyright (c) 2025 Riverbank Computing Limited <info@riverbankcomputing.com>
//
// This file is part of PyQt6.
//
// This file may be used under the terms of the GNU General Public License
// version 3.0 as published by the Free Software Foundation and appearing in
// the file LICENSE included in the packaging of this file. Please review the
// following information to ensure the GNU General Public License version 3.0
// requirements will be met: http://www.gnu.org/copyleft/gpl.html.
//
// If you do not wish to use this file under the terms of the GPL version 3.0
// then you may purchase a commercial license. For more information contact
// info@riverbankcomputing.com.
//
// This file is provided AS IS with NO WARRANTY OF ANY KIND, INCLUDING THE
// WARRANTY OF DESIGN, MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE.
%If (Qt_6_2_0 -)
class QGeoShape
{
%TypeHeaderCode
#include <qgeoshape.h>
%End
%ConvertToSubClassCode
switch (sipCpp->type())
{
case QGeoShape::CircleType:
sipType = sipType_QGeoCircle;
break;
case QGeoShape::RectangleType:
sipType = sipType_QGeoRectangle;
break;
case QGeoShape::PathType:
sipType = sipType_QGeoPath;
break;
case QGeoShape::PolygonType:
sipType = sipType_QGeoPolygon;
break;
default:
sipType = 0;
}
%End
public:
QGeoShape();
QGeoShape(const QGeoShape &other);
~QGeoShape();
enum ShapeType
{
UnknownType,
RectangleType,
CircleType,
PathType,
PolygonType,
};
QGeoShape::ShapeType type() const;
bool isValid() const;
bool isEmpty() const;
bool contains(const QGeoCoordinate &coordinate) const;
QGeoCoordinate center() const;
QString toString() const;
QGeoRectangle boundingGeoRectangle() const;
Py_hash_t __hash__() const;
%MethodCode
sipRes = qHash(*sipCpp);
%End
};
%End
%If (Qt_6_2_0 -)
QDataStream &operator<<(QDataStream &stream, const QGeoShape &shape);
%End
%If (Qt_6_2_0 -)
QDataStream &operator>>(QDataStream &stream, QGeoShape &shape /Constrained/);
%End
%If (Qt_6_2_0 -)
bool operator==(const QGeoShape &lhs, const QGeoShape &rhs);
%End
%If (Qt_6_2_0 -)
bool operator!=(const QGeoShape &lhs, const QGeoShape &rhs);
%End

View File

@@ -0,0 +1,62 @@
// qnmeapositioninfosource.sip generated by MetaSIP
//
// This file is part of the QtPositioning Python extension module.
//
// Copyright (c) 2025 Riverbank Computing Limited <info@riverbankcomputing.com>
//
// This file is part of PyQt6.
//
// This file may be used under the terms of the GNU General Public License
// version 3.0 as published by the Free Software Foundation and appearing in
// the file LICENSE included in the packaging of this file. Please review the
// following information to ensure the GNU General Public License version 3.0
// requirements will be met: http://www.gnu.org/copyleft/gpl.html.
//
// If you do not wish to use this file under the terms of the GPL version 3.0
// then you may purchase a commercial license. For more information contact
// info@riverbankcomputing.com.
//
// This file is provided AS IS with NO WARRANTY OF ANY KIND, INCLUDING THE
// WARRANTY OF DESIGN, MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE.
%If (Qt_6_2_0 -)
class QNmeaPositionInfoSource : public QGeoPositionInfoSource
{
%TypeHeaderCode
#include <qnmeapositioninfosource.h>
%End
public:
enum UpdateMode
{
RealTimeMode,
SimulationMode,
};
QNmeaPositionInfoSource(QNmeaPositionInfoSource::UpdateMode updateMode, QObject *parent /TransferThis/ = 0);
virtual ~QNmeaPositionInfoSource();
QNmeaPositionInfoSource::UpdateMode updateMode() const;
void setDevice(QIODevice *source);
QIODevice *device() const;
virtual void setUpdateInterval(int msec);
virtual QGeoPositionInfo lastKnownPosition(bool fromSatellitePositioningMethodsOnly = false) const;
virtual QGeoPositionInfoSource::PositioningMethods supportedPositioningMethods() const;
virtual int minimumUpdateInterval() const;
virtual QGeoPositionInfoSource::Error error() const;
public slots:
virtual void startUpdates();
virtual void stopUpdates();
virtual void requestUpdate(int timeout = 0);
protected:
virtual bool parsePosInfoFromNmeaData(const char *data /Encoding="None"/, int size, QGeoPositionInfo *posInfo, bool *hasFix);
public:
void setUserEquivalentRangeError(double uere);
double userEquivalentRangeError() const;
};
%End

View File

@@ -0,0 +1,68 @@
// qnmeasatelliteinfosource.sip generated by MetaSIP
//
// This file is part of the QtPositioning Python extension module.
//
// Copyright (c) 2025 Riverbank Computing Limited <info@riverbankcomputing.com>
//
// This file is part of PyQt6.
//
// This file may be used under the terms of the GNU General Public License
// version 3.0 as published by the Free Software Foundation and appearing in
// the file LICENSE included in the packaging of this file. Please review the
// following information to ensure the GNU General Public License version 3.0
// requirements will be met: http://www.gnu.org/copyleft/gpl.html.
//
// If you do not wish to use this file under the terms of the GPL version 3.0
// then you may purchase a commercial license. For more information contact
// info@riverbankcomputing.com.
//
// This file is provided AS IS with NO WARRANTY OF ANY KIND, INCLUDING THE
// WARRANTY OF DESIGN, MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE.
%If (Qt_6_2_0 -)
class QNmeaSatelliteInfoSource : public QGeoSatelliteInfoSource
{
%TypeHeaderCode
#include <qnmeasatelliteinfosource.h>
%End
public:
enum class UpdateMode
{
RealTimeMode,
SimulationMode,
};
static QString SimulationUpdateInterval;
QNmeaSatelliteInfoSource(QNmeaSatelliteInfoSource::UpdateMode mode, QObject *parent /TransferThis/ = 0);
virtual ~QNmeaSatelliteInfoSource();
QNmeaSatelliteInfoSource::UpdateMode updateMode() const;
void setDevice(QIODevice *source);
QIODevice *device() const;
virtual void setUpdateInterval(int msec);
virtual int minimumUpdateInterval() const;
virtual QGeoSatelliteInfoSource::Error error() const;
virtual bool setBackendProperty(const QString &name, const QVariant &value);
virtual QVariant backendProperty(const QString &name) const;
public slots:
virtual void startUpdates();
virtual void stopUpdates();
virtual void requestUpdate(int timeout = 0);
protected:
virtual QGeoSatelliteInfo::SatelliteSystem parseSatellitesInUseFromNmea(const char *data /Encoding="None"/, int size, QList<int> &pnrsInUse);
enum SatelliteInfoParseStatus
{
NotParsed,
PartiallyParsed,
FullyParsed,
};
virtual QNmeaSatelliteInfoSource::SatelliteInfoParseStatus parseSatelliteInfoFromNmea(const char *data /Encoding="None"/, int size, QList<QGeoSatelliteInfo> &infos, QGeoSatelliteInfo::SatelliteSystem &system);
};
%End