@@ -63,15 +63,19 @@ class GUI_EXPORT QgisInterface : public QObject
63
63
64
64
// ! Zoom to full extent of map layers
65
65
virtual void zoomFull () = 0;
66
- // ! Zoom to previous view extent
66
+
67
+ // ! Zoom to previous view extent
67
68
virtual void zoomToPrevious () = 0;
68
- // ! Zoome to extent of the active layer
69
+
70
+ // ! Zoom to extent of the active layer
69
71
virtual void zoomToActiveLayer () = 0;
70
72
71
73
// ! Add a vector layer
72
74
virtual QgsVectorLayer* addVectorLayer ( QString vectorLayerPath, QString baseName, QString providerKey ) = 0;
75
+
73
76
// ! Add a raster layer given a raster layer file name
74
77
virtual QgsRasterLayer* addRasterLayer ( QString rasterLayerPath, QString baseName = QString() ) = 0;
78
+
75
79
// ! Add a WMS layer
76
80
virtual QgsRasterLayer* addRasterLayer ( const QString& url, const QString& layerName, const QString& providerKey, const QStringList& layers,
77
81
const QStringList& styles, const QString& format, const QString& crs ) = 0;
@@ -86,20 +90,13 @@ class GUI_EXPORT QgisInterface : public QObject
86
90
87
91
// ! Add an icon to the plugins toolbar
88
92
virtual int addToolBarIcon ( QAction *qAction ) = 0;
93
+
89
94
// ! Remove an action (icon) from the plugin toolbar
90
95
virtual void removeToolBarIcon ( QAction *qAction ) = 0;
96
+
91
97
// ! Add toolbar with specified name
92
98
virtual QToolBar * addToolBar ( QString name ) = 0;
93
- // TODO: is this deprecated in favour of QgsContextHelp?
94
- /* * Open a url in the users browser. By default the QGIS doc directory is used
95
- * as the base for the URL. To open a URL that is not relative to the installed
96
- * QGIS documentation, set useQgisDocDirectory to false.
97
- * @param url URL to open
98
- * @param useQgisDocDirectory If true, the URL will be formed by concatenating
99
- * url to the QGIS documentation directory path (<prefix>/share/doc)
100
- */
101
- virtual void openURL ( QString url, bool useQgisDocDirectory = true ) = 0;
102
-
99
+
103
100
/* * Return a pointer to the map canvas */
104
101
virtual QgsMapCanvas * mapCanvas () = 0;
105
102
@@ -120,10 +117,22 @@ class GUI_EXPORT QgisInterface : public QObject
120
117
/* * Add window to Window menu. The action title is the window title
121
118
* and the action should raise, unminimize and activate the window. */
122
119
virtual void addWindow ( QAction *action ) = 0;
120
+
123
121
/* * Remove window from Window menu. Calling this is necessary only for
124
122
* windows which are hidden rather than deleted when closed. */
125
123
virtual void removeWindow ( QAction *action ) = 0;
126
124
125
+ // TODO: is this deprecated in favour of QgsContextHelp?
126
+ /* * Open a url in the users browser. By default the QGIS doc directory is used
127
+ * as the base for the URL. To open a URL that is not relative to the installed
128
+ * QGIS documentation, set useQgisDocDirectory to false.
129
+ * @param url URL to open
130
+ * @param useQgisDocDirectory If true, the URL will be formed by concatenating
131
+ * url to the QGIS documentation directory path (<prefix>/share/doc)
132
+ */
133
+ virtual void openURL ( QString url, bool useQgisDocDirectory = true ) = 0;
134
+
135
+
127
136
/* * Accessors for inserting items into menus and toolbars.
128
137
* An item can be inserted before any existing action.
129
138
*/
@@ -257,7 +266,7 @@ class GUI_EXPORT QgisInterface : public QObject
257
266
#ifdef WIN32
258
267
# define QGISEXTERN extern " C" __declspec( dllexport )
259
268
# ifdef _MSC_VER
260
- // do not warn about C bindings returing QString
269
+ // do not warn about C bindings returning QString
261
270
# pragma warning(disable:4190)
262
271
# endif
263
272
#else
0 commit comments