26 changes: 13 additions & 13 deletions python/core/qgsdataitem.sip
Original file line number Diff line number Diff line change
Expand Up @@ -25,25 +25,25 @@ class QgsDataItem : QObject
virtual void refresh();

// Create vector of children
// virtual QVector<QgsDataItem*> createChildren();
virtual QVector<QgsDataItem*> createChildren();

// Populate children using children vector created by createChildren()
virtual void populate();

// Insert new child using alphabetical order based on mName, emits necessary signal to model before and after, sets parent and connects signals
// refresh - refresh populated item, emit signals to model
virtual void addChildItem( QgsDataItem * child, bool refresh = false );
virtual void addChildItem( QgsDataItem *child /Transfer/, bool refresh = false );

// remove and delete child item, signals to browser are emited
// remove and delete child item, signals to browser are emitted
virtual void deleteChildItem( QgsDataItem * child );

// remove child item but don't delete it, signals to browser are emited
// returns pointer to the removed item or null if no such item was found
virtual QgsDataItem * removeChildItem( QgsDataItem * child );
virtual QgsDataItem *removeChildItem( QgsDataItem * child ) /TransferBack/;

virtual bool equal( const QgsDataItem *other );

virtual QWidget *paramWidget();
virtual QWidget *paramWidget() /Factory/;

// list of actions provided by this item - usually used for popup menu on right-click
virtual QList<QAction*> actions();
Expand All @@ -70,14 +70,14 @@ class QgsDataItem : QObject
// static methods

// Find child index in vector of items using '==' operator
// static int findItem( QVector<QgsDataItem*> items, QgsDataItem * item );
static int findItem( QVector<QgsDataItem*> items, QgsDataItem * item );

// members

Type type() const;
QgsDataItem* parent() const;
void setParent( QgsDataItem* parent );
// QVector<QgsDataItem*> children() const;
QVector<QgsDataItem*> children() const;
QIcon icon() const;
QString name() const;
QString path() const;
Expand Down Expand Up @@ -160,7 +160,7 @@ class QgsDataCollectionItem : QgsDataItem
~QgsDataCollectionItem();

void setPopulated();
void addChild( QgsDataItem *item );
void addChild( QgsDataItem *item /Transfer/ );

static const QIcon &iconDir(); // shared icon: open/closed directory
static const QIcon &iconDataCollection(); // default icon for data collection
Expand All @@ -186,11 +186,11 @@ class QgsDirectoryItem : QgsDataCollectionItem
QgsDirectoryItem( QgsDataItem* parent, QString name, QString path );
~QgsDirectoryItem();

// QVector<QgsDataItem*> createChildren();
QVector<QgsDataItem*> createChildren();

virtual bool equal( const QgsDataItem *other );

virtual QWidget * paramWidget();
virtual QWidget *paramWidget() /Factory/;

/* static QVector<QgsDataProvider*> mProviders; */
// static QVector<QLibrary*> mLibraries;
Expand Down Expand Up @@ -222,7 +222,7 @@ class QgsFavouritesItem : QgsDataCollectionItem
QgsFavouritesItem( QgsDataItem* parent, QString name, QString path = QString() );
~QgsFavouritesItem();

// QVector<QgsDataItem*> createChildren();
QVector<QgsDataItem*> createChildren();

static const QIcon &iconFavourites();
};
Expand All @@ -238,15 +238,15 @@ class QgsZipItem : QgsDataCollectionItem
QgsZipItem( QgsDataItem* parent, QString name, QString path );
~QgsZipItem();

// QVector<QgsDataItem*> createChildren();
QVector<QgsDataItem*> createChildren();
const QStringList & getZipFileList();

// static QVector<dataItem_t *> mDataItemPtr;
static QStringList mProviderNames;

static QString vsiPrefix( QString uri );

static QgsDataItem* itemFromPath( QgsDataItem* parent, QString path, QString name );
static QgsDataItem* itemFromPath( QgsDataItem* parent, QString path, QString name ) /Factory/;

static const QIcon &iconZip();

