Skip to content

Commit

Permalink
Browse files Browse the repository at this point in the history
Merge pull request #6365 from 3nids/geom_gadget
make QgsGeometry a Q_GADGET
  • Loading branch information
3nids committed Feb 17, 2018
2 parents a8a449f + 91e98ef commit 37f180c
Show file tree
Hide file tree
Showing 3 changed files with 6 additions and 2 deletions.
2 changes: 1 addition & 1 deletion python/core/core_auto.sip
Expand Up @@ -269,7 +269,6 @@
%Include geometry/qgsellipse.sip
%Include geometry/qgsgeometrycollection.sip
%Include geometry/qgsgeometryengine.sip
%Include geometry/qgsgeometry.sip
%Include geometry/qgsgeometryutils.sip
%Include geometry/qgslinestring.sip
%Include geometry/qgsmulticurve.sip
Expand Down Expand Up @@ -372,6 +371,7 @@
%Include raster/qgsrasterdataprovider.sip
%Include raster/qgsrasterinterface.sip
%Include geometry/qgspoint.sip
%Include geometry/qgsgeometry.sip
%Include geocms/geonode/qgsgeonoderequest.sip
%Include gps/qgsgpsconnection.sip
%Include gps/qgsgpsdetector.sip
Expand Down
2 changes: 1 addition & 1 deletion src/core/CMakeLists.txt
Expand Up @@ -669,6 +669,7 @@ SET(QGIS_CORE_MOC_HDRS
raster/qgsrasterlayerrenderer.h

geometry/qgspoint.h
geometry/qgsgeometry.h

geocms/geonode/qgsgeonoderequest.h

Expand Down Expand Up @@ -1090,7 +1091,6 @@ SET(QGIS_CORE_HDRS
geometry/qgsgeometryeditutils.h
geometry/qgsgeometryengine.h
geometry/qgsgeometryfactory.h
geometry/qgsgeometry.h
geometry/qgsgeometryutils.h
geometry/qgsgeos.h
geometry/qgsinternalgeometryengine.h
Expand Down
4 changes: 4 additions & 0 deletions src/core/geometry/qgsgeometry.h
Expand Up @@ -110,6 +110,7 @@ struct QgsGeometryPrivate;

class CORE_EXPORT QgsGeometry
{
Q_GADGET
public:

/**
Expand Down Expand Up @@ -848,6 +849,7 @@ class CORE_EXPORT QgsGeometry
SideLeft = 0, //!< Buffer to left of line
SideRight, //!< Buffer to right of line
};
Q_ENUM( BufferSide );

//! End cap styles for buffers
enum EndCapStyle
Expand All @@ -856,6 +858,7 @@ class CORE_EXPORT QgsGeometry
CapFlat, //!< Flat cap (in line with start/end of line)
CapSquare, //!< Square cap (extends past start/end of line by buffer distance)
};
Q_ENUM( EndCapStyle );

//! Join styles for buffers
enum JoinStyle
Expand All @@ -864,6 +867,7 @@ class CORE_EXPORT QgsGeometry
JoinStyleMiter, //!< Use mitered joins
JoinStyleBevel, //!< Use beveled joins
};
Q_ENUM( JoinStyle );

/**
* Returns a buffer region around this geometry having the given width and with a specified number
Expand Down

0 comments on commit 37f180c

Please sign in to comment.