mirror of
https://github.com/qgis/QGIS.git
synced 2025-02-26 00:02:08 -05:00
This is necessary in order to be able to correctly translate between absolute and relative paths deeper in the code - e.g. paths to SVG files used in marker or fill symbols. Until now, relative paths were translated to absolute paths on the fly. This is now changed - paths to files should be always absolute within QGIS objects - and paths only get turned into relative when saving projects. When loading a project, relative paths are translated to absolute paths immediately. This should lower the overall confusion about relative/absolute paths within QGIS, and also allow having different base directories for relative paths (e.g. QML or QPT files may use relative paths to their directory - rather than to the project directory)
70 lines
2.2 KiB
Plaintext
70 lines
2.2 KiB
Plaintext
/************************************************************************
|
|
* This file has been generated automatically from *
|
|
* *
|
|
* src/core/annotations/qgstextannotation.h *
|
|
* *
|
|
* Do not edit manually ! Edit header and run scripts/sipify.pl again *
|
|
************************************************************************/
|
|
|
|
|
|
|
|
|
|
class QgsTextAnnotation: QgsAnnotation
|
|
{
|
|
%Docstring
|
|
An annotation item that displays formatted text from a QTextDocument document.
|
|
.. versionadded:: 3.0
|
|
%End
|
|
|
|
%TypeHeaderCode
|
|
#include "qgstextannotation.h"
|
|
%End
|
|
public:
|
|
|
|
QgsTextAnnotation( QObject *parent /TransferThis/ = 0 );
|
|
%Docstring
|
|
Constructor for QgsTextAnnotation.
|
|
%End
|
|
|
|
virtual QgsTextAnnotation *clone() const /Factory/;
|
|
|
|
|
|
const QTextDocument *document() const;
|
|
%Docstring
|
|
Returns the text document which will be rendered
|
|
within the annotation.
|
|
.. seealso:: setDocument()
|
|
:rtype: QTextDocument
|
|
%End
|
|
|
|
void setDocument( const QTextDocument *doc );
|
|
%Docstring
|
|
Sets the text document which will be rendered
|
|
within the annotation. Ownership is not transferred.
|
|
.. seealso:: document()
|
|
%End
|
|
|
|
virtual void writeXml( QDomElement &elem, QDomDocument &doc, const QgsPathResolver &pathResolver ) const;
|
|
virtual void readXml( const QDomElement &itemElem, const QDomDocument &doc, const QgsPathResolver &pathResolver );
|
|
|
|
static QgsTextAnnotation *create() /Factory/;
|
|
%Docstring
|
|
Returns a new QgsTextAnnotation object.
|
|
:rtype: QgsTextAnnotation
|
|
%End
|
|
|
|
protected:
|
|
|
|
virtual void renderAnnotation( QgsRenderContext &context, QSizeF size ) const;
|
|
|
|
|
|
};
|
|
|
|
/************************************************************************
|
|
* This file has been generated automatically from *
|
|
* *
|
|
* src/core/annotations/qgstextannotation.h *
|
|
* *
|
|
* Do not edit manually ! Edit header and run scripts/sipify.pl again *
|
|
************************************************************************/
|