Expand Down
3 changes: 2 additions & 1 deletion python/core/qgsmaptopixel.sip
Original file line number Diff line number Diff line change
Expand Up @@ -47,7 +47,8 @@ class QgsMapToPixel

/* Transform device coordinates to map coordinates. Modifies the
given coordinates in place. Intended as a fast way to do the
transform. */
transform.
*/
// void transformInPlace( QVector<double>& x, QVector<double>& y ) const;

QgsPoint toMapCoordinates( int x, int y ) const;
Expand Down
2 changes: 1 addition & 1 deletion python/core/qgspluginlayerregistry.sip
Original file line number Diff line number Diff line change
Expand Up @@ -43,7 +43,7 @@ class QgsPluginLayerRegistry
QgsPluginLayerType* pluginLayerType(QString typeName);

/** return new layer if corresponding plugin has been found, else return NULL */
// QgsPluginLayer* createLayer(QString typeName) /Factory/;
QgsPluginLayer* createLayer(QString typeName) /Factory/;

private:

Expand Down
14 changes: 10 additions & 4 deletions python/core/qgsproject.sip
Original file line number Diff line number Diff line change
Expand Up @@ -173,10 +173,16 @@ class QgsProject : QObject
@note The key string <em>must</em> include '/'s. E.g., "/foo" not "foo".
*/
//@{
//! @note not available in python bindings
// bool writeEntry( const QString & scope, const QString & key, bool value );
//! @note not available in python bindings
// bool writeEntry( const QString & scope, const QString & key, double value );
bool writeEntryBool( const QString & scope, const QString & key, bool value );
%MethodCode
sipRes = sipCpp->writeEntry( *a0, *a1, a2 );
%End

bool writeEntryDouble( const QString & scope, const QString & key, double value );
%MethodCode
sipRes = sipCpp->writeEntry( *a0, *a1, a2 );
%End

bool writeEntry( const QString & scope, const QString & key, int value );
bool writeEntry( const QString & scope, const QString & key, const QString & value );
bool writeEntry( const QString & scope, const QString & key, const QStringList & value );
Expand Down
5 changes: 3 additions & 2 deletions python/core/raster/qgsrasterinterface.sip
Original file line number Diff line number Diff line change
Expand Up @@ -182,7 +182,8 @@ class QgsRasterInterface
/** \brief Test if value is within the list of ranges
* @param value value
* @param rangeList list of ranges
* @return true if value is in at least one of ranges */
// static bool valueInRange( double value, QList<QgsRasterInterface::Range> rangeList );
* @return true if value is in at least one of ranges
*/
static bool valueInRange( double value, QList<QgsRasterInterface::Range> rangeList );
};

