mirror of
https://github.com/qgis/QGIS.git
synced 2025-04-15 00:04:00 -04:00
Merge branch 'master' into regularShape_gui
This commit is contained in:
commit
a8f9f9f96b
3
debian/control.in
vendored
3
debian/control.in
vendored
@ -273,7 +273,8 @@ Depends:
|
||||
qgis-provider-grass (= ${binary:Version}),
|
||||
${shlibs:Depends},
|
||||
${misc:Depends},
|
||||
grass-core
|
||||
grass-core,
|
||||
grass{GRASSABI}
|
||||
Description: GRASS plugin for QGIS
|
||||
QGIS is a Geographic Information System (GIS) which manages, analyzes and
|
||||
display databases of geographic information.
|
||||
|
2
debian/rules
vendored
2
debian/rules
vendored
@ -54,6 +54,7 @@ QGIS_PATCH=$(shell sed -ne 's/SET(CPACK_PACKAGE_VERSION_PATCH "\([0-9]*\)")/\1/p
|
||||
QGIS_ABI=$(QGIS_MAJOR).$(QGIS_MINOR).$(QGIS_PATCH)
|
||||
GRASS=grass$(subst .,,$(shell pkg-config --modversion grass|cut -d. -f1,2))
|
||||
GRASSVER=$(subst .,,$(shell pkg-config --modversion grass|cut -d. -f1))
|
||||
GRASSABI=$(subst .,,$(shell pkg-config --modversion grass|cut -d. -f1,2,3|sed -e 's/RC/-/'))
|
||||
|
||||
CMAKE_OPTS := \
|
||||
-G Ninja \
|
||||
@ -187,6 +188,7 @@ $(2): $(1)
|
||||
-e "s/\{QGIS_ABI\}/$(QGIS_ABI)/g" \
|
||||
-e "s/\{GRASS\}/$(GRASS)/g" \
|
||||
-e "s/\{GRASSVER\}/$(GRASSVER)/g" \
|
||||
-e "s/\{GRASSABI\}/$(GRASSABI)/g" \
|
||||
-e "s/\{GRASSVER_QGISABI\}/$(GRASSVER)-$(QGIS_ABI)/g" \
|
||||
$$^ >$$@
|
||||
|
||||
|
@ -238,7 +238,7 @@ class PythonConsoleWidget(QWidget):
|
||||
self.pasteEditorButton.setToolTip(pasteEditorBt)
|
||||
self.pasteEditorButton.setText(pasteEditorBt)
|
||||
# Action Run Script (subprocess)
|
||||
runScriptEditorBt = QCoreApplication.translate("PythonConsole", "Run script")
|
||||
runScriptEditorBt = QCoreApplication.translate("PythonConsole", "Run Script")
|
||||
self.runScriptEditorButton = QAction(self)
|
||||
self.runScriptEditorButton.setCheckable(False)
|
||||
self.runScriptEditorButton.setEnabled(True)
|
||||
|
@ -34,6 +34,7 @@ from operator import itemgetter
|
||||
import traceback
|
||||
import codecs
|
||||
import re
|
||||
import importlib
|
||||
|
||||
|
||||
class KeyFilter(QObject):
|
||||
@ -520,7 +521,7 @@ class Editor(QsciScintilla):
|
||||
if dir not in sys.path:
|
||||
sys.path.append(dir)
|
||||
if name in sys.modules:
|
||||
reload(sys.modules[name]) # NOQA
|
||||
importlib.reload(sys.modules[name]) # NOQA
|
||||
try:
|
||||
# set creationflags for running command without shell window
|
||||
if sys.platform.startswith('win'):
|
||||
@ -1174,7 +1175,7 @@ class EditorTabWidget(QTabWidget):
|
||||
sys.path.append(pathFile)
|
||||
found = True
|
||||
try:
|
||||
reload(pyclbr) # NOQA
|
||||
importlib.reload(pyclbr) # NOQA
|
||||
dictObject = {}
|
||||
readModule = pyclbr.readmodule(module)
|
||||
readModuleFunction = pyclbr.readmodule_ex(module)
|
||||
@ -1236,10 +1237,10 @@ class EditorTabWidget(QTabWidget):
|
||||
iconWarning = QgsApplication.getThemeIcon("console/iconSyntaxErrorConsole.png")
|
||||
msgItem.setIcon(0, iconWarning)
|
||||
self.parent.listClassMethod.addTopLevelItem(msgItem)
|
||||
# s = traceback.format_exc()
|
||||
# print '## Error: '
|
||||
# sys.stderr.write(s)
|
||||
# pass
|
||||
# s = traceback.format_exc()
|
||||
# print('## Error: ')
|
||||
# sys.stderr.write(s)
|
||||
# pass
|
||||
|
||||
def refreshSettingsEditor(self):
|
||||
countTab = self.count()
|
||||
|
@ -359,6 +359,17 @@ Get list of authentication ids from database
|
||||
:rtype: bool
|
||||
%End
|
||||
|
||||
bool updateNetworkProxy( QNetworkProxy &proxy /In,Out/, const QString &authcfg,
|
||||
const QString &dataprovider = QString() );
|
||||
%Docstring
|
||||
Provider call to update a QNetworkProxy with an authentication config
|
||||
\param proxy the QNetworkProxy
|
||||
\param authcfg Associated authentication config id
|
||||
\param dataprovider Provider key filter, offering logic branching in authentication method
|
||||
:return: Whether operation succeeded
|
||||
:rtype: bool
|
||||
%End
|
||||
|
||||
|
||||
bool storeAuthSetting( const QString &key, const QVariant &value, bool encrypt = false );
|
||||
%Docstring
|
||||
|
@ -28,6 +28,7 @@ class QgsAuthMethod : QObject
|
||||
NetworkReply,
|
||||
DataSourceUri,
|
||||
GenericDataSourceUri,
|
||||
NetworkProxy,
|
||||
All
|
||||
};
|
||||
typedef QFlags<QgsAuthMethod::Expansion> Expansions;
|
||||
@ -110,6 +111,18 @@ Increment this if method is significantly updated, allow updater code to be writ
|
||||
:rtype: bool
|
||||
%End
|
||||
|
||||
virtual bool updateNetworkProxy( QNetworkProxy &proxy, const QString &authcfg,
|
||||
const QString &dataprovider = QString() );
|
||||
%Docstring
|
||||
Update proxy settings with authentication components
|
||||
\param proxy
|
||||
\param authcfg Authentication configuration ID
|
||||
\param dataprovider Textual key for a data provider, e.g. 'proxy', that allows
|
||||
for custom updater code specific to the provider
|
||||
:return: Whether the update succeeded
|
||||
:rtype: bool
|
||||
%End
|
||||
|
||||
virtual void clearCachedConfig( const QString &authcfg ) = 0;
|
||||
%Docstring
|
||||
Clear any cached configuration. Called when the QgsAuthManager deletes an authentication configuration (authcfg).
|
||||
|
@ -12,6 +12,7 @@
|
||||
|
||||
|
||||
|
||||
|
||||
class QgsDxfExport
|
||||
{
|
||||
|
||||
|
@ -1201,7 +1201,9 @@ Returns an extruded version of this geometry.
|
||||
%End
|
||||
public:
|
||||
Error();
|
||||
|
||||
explicit Error( const QString &m );
|
||||
|
||||
Error( const QString &m, const QgsPointXY &p );
|
||||
QString what();
|
||||
%Docstring
|
||||
|
@ -37,10 +37,10 @@ Constructor for ColumnConfig
|
||||
%End
|
||||
|
||||
|
||||
QgsAttributeTableConfig::Type type; //!< The type of this column.
|
||||
QgsAttributeTableConfig::Type type;
|
||||
QString name; //!< The name of the attribute if this column represents a field
|
||||
bool hidden; //!< Flag that controls if the column is hidden
|
||||
int width; //!< Width of column, or -1 for default width
|
||||
bool hidden;
|
||||
int width;
|
||||
};
|
||||
|
||||
enum ActionWidgetStyle
|
||||
|
@ -318,6 +318,7 @@ class QgsDiagramSettings
|
||||
};
|
||||
|
||||
QgsDiagramSettings();
|
||||
|
||||
bool enabled;
|
||||
QFont font;
|
||||
QList< QColor > categoryColors;
|
||||
|
@ -21,6 +21,7 @@ class QgsLabelPosition
|
||||
public:
|
||||
QgsLabelPosition( int id, double r, const QVector< QgsPointXY > &corners, const QgsRectangle &rect, double w, double h, const QString &layer, const QString &labeltext, const QFont &labelfont, bool upside_down, bool diagram = false, bool pinned = false, const QString &providerId = QString() );
|
||||
QgsLabelPosition();
|
||||
|
||||
int featureId;
|
||||
double rotation;
|
||||
QVector< QgsPointXY > cornerPoints;
|
||||
@ -701,9 +702,9 @@ Z-Index of label, where labels with a higher z-index are rendered on top of labe
|
||||
QgsPointXY ptZero;
|
||||
QgsPointXY ptOne;
|
||||
QgsGeometry extentGeom;
|
||||
int mFeaturesToLabel; // total features that will probably be labeled, may be less (figured before PAL)
|
||||
int mFeatsSendingToPal; // total features tested for sending into PAL (relative to maxNumLabels)
|
||||
int mFeatsRegPal; // number of features registered in PAL, when using limitNumLabels
|
||||
int mFeaturesToLabel;
|
||||
int mFeatsSendingToPal;
|
||||
int mFeatsRegPal;
|
||||
|
||||
};
|
||||
|
||||
|
@ -130,7 +130,7 @@ class QgsSettings : QObject
|
||||
%End
|
||||
~QgsSettings();
|
||||
|
||||
void beginGroup( const QString &prefix );
|
||||
void beginGroup( const QString &prefix, const QgsSettings::Section section = QgsSettings::NoSection );
|
||||
%Docstring
|
||||
Appends prefix to the current group.
|
||||
The current group is automatically prepended to all keys specified to QSettings.
|
||||
@ -245,9 +245,9 @@ Returns the path where settings written using this QSettings object are stored.
|
||||
This function is called automatically from QSettings's destructor and by the event
|
||||
loop at regular intervals, so you normally don't need to call it yourself.
|
||||
%End
|
||||
void remove( const QString &key );
|
||||
void remove( const QString &key, const QgsSettings::Section section = QgsSettings::NoSection );
|
||||
%Docstring
|
||||
Removes the setting key and any sub-settings of key.
|
||||
Removes the setting key and any sub-settings of key in a section.
|
||||
%End
|
||||
QString prefixedKey( const QString &key, const QgsSettings::Section section ) const;
|
||||
%Docstring
|
||||
|
@ -37,7 +37,7 @@ class QgsSvgCacheEntry
|
||||
%Docstring
|
||||
Absolute path to SVG file
|
||||
%End
|
||||
double size; //size in pixels (cast to int for QImage)
|
||||
double size;
|
||||
double strokeWidth;
|
||||
double widthScaleFactor;
|
||||
|
||||
|
@ -22,7 +22,7 @@ class QgsAuthCertTrustPolicyComboBox : QComboBox
|
||||
explicit QgsAuthCertTrustPolicyComboBox(
|
||||
QWidget *parent /TransferThis/ = 0,
|
||||
QgsAuthCertUtils::CertTrustPolicy policy = QgsAuthCertUtils::DefaultTrust,
|
||||
QgsAuthCertUtils::CertTrustPolicy defaultpolicy = QgsAuthCertUtils::DefaultTrust );
|
||||
QgsAuthCertUtils::CertTrustPolicy defaultpolicy = QgsAuthCertUtils::DefaultTrust );
|
||||
%Docstring
|
||||
Construct a combo box for defining certificate trust policy
|
||||
\param parent Parent widget
|
||||
|
@ -93,7 +93,7 @@ Emitted when the widget curve changes
|
||||
|
||||
protected:
|
||||
|
||||
virtual void keyPressEvent( QKeyEvent *event ) ;
|
||||
virtual void keyPressEvent( QKeyEvent *event );
|
||||
|
||||
};
|
||||
|
||||
|
@ -97,7 +97,7 @@ returns the height of the document viewer
|
||||
setDocumentViewerWidth set the height of the document viewer.
|
||||
\param height the height. Use 0 for automatic best display.
|
||||
%End
|
||||
int documentViewerWidth() const ;
|
||||
int documentViewerWidth() const;
|
||||
%Docstring
|
||||
returns the width of the document viewer
|
||||
:rtype: int
|
||||
|
@ -114,6 +114,7 @@ class QgsNewNameDialog : QgsDialog
|
||||
|
||||
QString highlightText( const QString &text );
|
||||
%Docstring
|
||||
List of names with extensions
|
||||
:rtype: str
|
||||
%End
|
||||
static QStringList fullNames( const QString &name, const QStringList &extensions );
|
||||
|
@ -27,9 +27,9 @@ class QgsSublayersDialog : QDialog
|
||||
{
|
||||
LayerDefinition();
|
||||
|
||||
int layerId; //!< Identifier of the layer (one unique layer id may have multiple types though)
|
||||
int layerId;
|
||||
QString layerName; //!< Name of the layer (not necessarily unique)
|
||||
int count; //!< Number of features (might be unused)
|
||||
int count;
|
||||
QString type; //!< Extra type depending on the use (e.g. geometry type for vector sublayers)
|
||||
};
|
||||
|
||||
|
@ -748,7 +748,7 @@ while ($LINE_IDX < $LINE_COUNT){
|
||||
};
|
||||
|
||||
# remove struct member assignment
|
||||
if ( $SIP_RUN != 1 && $ACCESS[$#ACCESS] == PUBLIC && $LINE =~ m/^(\s*\w+[\w<> *&:,]* \*?\w+) = \w+(\([^()]+\))?;/ ){
|
||||
if ( $SIP_RUN != 1 && $ACCESS[$#ACCESS] == PUBLIC && $LINE =~ m/^(\s*\w+[\w<> *&:,]* \*?\w+) = [\-\w\:\.]+(\([^()]+\))?\s*;/ ){
|
||||
dbg_info("remove struct member assignment");
|
||||
$LINE = "$1;";
|
||||
}
|
||||
|
@ -20,26 +20,12 @@
|
||||
#include "NormVecDecorator.h"
|
||||
|
||||
CloughTocherInterpolator::CloughTocherInterpolator()
|
||||
: mEdgeTolerance( 0.00001 )
|
||||
, der1X( 0.0 )
|
||||
, der1Y( 0.0 )
|
||||
, der2X( 0.0 )
|
||||
, der2Y( 0.0 )
|
||||
, der3X( 0.0 )
|
||||
, der3Y( 0.0 )
|
||||
{
|
||||
|
||||
}
|
||||
|
||||
CloughTocherInterpolator::CloughTocherInterpolator( NormVecDecorator *tin )
|
||||
: mTIN( tin )
|
||||
, mEdgeTolerance( 0.00001 )
|
||||
, der1X( 0.0 )
|
||||
, der1Y( 0.0 )
|
||||
, der2X( 0.0 )
|
||||
, der2Y( 0.0 )
|
||||
, der3X( 0.0 )
|
||||
, der3Y( 0.0 )
|
||||
{
|
||||
|
||||
}
|
||||
|
@ -35,7 +35,7 @@ class ANALYSIS_EXPORT CloughTocherInterpolator : public TriangleInterpolator
|
||||
//! Association with a triangulation object
|
||||
NormVecDecorator *mTIN = nullptr;
|
||||
//! Tolerance of the barycentric coordinates at the borders of the triangles (to prevent errors because of very small negativ baricentric coordinates)
|
||||
double mEdgeTolerance;
|
||||
double mEdgeTolerance = 0.00001;
|
||||
//! First point of the triangle in x-,y-,z-coordinates
|
||||
QgsPoint point1 = QgsPoint( 0, 0, 0 );
|
||||
//! Second point of the triangle in x-,y-,z-coordinates
|
||||
@ -75,17 +75,17 @@ class ANALYSIS_EXPORT CloughTocherInterpolator : public TriangleInterpolator
|
||||
//! Control point 16
|
||||
QgsPoint cp16 = QgsPoint( 0, 0, 0 );
|
||||
//! Derivative in x-direction at point1
|
||||
double der1X;
|
||||
double der1X = 0.0;
|
||||
//! Derivative in y-direction at point1
|
||||
double der1Y;
|
||||
double der1Y = 0.0;
|
||||
//! Derivative in x-direction at point2
|
||||
double der2X;
|
||||
double der2X = 0.0;
|
||||
//! Derivative in y-direction at point2
|
||||
double der2Y;
|
||||
double der2Y = 0.0;
|
||||
//! Derivative in x-direction at point3
|
||||
double der3X;
|
||||
double der3X = 0.0;
|
||||
//! Derivative in y-direction at point3
|
||||
double der3Y;
|
||||
double der3Y = 0.0;
|
||||
//! Stores point1 of the last run
|
||||
QgsPoint lpoint1 = QgsPoint( 0, 0, 0 );
|
||||
//! Stores point2 of the last run
|
||||
|
@ -107,13 +107,13 @@ class ANALYSIS_EXPORT DualEdgeTriangulation: public Triangulation
|
||||
|
||||
protected:
|
||||
//! X-coordinate of the upper right corner of the bounding box
|
||||
double xMax;
|
||||
double xMax = 0;
|
||||
//! X-coordinate of the lower left corner of the bounding box
|
||||
double xMin;
|
||||
double xMin = 0;
|
||||
//! Y-coordinate of the upper right corner of the bounding box
|
||||
double yMax;
|
||||
double yMax = 0;
|
||||
//! Y-coordinate of the lower left corner of the bounding box
|
||||
double yMin;
|
||||
double yMin = 0;
|
||||
//! Default value for the number of storable points at the beginning
|
||||
static const unsigned int DEFAULT_STORAGE_FOR_POINTS = 100000;
|
||||
//! Stores pointers to all points in the triangulations (including the points contained in the lines)
|
||||
@ -125,7 +125,7 @@ class ANALYSIS_EXPORT DualEdgeTriangulation: public Triangulation
|
||||
//! Association to an interpolator object
|
||||
TriangleInterpolator *mTriangleInterpolator = nullptr;
|
||||
//! Member to store the behavior in case of crossing forced segments
|
||||
Triangulation::ForcedCrossBehavior mForcedCrossBehavior;
|
||||
Triangulation::ForcedCrossBehavior mForcedCrossBehavior = Triangulation::DeleteFirst;
|
||||
//! Color to paint the normal edges
|
||||
QColor mEdgeColor;
|
||||
//! Color to paint the forced edges
|
||||
@ -153,15 +153,15 @@ class ANALYSIS_EXPORT DualEdgeTriangulation: public Triangulation
|
||||
//! Swaps 'edge' and does no recursiv testing
|
||||
void doOnlySwap( unsigned int edge );
|
||||
//! Number of an edge which does not point to the virtual point. It continuously updated for a fast search
|
||||
unsigned int mEdgeInside;
|
||||
unsigned int mEdgeInside = 0;
|
||||
//! Number of an edge on the outside of the convex hull. It is updated in method 'baseEdgeOfTriangle' to enable insertion of points outside the convex hull
|
||||
unsigned int mEdgeOutside;
|
||||
unsigned int mEdgeOutside = 0;
|
||||
//! If an inserted point is exactly on an existing edge, 'baseEdgeOfTriangle' returns -20 and sets the variable 'mEdgeWithPoint'
|
||||
unsigned int mEdgeWithPoint;
|
||||
unsigned int mEdgeWithPoint = 0;
|
||||
//! If an instability occurs in 'baseEdgeOfTriangle', mUnstableEdge is set to the value of the current edge
|
||||
unsigned int mUnstableEdge;
|
||||
unsigned int mUnstableEdge = 0;
|
||||
//! If a point has been inserted twice, its number is stored in this member
|
||||
int mTwiceInsPoint;
|
||||
int mTwiceInsPoint = 0;
|
||||
//! Returns true, if it is possible to swap an edge, otherwise false(concave quad or edge on (or outside) the convex hull)
|
||||
bool swapPossible( unsigned int edge );
|
||||
//! Divides a polygon in a triangle and two polygons and calls itself recursively for these two polygons. 'poly' is a pointer to a list with the numbers of the edges of the polygon, 'free' is a pointer to a list of free halfedges, and 'mainedge' is the number of the edge, towards which the new triangle is inserted. Mainedge has to be the same as poly->begin(), otherwise the recursion does not work
|
||||
@ -181,42 +181,20 @@ class ANALYSIS_EXPORT DualEdgeTriangulation: public Triangulation
|
||||
#ifndef SIP_RUN
|
||||
|
||||
inline DualEdgeTriangulation::DualEdgeTriangulation()
|
||||
: xMax( 0 )
|
||||
, xMin( 0 )
|
||||
, yMax( 0 )
|
||||
, yMin( 0 )
|
||||
, mTriangleInterpolator( nullptr )
|
||||
, mForcedCrossBehavior( Triangulation::DeleteFirst )
|
||||
, mEdgeColor( 0, 255, 0 )
|
||||
: mEdgeColor( 0, 255, 0 )
|
||||
, mForcedEdgeColor( 0, 0, 255 )
|
||||
, mBreakEdgeColor( 100, 100, 0 )
|
||||
, mDecorator( this )
|
||||
, mEdgeInside( 0 )
|
||||
, mEdgeOutside( 0 )
|
||||
, mEdgeWithPoint( 0 )
|
||||
, mUnstableEdge( 0 )
|
||||
, mTwiceInsPoint( 0 )
|
||||
{
|
||||
mPointVector.reserve( DEFAULT_STORAGE_FOR_POINTS );
|
||||
mHalfEdge.reserve( DEFAULT_STORAGE_FOR_HALF_EDGES );
|
||||
}
|
||||
|
||||
inline DualEdgeTriangulation::DualEdgeTriangulation( int nop, Triangulation *decorator )
|
||||
: xMax( 0 )
|
||||
, xMin( 0 )
|
||||
, yMax( 0 )
|
||||
, yMin( 0 )
|
||||
, mTriangleInterpolator( nullptr )
|
||||
, mForcedCrossBehavior( Triangulation::DeleteFirst )
|
||||
, mEdgeColor( 0, 255, 0 )
|
||||
: mEdgeColor( 0, 255, 0 )
|
||||
, mForcedEdgeColor( 0, 0, 255 )
|
||||
, mBreakEdgeColor( 100, 100, 0 )
|
||||
, mDecorator( decorator ? decorator : this )
|
||||
, mEdgeInside( 0 )
|
||||
, mEdgeOutside( 0 )
|
||||
, mEdgeWithPoint( 0 )
|
||||
, mUnstableEdge( 0 )
|
||||
, mTwiceInsPoint( 0 )
|
||||
{
|
||||
mPointVector.reserve( nop );
|
||||
mHalfEdge.reserve( nop );
|
||||
|
@ -29,15 +29,15 @@ class ANALYSIS_EXPORT HalfEdge
|
||||
{
|
||||
protected:
|
||||
//! Number of the dual HalfEdge
|
||||
int mDual;
|
||||
int mDual = -10;
|
||||
//! Number of the next HalfEdge
|
||||
int mNext;
|
||||
int mNext = -10;
|
||||
//! Number of the point at which this HalfEdge points
|
||||
int mPoint;
|
||||
int mPoint = -10;
|
||||
//! True, if the HalfEdge belongs to a break line, false otherwise
|
||||
bool mBreak;
|
||||
bool mBreak = false;
|
||||
//! True, if the HalfEdge belongs to a constrained edge, false otherwise
|
||||
bool mForced;
|
||||
bool mForced = false;
|
||||
|
||||
public:
|
||||
//! Default constructor. Values for mDual, mNext, mPoint are set to -10 which means that they are undefined
|
||||
@ -69,7 +69,7 @@ class ANALYSIS_EXPORT HalfEdge
|
||||
#ifndef SIP_RUN
|
||||
|
||||
|
||||
inline HalfEdge::HalfEdge(): mDual( -10 ), mNext( -10 ), mPoint( -10 ), mBreak( false ), mForced( false )
|
||||
inline HalfEdge::HalfEdge()
|
||||
{
|
||||
|
||||
}
|
||||
|
@ -56,7 +56,6 @@ class ANALYSIS_EXPORT LinTriangleInterpolator : public TriangleInterpolator
|
||||
#ifndef SIP_RUN
|
||||
|
||||
inline LinTriangleInterpolator::LinTriangleInterpolator()
|
||||
: mTIN( nullptr )
|
||||
{
|
||||
|
||||
}
|
||||
|
@ -52,8 +52,6 @@ class ANALYSIS_EXPORT Node
|
||||
|
||||
|
||||
inline Node::Node()
|
||||
: mPoint( nullptr )
|
||||
, mNext( nullptr )
|
||||
{
|
||||
|
||||
}
|
||||
|
@ -86,12 +86,18 @@ class ANALYSIS_EXPORT NormVecDecorator: public TriDecorator
|
||||
|
||||
#ifndef SIP_RUN
|
||||
|
||||
inline NormVecDecorator::NormVecDecorator(): TriDecorator(), mInterpolator( nullptr ), mNormVec( new QVector<Vector3D*>( DEFAULT_STORAGE_FOR_NORMALS ) ), mPointState( new QVector<PointState>( DEFAULT_STORAGE_FOR_NORMALS ) )
|
||||
inline NormVecDecorator::NormVecDecorator()
|
||||
: TriDecorator()
|
||||
, mNormVec( new QVector<Vector3D*>( DEFAULT_STORAGE_FOR_NORMALS ) )
|
||||
, mPointState( new QVector<PointState>( DEFAULT_STORAGE_FOR_NORMALS ) )
|
||||
{
|
||||
alreadyestimated = false;
|
||||
}
|
||||
|
||||
inline NormVecDecorator::NormVecDecorator( Triangulation *tin ): TriDecorator( tin ), mInterpolator( nullptr ), mNormVec( new QVector<Vector3D*>( DEFAULT_STORAGE_FOR_NORMALS ) ), mPointState( new QVector<PointState>( DEFAULT_STORAGE_FOR_NORMALS ) )
|
||||
inline NormVecDecorator::NormVecDecorator( Triangulation *tin )
|
||||
: TriDecorator( tin )
|
||||
, mNormVec( new QVector<Vector3D*>( DEFAULT_STORAGE_FOR_NORMALS ) )
|
||||
, mPointState( new QVector<PointState>( DEFAULT_STORAGE_FOR_NORMALS ) )
|
||||
{
|
||||
alreadyestimated = false;
|
||||
}
|
||||
|
@ -35,11 +35,11 @@ class ANALYSIS_EXPORT ParametricLine
|
||||
{
|
||||
protected:
|
||||
//! Degree of the parametric Line
|
||||
int mDegree;
|
||||
int mDegree = 0;
|
||||
//! Pointer to the parent object. If there isn't one, mParent is 0
|
||||
ParametricLine *mParent = nullptr;
|
||||
//! MControlPoly stores the points of the control polygon
|
||||
QVector<QgsPoint *> *mControlPoly;
|
||||
QVector<QgsPoint *> *mControlPoly = nullptr;
|
||||
public:
|
||||
//! Default constructor
|
||||
ParametricLine();
|
||||
@ -70,16 +70,12 @@ class ANALYSIS_EXPORT ParametricLine
|
||||
//-----------------------------------------constructors and destructor----------------------
|
||||
|
||||
inline ParametricLine::ParametricLine()
|
||||
: mDegree( 0 )
|
||||
, mParent( nullptr )
|
||||
, mControlPoly( nullptr )
|
||||
{
|
||||
|
||||
}
|
||||
|
||||
inline ParametricLine::ParametricLine( ParametricLine *par, QVector<QgsPoint *> *controlpoly )
|
||||
: mDegree( 0 )
|
||||
, mParent( par )
|
||||
: mParent( par )
|
||||
, mControlPoly( controlpoly )
|
||||
{
|
||||
|
||||
|
@ -68,12 +68,13 @@ class ANALYSIS_EXPORT TriDecorator : public Triangulation
|
||||
|
||||
#ifndef SIP_RUN
|
||||
|
||||
inline TriDecorator::TriDecorator(): mTIN( nullptr )
|
||||
inline TriDecorator::TriDecorator()
|
||||
{
|
||||
|
||||
}
|
||||
|
||||
inline TriDecorator::TriDecorator( Triangulation *t ): mTIN( t )
|
||||
inline TriDecorator::TriDecorator( Triangulation *t )
|
||||
: mTIN( t )
|
||||
{
|
||||
|
||||
}
|
||||
|
@ -33,11 +33,11 @@ class ANALYSIS_EXPORT Vector3D
|
||||
{
|
||||
protected:
|
||||
//! X-component of the vector
|
||||
double mX;
|
||||
double mX = 0;
|
||||
//! Y-component of the vector
|
||||
double mY;
|
||||
double mY = 0;
|
||||
//! Z-component of the vector
|
||||
double mZ;
|
||||
double mZ = 0;
|
||||
|
||||
public:
|
||||
//! Constructor taking the three components as arguments
|
||||
@ -83,9 +83,6 @@ inline Vector3D::Vector3D( double x, double y, double z )
|
||||
}
|
||||
|
||||
inline Vector3D::Vector3D()
|
||||
: mX( 0 )
|
||||
, mY( 0 )
|
||||
, mZ( 0 )//using a list
|
||||
{
|
||||
|
||||
}
|
||||
|
@ -35,10 +35,6 @@ QgsGridFileWriter::QgsGridFileWriter( QgsInterpolator *i, const QString &outputP
|
||||
}
|
||||
|
||||
QgsGridFileWriter::QgsGridFileWriter()
|
||||
: mNumColumns( 0 )
|
||||
, mNumRows( 0 )
|
||||
, mCellSizeX( 0 )
|
||||
, mCellSizeY( 0 )
|
||||
{
|
||||
|
||||
}
|
||||
|
@ -48,11 +48,11 @@ class ANALYSIS_EXPORT QgsGridFileWriter
|
||||
QgsInterpolator *mInterpolator = nullptr;
|
||||
QString mOutputFilePath;
|
||||
QgsRectangle mInterpolationExtent;
|
||||
int mNumColumns;
|
||||
int mNumRows;
|
||||
int mNumColumns = 0;
|
||||
int mNumRows = 0;
|
||||
|
||||
double mCellSizeX;
|
||||
double mCellSizeY;
|
||||
double mCellSizeX = 0;
|
||||
double mCellSizeY = 0;
|
||||
};
|
||||
|
||||
#endif
|
||||
|
@ -19,12 +19,14 @@
|
||||
#include <cmath>
|
||||
#include <limits>
|
||||
|
||||
QgsIDWInterpolator::QgsIDWInterpolator( const QList<LayerData> &layerData ): QgsInterpolator( layerData ), mDistanceCoefficient( 2.0 )
|
||||
QgsIDWInterpolator::QgsIDWInterpolator( const QList<LayerData> &layerData )
|
||||
: QgsInterpolator( layerData )
|
||||
{
|
||||
|
||||
}
|
||||
|
||||
QgsIDWInterpolator::QgsIDWInterpolator(): QgsInterpolator( QList<LayerData>() ), mDistanceCoefficient( 2.0 )
|
||||
QgsIDWInterpolator::QgsIDWInterpolator()
|
||||
: QgsInterpolator( QList<LayerData>() )
|
||||
{
|
||||
|
||||
}
|
||||
|
@ -45,7 +45,7 @@ class ANALYSIS_EXPORT QgsIDWInterpolator: public QgsInterpolator
|
||||
/** The parameter that sets how the values are weighted with distance.
|
||||
Smaller values mean sharper peaks at the data points. The default is a
|
||||
value of 2*/
|
||||
double mDistanceCoefficient;
|
||||
double mDistanceCoefficient = 2.0;
|
||||
};
|
||||
|
||||
#endif
|
||||
|
@ -23,14 +23,12 @@
|
||||
#include "qgswkbptr.h"
|
||||
|
||||
QgsInterpolator::QgsInterpolator( const QList<LayerData> &layerData )
|
||||
: mDataIsCached( false )
|
||||
, mLayerData( layerData )
|
||||
: mLayerData( layerData )
|
||||
{
|
||||
|
||||
}
|
||||
|
||||
QgsInterpolator::QgsInterpolator()
|
||||
: mDataIsCached( false )
|
||||
{
|
||||
|
||||
}
|
||||
@ -208,7 +206,7 @@ int QgsInterpolator::addVerticesToCache( const QgsGeometry &geom, bool zCoord, d
|
||||
wkbPtr >> nPoints;
|
||||
for ( int index = 0; index < nPoints; ++index )
|
||||
{
|
||||
wkbPtr += 1 + sizeof( int ); //skip endian and point type
|
||||
wkbPtr += 1 + sizeof( int ); //skip endian and point type
|
||||
|
||||
double x, y;
|
||||
wkbPtr >> x >> y;
|
||||
|
@ -80,7 +80,7 @@ class ANALYSIS_EXPORT QgsInterpolator
|
||||
QVector<vertexData> mCachedBaseData;
|
||||
|
||||
//! Flag that tells if the cache already has been filled
|
||||
bool mDataIsCached;
|
||||
bool mDataIsCached = false;
|
||||
|
||||
//Information about the input vector layers and the attributes (or z-values) that are used for interpolation
|
||||
QList<LayerData> mLayerData;
|
||||
|
@ -76,8 +76,6 @@ int QgsGraph::findVertex( const QgsPointXY &pt ) const
|
||||
}
|
||||
|
||||
QgsGraphEdge::QgsGraphEdge()
|
||||
: mOut( 0 )
|
||||
, mIn( 0 )
|
||||
{
|
||||
|
||||
}
|
||||
|
@ -70,8 +70,8 @@ class ANALYSIS_EXPORT QgsGraphEdge
|
||||
|
||||
QVector< QVariant > mStrategies;
|
||||
|
||||
int mOut;
|
||||
int mIn;
|
||||
int mOut = 0;
|
||||
int mIn = 0;
|
||||
|
||||
friend class QgsGraph;
|
||||
};
|
||||
|
@ -71,7 +71,7 @@ point features or be used to define the path of a way.
|
||||
class ANALYSIS_EXPORT QgsOSMNode : public QgsOSMElement
|
||||
{
|
||||
public:
|
||||
QgsOSMNode() : mPoint() {}
|
||||
QgsOSMNode() {}
|
||||
QgsOSMNode( QgsOSMId id, const QgsPointXY &point )
|
||||
: QgsOSMElement( QgsOSMElementID::Node, id )
|
||||
, mPoint( point )
|
||||
|
@ -25,21 +25,11 @@ QgsNineCellFilter::QgsNineCellFilter( const QString &inputFile, const QString &o
|
||||
: mInputFile( inputFile )
|
||||
, mOutputFile( outputFile )
|
||||
, mOutputFormat( outputFormat )
|
||||
, mCellSizeX( -1.0 )
|
||||
, mCellSizeY( -1.0 )
|
||||
, mInputNodataValue( -1.0 )
|
||||
, mOutputNodataValue( -1.0 )
|
||||
, mZFactor( 1.0 )
|
||||
{
|
||||
|
||||
}
|
||||
|
||||
QgsNineCellFilter::QgsNineCellFilter()
|
||||
: mCellSizeX( -1.0 )
|
||||
, mCellSizeY( -1.0 )
|
||||
, mInputNodataValue( -1.0 )
|
||||
, mOutputNodataValue( -1.0 )
|
||||
, mZFactor( 1.0 )
|
||||
{
|
||||
}
|
||||
|
||||
|
@ -81,14 +81,14 @@ class ANALYSIS_EXPORT QgsNineCellFilter
|
||||
QString mOutputFile;
|
||||
QString mOutputFormat;
|
||||
|
||||
double mCellSizeX;
|
||||
double mCellSizeY;
|
||||
double mCellSizeX = -1.0;
|
||||
double mCellSizeY = -1.0;
|
||||
//! The nodata value of the input layer
|
||||
float mInputNodataValue;
|
||||
float mInputNodataValue = -1.0;
|
||||
//! The nodata value of the output layer
|
||||
float mOutputNodataValue;
|
||||
float mOutputNodataValue = -1.0;
|
||||
//! Scale factor for z-value if x-/y- units are different to z-units (111120 for degree->meters and 370400 for degree->feet)
|
||||
double mZFactor;
|
||||
double mZFactor = 1.0;
|
||||
};
|
||||
|
||||
#endif // QGSNINECELLFILTER_H
|
||||
|
@ -18,24 +18,17 @@
|
||||
#include <cfloat>
|
||||
|
||||
QgsRasterCalcNode::QgsRasterCalcNode()
|
||||
: mType( tNumber )
|
||||
, mNumber( 0 )
|
||||
, mOperator( opNONE )
|
||||
{
|
||||
}
|
||||
|
||||
QgsRasterCalcNode::QgsRasterCalcNode( double number )
|
||||
: mType( tNumber )
|
||||
, mNumber( number )
|
||||
, mOperator( opNONE )
|
||||
: mNumber( number )
|
||||
{
|
||||
}
|
||||
|
||||
QgsRasterCalcNode::QgsRasterCalcNode( QgsRasterMatrix *matrix )
|
||||
: mType( tMatrix )
|
||||
, mNumber( 0 )
|
||||
, mMatrix( matrix )
|
||||
, mOperator( opNONE )
|
||||
{
|
||||
|
||||
}
|
||||
@ -44,16 +37,13 @@ QgsRasterCalcNode::QgsRasterCalcNode( Operator op, QgsRasterCalcNode *left, QgsR
|
||||
: mType( tOperator )
|
||||
, mLeft( left )
|
||||
, mRight( right )
|
||||
, mNumber( 0 )
|
||||
, mOperator( op )
|
||||
{
|
||||
}
|
||||
|
||||
QgsRasterCalcNode::QgsRasterCalcNode( const QString &rasterName )
|
||||
: mType( tRasterRef )
|
||||
, mNumber( 0 )
|
||||
, mRasterName( rasterName )
|
||||
, mOperator( opNONE )
|
||||
{
|
||||
if ( mRasterName.startsWith( '"' ) && mRasterName.endsWith( '"' ) )
|
||||
mRasterName = mRasterName.mid( 1, mRasterName.size() - 2 );
|
||||
|
@ -107,13 +107,13 @@ class ANALYSIS_EXPORT QgsRasterCalcNode
|
||||
QgsRasterCalcNode( const QgsRasterCalcNode &rh );
|
||||
#endif
|
||||
|
||||
Type mType;
|
||||
Type mType = tNumber;
|
||||
QgsRasterCalcNode *mLeft = nullptr;
|
||||
QgsRasterCalcNode *mRight = nullptr;
|
||||
double mNumber;
|
||||
double mNumber = 0;
|
||||
QString mRasterName;
|
||||
QgsRasterMatrix *mMatrix = nullptr;
|
||||
Operator mOperator;
|
||||
Operator mOperator = opNONE;
|
||||
|
||||
};
|
||||
|
||||
|
@ -176,8 +176,6 @@ int QgsRasterCalculator::processCalculation( QgsFeedback *feedback )
|
||||
}
|
||||
|
||||
QgsRasterCalculator::QgsRasterCalculator()
|
||||
: mNumOutputColumns( 0 )
|
||||
, mNumOutputRows( 0 )
|
||||
{
|
||||
}
|
||||
|
||||
|
@ -118,9 +118,9 @@ class ANALYSIS_EXPORT QgsRasterCalculator
|
||||
QgsCoordinateReferenceSystem mOutputCrs;
|
||||
|
||||
//! Number of output columns
|
||||
int mNumOutputColumns;
|
||||
int mNumOutputColumns = 0;
|
||||
//! Number of output rows
|
||||
int mNumOutputRows;
|
||||
int mNumOutputRows = 0;
|
||||
|
||||
/***/
|
||||
QVector<QgsRasterCalculatorEntry> mRasterEntries;
|
||||
|
@ -20,9 +20,6 @@
|
||||
#include <cmath>
|
||||
|
||||
QgsRasterMatrix::QgsRasterMatrix()
|
||||
: mColumns( 0 )
|
||||
, mRows( 0 )
|
||||
, mNodataValue( -1 )
|
||||
{
|
||||
}
|
||||
|
||||
@ -35,8 +32,6 @@ QgsRasterMatrix::QgsRasterMatrix( int nCols, int nRows, double *data, double nod
|
||||
}
|
||||
|
||||
QgsRasterMatrix::QgsRasterMatrix( const QgsRasterMatrix &m )
|
||||
: mColumns( 0 )
|
||||
, mRows( 0 )
|
||||
{
|
||||
operator=( m );
|
||||
}
|
||||
|
@ -115,10 +115,10 @@ class ANALYSIS_EXPORT QgsRasterMatrix
|
||||
bool log10();
|
||||
|
||||
private:
|
||||
int mColumns;
|
||||
int mRows;
|
||||
int mColumns = 0;
|
||||
int mRows = 0;
|
||||
double *mData = nullptr;
|
||||
double mNodataValue;
|
||||
double mNodataValue = -1;
|
||||
|
||||
//! +,-,*,/,^,<,>,<=,>=,=,!=, and, or
|
||||
bool twoArgumentOperation( TwoArgOperator op, const QgsRasterMatrix &other );
|
||||
|
@ -387,7 +387,7 @@ bool QgsRelief::processNineCellWindow( float *x1, float *x2, float *x3, float *x
|
||||
|
||||
bool QgsRelief::setElevationColor( double elevation, int *red, int *green, int *blue )
|
||||
{
|
||||
QList< ReliefColor >::const_iterator reliefColorIt = mReliefColors.constBegin();
|
||||
QList< ReliefColor >::const_iterator reliefColorIt = mReliefColors.constBegin();
|
||||
for ( ; reliefColorIt != mReliefColors.constEnd(); ++reliefColorIt )
|
||||
{
|
||||
if ( elevation >= reliefColorIt->minElevation && elevation <= reliefColorIt->maxElevation )
|
||||
|
@ -18,12 +18,14 @@
|
||||
#include "qgsruggednessfilter.h"
|
||||
#include <cmath>
|
||||
|
||||
QgsRuggednessFilter::QgsRuggednessFilter( const QString &inputFile, const QString &outputFile, const QString &outputFormat ): QgsNineCellFilter( inputFile, outputFile, outputFormat )
|
||||
QgsRuggednessFilter::QgsRuggednessFilter( const QString &inputFile, const QString &outputFile, const QString &outputFormat )
|
||||
: QgsNineCellFilter( inputFile, outputFile, outputFormat )
|
||||
{
|
||||
|
||||
}
|
||||
|
||||
QgsRuggednessFilter::QgsRuggednessFilter(): QgsNineCellFilter( QLatin1String( "" ), QLatin1String( "" ), QLatin1String( "" ) )
|
||||
QgsRuggednessFilter::QgsRuggednessFilter()
|
||||
: QgsNineCellFilter( QString(), QString(), QString() )
|
||||
{
|
||||
|
||||
}
|
||||
|
@ -353,7 +353,7 @@ void QgsSnapIndex::addGeometry( const QgsAbstractGeometry *geom )
|
||||
QgsPoint QgsSnapIndex::getClosestSnapToPoint( const QgsPoint &p, const QgsPoint &q )
|
||||
{
|
||||
// Look for intersections on segment from the target point to the point opposite to the point reference point
|
||||
// p2 = p1 + 2 * (q - p1)
|
||||
// p2 = p1 + 2 * (q - p1)
|
||||
QgsPoint p2( 2 * q.x() - p.x(), 2 * q.y() - p.y() );
|
||||
|
||||
// Raytrace along the grid, get touched cells
|
||||
|
@ -222,7 +222,7 @@ class QgsSnapIndex
|
||||
class GridRow
|
||||
{
|
||||
public:
|
||||
GridRow() : mColStartIdx( 0 ) {}
|
||||
GridRow() {}
|
||||
~GridRow();
|
||||
const Cell *getCell( int col ) const;
|
||||
Cell &getCreateCell( int col );
|
||||
@ -230,7 +230,7 @@ class QgsSnapIndex
|
||||
|
||||
private:
|
||||
QList<QgsSnapIndex::Cell> mCells;
|
||||
int mColStartIdx;
|
||||
int mColStartIdx = 0;
|
||||
};
|
||||
|
||||
QgsPoint mOrigin;
|
||||
|
@ -283,7 +283,7 @@ int QgsZonalStatistics::calculateStatistics( QgsFeedback *feedback )
|
||||
if ( mStatistics & QgsZonalStatistics::Median )
|
||||
{
|
||||
std::sort( featureStats.values.begin(), featureStats.values.end() );
|
||||
int size = featureStats.values.count();
|
||||
int size = featureStats.values.count();
|
||||
bool even = ( size % 2 ) < 1;
|
||||
double medianValue;
|
||||
if ( even )
|
||||
|
@ -131,7 +131,7 @@ void QgsAtlasCompositionWidget::on_mAtlasFilenameExpressionButton_clicked()
|
||||
|
||||
if ( exprDlg.exec() == QDialog::Accepted )
|
||||
{
|
||||
QString expression = exprDlg.expressionText();
|
||||
QString expression = exprDlg.expressionText();
|
||||
if ( !expression.isEmpty() )
|
||||
{
|
||||
//set atlas filename expression
|
||||
@ -304,7 +304,7 @@ void QgsAtlasCompositionWidget::on_mAtlasFeatureFilterButton_clicked()
|
||||
|
||||
if ( exprDlg.exec() == QDialog::Accepted )
|
||||
{
|
||||
QString expression = exprDlg.expressionText();
|
||||
QString expression = exprDlg.expressionText();
|
||||
if ( !expression.isEmpty() )
|
||||
{
|
||||
mAtlasFeatureFilterEdit->setText( expression );
|
||||
|
@ -111,7 +111,7 @@ QgsComposer::QgsComposer( QgsComposition *composition )
|
||||
setWindowTitle( mComposition->name() );
|
||||
setAttribute( Qt::WA_DeleteOnClose );
|
||||
#if QT_VERSION >= 0x050600
|
||||
setDockOptions( dockOptions() | QMainWindow::GroupedDragging ) ;
|
||||
setDockOptions( dockOptions() | QMainWindow::GroupedDragging );
|
||||
#endif
|
||||
setupTheme();
|
||||
|
||||
@ -1678,7 +1678,7 @@ void QgsComposer::exportCompositionAsPDF( QgsComposer::OutputMode mode )
|
||||
mComposition->beginPrintAsPDF( printer, outputFileName );
|
||||
// set the correct resolution
|
||||
mComposition->beginPrint( printer );
|
||||
bool printReady = painter.begin( &printer );
|
||||
bool printReady = painter.begin( &printer );
|
||||
if ( !printReady )
|
||||
{
|
||||
QMessageBox::warning( this, tr( "Atlas processing error" ),
|
||||
@ -2270,7 +2270,7 @@ void QgsComposer::exportCompositionAsImage( QgsComposer::OutputMode mode )
|
||||
imageFilename = fi.absolutePath() + '/' + fi.baseName() + '_' + QString::number( i + 1 ) + '.' + fi.suffix();
|
||||
}
|
||||
|
||||
bool saveOk = saveImage( image, imageFilename, format );
|
||||
bool saveOk = saveImage( image, imageFilename, format );
|
||||
if ( !saveOk )
|
||||
{
|
||||
QMessageBox::warning( this, tr( "Atlas processing error" ),
|
||||
|
@ -236,7 +236,7 @@ void QgsComposerArrowWidget::on_mStartMarkerLineEdit_textChanged( const QString
|
||||
}
|
||||
else
|
||||
{
|
||||
mArrow->setStartMarker( QLatin1String( "" ) );
|
||||
mArrow->setStartMarker( QString() );
|
||||
}
|
||||
mArrow->update();
|
||||
mArrow->endCommand();
|
||||
@ -255,7 +255,7 @@ void QgsComposerArrowWidget::on_mEndMarkerLineEdit_textChanged( const QString &t
|
||||
}
|
||||
else
|
||||
{
|
||||
mArrow->setEndMarker( QLatin1String( "" ) );
|
||||
mArrow->setEndMarker( QString() );
|
||||
}
|
||||
mArrow->update();
|
||||
mArrow->endCommand();
|
||||
|
@ -784,7 +784,7 @@ void QgsComposerAttributeTableWidget::on_mFeatureFilterButton_clicked()
|
||||
exprDlg.setWindowTitle( tr( "Expression Based Filter" ) );
|
||||
if ( exprDlg.exec() == QDialog::Accepted )
|
||||
{
|
||||
QString expression = exprDlg.expressionText();
|
||||
QString expression = exprDlg.expressionText();
|
||||
if ( !expression.isEmpty() )
|
||||
{
|
||||
mFeatureFilterEdit->setText( expression );
|
||||
|
@ -358,7 +358,7 @@ void QgsComposerHtmlWidget::on_mInsertExpressionButton_clicked()
|
||||
exprDlg.setWindowTitle( tr( "Insert Expression" ) );
|
||||
if ( exprDlg.exec() == QDialog::Accepted )
|
||||
{
|
||||
QString expression = exprDlg.expressionText();
|
||||
QString expression = exprDlg.expressionText();
|
||||
QgsComposition *composition = mHtml->composition();
|
||||
if ( !expression.isEmpty() && composition )
|
||||
{
|
||||
|
@ -164,7 +164,7 @@ void QgsComposerLabelWidget::on_mInsertExpressionButton_clicked()
|
||||
exprDlg.setWindowTitle( tr( "Insert Expression" ) );
|
||||
if ( exprDlg.exec() == QDialog::Accepted )
|
||||
{
|
||||
QString expression = exprDlg.expressionText();
|
||||
QString expression = exprDlg.expressionText();
|
||||
if ( !expression.isEmpty() )
|
||||
{
|
||||
mComposerLabel->beginCommand( tr( "Insert expression" ) );
|
||||
|
@ -438,7 +438,7 @@ bool QgsComposerMapGridWidget::hasPredefinedScales() const
|
||||
QgsSettings settings;
|
||||
QString scalesStr( settings.value( QStringLiteral( "Map/scales" ), PROJECT_SCALES ).toString() );
|
||||
QStringList myScalesList = scalesStr.split( ',' );
|
||||
return !myScalesList.isEmpty() && myScalesList[0] != QLatin1String( "" );
|
||||
return !myScalesList.isEmpty() && !myScalesList[0].isEmpty();
|
||||
}
|
||||
return true;
|
||||
}
|
||||
@ -1075,7 +1075,7 @@ void QgsComposerMapGridWidget::on_mAnnotationFormatButton_clicked()
|
||||
|
||||
if ( exprDlg.exec() == QDialog::Accepted )
|
||||
{
|
||||
QString expression = exprDlg.expressionText();
|
||||
QString expression = exprDlg.expressionText();
|
||||
mComposerMap->beginCommand( tr( "Annotation format changed" ) );
|
||||
mComposerMapGrid->setAnnotationExpression( expression );
|
||||
mComposerMap->updateBoundingRect();
|
||||
|
@ -1051,7 +1051,7 @@ bool QgsComposerMapWidget::hasPredefinedScales() const
|
||||
QgsSettings settings;
|
||||
QString scalesStr( settings.value( QStringLiteral( "Map/scales" ), PROJECT_SCALES ).toString() );
|
||||
QStringList myScalesList = scalesStr.split( ',' );
|
||||
return !myScalesList.isEmpty() && myScalesList[0] != QLatin1String( "" );
|
||||
return !myScalesList.isEmpty() && !myScalesList[0].isEmpty();
|
||||
}
|
||||
return true;
|
||||
}
|
||||
|
@ -564,7 +564,7 @@ int QgsComposerPictureWidget::addDirectoryToPreview( const QString &path )
|
||||
listItem->setIcon( icon );
|
||||
}
|
||||
|
||||
listItem->setText( QLatin1String( "" ) );
|
||||
listItem->setText( QString() );
|
||||
//store the absolute icon file path as user data
|
||||
listItem->setData( Qt::UserRole, fileIt->absoluteFilePath() );
|
||||
++counter;
|
||||
|
@ -94,7 +94,7 @@ QgsLayoutDesignerDialog::QgsLayoutDesignerDialog( QWidget *parent, Qt::WindowFla
|
||||
|
||||
setAttribute( Qt::WA_DeleteOnClose );
|
||||
#if QT_VERSION >= 0x050600
|
||||
setDockOptions( dockOptions() | QMainWindow::GroupedDragging ) ;
|
||||
setDockOptions( dockOptions() | QMainWindow::GroupedDragging );
|
||||
#endif
|
||||
|
||||
//create layout view
|
||||
|
@ -168,7 +168,7 @@ void usage( const QString &appName )
|
||||
// AppleEvent handler as well as by the main routine argv processing
|
||||
|
||||
// This behavior will cause QGIS to autoload a project
|
||||
static QString sProjectFileName = QLatin1String( "" );
|
||||
static QString sProjectFileName;
|
||||
|
||||
// This is the 'leftover' arguments collection
|
||||
static QStringList sFileList;
|
||||
@ -492,8 +492,8 @@ int main( int argc, char *argv[] )
|
||||
|
||||
// This behavior is used to load the app, snapshot the map,
|
||||
// save the image to disk and then exit
|
||||
QString mySnapshotFileName = QLatin1String( "" );
|
||||
QString configLocalStorageLocation = QLatin1String( "" );
|
||||
QString mySnapshotFileName;
|
||||
QString configLocalStorageLocation;
|
||||
QString profileName;
|
||||
int mySnapshotWidth = 800;
|
||||
int mySnapshotHeight = 600;
|
||||
@ -520,7 +520,7 @@ int main( int argc, char *argv[] )
|
||||
// there are no command line arguments. This gives a usable map
|
||||
// extent when qgis starts with no layers loaded. When layers are
|
||||
// loaded, we let the layers define the initial extent.
|
||||
QString myInitialExtent = QLatin1String( "" );
|
||||
QString myInitialExtent;
|
||||
if ( argc == 1 )
|
||||
myInitialExtent = QStringLiteral( "-1,-1,1,1" );
|
||||
|
||||
@ -998,7 +998,7 @@ int main( int argc, char *argv[] )
|
||||
if ( activeStyleName.isEmpty() ) // not set, using default style
|
||||
{
|
||||
//not set, check default
|
||||
activeStyleName = QApplication::style()->metaObject()->className() ;
|
||||
activeStyleName = QApplication::style()->metaObject()->className();
|
||||
}
|
||||
if ( activeStyleName.contains( QStringLiteral( "adwaita" ), Qt::CaseInsensitive ) )
|
||||
{
|
||||
@ -1238,7 +1238,7 @@ int main( int argc, char *argv[] )
|
||||
/////////////////////////////////`////////////////////////////////////
|
||||
// Take a snapshot of the map view then exit if snapshot mode requested
|
||||
/////////////////////////////////////////////////////////////////////
|
||||
if ( mySnapshotFileName != QLatin1String( "" ) )
|
||||
if ( !mySnapshotFileName.isEmpty() )
|
||||
{
|
||||
/*You must have at least one paintEvent() delivered for the window to be
|
||||
rendered properly.
|
||||
|
@ -622,20 +622,19 @@ void QgsPluginManager::showPluginDetails( QStandardItem *item )
|
||||
return;
|
||||
}
|
||||
|
||||
QString html = QLatin1String( "" );
|
||||
html += "<style>"
|
||||
" body, table {"
|
||||
" padding:0px;"
|
||||
" margin:0px;"
|
||||
" font-family:verdana;"
|
||||
" font-size: 10pt;"
|
||||
" }"
|
||||
" div#votes {"
|
||||
" width:360px;"
|
||||
" margin-left:98px;"
|
||||
" padding-top:3px;"
|
||||
" }"
|
||||
"</style>";
|
||||
QString html = "<style>"
|
||||
" body, table {"
|
||||
" padding:0px;"
|
||||
" margin:0px;"
|
||||
" font-family:verdana;"
|
||||
" font-size: 10pt;"
|
||||
" }"
|
||||
" div#votes {"
|
||||
" width:360px;"
|
||||
" margin-left:98px;"
|
||||
" padding-top:3px;"
|
||||
" }"
|
||||
"</style>";
|
||||
|
||||
if ( !metadata->value( QStringLiteral( "plugin_id" ) ).isEmpty() )
|
||||
{
|
||||
@ -1135,7 +1134,7 @@ void QgsPluginManager::setCurrentTab( int idx )
|
||||
mModelProxy->setAcceptedStatuses( acceptedStatuses );
|
||||
|
||||
// load tab description HTML to the detail browser
|
||||
QString tabInfoHTML = QLatin1String( "" );
|
||||
QString tabInfoHTML;
|
||||
QMap<QString, QString>::const_iterator it = mTabDescriptions.constFind( tabTitle );
|
||||
if ( it != mTabDescriptions.constEnd() )
|
||||
{
|
||||
|
@ -622,7 +622,6 @@ QgisApp *QgisApp::sInstance = nullptr;
|
||||
QgisApp::QgisApp( QSplashScreen *splash, bool restorePlugins, bool skipVersionCheck, const QString &rootProfileLocation, const QString &activeProfile, QWidget *parent, Qt::WindowFlags fl )
|
||||
: QMainWindow( parent, fl )
|
||||
, mSplash( splash )
|
||||
, mShowProjectionTab( false )
|
||||
{
|
||||
if ( sInstance )
|
||||
{
|
||||
@ -644,8 +643,6 @@ QgisApp::QgisApp( QSplashScreen *splash, bool restorePlugins, bool skipVersionCh
|
||||
connect( mUserProfileManager, &QgsUserProfileManager::profilesChanged, this, &QgisApp::refreshProfileMenu );
|
||||
endProfile();
|
||||
|
||||
namSetup();
|
||||
|
||||
// load GUI: actions, menus, toolbars
|
||||
profiler->beginGroup( QStringLiteral( "qgisapp" ) );
|
||||
profiler->beginGroup( QStringLiteral( "startup" ) );
|
||||
@ -654,7 +651,7 @@ QgisApp::QgisApp( QSplashScreen *splash, bool restorePlugins, bool skipVersionCh
|
||||
endProfile();
|
||||
|
||||
#if QT_VERSION >= 0x050600
|
||||
setDockOptions( dockOptions() | QMainWindow::GroupedDragging ) ;
|
||||
setDockOptions( dockOptions() | QMainWindow::GroupedDragging );
|
||||
#endif
|
||||
|
||||
//////////
|
||||
@ -670,6 +667,10 @@ QgisApp::QgisApp( QSplashScreen *splash, bool restorePlugins, bool skipVersionCh
|
||||
}
|
||||
endProfile();
|
||||
|
||||
mTray = new QSystemTrayIcon();
|
||||
mTray->setIcon( QIcon( QgsApplication::appIconPath() ) );
|
||||
mTray->hide();
|
||||
|
||||
startProfile( QStringLiteral( "Initializing authentication" ) );
|
||||
mSplash->showMessage( tr( "Initializing authentication" ), Qt::AlignHCenter | Qt::AlignBottom );
|
||||
qApp->processEvents();
|
||||
@ -680,6 +681,9 @@ QgisApp::QgisApp( QSplashScreen *splash, bool restorePlugins, bool skipVersionCh
|
||||
}
|
||||
endProfile();
|
||||
|
||||
// Setup QgsNetworkAccessManager (this needs to happen after authentication, for proxy settings)
|
||||
namSetup();
|
||||
|
||||
// Create the themes folder for the user
|
||||
startProfile( QStringLiteral( "Creating theme folder" ) );
|
||||
QgsApplication::createThemeFolder();
|
||||
@ -1170,11 +1174,6 @@ QgisApp::QgisApp( QSplashScreen *splash, bool restorePlugins, bool skipVersionCh
|
||||
grabGesture( Qt::TapAndHoldGesture );
|
||||
}
|
||||
|
||||
|
||||
mTray = new QSystemTrayIcon();
|
||||
mTray->setIcon( QIcon( QgsApplication::appIconPath() ) );
|
||||
mTray->hide();
|
||||
|
||||
connect( QgsApplication::taskManager(), &QgsTaskManager::statusChanged, this, &QgisApp::onTaskCompleteShowNotify );
|
||||
|
||||
#ifdef Q_OS_WIN
|
||||
@ -1238,13 +1237,6 @@ QgisApp::QgisApp()
|
||||
#ifdef Q_OS_MAC
|
||||
, mWindowMenu( nullptr )
|
||||
#endif
|
||||
, mShowProjectionTab( false )
|
||||
, mMapTipsVisible( false )
|
||||
, mFullScreenMode( false )
|
||||
, mPrevScreenModeMaximized( false )
|
||||
, mSaveRollbackInProgress( false )
|
||||
, mTrustedMacros( false )
|
||||
, mProjOpen( 0 )
|
||||
{
|
||||
sInstance = this;
|
||||
setupUi( this );
|
||||
@ -2456,7 +2448,7 @@ void QgisApp::createToolBars()
|
||||
defAnnotationAction = mActionSvgAnnotation;
|
||||
break;
|
||||
case 4:
|
||||
defAnnotationAction = mActionAnnotation;
|
||||
defAnnotationAction = mActionAnnotation;
|
||||
break;
|
||||
|
||||
}
|
||||
@ -5919,7 +5911,7 @@ void QgisApp::saveMapAsPdf()
|
||||
//overloaded version of the above function
|
||||
void QgisApp::saveMapAsImage( const QString &imageFileNameQString, QPixmap *theQPixmap )
|
||||
{
|
||||
if ( imageFileNameQString == QLatin1String( "" ) )
|
||||
if ( imageFileNameQString.isEmpty() )
|
||||
{
|
||||
//no fileName chosen
|
||||
return;
|
||||
@ -9254,7 +9246,7 @@ void QgisApp::legendLayerZoomNative()
|
||||
if ( !currentLayer )
|
||||
return;
|
||||
|
||||
QgsRasterLayer *layer = qobject_cast<QgsRasterLayer *>( currentLayer );
|
||||
QgsRasterLayer *layer = qobject_cast<QgsRasterLayer *>( currentLayer );
|
||||
if ( layer )
|
||||
{
|
||||
QgsDebugMsg( "Raster units per pixel : " + QString::number( layer->rasterUnitsPerPixelX() ) );
|
||||
@ -9286,7 +9278,7 @@ void QgisApp::legendLayerStretchUsingCurrentExtent()
|
||||
if ( !currentLayer )
|
||||
return;
|
||||
|
||||
QgsRasterLayer *layer = qobject_cast<QgsRasterLayer *>( currentLayer );
|
||||
QgsRasterLayer *layer = qobject_cast<QgsRasterLayer *>( currentLayer );
|
||||
if ( layer )
|
||||
{
|
||||
QgsRectangle myRectangle;
|
||||
@ -10105,7 +10097,7 @@ void QgisApp::setExtent( const QgsRectangle &rect )
|
||||
*/
|
||||
bool QgisApp::saveDirty()
|
||||
{
|
||||
QString whyDirty = QLatin1String( "" );
|
||||
QString whyDirty;
|
||||
bool hasUnsavedEdits = false;
|
||||
// extra check to see if there are any vector layers with unsaved provider edits
|
||||
// to ensure user has opportunity to save any editing
|
||||
@ -12087,7 +12079,7 @@ void QgisApp::oldProjectVersionWarning( const QString &oldVersion )
|
||||
" When saving this project file, QGIS will update it to the latest version, "
|
||||
"possibly rendering it useless for older versions of QGIS." );
|
||||
|
||||
QString title = tr( "Project file is older" );
|
||||
QString title = tr( "Project file is older" );
|
||||
|
||||
messageBar()->pushMessage( title, smalltext );
|
||||
}
|
||||
|
@ -1805,63 +1805,6 @@ class APP_EXPORT QgisApp : public QMainWindow, private Ui::MainWindow
|
||||
public:
|
||||
|
||||
Tools()
|
||||
: mZoomIn( nullptr )
|
||||
, mZoomOut( nullptr )
|
||||
, mPan( nullptr )
|
||||
, mIdentify( nullptr )
|
||||
, mFeatureAction( nullptr )
|
||||
, mMeasureDist( nullptr )
|
||||
, mMeasureArea( nullptr )
|
||||
, mMeasureAngle( nullptr )
|
||||
, mAddFeature( nullptr )
|
||||
, mCircularStringCurvePoint( nullptr )
|
||||
, mCircularStringRadius( nullptr )
|
||||
, mCircle2Points( nullptr )
|
||||
, mCircle3Points( nullptr )
|
||||
, mCircleCenterPoint( nullptr )
|
||||
, mEllipseCenter2Points( nullptr )
|
||||
, mEllipseCenterPoint( nullptr )
|
||||
, mEllipseExtent( nullptr )
|
||||
, mEllipseFoci( nullptr )
|
||||
, mRectangleCenterPoint( nullptr )
|
||||
, mRectangleExtent( nullptr )
|
||||
, mRectangle3Points( nullptr )
|
||||
, mSquareCenter( nullptr )
|
||||
, mRegularPolygon2Points( nullptr )
|
||||
, mRegularPolygonCenterPoint( nullptr )
|
||||
, mMoveFeature( nullptr )
|
||||
, mOffsetCurve( nullptr )
|
||||
, mReshapeFeatures( nullptr )
|
||||
, mSplitFeatures( nullptr )
|
||||
, mSplitParts( nullptr )
|
||||
, mSelect( nullptr )
|
||||
, mSelectFeatures( nullptr )
|
||||
, mSelectPolygon( nullptr )
|
||||
, mSelectFreehand( nullptr )
|
||||
, mSelectRadius( nullptr )
|
||||
, mVertexAdd( nullptr )
|
||||
, mVertexMove( nullptr )
|
||||
, mVertexDelete( nullptr )
|
||||
, mAddRing( nullptr )
|
||||
, mFillRing( nullptr )
|
||||
, mAddPart( nullptr )
|
||||
, mSimplifyFeature( nullptr )
|
||||
, mDeleteRing( nullptr )
|
||||
, mDeletePart( nullptr )
|
||||
, mNodeTool( nullptr )
|
||||
, mRotatePointSymbolsTool( nullptr )
|
||||
, mOffsetPointSymbolTool( nullptr )
|
||||
, mAnnotation( nullptr )
|
||||
, mFormAnnotation( nullptr )
|
||||
, mHtmlAnnotation( nullptr )
|
||||
, mSvgAnnotation( nullptr )
|
||||
, mTextAnnotation( nullptr )
|
||||
, mPinLabels( nullptr )
|
||||
, mShowHideLabels( nullptr )
|
||||
, mMoveLabel( nullptr )
|
||||
, mRotateFeature( nullptr )
|
||||
, mRotateLabel( nullptr )
|
||||
, mChangeLabelProperties( nullptr )
|
||||
{}
|
||||
|
||||
QgsMapTool *mZoomIn = nullptr;
|
||||
@ -2001,7 +1944,7 @@ class APP_EXPORT QgisApp : public QMainWindow, private Ui::MainWindow
|
||||
//! QGIS-internal vector feature clipboard
|
||||
QgsClipboard *mInternalClipboard = nullptr;
|
||||
//! Flag to indicate how the project properties dialog was summoned
|
||||
bool mShowProjectionTab;
|
||||
bool mShowProjectionTab = false;
|
||||
|
||||
/** String containing supporting vector file formats
|
||||
Suitable for a QFileDialog file filter. Build in ctor.
|
||||
@ -2023,16 +1966,16 @@ class APP_EXPORT QgisApp : public QMainWindow, private Ui::MainWindow
|
||||
QgsMapTip *mpMaptip = nullptr;
|
||||
|
||||
//! Flag to indicate if maptips are on or off
|
||||
bool mMapTipsVisible;
|
||||
bool mMapTipsVisible = false;
|
||||
|
||||
//! Flag to indicate whether we are in fullscreen mode or not
|
||||
bool mFullScreenMode;
|
||||
bool mFullScreenMode = false;
|
||||
|
||||
//! Flag to indicate that the previous screen mode was 'maximised'
|
||||
bool mPrevScreenModeMaximized;
|
||||
bool mPrevScreenModeMaximized = false;
|
||||
|
||||
//! Flag to indicate an edits save/rollback for active layer is in progress
|
||||
bool mSaveRollbackInProgress;
|
||||
bool mSaveRollbackInProgress = false;
|
||||
|
||||
QgsPythonUtils *mPythonUtils = nullptr;
|
||||
|
||||
@ -2081,7 +2024,7 @@ class APP_EXPORT QgisApp : public QMainWindow, private Ui::MainWindow
|
||||
bool cmpByText( QAction *a, QAction *b );
|
||||
|
||||
//! the user has trusted the project macros
|
||||
bool mTrustedMacros;
|
||||
bool mTrustedMacros = false;
|
||||
|
||||
//! a bar to display warnings in a non-blocker manner
|
||||
QgsMessageBar *mInfoBar = nullptr;
|
||||
@ -2115,7 +2058,7 @@ class APP_EXPORT QgisApp : public QMainWindow, private Ui::MainWindow
|
||||
|
||||
QHash< QgsComposition *, QgsMapLayerAction * > mAtlasFeatureActions;
|
||||
|
||||
int mProjOpen;
|
||||
int mProjOpen = 0;
|
||||
|
||||
bool gestureEvent( QGestureEvent *event );
|
||||
void tapAndHoldTriggered( QTapAndHoldGesture *gesture );
|
||||
|
@ -186,7 +186,7 @@ void QgsAbout::init()
|
||||
#endif
|
||||
if ( translatorFile.open( QIODevice::ReadOnly ) )
|
||||
{
|
||||
QString translatorHTML = QLatin1String( "" );
|
||||
QString translatorHTML;
|
||||
QTextStream translatorStream( &translatorFile );
|
||||
// Always use UTF-8
|
||||
translatorStream.setCodec( "UTF-8" );
|
||||
|
@ -483,7 +483,7 @@ bool QgsProjectBookmarksTableModel::removeRows( int row, int count, const QModel
|
||||
|
||||
for ( int newRow = row ; newRow < rowCount() - count ; newRow++ )
|
||||
{
|
||||
for ( int column = 0 ; column < columnCount() ; column++ )
|
||||
for ( int column = 0; column < columnCount() ; column++ )
|
||||
{
|
||||
setData( index( newRow, column ), data( index( newRow + count, column ) ) );
|
||||
}
|
||||
|
@ -41,7 +41,6 @@
|
||||
|
||||
QgsClipboard::QgsClipboard()
|
||||
: QObject()
|
||||
, mUseSystemClipboard( false )
|
||||
{
|
||||
connect( QApplication::clipboard(), &QClipboard::dataChanged, this, &QgsClipboard::systemClipboardChanged );
|
||||
}
|
||||
|
@ -177,7 +177,7 @@ class APP_EXPORT QgsClipboard : public QObject
|
||||
QPointer<QgsVectorLayer> mSrcLayer;
|
||||
|
||||
//! True when the data from the system clipboard should be read
|
||||
bool mUseSystemClipboard;
|
||||
bool mUseSystemClipboard = false;
|
||||
|
||||
friend class TestQgisAppClipboard;
|
||||
|
||||
|
@ -636,8 +636,7 @@ QgsCustomization *QgsCustomization::instance()
|
||||
}
|
||||
|
||||
QgsCustomization::QgsCustomization()
|
||||
: mEnabled( false )
|
||||
, mStatusPath( QStringLiteral( "/Customization/status" ) )
|
||||
: mStatusPath( QStringLiteral( "/Customization/status" ) )
|
||||
{
|
||||
|
||||
QSettings settings;
|
||||
@ -948,7 +947,7 @@ void QgsCustomization::loadDefault()
|
||||
return;
|
||||
|
||||
// Look for default
|
||||
QString path = QgsApplication::pkgDataPath() + "/resources/customization.ini";
|
||||
QString path = QgsApplication::pkgDataPath() + "/resources/customization.ini";
|
||||
if ( ! QFile::exists( path ) )
|
||||
{
|
||||
QgsDebugMsg( "Default customization not found in " + path );
|
||||
|
@ -151,7 +151,7 @@ class APP_EXPORT QgsCustomization : public QObject
|
||||
~QgsCustomization() = default;
|
||||
QgsCustomizationDialog *pDialog = nullptr;
|
||||
|
||||
bool mEnabled;
|
||||
bool mEnabled = false;
|
||||
QSettings *mSettings = nullptr;
|
||||
QString mStatusPath;
|
||||
|
||||
|
@ -243,7 +243,7 @@ bool QgsCustomProjectionDialog::saveCrs( QgsCoordinateReferenceSystem myCRS, con
|
||||
QString mySql;
|
||||
int return_id;
|
||||
QString myProjectionAcronym = myCRS.projectionAcronym();
|
||||
QString myEllipsoidAcronym = myCRS.ellipsoidAcronym();
|
||||
QString myEllipsoidAcronym = myCRS.ellipsoidAcronym();
|
||||
QgsDebugMsg( QString( "Saving a CRS:%1, %2, %3" ).arg( myName, myCRS.toProj4() ).arg( newEntry ) );
|
||||
if ( newEntry )
|
||||
{
|
||||
@ -308,7 +308,7 @@ bool QgsCustomProjectionDialog::saveCrs( QgsCoordinateReferenceSystem myCRS, con
|
||||
void QgsCustomProjectionDialog::on_pbnAdd_clicked()
|
||||
{
|
||||
QString name = tr( "new CRS" );
|
||||
QString id = QLatin1String( "" );
|
||||
QString id;
|
||||
QgsCoordinateReferenceSystem parameters;
|
||||
|
||||
QTreeWidgetItem *newItem = new QTreeWidgetItem( leNameList, QStringList() );
|
||||
@ -331,7 +331,7 @@ void QgsCustomProjectionDialog::on_pbnRemove_clicked()
|
||||
}
|
||||
QTreeWidgetItem *item = leNameList->takeTopLevelItem( i );
|
||||
delete item;
|
||||
if ( customCRSids[i] != QLatin1String( "" ) )
|
||||
if ( !customCRSids[i].isEmpty() )
|
||||
{
|
||||
deletedCRSs.push_back( customCRSids[i] );
|
||||
}
|
||||
@ -361,8 +361,8 @@ void QgsCustomProjectionDialog::on_leNameList_currentItemChanged( QTreeWidgetIte
|
||||
else
|
||||
{
|
||||
//Can happen that current is null, for example if we just deleted the last element
|
||||
leName->setText( QLatin1String( "" ) );
|
||||
teParameters->setPlainText( QLatin1String( "" ) );
|
||||
leName->clear();
|
||||
teParameters->clear();
|
||||
return;
|
||||
}
|
||||
}
|
||||
@ -415,7 +415,7 @@ void QgsCustomProjectionDialog::on_buttonBox_accepted()
|
||||
{
|
||||
CRS.createFromProj4( customCRSparameters[i] );
|
||||
//Test if we just added this CRS (if it has no existing ID)
|
||||
if ( customCRSids[i] == QLatin1String( "" ) )
|
||||
if ( !customCRSids[i].isEmpty() )
|
||||
{
|
||||
save_success &= saveCrs( CRS, customCRSnames[i], QLatin1String( "" ), true );
|
||||
}
|
||||
@ -462,8 +462,8 @@ void QgsCustomProjectionDialog::on_pbnCalculate_clicked()
|
||||
{
|
||||
QMessageBox::information( this, tr( "QGIS Custom Projection" ),
|
||||
tr( "This proj4 projection definition is not valid." ) );
|
||||
projectedX->setText( QLatin1String( "" ) );
|
||||
projectedY->setText( QLatin1String( "" ) );
|
||||
projectedX->clear();
|
||||
projectedY->clear();
|
||||
pj_free( myProj );
|
||||
pj_ctx_free( pContext );
|
||||
return;
|
||||
@ -478,8 +478,8 @@ void QgsCustomProjectionDialog::on_pbnCalculate_clicked()
|
||||
{
|
||||
QMessageBox::information( this, tr( "QGIS Custom Projection" ),
|
||||
tr( "Northing and Easthing must be in decimal form." ) );
|
||||
projectedX->setText( QLatin1String( "" ) );
|
||||
projectedY->setText( QLatin1String( "" ) );
|
||||
projectedX->clear();
|
||||
projectedY->clear();
|
||||
pj_free( myProj );
|
||||
pj_ctx_free( pContext );
|
||||
return;
|
||||
@ -491,8 +491,8 @@ void QgsCustomProjectionDialog::on_pbnCalculate_clicked()
|
||||
{
|
||||
QMessageBox::information( this, tr( "QGIS Custom Projection" ),
|
||||
tr( "Internal Error (source projection invalid?)" ) );
|
||||
projectedX->setText( QLatin1String( "" ) );
|
||||
projectedY->setText( QLatin1String( "" ) );
|
||||
projectedX->clear();
|
||||
projectedY->clear();
|
||||
pj_free( wgs84Proj );
|
||||
pj_ctx_free( pContext );
|
||||
return;
|
||||
|
@ -44,8 +44,6 @@ email : tim@linfiniti.com
|
||||
|
||||
QgsDecorationCopyright::QgsDecorationCopyright( QObject *parent )
|
||||
: QgsDecorationItem( parent )
|
||||
, mMarginHorizontal( 0 )
|
||||
, mMarginVertical( 0 )
|
||||
{
|
||||
mPlacement = BottomRight;
|
||||
mMarginUnit = QgsUnitTypes::RenderMillimeters;
|
||||
|
@ -59,8 +59,8 @@ class APP_EXPORT QgsDecorationCopyright : public QgsDecorationItem
|
||||
QColor mColor;
|
||||
|
||||
//! enable or disable use of position percentage for placement
|
||||
int mMarginHorizontal;
|
||||
int mMarginVertical;
|
||||
int mMarginHorizontal = 0;
|
||||
int mMarginVertical = 0;
|
||||
|
||||
friend class QgsDecorationCopyrightDialog;
|
||||
};
|
||||
|
@ -110,8 +110,8 @@ void QgsDecorationGrid::projectRead()
|
||||
mGridAnnotationPosition = InsideMapFrame; // don't allow outside frame, doesn't make sense
|
||||
mGridAnnotationDirection = static_cast< GridAnnotationDirection >( QgsProject::instance()->readNumEntry( mNameConfig,
|
||||
QStringLiteral( "/AnnotationDirection" ), 0 ) );
|
||||
QString fontStr = QgsProject::instance()->readEntry( mNameConfig, QStringLiteral( "/AnnotationFont" ), QLatin1String( "" ) );
|
||||
if ( fontStr != QLatin1String( "" ) )
|
||||
QString fontStr = QgsProject::instance()->readEntry( mNameConfig, QStringLiteral( "/AnnotationFont" ), QString() );
|
||||
if ( !fontStr.isEmpty() )
|
||||
{
|
||||
mGridAnnotationFont.fromString( fontStr );
|
||||
}
|
||||
@ -134,7 +134,7 @@ void QgsDecorationGrid::projectRead()
|
||||
if ( mLineSymbol )
|
||||
setLineSymbol( nullptr );
|
||||
xml = QgsProject::instance()->readEntry( mNameConfig, QStringLiteral( "/LineSymbol" ) );
|
||||
if ( xml != QLatin1String( "" ) )
|
||||
if ( !xml.isEmpty() )
|
||||
{
|
||||
doc.setContent( xml );
|
||||
elem = doc.documentElement();
|
||||
@ -146,7 +146,7 @@ void QgsDecorationGrid::projectRead()
|
||||
if ( mMarkerSymbol )
|
||||
setMarkerSymbol( nullptr );
|
||||
xml = QgsProject::instance()->readEntry( mNameConfig, QStringLiteral( "/MarkerSymbol" ) );
|
||||
if ( xml != QLatin1String( "" ) )
|
||||
if ( !xml.isEmpty() )
|
||||
{
|
||||
doc.setContent( xml );
|
||||
elem = doc.documentElement();
|
||||
@ -785,7 +785,7 @@ bool QgsDecorationGrid::getIntervalFromExtent( double *values, bool useXAxis )
|
||||
if ( !qgsDoubleNear( interval, 0.0 ) )
|
||||
{
|
||||
double interval2 = 0;
|
||||
int factor = std::pow( 10, std::floor( std::log10( interval ) ) );
|
||||
int factor = std::pow( 10, std::floor( std::log10( interval ) ) );
|
||||
if ( factor != 0 )
|
||||
{
|
||||
interval2 = std::round( interval / factor ) * factor;
|
||||
|
@ -46,9 +46,6 @@
|
||||
|
||||
QgsDecorationItem::QgsDecorationItem( QObject *parent )
|
||||
: QObject( parent )
|
||||
, mEnabled( false )
|
||||
, mPlacement( TopLeft )
|
||||
, mMarginUnit( QgsUnitTypes::RenderMillimeters )
|
||||
{
|
||||
}
|
||||
|
||||
|
@ -81,12 +81,12 @@ class APP_EXPORT QgsDecorationItem : public QObject, public QgsMapDecoration
|
||||
void setName( const char *name );
|
||||
|
||||
//! True if decoration item has to be displayed
|
||||
bool mEnabled;
|
||||
bool mEnabled = false;
|
||||
|
||||
//! Placement of the decoration
|
||||
Placement mPlacement;
|
||||
Placement mPlacement = TopLeft;
|
||||
//! Units used for the decoration placement margin
|
||||
QgsUnitTypes::RenderUnit mMarginUnit;
|
||||
QgsUnitTypes::RenderUnit mMarginUnit = QgsUnitTypes::RenderMillimeters;
|
||||
|
||||
QString mName;
|
||||
QString mNameConfig;
|
||||
|
@ -57,10 +57,6 @@ const double QgsDecorationNorthArrow::TOL = 1e-8;
|
||||
*/
|
||||
QgsDecorationNorthArrow::QgsDecorationNorthArrow( QObject *parent )
|
||||
: QgsDecorationItem( parent )
|
||||
, mRotationInt( 0 )
|
||||
, mAutomatic( true )
|
||||
, mMarginHorizontal( 0 )
|
||||
, mMarginVertical( 0 )
|
||||
{
|
||||
mPlacement = BottomLeft;
|
||||
mMarginUnit = QgsUnitTypes::RenderMillimeters;
|
||||
|
@ -58,13 +58,13 @@ class APP_EXPORT QgsDecorationNorthArrow: public QgsDecorationItem
|
||||
QColor mOutlineColor;
|
||||
|
||||
// The amount of rotation for the north arrow
|
||||
int mRotationInt;
|
||||
int mRotationInt = 0;
|
||||
|
||||
//! enable or disable the automatic setting of the arrow direction
|
||||
bool mAutomatic;
|
||||
bool mAutomatic = true;
|
||||
//! margin values
|
||||
int mMarginHorizontal;
|
||||
int mMarginVertical;
|
||||
int mMarginHorizontal = 0;
|
||||
int mMarginVertical = 0;
|
||||
|
||||
friend class QgsDecorationNorthArrowDialog;
|
||||
};
|
||||
|
@ -53,8 +53,6 @@ email : sbr00pwb@users.sourceforge.net
|
||||
|
||||
QgsDecorationScaleBar::QgsDecorationScaleBar( QObject *parent )
|
||||
: QgsDecorationItem( parent )
|
||||
, mMarginHorizontal( 0 )
|
||||
, mMarginVertical( 0 )
|
||||
{
|
||||
mPlacement = TopLeft;
|
||||
mMarginUnit = QgsUnitTypes::RenderMillimeters;
|
||||
|
@ -63,8 +63,8 @@ class APP_EXPORT QgsDecorationScaleBar: public QgsDecorationItem
|
||||
QColor mOutlineColor;
|
||||
|
||||
//! Margin percentage values
|
||||
int mMarginHorizontal;
|
||||
int mMarginVertical;
|
||||
int mMarginHorizontal = 0;
|
||||
int mMarginVertical = 0;
|
||||
|
||||
friend class QgsDecorationScaleBarDialog;
|
||||
};
|
||||
|
@ -25,7 +25,6 @@
|
||||
QgsDisplayAngle::QgsDisplayAngle( QgsMapToolMeasureAngle *tool, Qt::WindowFlags f )
|
||||
: QDialog( tool->canvas()->topLevelWidget(), f )
|
||||
, mTool( tool )
|
||||
, mValue( 0.0 )
|
||||
{
|
||||
setupUi( this );
|
||||
}
|
||||
|
@ -38,7 +38,7 @@ class APP_EXPORT QgsDisplayAngle: public QDialog, private Ui::QgsDisplayAngleBas
|
||||
QgsMapToolMeasureAngle *mTool = nullptr;
|
||||
|
||||
//! The value we're showing
|
||||
double mValue;
|
||||
double mValue = 0.0;
|
||||
|
||||
//! Updates UI according to user settings.
|
||||
void updateUi();
|
||||
|
@ -399,9 +399,9 @@ void QgsFieldsProperties::loadRelations()
|
||||
|
||||
const QgsEditFormConfig editFormConfig = mLayer->editFormConfig();
|
||||
|
||||
const QVariant nmrelcfg = editFormConfig.widgetConfig( relation.id() ).value( QStringLiteral( "nm-rel" ) );
|
||||
const QVariant nmrelcfg = editFormConfig.widgetConfig( relation.id() ).value( QStringLiteral( "nm-rel" ) );
|
||||
|
||||
int idx = nmCombo->findData( nmrelcfg.toString() );
|
||||
int idx = nmCombo->findData( nmrelcfg.toString() );
|
||||
|
||||
if ( idx != -1 )
|
||||
nmCombo->setCurrentIndex( idx );
|
||||
@ -1077,17 +1077,12 @@ void QgsFieldsProperties::apply()
|
||||
*/
|
||||
|
||||
QgsFieldsProperties::FieldConfig::FieldConfig()
|
||||
: mEditable( true )
|
||||
, mEditableEnabled( true )
|
||||
, mLabelOnTop( false )
|
||||
, mConstraints( 0 )
|
||||
: mConstraints( 0 )
|
||||
, mConstraintDescription( QString() )
|
||||
|
||||
{
|
||||
}
|
||||
|
||||
QgsFieldsProperties::FieldConfig::FieldConfig( QgsVectorLayer *layer, int idx )
|
||||
|
||||
{
|
||||
mEditable = !layer->editFormConfig().readOnly( idx );
|
||||
mEditableEnabled = layer->fields().fieldOrigin( idx ) != QgsFields::OriginJoin
|
||||
@ -1334,7 +1329,7 @@ void DesignerTree::onItemDoubleClicked( QTreeWidgetItem *item, int column )
|
||||
{
|
||||
QDialog dlg;
|
||||
dlg.setWindowTitle( tr( "Configure Container" ) );
|
||||
QFormLayout *layout = new QFormLayout() ;
|
||||
QFormLayout *layout = new QFormLayout();
|
||||
dlg.setLayout( layout );
|
||||
layout->addRow( baseWidget );
|
||||
|
||||
@ -1393,7 +1388,7 @@ void DesignerTree::onItemDoubleClicked( QTreeWidgetItem *item, int column )
|
||||
{
|
||||
QDialog dlg;
|
||||
dlg.setWindowTitle( tr( "Configure Relation Editor" ) );
|
||||
QFormLayout *layout = new QFormLayout() ;
|
||||
QFormLayout *layout = new QFormLayout();
|
||||
dlg.setLayout( layout );
|
||||
layout->addWidget( baseWidget );
|
||||
|
||||
|
@ -46,11 +46,9 @@ class APP_EXPORT QgsFieldsProperties : public QWidget, private Ui_QgsFieldsPrope
|
||||
struct RelationEditorConfiguration
|
||||
{
|
||||
RelationEditorConfiguration()
|
||||
: showLinkButton( true )
|
||||
, showUnlinkButton( true )
|
||||
{}
|
||||
bool showLinkButton;
|
||||
bool showUnlinkButton;
|
||||
bool showLinkButton = true;
|
||||
bool showUnlinkButton = true;
|
||||
};
|
||||
|
||||
class DesignerTreeItemData
|
||||
@ -64,18 +62,11 @@ class APP_EXPORT QgsFieldsProperties : public QWidget, private Ui_QgsFieldsPrope
|
||||
};
|
||||
|
||||
DesignerTreeItemData()
|
||||
: mType( Field )
|
||||
, mColumnCount( 1 )
|
||||
, mShowAsGroupBox( false )
|
||||
, mShowLabel( true )
|
||||
{}
|
||||
|
||||
DesignerTreeItemData( Type type, const QString &name )
|
||||
: mType( type )
|
||||
, mName( name )
|
||||
, mColumnCount( 1 )
|
||||
, mShowAsGroupBox( false )
|
||||
, mShowLabel( true )
|
||||
{}
|
||||
|
||||
QString name() const { return mName; }
|
||||
@ -102,11 +93,11 @@ class APP_EXPORT QgsFieldsProperties : public QWidget, private Ui_QgsFieldsPrope
|
||||
void setRelationEditorConfiguration( RelationEditorConfiguration relationEditorConfiguration );
|
||||
|
||||
private:
|
||||
Type mType;
|
||||
Type mType = Field;
|
||||
QString mName;
|
||||
int mColumnCount;
|
||||
bool mShowAsGroupBox;
|
||||
bool mShowLabel;
|
||||
int mColumnCount = 1;
|
||||
bool mShowAsGroupBox = false;
|
||||
bool mShowLabel = true;
|
||||
QgsOptionalExpression mVisibilityExpression;
|
||||
RelationEditorConfiguration mRelationEditorConfiguration;
|
||||
};
|
||||
@ -120,9 +111,9 @@ class APP_EXPORT QgsFieldsProperties : public QWidget, private Ui_QgsFieldsPrope
|
||||
FieldConfig();
|
||||
FieldConfig( QgsVectorLayer *layer, int idx );
|
||||
|
||||
bool mEditable;
|
||||
bool mEditableEnabled;
|
||||
bool mLabelOnTop;
|
||||
bool mEditable = true;
|
||||
bool mEditableEnabled = true;
|
||||
bool mLabelOnTop = false;
|
||||
QgsFieldConstraints::Constraints mConstraints;
|
||||
QHash< QgsFieldConstraints::Constraint, QgsFieldConstraints::ConstraintStrength > mConstraintStrength;
|
||||
QString mConstraint;
|
||||
|
@ -135,7 +135,7 @@ void QgsLayerStylingWidget::setLayer( QgsMapLayer *layer )
|
||||
bool sameLayerType = false;
|
||||
if ( mCurrentLayer )
|
||||
{
|
||||
sameLayerType = mCurrentLayer->type() == layer->type();
|
||||
sameLayerType = mCurrentLayer->type() == layer->type();
|
||||
}
|
||||
|
||||
mCurrentLayer = layer;
|
||||
@ -183,7 +183,7 @@ void QgsLayerStylingWidget::setLayer( QgsMapLayer *layer )
|
||||
{
|
||||
if ( factory->supportsStyleDock() && factory->supportsLayer( layer ) )
|
||||
{
|
||||
QListWidgetItem *item = new QListWidgetItem( factory->icon(), QString() );
|
||||
QListWidgetItem *item = new QListWidgetItem( factory->icon(), QString() );
|
||||
item->setToolTip( factory->title() );
|
||||
mOptionsListWidget->addItem( item );
|
||||
int row = mOptionsListWidget->row( item );
|
||||
|
@ -23,7 +23,6 @@
|
||||
|
||||
QgsLoadStyleFromDBDialog::QgsLoadStyleFromDBDialog( QWidget *parent )
|
||||
: QDialog( parent )
|
||||
, mSectionLimit( 0 )
|
||||
{
|
||||
setupUi( this );
|
||||
setWindowTitle( QStringLiteral( "Database styles manager" ) );
|
||||
|
@ -26,7 +26,7 @@ class APP_EXPORT QgsLoadStyleFromDBDialog : public QDialog, private Ui::QgsLoadS
|
||||
{
|
||||
QString mSelectedStyleId;
|
||||
QString mSelectedStyleName;
|
||||
int mSectionLimit;
|
||||
int mSectionLimit = 0;
|
||||
Q_OBJECT
|
||||
public:
|
||||
explicit QgsLoadStyleFromDBDialog( QWidget *parent = nullptr );
|
||||
|
@ -380,7 +380,7 @@ void QgsMapSaveDialog::onAccepted()
|
||||
if ( mDialogType == Image )
|
||||
{
|
||||
QPair< QString, QString> fileNameAndFilter = QgsGuiUtils::getSaveAsImageName( QgisApp::instance(), tr( "Choose a file name to save the map image as" ) );
|
||||
if ( fileNameAndFilter.first != QLatin1String( "" ) )
|
||||
if ( !fileNameAndFilter.first.isEmpty() )
|
||||
{
|
||||
QgsMapSettings ms = QgsMapSettings();
|
||||
applyMapSettings( ms );
|
||||
|
@ -74,7 +74,7 @@ void QgsMapToolDeletePart::canvasPressEvent( QgsMapMouseEvent *e )
|
||||
|
||||
if ( mPressedFid != -1 )
|
||||
{
|
||||
mRubberBand = createRubberBand( vlayer->geometryType() ) ;
|
||||
mRubberBand = createRubberBand( vlayer->geometryType() );
|
||||
|
||||
mRubberBand->setToGeometry( geomPart, vlayer );
|
||||
mRubberBand->show();
|
||||
|
@ -85,7 +85,7 @@ void QgsMapToolDeleteRing::canvasPressEvent( QgsMapMouseEvent *e )
|
||||
{
|
||||
QgsFeature f;
|
||||
vlayer->getFeatures( QgsFeatureRequest().setFilterFid( mPressedFid ) ).nextFeature( f );
|
||||
mRubberBand = createRubberBand( vlayer->geometryType() ) ;
|
||||
mRubberBand = createRubberBand( vlayer->geometryType() );
|
||||
|
||||
mRubberBand->setToGeometry( ringGeom, vlayer );
|
||||
mRubberBand->show();
|
||||
|
@ -685,8 +685,7 @@ bool QgsMapToolLabel::diagramCanShowHide( QgsVectorLayer *vlayer, int &showCol )
|
||||
//
|
||||
|
||||
QgsMapToolLabel::LabelDetails::LabelDetails( const QgsLabelPosition &p )
|
||||
: valid( false )
|
||||
, pos( p )
|
||||
: pos( p )
|
||||
{
|
||||
layer = qobject_cast<QgsVectorLayer *>( QgsProject::instance()->mapLayer( pos.layerID ) );
|
||||
if ( layer && layer->labeling() )
|
||||
|
@ -74,9 +74,9 @@ class APP_EXPORT QgsMapToolLabel: public QgsMapTool
|
||||
|
||||
struct LabelDetails
|
||||
{
|
||||
LabelDetails(): valid( false ), layer( nullptr ) {}
|
||||
LabelDetails() {}
|
||||
explicit LabelDetails( const QgsLabelPosition &p );
|
||||
bool valid;
|
||||
bool valid = false;
|
||||
QgsLabelPosition pos;
|
||||
QgsVectorLayer *layer = nullptr;
|
||||
QgsPalLayerSettings settings;
|
||||
|
@ -228,15 +228,15 @@ QPointF QgsMapToolOffsetPointSymbol::calculateOffset( const QgsPointXY &startPoi
|
||||
switch ( unit )
|
||||
{
|
||||
case QgsUnitTypes::RenderMillimeters:
|
||||
factor = 25.4 / mCanvas->mapSettings().outputDpi() / mCanvas->mapSettings().mapUnitsPerPixel() ;
|
||||
factor = 25.4 / mCanvas->mapSettings().outputDpi() / mCanvas->mapSettings().mapUnitsPerPixel();
|
||||
break;
|
||||
|
||||
case QgsUnitTypes::RenderPoints:
|
||||
factor = 2.83464567 * 25.4 / mCanvas->mapSettings().outputDpi() / mCanvas->mapSettings().mapUnitsPerPixel() ;
|
||||
factor = 2.83464567 * 25.4 / mCanvas->mapSettings().outputDpi() / mCanvas->mapSettings().mapUnitsPerPixel();
|
||||
break;
|
||||
|
||||
case QgsUnitTypes::RenderInches:
|
||||
factor = 1.0 / mCanvas->mapSettings().outputDpi() / mCanvas->mapSettings().mapUnitsPerPixel() ;
|
||||
factor = 1.0 / mCanvas->mapSettings().outputDpi() / mCanvas->mapSettings().mapUnitsPerPixel();
|
||||
break;
|
||||
|
||||
case QgsUnitTypes::RenderPixels:
|
||||
|
@ -272,7 +272,7 @@ void QgsMapToolRotateFeature::canvasReleaseEvent( QgsMapMouseEvent *e )
|
||||
{
|
||||
mRotatedFeatures = vlayer->selectedFeatureIds();
|
||||
|
||||
mRubberBand = createRubberBand( vlayer->geometryType() ) ;
|
||||
mRubberBand = createRubberBand( vlayer->geometryType() );
|
||||
|
||||
QgsFeature feat;
|
||||
QgsFeatureIterator it = vlayer->getSelectedFeatures();
|
||||
@ -287,7 +287,7 @@ void QgsMapToolRotateFeature::canvasReleaseEvent( QgsMapMouseEvent *e )
|
||||
mRubberBand->show();
|
||||
|
||||
double XDistance = mInitialPos.x() - mAnchorPoint->x();
|
||||
double YDistance = mInitialPos.y() - mAnchorPoint->y() ;
|
||||
double YDistance = mInitialPos.y() - mAnchorPoint->y();
|
||||
mRotationOffset = std::atan2( YDistance, XDistance ) * ( 180 / M_PI );
|
||||
|
||||
createRotationWidget();
|
||||
|
@ -340,7 +340,7 @@ bool QgsNewSpatialiteLayerDialog::apply()
|
||||
{
|
||||
// Build up the sql statement for creating the table
|
||||
QString sql = QStringLiteral( "create table %1(" ).arg( quotedIdentifier( leLayerName->text() ) );
|
||||
QString delim = QLatin1String( "" );
|
||||
QString delim;
|
||||
|
||||
if ( checkBoxPrimaryKey->isChecked() )
|
||||
{
|
||||
|
@ -28,6 +28,7 @@
|
||||
#include "qgstolerance.h"
|
||||
#include "qgsscaleutils.h"
|
||||
#include "qgsnetworkaccessmanager.h"
|
||||
#include "qgsauthconfigselect.h"
|
||||
#include "qgsproject.h"
|
||||
#include "qgsdualview.h"
|
||||
#include "qgsrasterlayer.h"
|
||||
@ -307,6 +308,16 @@ QgsOptions::QgsOptions( QWidget *parent, Qt::WindowFlags fl, const QList<QgsOpti
|
||||
// WMS/WMS-C default max retry in case of tile request errors
|
||||
mDefaultTileMaxRetrySpinBox->setValue( mSettings->value( QStringLiteral( "/qgis/defaultTileMaxRetry" ), "3" ).toInt() );
|
||||
|
||||
// Proxy stored authentication configurations
|
||||
mProxyAuthConfigSelect = new QgsAuthConfigSelect( this, QStringLiteral( "proxy" ) );
|
||||
tabAuth->insertTab( 1, mProxyAuthConfigSelect, tr( "Configurations" ) );
|
||||
QString authcfg = mSettings->value( QStringLiteral( "proxy/authcfg" ) ).toString();
|
||||
mProxyAuthConfigSelect->setConfigId( authcfg );
|
||||
if ( !authcfg.isEmpty() )
|
||||
{
|
||||
tabAuth->setCurrentIndex( tabAuth->indexOf( mProxyAuthConfigSelect ) );
|
||||
}
|
||||
|
||||
//Web proxy settings
|
||||
grpProxy->setChecked( mSettings->value( QStringLiteral( "proxy/proxyEnabled" ), "0" ).toBool() );
|
||||
leProxyHost->setText( mSettings->value( QStringLiteral( "proxy/proxyHost" ), "" ).toString() );
|
||||
@ -1162,6 +1173,9 @@ void QgsOptions::saveOptions()
|
||||
// WMS/WMS-C default max retry in case of tile request errors
|
||||
mSettings->setValue( QStringLiteral( "/qgis/defaultTileMaxRetry" ), mDefaultTileMaxRetrySpinBox->value() );
|
||||
|
||||
// Proxy stored authentication configurations
|
||||
mSettings->setValue( QStringLiteral( "proxy/authcfg" ), mProxyAuthConfigSelect->configId( ) );
|
||||
|
||||
//Web proxy settings
|
||||
mSettings->setValue( QStringLiteral( "proxy/proxyEnabled" ), grpProxy->isChecked() );
|
||||
mSettings->setValue( QStringLiteral( "proxy/proxyHost" ), leProxyHost->text() );
|
||||
|
@ -32,6 +32,7 @@
|
||||
class QgsExpressionContext;
|
||||
class QgsOptionsPageWidget;
|
||||
class QgsLocatorOptionsWidget;
|
||||
class QgsAuthConfigSelect;
|
||||
|
||||
/**
|
||||
* \class QgsOptions
|
||||
@ -255,6 +256,7 @@ class APP_EXPORT QgsOptions : public QgsOptionsDialogBase, private Ui::QgsOption
|
||||
|
||||
QList< QgsOptionsPageWidget * > mAdditionalOptionWidgets;
|
||||
QgsLocatorOptionsWidget *mLocatorOptionsWidget = nullptr;
|
||||
QgsAuthConfigSelect *mProxyAuthConfigSelect = nullptr;
|
||||
|
||||
};
|
||||
|
||||
|
@ -106,7 +106,7 @@ void QgsPointMarkerItem::updateSize()
|
||||
{
|
||||
QgsRenderContext rc = renderContext( nullptr );
|
||||
mMarkerSymbol->startRender( rc, mFeature.fields() );
|
||||
QRectF bounds = mMarkerSymbol->bounds( mLocation, rc, mFeature );
|
||||
QRectF bounds = mMarkerSymbol->bounds( mLocation, rc, mFeature );
|
||||
mMarkerSymbol->stopRender( rc );
|
||||
QgsRectangle r( mMapCanvas->mapSettings().mapToPixel().toMapCoordinates( bounds.x(), bounds.y() ),
|
||||
mMapCanvas->mapSettings().mapToPixel().toMapCoordinates( bounds.x() + bounds.width() * 2, bounds.y() + bounds.height() * 2 ) );
|
||||
|
@ -28,7 +28,6 @@
|
||||
|
||||
QgsProjectLayerGroupDialog::QgsProjectLayerGroupDialog( QWidget *parent, const QString &projectFile, Qt::WindowFlags f )
|
||||
: QDialog( parent, f )
|
||||
, mShowEmbeddedContent( false )
|
||||
, mRootGroup( new QgsLayerTree )
|
||||
{
|
||||
setupUi( this );
|
||||
|
Some files were not shown because too many files have changed in this diff Show More
Loading…
x
Reference in New Issue
Block a user