-
-
Notifications
You must be signed in to change notification settings - Fork 3k
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Loading branch information
1 parent
b42c055
commit 361dd31
Showing
13 changed files
with
327 additions
and
150 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,100 @@ | ||
/************************************************************************ | ||
* This file has been generated automatically from * | ||
* * | ||
* src/core/layout/qgslayoutsnapper.h * | ||
* * | ||
* Do not edit manually ! Edit header and run scripts/sipify.pl again * | ||
************************************************************************/ | ||
|
||
|
||
class QgsLayoutSnapper | ||
{ | ||
%Docstring | ||
Manages snapping grids and preset snap lines in a layout, and handles | ||
snapping points to the nearest grid coordinate/snap line when possible. | ||
.. versionadded:: 3.0 | ||
%End | ||
|
||
%TypeHeaderCode | ||
#include "qgslayoutsnapper.h" | ||
%End | ||
public: | ||
|
||
enum GridStyle | ||
{ | ||
GridLines, | ||
GridDots, | ||
GridCrosses | ||
}; | ||
|
||
QgsLayoutSnapper(); | ||
|
||
void setGridResolution( const QgsLayoutMeasurement &resolution ); | ||
%Docstring | ||
Sets the page/snap grid ``resolution``. | ||
.. seealso:: gridResolution() | ||
.. seealso:: setGridOffset() | ||
%End | ||
|
||
QgsLayoutMeasurement gridResolution() const; | ||
%Docstring | ||
Returns the page/snap grid resolution. | ||
.. seealso:: setGridResolution() | ||
.. seealso:: gridOffset() | ||
:rtype: QgsLayoutMeasurement | ||
%End | ||
|
||
void setGridOffset( const QgsLayoutPoint offset ); | ||
%Docstring | ||
Sets the ``offset`` of the page/snap grid. | ||
.. seealso:: gridOffset() | ||
.. seealso:: setGridResolution() | ||
%End | ||
|
||
QgsLayoutPoint gridOffset() const; | ||
%Docstring | ||
Returns the offset of the page/snap grid. | ||
.. seealso:: setGridOffset() | ||
.. seealso:: gridResolution() | ||
:rtype: QgsLayoutPoint | ||
%End | ||
|
||
void setGridPen( const QPen &pen ); | ||
%Docstring | ||
Sets the ``pen`` used for drawing page/snap grids. | ||
.. seealso:: gridPen() | ||
.. seealso:: setGridStyle() | ||
%End | ||
|
||
QPen gridPen() const; | ||
%Docstring | ||
Returns the pen used for drawing page/snap grids. | ||
.. seealso:: setGridPen() | ||
.. seealso:: gridStyle() | ||
:rtype: QPen | ||
%End | ||
|
||
void setGridStyle( const GridStyle style ); | ||
%Docstring | ||
Sets the ``style`` used for drawing the page/snap grids. | ||
.. seealso:: gridStyle() | ||
.. seealso:: setGridPen() | ||
%End | ||
|
||
GridStyle gridStyle() const; | ||
%Docstring | ||
Returns the style used for drawing the page/snap grids. | ||
.. seealso:: setGridStyle() | ||
.. seealso:: gridPen() | ||
:rtype: GridStyle | ||
%End | ||
|
||
}; | ||
|
||
/************************************************************************ | ||
* This file has been generated automatically from * | ||
* * | ||
* src/core/layout/qgslayoutsnapper.h * | ||
* * | ||
* Do not edit manually ! Edit header and run scripts/sipify.pl again * | ||
************************************************************************/ |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Oops, something went wrong.