29 changes: 19 additions & 10 deletions python/core/raster/qgsrasterlayer.sip
Original file line number Diff line number Diff line change
Expand Up @@ -6,11 +6,7 @@
class QgsRasterLayer : QgsMapLayer
{
%TypeHeaderCode
// #include <qgsrasterpyramid.h>
#include <qgsrasterlayer.h>
#include <qgscontrastenhancement.h>
#include <qgsrastertransparency.h>
#include <qgsrastershader.h>
%End

public:
Expand Down Expand Up @@ -275,13 +271,16 @@ class QgsRasterLayer : QgsMapLayer
bool copySymbologySettings( const QgsMapLayer& theOther );

/** \brief Get a pointer to the color table */
// QList<QgsColorRampShader::ColorRampItem>* colorTable( int theBandNoInt );
QList<QgsColorRampShader::ColorRampItem> colorTable( int theBandNoInt );

/** Returns the data provider */
QgsRasterDataProvider* dataProvider();

/** Returns the data provider in a const-correct manner */
// const QgsRasterDataProvider* dataProvider() const;
const QgsRasterDataProvider* constDataProvider() const;
%MethodCode
sipRes = sipCpp->dataProvider();
%End

/**Synchronises with changes in the datasource
@note added in version 1.6*/
Expand Down Expand Up @@ -309,7 +308,10 @@ class QgsRasterLayer : QgsMapLayer
bool identify( const QgsPoint & point, QMap<QString, QString>& results /Out/ );

/** \brief Identify raster value(s) found on the point position */
// bool identify( const QgsPoint & point, QMap<int, QString>& results /Out/ );
bool identifyMap( const QgsPoint & point, QMap<int, QString>& results /Out/ );
%MethodCode
sipRes = sipCpp->identify( *a0, *a1 );
%End

/** \brief Identify arbitrary details from the WMS server found on the point position */
QString identifyAsText( const QgsPoint & point );
Expand All @@ -336,10 +338,16 @@ class QgsRasterLayer : QgsMapLayer
QPixmap legendAsPixmap();

/** \brief Overloaded version of above function that can print layer name onto legend */
// QPixmap legendAsPixmap( bool ) /Deprecated/;
QPixmap legendAsPixmapBool( bool ) /Deprecated/;
%MethodCode
sipRes = new QPixmap( sipCpp->legendAsPixmap( a0 ) );
%End

/** \brief Use this method when you want an annotated legend suitable for print output etc */
QPixmap legendAsPixmap( int theLabelCount ) /Deprecated/;
QPixmap legendAsPixmapCount( int theLabelCount ) /Deprecated/;
%MethodCode
sipRes = new QPixmap( sipCpp->legendAsPixmap( a0 ) );
%End

/** \brief Accessor for maximum value user for contrast enhancement */
double maximumValue( unsigned int theBand );
Expand Down Expand Up @@ -392,7 +400,8 @@ class QgsRasterLayer : QgsMapLayer

/** \brief Mutator for contrast enhancement algorithm using min/max */
// TODO: remove in 2.0, replaced by following
// void setContrastEnhancementAlgorithm( QgsContrastEnhancement::ContrastEnhancementAlgorithm theAlgorithm, bool theGenerateLookupTableFlag = true );
// void setContrastEnhancementAlgorithm( QgsContrastEnhancement::ContrastEnhancementAlgorithm theAlgorithm,
// bool theGenerateLookupTableFlag = true );

/** \brief Mutator for contrast enhancement algorithm
* @param theAlgorithm Contrast enhancement algorithm
Expand Down
24 changes: 12 additions & 12 deletions python/core/symbology-ng/qgscptcityarchive.sip
Original file line number Diff line number Diff line change
Expand Up @@ -33,8 +33,8 @@ class QgsCptCityArchive
static QMap< QString, QgsCptCityArchive* > archiveRegistry();

// items
// QVector< QgsCptCityDataItem* > rootItems() const;
// QVector< QgsCptCityDataItem* > selectionItems() const;
QVector< QgsCptCityDataItem* > rootItems() const;
QVector< QgsCptCityDataItem* > selectionItems() const;
};

/** base class for all items in the model */
Expand Down Expand Up @@ -66,26 +66,26 @@ class QgsCptCityDataItem : QObject
virtual void refresh();

// Create vector of children
// virtual QVector<QgsCptCityDataItem*> createChildren();
virtual QVector<QgsCptCityDataItem*> createChildren();

// Populate children using children vector created by createChildren()
virtual void populate();
bool isPopulated();

// Insert new child using alphabetical order based on mName, emits necessary signal to model before and after, sets parent and connects signals
// refresh - refresh populated item, emit signals to model
virtual void addChildItem( QgsCptCityDataItem * child, bool refresh = false );
virtual void addChildItem( QgsCptCityDataItem * child /Transfer/, bool refresh = false );

// remove and delete child item, signals to browser are emited
virtual void deleteChildItem( QgsCptCityDataItem * child );

// remove child item but don't delete it, signals to browser are emited
// returns pointer to the removed item or null if no such item was found
virtual QgsCptCityDataItem * removeChildItem( QgsCptCityDataItem * child );
virtual QgsCptCityDataItem * removeChildItem( QgsCptCityDataItem * child ) /TransferBack/;

virtual bool equal( const QgsCptCityDataItem *other );

virtual QWidget * paramWidget();
virtual QWidget *paramWidget() /Factory/;

// list of actions provided by this item - usually used for popup menu on right-click
virtual QList<QAction*> actions();
Expand All @@ -99,14 +99,14 @@ class QgsCptCityDataItem : QObject
// static methods

// Find child index in vector of items using '==' operator
// static int findItem( QVector<QgsCptCityDataItem*> items, QgsCptCityDataItem * item );
static int findItem( QVector<QgsCptCityDataItem*> items, QgsCptCityDataItem * item );

// members

Type type() const;
QgsCptCityDataItem* parent() const;
void setParent( QgsCptCityDataItem* parent );
// QVector<QgsCptCityDataItem*> children() const;
QVector<QgsCptCityDataItem*> children() const;
virtual QIcon icon();
virtual QIcon icon( const QSize& size );
QString name() const;
Expand Down Expand Up @@ -175,8 +175,8 @@ class QgsCptCityCollectionItem : QgsCptCityDataItem
~QgsCptCityCollectionItem();

void setPopulated();
void addChild( QgsCptCityDataItem *item );
// QVector<QgsCptCityDataItem*> childrenRamps( bool recursive );
void addChild( QgsCptCityDataItem *item /Transfer/ );
QVector<QgsCptCityDataItem*> childrenRamps( bool recursive );
};

