51 #include <private/qcursor_p.h> 240 #ifndef QT_NO_DATASTREAM 259 bool isPixmap =
false;
290 bool isPixmap =
false;
297 c =
QCursor(pm, hot.x(), hot.y());
301 s >> bm >> bmm >> hot;
302 c =
QCursor(bm, bmm, hot.x(), hot.y());
309 #endif // QT_NO_DATASTREAM 409 if (!qt_cursorTable[
shape]->ref.deref())
410 delete qt_cursorTable[
shape];
411 qt_cursorTable[
shape] = 0;
489 c = qt_cursorTable[0];
595 #endif // QT_NO_CURSOR The QVariant class acts like a union for the most common Qt data types.
QImage toImage() const
Converts the pixmap to a QImage.
The QCursor class provides a mouse cursor with an arbitrary shape.
#define QT_END_NAMESPACE
This macro expands to.
QSize size() const
Returns the size of the pixmap.
void setMask(const QBitmap &)
Sets a mask bitmap.
bool ref()
Atomically increments the value of this QAtomicInt.
static QCursorData * setBitmap(const QBitmap &bitmap, const QBitmap &mask, int hotX, int hotY)
The QBitmap class provides monochrome (1-bit depth) pixmaps.
#define QT_BEGIN_NAMESPACE
This macro expands to.
bool deref()
Atomically decrements the value of this QAtomicInt.
QPixmap pixmap() const
Returns the cursor pixmap.
The QImage class provides a hardware-independent image representation that allows direct access to th...
QCursorData * qt_cursorTable[Qt::LastCursor+1]
QCursor & operator=(const QCursor &cursor)
Assigns c to this cursor and returns a reference to this cursor.
static bool startingUp()
Returns true if an application object has not been created yet; otherwise returns false...
int version() const
Returns the version number of the data serialization format.
QPoint hotSpot() const
Returns the cursor hot spot, or (0, 0) if it is one of the standard cursors.
void fill(const QColor &fillColor=Qt::white)
Fills the pixmap with the given color.
QImage convertToFormat(Format f, Qt::ImageConversionFlags flags=Qt::AutoColor) const Q_REQUIRED_RESULT
Returns a copy of the image in the given format.
QBitmap mask() const
Extracts a bitmap mask from the pixmap's alpha channel.
const QBitmap * bitmap() const
Returns the cursor bitmap, or 0 if it is one of the standard cursors.
The QPoint class defines a point in the plane using integer precision.
The QPixmap class is an off-screen image representation that can be used as a paint device...
static QBitmap fromImage(const QImage &image, Qt::ImageConversionFlags flags=Qt::AutoColor)
Returns a copy of the given image converted to a bitmap using the specified image conversion flags...
QCursor()
Constructs a cursor with the default arrow shape.
The QDataStream class provides serialization of binary data to a QIODevice.
bool isNull() const
Returns true if this is a null pixmap; otherwise returns false.
void setShape(Qt::CursorShape newShape)
Sets the cursor to the shape identified by shape.
~QCursor()
Destroys the cursor.
QDataStream & operator<<(QDataStream &out, const QUrl &url)
Writes url url to the stream out and returns a reference to the stream.
const QBitmap * mask() const
Returns the cursor bitmap mask, or 0 if it is one of the standard cursors.
Qt::CursorShape shape() const
Returns the cursor shape identifier.
QDataStream & operator>>(QDataStream &in, QUrl &url)
Reads a url into url from the stream in and returns a reference to the stream.