1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 52 53 54 55 56 57 58 59 60 61 62 63 64 65 66 67 68 69 70 71 72 73 74 75 76 77 78 79 80 81 82 83 84 85 86 87 88 89 90 91 92 93 94 95 96 97 98 99 100 101 102 103 104 105 106 107 108 109 110 111 112 113 114 115 116 117 118 119 120 121 122 123 124 125 126 127 128 129 130 131 132 133 134 135 136 137 138 139 140 141 142 143 144 145 146 147 148 149 150 151 152 153 154 155 156 157 158 159 160 161 162 163 164 165 166 167 168 169 170 171 172 173 174 175 176 177 178 179 180 181 182 183 184 185 186 187 188 189 190 191 192 193 194 195 196 197 198 199 200 201 202 203 204 205 206 207 208 209 210 211 212 213 214 215 216 217 218 219 220 221 222 223 224 225 226 227 228 229 230 231 232 233 234 235 236 237 238 239 240
|
/************************************************************************
* This file has been generated automatically from *
* *
* src/core/qgstablecell.h *
* *
* Do not edit manually ! Edit header and run scripts/sipify.py again *
************************************************************************/
class QgsTableCell
{
%Docstring(signature="appended")
Encapsulates the contents and formatting of a single table cell.
.. versionadded:: 3.12
%End
%TypeHeaderCode
#include "qgstablecell.h"
%End
public:
QgsTableCell( const QVariant &content = QVariant() );
%Docstring
Constructor for QgsTableCell, with the specified ``content``.
%End
QgsTableCell( const QgsTableCell &other );
~QgsTableCell();
QVariant content() const;
%Docstring
Returns the cell's content.
.. seealso:: :py:func:`setContent`
%End
void setContent( const QVariant &content );
%Docstring
Sets the cell's ``content``.
.. seealso:: :py:func:`content`
%End
QColor backgroundColor() const;
%Docstring
Returns the cell's background color, or an invalid color if a default
color should be used for the background.
.. seealso:: :py:func:`setBackgroundColor`
%End
void setBackgroundColor( const QColor &color );
%Docstring
Sets the cell's background ``color``.
Set an invalid ``color`` if a default color should be used for the
background.
.. seealso:: :py:func:`backgroundColor`
%End
QColor foregroundColor() const;
%Docstring
Returns the cell's foreground color, or an invalid color if a default
color should be used for the foreground.
.. seealso:: :py:func:`setForegroundColor`
%End
void setForegroundColor( const QColor &color );
%Docstring
Sets the cell's foreground ``color``.
Set an invalid ``color`` if a default color should be used for the
foreground.
.. seealso:: :py:func:`foregroundColor`
%End
QgsTextFormat textFormat() const;
%Docstring
Returns the cell's text format.
.. note::
The text format will only be used if :py:func:`~QgsTableCell.hasTextFormat` returns ``True``.
.. seealso:: :py:func:`setTextFormat`
.. versionadded:: 3.16
%End
void setTextFormat( const QgsTextFormat &format );
%Docstring
Sets the cell's text ``format``.
.. note::
The text format will only be used if :py:func:`~QgsTableCell.hasTextFormat` returns ``True``.
.. seealso:: :py:func:`textFormat`
.. versionadded:: 3.16
%End
const QgsNumericFormat *numericFormat() const;
%Docstring
Returns the numeric format used for numbers in the cell, or ``None`` if
no format is set.
.. seealso:: :py:func:`setNumericFormat`
%End
void setNumericFormat( QgsNumericFormat *format /Transfer/ );
%Docstring
Sets the numeric ``format`` used for numbers in the cell, or ``None`` if
no specific format is set.
Ownership of ``format`` is transferred to the cell.
.. seealso:: :py:func:`numericFormat`
%End
Qt::Alignment horizontalAlignment() const;
%Docstring
Returns the horizontal alignment for text in the cell.
.. seealso:: :py:func:`setHorizontalAlignment`
.. seealso:: :py:func:`verticalAlignment`
.. versionadded:: 3.16
%End
void setHorizontalAlignment( Qt::Alignment alignment );
%Docstring
Sets the horizontal ``alignment`` for text in the cell.
.. seealso:: :py:func:`horizontalAlignment`
.. seealso:: :py:func:`setVerticalAlignment`
.. versionadded:: 3.16
%End
Qt::Alignment verticalAlignment() const;
%Docstring
Returns the vertical alignment for text in the cell.
.. seealso:: :py:func:`setVerticalAlignment`
.. seealso:: :py:func:`horizontalAlignment`
.. versionadded:: 3.16
%End
void setVerticalAlignment( Qt::Alignment alignment );
%Docstring
Sets the vertical ``alignment`` for text in the cell.
.. seealso:: :py:func:`verticalAlignment`
.. seealso:: :py:func:`setHorizontalAlignment`
.. versionadded:: 3.16
%End
void setSpan( int rowSpan, int columnSpan );
%Docstring
Sets the row and column span for the cell.
.. seealso:: :py:func:`rowSpan`
.. seealso:: :py:func:`columnSpan`
.. versionadded:: 3.40
%End
int rowSpan() const;
%Docstring
Returns the row span for the cell.
.. seealso:: :py:func:`columnSpan`
.. seealso:: :py:func:`setSpan`
.. versionadded:: 3.40
%End
int columnSpan() const;
%Docstring
Returns the column span for the cell.
.. seealso:: :py:func:`rowSpan`
.. seealso:: :py:func:`setSpan`
.. versionadded:: 3.40
%End
QVariantMap properties( const QgsReadWriteContext &context ) const;
%Docstring
Returns the properties of the cell.
.. seealso:: :py:func:`setProperties`
%End
void setProperties( const QVariantMap &properties, const QgsReadWriteContext &context );
%Docstring
Sets the ``properties`` for the cell.
.. seealso:: :py:func:`properties`
%End
SIP_PYOBJECT __repr__();
%MethodCode
QString str = QStringLiteral( "<QgsTableCell: %1>" ).arg( sipCpp->content().toString() );
sipRes = PyUnicode_FromString( str.toUtf8().constData() );
%End
};
typedef QVector<QgsTableCell> QgsTableRow;
typedef QVector<QVector<QgsTableCell>> QgsTableContents;
/************************************************************************
* This file has been generated automatically from *
* *
* src/core/qgstablecell.h *
* *
* Do not edit manually ! Edit header and run scripts/sipify.py again *
************************************************************************/
|