Skip to content

Commit fe65063

Browse files
committedSep 15, 2016
Remove many deprecated methods
1 parent ccd9cc8 commit fe65063

File tree

95 files changed

+326
-1755
lines changed

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

95 files changed

+326
-1755
lines changed
 

‎doc/api_break.dox

Lines changed: 164 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -266,7 +266,8 @@ corresponding counterparts in QgsUnitTypes should be used instead.</li>
266266
\subsection qgis_api_break_3_0_QgisInterface QgisInterface
267267

268268
<ul>
269-
<li>fileMenu() has been removed, use projectMenu() instead.
269+
<li>fileMenu() has been removed, use projectMenu() instead.</li>
270+
<li>actionRemoveLayer was removed as it no longer exists.</li>
270271
</ul>
271272

272273
\subsection qgis_api_break_3_0_QgsAnnotation QgsAnnotation
@@ -283,6 +284,7 @@ corresponding counterparts in QgsUnitTypes should be used instead.</li>
283284
<li>The doAction() variant which takes a QgsFeature along has been removed. Use the expression context
284285
variant instead.</li>
285286
<li>expandAction() has been removed. Use QgsExpression::replaceExpressionText() instead.</li>
287+
<li>setPythonExecute() was removed. Initialize QgsPythonRunner instead.</li>
286288
</ul>
287289

288290
\subsection qgis_api_break_3_0_QgsAdvancedDigitizingDockWidget QgsAdvancedDigitizingDockWidget
@@ -306,6 +308,22 @@ and setSortKeyAttributeName() instead.</li>
306308
<li>currentFeature() was removed. Use feature() instead.</li>
307309
</ul>
308310

311+
\subsection qgis_api_break_3_0_QgsAttributeDialog QgsAttributeDialog
312+
313+
<ul>
314+
<li>The constructor for QgsAttributeDialog has changed</li>
315+
<li>dialog() was removed - just use the object directly.</li>
316+
<li>setIsAddDialog() was removed. Use setMode() instead.</li>
317+
</ul>
318+
319+
\subsection qgis_api_break_3_0_QgsAttributeForm QgsAttributeForm
320+
321+
<ul>
322+
<li>setIsAddDialog() was removed. Use setMode() instead.</li>
323+
<li>accept() was removed. Use save() instead.</li>
324+
<li>reject() was removed. Use resetValues() instead.</li>
325+
</ul>
326+
309327
\subsection qgis_api_break_3_0_QgsAuthConfigUriEdit QgsAuthConfigUriEdit
310328

311329
<ul>
@@ -318,6 +336,11 @@ and setSortKeyAttributeName() instead.</li>
318336
<li>GenericDataSourceURI has been renamed to GenericDataSourceUri</li>
319337
</ul>
320338

339+
\subsection qgis_api_break_3_0_QgsQgsCachedFeatureIterator QgsCachedFeatureIterator
340+
<ul>
341+
<li>The constructor for QgsCachedFeatureIterator has changed.</li>
342+
</ul>
343+
321344
\subsection qgis_api_break_3_0_QgsCategorizedSymbolRendererWidget QgsCategorizedSymbolRendererWidget
322345
<ul>
323346
<li>sizeScaleFieldChanged() and scaleMethodChanged() were removed. These settings are no longer exposed in the widget's GUI.</li>
@@ -337,6 +360,12 @@ and the new ramp can be retrieved after executing the dialog by calling ramp().<
337360
<li>Some internal methods which were previously public or protected were made private.</li>
338361
</ul>
339362

363+
\subsection qgis_api_break_3_0_QgsColorRampShader QgsColorRampShader
364+
365+
<ul>
366+
<li>maximumColorCacheSize() and setMaximumColorCacheSize() were no longer used and are removed.</li>
367+
</ul>
368+
340369
\subsection qgis_api_break_3_0_QgsComposerArrow QgsComposerArrow
341370

342371
<ul>
@@ -547,6 +576,10 @@ and the new ramp can be retrieved after executing the dialog by calling ramp().<
547576
<ul>
548577
<li>expressionParams(), setExpressionParams() and insertExpressionParam() have been removed.
549578
QgsExpressionContext variables should be used in their place.</li>
579+
<li>prepareExpression( QgsVectorLayer* layer ) and prepareExpression( const QgsFields &fields )
580+
were removed. Use QgsExpressionContext variant instead.</li>
581+
<li>referencedColumns( QgsVectorLayer* layer ) and referencedColumns( const QgsFields& fields )
582+
were removed. Use QgsExpressionContext variant instead.</li>
550583
</ul>
551584

