QGIS/python/PyQt6/core/auto_generated/qgstranslationcontext.sip.in
2024-08-13 20:28:55 +10:00

76 lines
2.2 KiB
Plaintext

/************************************************************************
* This file has been generated automatically from *
* *
* src/core/qgstranslationcontext.h *
* *
* Do not edit manually ! Edit header and run scripts/sipify.py again *
************************************************************************/
class QgsTranslationContext
{
%Docstring(signature="appended")
Used for the collecting of strings from projects for translation and creation of ts files.
.. versionadded:: 3.4
%End
%TypeHeaderCode
#include "qgstranslationcontext.h"
%End
public:
QgsTranslationContext();
QgsProject *project() const;
%Docstring
Returns the project
.. seealso:: :py:func:`setProject`
%End
void setProject( QgsProject *project );
%Docstring
Sets the ``project`` being translated.
.. seealso:: :py:func:`project`
%End
QString fileName() const;
%Docstring
Returns the TS fileName
.. seealso:: :py:func:`setFileName`
%End
void setFileName( const QString &fileName );
%Docstring
Sets the ``fileName`` of the TS file
.. seealso:: :py:func:`fileName`
%End
void registerTranslation( const QString &context, const QString &source );
%Docstring
Registers the ``source`` to be translated. It's the text of the object needed to be translated.
The ``context`` defines in what context the object is used. Means layer name and sub category of object needed to be translated.
%End
void writeTsFile( const QString &locale ) const;
%Docstring
Writes the Ts-file
%End
};
/************************************************************************
* This file has been generated automatically from *
* *
* src/core/qgstranslationcontext.h *
* *
* Do not edit manually ! Edit header and run scripts/sipify.py again *
************************************************************************/