Skip to content

Commit cb1ecad

Browse files
committed
Python bindings for multipage composer
1 parent f064cb0 commit cb1ecad

File tree

2 files changed

+13
-0
lines changed

2 files changed

+13
-0
lines changed

python/core/qgscomposition.sip

+9
Original file line numberDiff line numberDiff line change
@@ -39,6 +39,11 @@ class QgsComposition: QGraphicsScene
3939
/**Returns width of paper item*/
4040
double paperWidth() const;
4141

42+
/**Note: added in version 1.9*/
43+
void setNumPages( int pages );
44+
/**Note: added in version 1.9*/
45+
int numPages() const;
46+
4247
void setSnapToGridEnabled( bool b );
4348
bool snapToGridEnabled() const;
4449

@@ -172,4 +177,8 @@ class QgsComposition: QGraphicsScene
172177

173178
/**Convenience function to create a QgsAddRemoveItemCommand, connect its signals and push it to the undo stack*/
174179
void pushAddRemoveCommand( QgsComposerItem* item, const QString& text, QgsAddRemoveItemCommand::State state );
180+
181+
/**Render a page to a paint device
182+
@note added in version 1.9*/
183+
void renderPage( QPainter* p, int page );
175184
};

src/core/composer/qgscomposition.h

+4
Original file line numberDiff line numberDiff line change
@@ -79,7 +79,9 @@ class CORE_EXPORT QgsComposition: public QGraphicsScene
7979
/**Returns width of paper item*/
8080
double paperWidth() const;
8181

82+
/**Note: added in version 1.9*/
8283
void setNumPages( int pages );
84+
/**Note: added in version 1.9*/
8385
int numPages() const;
8486

8587
void setSnapToGridEnabled( bool b );
@@ -217,6 +219,8 @@ class CORE_EXPORT QgsComposition: public QGraphicsScene
217219
/**Convenience function to create a QgsAddRemoveItemCommand, connect its signals and push it to the undo stack*/
218220
void pushAddRemoveCommand( QgsComposerItem* item, const QString& text, QgsAddRemoveItemCommand::State state = QgsAddRemoveItemCommand::Added );
219221

222+
/**Render a page to a paint device
223+
@note added in version 1.9*/
220224
void renderPage( QPainter* p, int page );
221225

222226
public slots:

0 commit comments

Comments
 (0)