Skip to content

Commit

Permalink
Fix PyQGIS docs for colorFromMimeData
Browse files Browse the repository at this point in the history
  • Loading branch information
nyalldawson committed Oct 23, 2020
1 parent f86a2e9 commit 395718f
Show file tree
Hide file tree
Showing 2 changed files with 5 additions and 8 deletions.
Expand Up @@ -566,16 +566,14 @@ mime data's text with the color's hex code.
.. versionadded:: 2.5
%End

static QColor colorFromMimeData( const QMimeData *data, bool &hasAlpha );
static QColor colorFromMimeData( const QMimeData *data, bool &hasAlpha /Out/ );
%Docstring
Attempts to parse mime data as a color

:param data: mime data to parse
:param hasAlpha: will be set to ``True`` if mime data was interpreted as a color containing
an explicit alpha value

:return: valid color if mimedata could be interpreted as a color, otherwise an
invalid color
:return: - valid color if mimedata could be interpreted as a color, otherwise an invalid color
- hasAlpha: will be set to ``True`` if mime data was interpreted as a color containing an explicit alpha value

.. versionadded:: 2.5
%End
Expand Down
5 changes: 2 additions & 3 deletions src/core/symbology/qgssymbollayerutils.h
Expand Up @@ -537,11 +537,10 @@ class CORE_EXPORT QgsSymbolLayerUtils
* \param data mime data to parse
* \param hasAlpha will be set to TRUE if mime data was interpreted as a color containing
* an explicit alpha value
* \returns valid color if mimedata could be interpreted as a color, otherwise an
* invalid color
* \returns valid color if mimedata could be interpreted as a color, otherwise an invalid color
* \since QGIS 2.5
*/
static QColor colorFromMimeData( const QMimeData *data, bool &hasAlpha );
static QColor colorFromMimeData( const QMimeData *data, bool &hasAlpha SIP_OUT );

/**
* Attempts to parse mime data as a list of named colors
Expand Down

0 comments on commit 395718f

Please sign in to comment.