/** A directory: contains subdirectories and color ramps */
Expand All @@ -190,7 +190,7 @@ class QgsCptCityDirectoryItem : QgsCptCityCollectionItem
QString name, QString path );
~QgsCptCityDirectoryItem();

// QVector<QgsCptCityDataItem*> createChildren();
QVector<QgsCptCityDataItem*> createChildren();

virtual bool equal( const QgsCptCityDataItem *other );

Expand All @@ -213,7 +213,7 @@ class QgsCptCitySelectionItem : QgsCptCityCollectionItem
QgsCptCitySelectionItem( QgsCptCityDataItem* parent, QString name, QString path );
~QgsCptCitySelectionItem();

// QVector<QgsCptCityDataItem*> createChildren();
QVector<QgsCptCityDataItem*> createChildren();

virtual bool equal( const QgsCptCityDataItem *other );

Expand Down
5 changes: 2 additions & 3 deletions src/core/qgsattributeaction.h
Original file line number Diff line number Diff line change
Expand Up @@ -123,7 +123,7 @@ class CORE_EXPORT QgsAttributeAction
/*! Does the given values. defaultValueIndex is the index of the
* field to be used if the action has a $currfield placeholder.
* @note added in 1.9
* @note not available in python bindings
* @note available in python bindings as doActionFeature
*/
void doAction( int index,
QgsFeature &feat,
Expand All @@ -134,7 +134,7 @@ class CORE_EXPORT QgsAttributeAction
* substitutionMap is used to pass custom substitutions, to replace
* each key in the map with the associated value
* @note added in 1.9
* @note not available in python bindings
* @note available in python bindings as doActionFeatureWithSubstitution
*/
void doAction( int index,
QgsFeature &feat,
Expand All @@ -160,7 +160,6 @@ class CORE_EXPORT QgsAttributeAction
* parameter
*
* @note added in 1.9
* @note not available in python bindings
*/
QString expandAction( QString action,
QgsFeature &feat,
Expand Down
5 changes: 2 additions & 3 deletions src/core/qgsdataitem.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -176,10 +176,9 @@ void QgsDataItem::emitEndRemoveItems()
emit endRemoveItems();
}

QVector<QgsDataItem*> QgsDataItem::createChildren( )
QVector<QgsDataItem*> QgsDataItem::createChildren()
{
QVector<QgsDataItem*> children;
return children;
return QVector<QgsDataItem*>();
}

void QgsDataItem::populate()
Expand Down
8 changes: 1 addition & 7 deletions src/core/qgsdataitem.h
Original file line number Diff line number Diff line change
Expand Up @@ -63,7 +63,6 @@ class CORE_EXPORT QgsDataItem : public QObject
virtual void refresh();

// Create vector of children
// @note not available in python bindings
virtual QVector<QgsDataItem*> createChildren();

// Populate children using children vector created by createChildren()
Expand All @@ -73,7 +72,7 @@ class CORE_EXPORT QgsDataItem : public QObject
// refresh - refresh populated item, emit signals to model
virtual void addChildItem( QgsDataItem * child, bool refresh = false );

// remove and delete child item, signals to browser are emited
// remove and delete child item, signals to browser are emitted
virtual void deleteChildItem( QgsDataItem * child );

// remove child item but don't delete it, signals to browser are emited
Expand Down Expand Up @@ -110,15 +109,13 @@ class CORE_EXPORT QgsDataItem : public QObject
// static methods

// Find child index in vector of items using '==' operator
// @note not available in python bindings
static int findItem( QVector<QgsDataItem*> items, QgsDataItem * item );

// members

Type type() const { return mType; }
QgsDataItem* parent() const { return mParent; }
void setParent( QgsDataItem* parent ) { mParent = parent; }
// @note not available in python bindings
QVector<QgsDataItem*> children() const { return mChildren; }
QIcon icon() const { return mIcon; }
QString name() const { return mName; }
Expand Down Expand Up @@ -239,7 +236,6 @@ class CORE_EXPORT QgsDirectoryItem : public QgsDataCollectionItem
QgsDirectoryItem( QgsDataItem* parent, QString name, QString path );
~QgsDirectoryItem();

//! @note not available via python bindings
QVector<QgsDataItem*> createChildren();

virtual bool equal( const QgsDataItem *other );
Expand Down Expand Up @@ -291,7 +287,6 @@ class CORE_EXPORT QgsFavouritesItem : public QgsDataCollectionItem
QgsFavouritesItem( QgsDataItem* parent, QString name, QString path = QString() );
~QgsFavouritesItem();

//! @note not available in python bindings
QVector<QgsDataItem*> createChildren();

static const QIcon &iconFavourites();
Expand All @@ -310,7 +305,6 @@ class CORE_EXPORT QgsZipItem : public QgsDataCollectionItem
QgsZipItem( QgsDataItem* parent, QString name, QString path );
~QgsZipItem();

//! @note not available in python bindings
QVector<QgsDataItem*> createChildren();
const QStringList & getZipFileList();

Expand Down
1 change: 0 additions & 1 deletion src/core/qgspluginlayerregistry.h
Original file line number Diff line number Diff line change
Expand Up @@ -74,7 +74,6 @@ class CORE_EXPORT QgsPluginLayerRegistry
QgsPluginLayerType* pluginLayerType( QString typeName );

/** return new layer if corresponding plugin has been found, else return NULL */
// @note not available in python bindings
QgsPluginLayer* createLayer( QString typeName );

private:
Expand Down
6 changes: 3 additions & 3 deletions src/core/qgsproject.h
Original file line number Diff line number Diff line change
Expand Up @@ -213,9 +213,9 @@ class CORE_EXPORT QgsProject : public QObject
@note The key string <em>must</em> include '/'s. E.g., "/foo" not "foo".
*/
//@{
//! @note not available in python bindings
bool writeEntry( QString const & scope, const QString & key, bool value );
//! @note not available in python bindings
//! @note available in python bindings as writeEntryBool
bool writeEntry( const QString & scope, const QString & key, bool value );
//! @note available in python bindings as writeEntryDouble
bool writeEntry( const QString & scope, const QString & key, double value );
bool writeEntry( const QString & scope, const QString & key, int value );
bool writeEntry( const QString & scope, const QString & key, const QString & value );
Expand Down
13 changes: 6 additions & 7 deletions src/core/raster/qgsrasterlayer.h
Original file line number Diff line number Diff line change
Expand Up @@ -440,17 +440,13 @@ class CORE_EXPORT QgsRasterLayer : public QgsMapLayer
/**Copies the symbology settings from another layer. Returns true in case of success*/
bool copySymbologySettings( const QgsMapLayer& theOther );

/** \brief Get a pointer to the color table
@note not available in python bindings
*/
/** \brief Get a pointer to the color table */
QList<QgsColorRampShader::ColorRampItem> colorTable( int theBandNoInt );

/** Returns the data provider */
QgsRasterDataProvider* dataProvider();

/** Returns the data provider in a const-correct manner
@note not available in python bindings
*/
/** Returns the data provider in a const-correct manner */
const QgsRasterDataProvider* dataProvider() const;

/**Synchronises with changes in the datasource
Expand Down Expand Up @@ -479,7 +475,7 @@ class CORE_EXPORT QgsRasterLayer : public QgsMapLayer
bool identify( const QgsPoint & point, QMap<QString, QString>& results );

/** \brief Identify raster value(s) found on the point position
* @note not available in python bindings
* @note available in python bindings as identifyMap
*/
bool identify( const QgsPoint & point, QMap<int, QString>& results );

Expand Down Expand Up @@ -508,9 +504,12 @@ class CORE_EXPORT QgsRasterLayer : public QgsMapLayer
QPixmap legendAsPixmap();

/** \brief Overloaded version of above function that can print layer name onto legend */
//! @deprecated
//! @note available as legendAsPixmapBool in python bindings
Q_DECL_DEPRECATED QPixmap legendAsPixmap( bool );

/** \brief Use this method when you want an annotated legend suitable for print output etc */
//! @note available as legendAsPixmapCount in python bindings
Q_DECL_DEPRECATED QPixmap legendAsPixmap( int theLabelCount );

/** \brief Accessor for maximum value user for contrast enhancement */
Expand Down
6 changes: 0 additions & 6 deletions src/core/symbology-ng/qgscptcityarchive.h
Original file line number Diff line number Diff line change
Expand Up @@ -106,7 +106,6 @@ class CORE_EXPORT QgsCptCityDataItem : public QObject
virtual void refresh();

// Create vector of children
//! note not available in python bindings
virtual QVector<QgsCptCityDataItem*> createChildren();

// Populate children using children vector created by createChildren()
Expand Down Expand Up @@ -140,15 +139,13 @@ class CORE_EXPORT QgsCptCityDataItem : public QObject
// static methods

// Find child index in vector of items using '==' operator
//! note not available in python bindings
static int findItem( QVector<QgsCptCityDataItem*> items, QgsCptCityDataItem * item );

// members

Type type() const { return mType; }
QgsCptCityDataItem* parent() const { return mParent; }
void setParent( QgsCptCityDataItem* parent ) { mParent = parent; }
//! note not available in python bindings
QVector<QgsCptCityDataItem*> children() const { return mChildren; }
virtual QIcon icon() { return mIcon; }
virtual QIcon icon( const QSize& size ) { Q_UNUSED( size ) ; return icon(); }
Expand Down Expand Up @@ -233,7 +230,6 @@ class CORE_EXPORT QgsCptCityCollectionItem : public QgsCptCityDataItem

void setPopulated() { mPopulated = true; }
void addChild( QgsCptCityDataItem *item ) { mChildren.append( item ); }
//! note not available in python bindings
QVector<QgsCptCityDataItem*> childrenRamps( bool recursive );

protected:
Expand All @@ -249,7 +245,6 @@ class CORE_EXPORT QgsCptCityDirectoryItem : public QgsCptCityCollectionItem
QString name, QString path );
~QgsCptCityDirectoryItem();

//! note not available in python bindings
QVector<QgsCptCityDataItem*> createChildren();

virtual bool equal( const QgsCptCityDataItem *other );
Expand All @@ -271,7 +266,6 @@ class CORE_EXPORT QgsCptCitySelectionItem : public QgsCptCityCollectionItem
QgsCptCitySelectionItem( QgsCptCityDataItem* parent, QString name, QString path );
~QgsCptCitySelectionItem();

//! note not available in python bindings
QVector<QgsCptCityDataItem*> createChildren();

virtual bool equal( const QgsCptCityDataItem *other );
Expand Down