552585
\subsection qgis_api_break_3_0_QgsDataDefinedButton QgsDataDefinedButton
@@ -597,6 +630,12 @@ Use renderDiagram( const QgsFeature& feature, QgsRenderContext& c, const QgsDiag
597630
Use diagramSize( const QgsFeature& feature, const QgsRenderContext& c, const QgsDiagramSettings& s, const QgsDiagramInterpolationSettings& is ) instead.
598631
</ul>
599632

633+
\subsection qgis_api_break_3_0_QgsDiagramRenderer QgsDiagramRenderer
634+
635+
<ul>
636+
<li>xform, fields were no longer required and are removed.</li>
637+
</ul>
638+
600639
\subsection qgis_api_break_3_0_QgsDiagramLayerSettings QgsDiagramLayerSettings
601640

602641
<ul>
@@ -607,6 +646,33 @@ place of a null pointer.</li>
607646
<li>The ct member has been removed. Use coordinateTransform() and setCoordinateTransform() instead.
608647
</ul>
609648

649+
\subsection qgis_api_break_3_0_QgsDiagramSettings QgsDiagramSettings
650+
651+
<ul>
652+
<li>The SizeType enum was removed. Use QgsUnitTypes.RenderUnit instead.</li>
653+
</ul>
654+
655+
\subsection qgis_api_break_3_0_QgsDistanceArea QgsDistanceArea
656+
657+
<ul>
658+
<li>sourceCrs() now returns a QgsCoordinateReferenceSystem instead of the crs ID.</li>
659+
<li>measure() has been removed. Use measureArea() or measureLength() instead.</li>
660+
<li>textUnit() was removed. Use formatDistance() or formatArea() instead.</li>
661+
<li>convertMeasurement was removed. Use QgsUnitTypes for conversion instead.</li>
662+
</ul>
663+
664+
\subsection qgis_api_break_3_0_QgsDxfExport QgsDxfExport
665+
666+
<ul>
667+
<li>The writeGroup() method taking a QgsPoint argument was removed. Use the version which takes a QgsPointV2 instead.</li>
668+
<li>The writePolyline() method taking a QgsPolyline argument was removed. Use the alternative version instead.</li>
669+
<li>The writePolygon() method taking a QgsPolygon argument was removed. Use the version which takes a QgsRingSequence instead.</li>
670+
<li>writeSolid() was removed. Use writePolygon() instead.</li>
671+
<li>The signature for writeLine() has changed.</li>
672+
<li>writePoint(), writeFilledCircle(), writeCircle(), writeText() and writeMText() now take QgsPointV2 arguments</li>
673+
674+
</ul>
675+
610676
\subsection qgis_api_break_3_0_QgsEditFormConfig QgsEditFormConfig
611677

612678
<ul>
@@ -772,6 +838,10 @@ plugins calling this method will need to be updated.</li>
772838

773839
<ul>
774840
<li>init(QgsMapRenderer*) has been removed. Use init(const QgsMapSettings&) instead.</li>
841+
<li>&layer() was removed. use QgsPalLayerSettings::fromLayer() instead.</li>
842+
<li>addDiagramLayer() was removed. Use prepareDiagramLayer() instead.</li>
843+
<li>labelsAtPosition() was removed. Use takeResults() and methods of QgsLabelingResults instead.</li>
844+
<li>labelsWithinRect() was removed. Use takeResults() and methods of QgsLabelingResults.</li>
775845
</ul>
776846

777847
\subsection qgis_api_break_3_0_QgsLayerTreeGroup QgsLayerTreeGroup
@@ -780,6 +850,20 @@ plugins calling this method will need to be updated.</li>
780850
<li>readChildrenFromXML() has been renamed to readChildrenFromXml()</li>
781851
</ul>
782852

853+
\subsection qgis_api_break_3_0_QgsLayerTreeMode QgsLayerTreeModel
854+
855+
<ul>
856+
<li>The ShowSymbology flag was removed. Use ShowLegend instead.</li>
857+
<li>The AllowSymbologyChangeState flag was removed. Use AllowLegendChangeState instead.</li>
858+
<li>legendFilterByMap() was renamed to legendFilterMapSettings()</li>
859+
<li>isIndexSymbologyNode() was removed. Use index2legendNode() instead.</li>
860+
<li>layerNodeForSymbologyNode() was removed. Use index2legendNode()->parent() instead.</li>
861+
<li>refreshLayerSymbology() was removed. Use refreshLayerLegend() instead.</li>
862+
<li>setAutoCollapseSymbologyNodes() was removed. Use setAutoCollapseLegendNodes() instead.</li>
863+
<li>autoCollapseSymbologyNodes() was removed. Use autoCollapseLegendNodes() instead.</li>
864+
</ul>
865+
866+
783867
\subsection qgis_api_break_3_0_QgsLayerTreeNode QgsLayerTreeNode
784868

785869
<ul>
@@ -812,6 +896,12 @@ and the new ramp can be retrieved after executing the dialog by calling ramp().<
812896
<li>setProgress() signal has been removed. It was not emitted since 2.0.</li>
813897
</ul>
814898

899+
\subsection qgis_api_break_3_0_QgsMapCanvasItem QgsMapCanvasItem
900+
901+
<ul>
902+
<li>setPanningOffset() was removed.</li>
903+
</ul>
904+
815905
\subsection qgis_api_break_3_0_QgsMapLayer QgsMapLayer
816906

817907
<ul>
@@ -834,6 +924,12 @@ screenUpdateRequested() were removed. These members have had no effect for a num
834924
<li>writeLayerXML() was renamed to writeLayerXml()</li>
835925
</ul>
836926

927+
\subsection qgis_api_break_3_0_QgsMapLayerRegistry QgsMapLayerRegistry
928+
929+
<ul>
930+
<li>clearAllLayerCaches() was removed. This method has had no effect since QGIS 2.4</li>
931+
</ul>
932+
837933
\subsection qgis_api_break_3_0_QgsMapOverviewCanvas QgsMapOverviewCanvas
838934

839935
<ul>
@@ -858,6 +954,27 @@ be used instead of a null pointer if no transformation is required.</li>
858954
<li>drawOldLabeling(), drawNewLabeling() were removed. The method drawLabeling() should be used instead.</li>
859955
</ul>
860956

957+
\subsection qgis_api_break_3_0_QgsMapTool QgsMapTool
958+
959+
<ul>
960+
<li>renderComplete() was removed. Map tools must not directly depend on rendering progress.</li>
961+
<li>isTransient() and isEditTool() were removed. Use flags() instead.</li>
962+
</ul>
963+
964+
\subsection qgis_api_break_3_0_QgsMapToolCapture QgsMapToolCapture
965+
966+
<ul>
967+
<li>The nextPoint() method taking a QgsPoint was removed. Use the version taking a QgsPointV2 instead.</li>
968+
</ul>
969+
970+
\subsection qgis_api_break_3_0_QgsMapToPixel QgsMapToPixel
971+
972+
<ul>
973+
<li>The constructor now uses the map center x and y, and requires both height and width in pixels and a rotation value</li>
974+
<li>setYMaximum(), setYMinimum(), setXMinimum() were removed. Use setParameters() instead</li>
975+
976+
</ul>
977+
861978
\subsection qgis_api_break_3_0_QgsMapToPixelGeometrySimplifier QgsMapToPixelGeometrySimplifier
862979

863980
The whole class has been refactored to stop using WKB and to use QgsAbstractGeometry classes.
@@ -887,12 +1004,26 @@ plugins calling this method will need to be updated.</li>
8871004
<li>Constructor taking QgsLayerItem argument has been removed. Use QgsDataItem::mimeUri() instead.</li>
8881005
</ul>
8891006

1007+
\subsection qgis_api_break_3_0_QgsNetworkAccessManager QgsNetworkAccessManager
1008+
1009+
<ul>
1010+
<li>sendGet() was removed. Use get() directly.</li>
1011+
<li>deleteReply() was removed. Use abort() and deleteLayer() on the reply directly.</li>
1012+
<li>requestSent signal was removed. This is no longer emitted.</li>
1013+
</ul>
1014+
8901015
\subsection qgis_api_break_3_0_QgsOSMElement QgsOSMElement
8911016

8921017
<ul>
8931018
<li>elemID() has been renamed to elemId()</li>
8941019
</ul>
8951020

1021+
\subsection qgis_api_break_3_0_QgsOwsConnection QgsOwsConnection
1022+
1023+
<ul>
1024+
<li>connectionInfo() was removed.</li>
1025+
</ul>
1026+
8961027
\subsection qgis_api_break_3_0_QgsOWSSourceSelect QgsOWSSourceSelect
8971028

8981029
<ul>
@@ -923,6 +1054,12 @@ and for forcing certain items to always sort on top.</li>
9231054
<ul>
9241055
<li>init(QgsMapRenderer*) has been removed. Use init(const QgsMapSettings&) instead.</li>
9251056
<li>prepareGeometry and geometryRequiresPreparation now take geometry references, not pointers.</li>
1057+
<li>layer() was removed. If direct access to QgsPalLayerSettings is necessary, use QgsPalLayerSettings::fromLayer()</li>
1058+
<li>candidates() was removed.</li>
1059+
<li>addDiagramLayer() was removed. Use prepareDiagramLayer() instead.</li>
1060+
<li>labelsAtPosition() was removed. Use takeResults() and methods of QgsLabelingResults instead.</li>
1061+
<li>labelsWithinRect() was removed. Use takeResults() and methods of QgsLabelingResults instead.</li>
1062+
<li>isStoredWithProject() and setStoredWithProject() had no effect and were removed.</li>
9261063
</ul>
9271064

9281065
\subsection qgis_api_break_3_0_QgsPalLayerSettings QgsPalLayerSettings
@@ -948,6 +1085,9 @@ plugins calling this method will need to be updated.</li>
9481085

9491086
<ul>
9501087
<li>visibilityPresetCollection() has been renamed to mapThemeCollection()</li>
1088+
<li>title( const QString & title ) was removed. Use setTitle() instead.</li>
1089+
<li>dirty( bool b ) was removed. Use setDirty() instead.</li>
1090+
<li>clearProperties() was removed. Use clear() instead.</li>
9511091
</ul>
9521092

9531093
\subsection qgis_api_break_3_0_QgsRasterCalcNode QgsRasterCalcNode
@@ -974,6 +1114,14 @@ plugins calling this method will need to be updated.</li>
9741114
<li>block() has new "feedback" argument.</li>
9751115
</ul>
9761116

1117+
\subsection qgis_api_break_3_0_QgsRasterLayer QgsRasterLayer
1118+
1119+
<ul>
1120+
<li>setDrawingStyle() was removed. Use setRendererForDrawingStyle() or setRenderer() instead.</li>
1121+
<li>previewAsPixmap() was removed. Use previewAsImage() instead.</li>
1122+
<li>updateProgress() had no effect and was removed.</li>
1123+
</ul>
1124+
9771125
\subsection qgis_api_break_3_0_QgsRasterProjector QgsRasterProjector
9781126

9791127
<ul>
@@ -1053,6 +1201,14 @@ be returned instead of a null pointer if no transformation is required.</li>
10531201

10541202
<ul>
10551203
<li>Constructor variant with QgsMapRenderer has been removed. Use the variant with QgsMapSettings.</li>
1204+
<li>Signature for snapPoint() has changed.</li>
1205+
</ul>
1206+
1207+
\subsection qgis_api_break_3_0_QgsSublayersDialog QgsSublayersDialog
1208+
1209+
<ul>
1210+
<li>populateLayerTable() now takes a list of QgsSublayersDialog.LayerDefinition values</li>
1211+
<li>selectionNames() and selectionIndexes() were removed. Use selection().</li>
10561212
</ul>
10571213

10581214
\subsection qgis_api_break_3_0_QgsSvgCache QgsSvgCache
@@ -1119,6 +1275,7 @@ than an integer value</li>
11191275

11201276
<ul>
11211277
<li>vertexSearchRadius(), defaultTolerance(), toleranceInMapUnits() do not have variant with QgsMapRenderer anymore. Use the variants with QgsMapSettings.</li>
1278+
<li>The MapUnits UnitType was removed. Use LayerUnits or ProjectUnits instead.</li>
11221279
</ul>
11231280

11241281
\subsection qgis_api_break_3_0_QgsTreeWidgetItem QgsTreeWidgetItem
@@ -1145,6 +1302,12 @@ Radians (to AngleRadians), Gon (to AngleGon), MinutesOfArc (to AngleMinutesOfArc
11451302
SecondsOfArc (to AngleSecondsOfArc), Turn (to AngleTurn) and UnknownAngleUnit to AngleUnknownUnit</li>
11461303
</ul>
11471304

1305+
\subsection qgis_api_break_3_0_QgsVector QgsVector
1306+
1307+
<ul>
1308+
<li>normal() was removed. Use normalized() instead.</li>
1309+
</ul>
1310+
11481311
\subsection qgis_api_break_3_0_QgsVectorDataProvider QgsVectorDataProvider
11491312

11501313
<ul>

0 commit comments

Comments
 (0)
Please sign in to comment.