亚洲欧美第一页_禁久久精品乱码_粉嫩av一区二区三区免费野_久草精品视频

? 歡迎來到蟲蟲下載站! | ?? 資源下載 ?? 資源專輯 ?? 關(guān)于我們
? 蟲蟲下載站

?? qcursor.cpp

?? qt-x11-opensource-src-4.1.4.tar.gz源碼
?? CPP
字號(hào):
/******************************************************************************** Copyright (C) 1992-2006 Trolltech ASA. All rights reserved.**** This file is part of the QtGui module of the Qt Toolkit.**** This file may be used under the terms of the GNU General Public** License version 2.0 as published by the Free Software Foundation** and appearing in the file LICENSE.GPL included in the packaging of** this file.  Please review the following information to ensure GNU** General Public Licensing requirements will be met:** http://www.trolltech.com/products/qt/opensource.html**** If you are unsure which license is appropriate for your use, please** review the following information:** http://www.trolltech.com/products/qt/licensing.html or contact the** sales department at sales@trolltech.com.**** This file is provided AS IS with NO WARRANTY OF ANY KIND, INCLUDING THE** WARRANTY OF DESIGN, MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE.******************************************************************************/#include "qcursor.h"#ifndef QT_NO_CURSOR#include <qapplication.h>#include <qbitmap.h>#include <qimage.h>#include <qdatastream.h>#include <qvariant.h>#include <private/qcursor_p.h>/*!    \class QCursor    \brief The QCursor class provides a mouse cursor with an arbitrary    shape.    \ingroup appearance    \ingroup shared    \mainclass    This class is mainly used to create mouse cursors that are    associated with particular widgets and to get and set the position    of the mouse cursor.    Qt has a number of standard cursor shapes, but you can also make    custom cursor shapes based on a QBitmap, a mask and a hotspot.    To associate a cursor with a widget, use QWidget::setCursor(). To    associate a cursor with all widgets (normally for a short period    of time), use QApplication::setOverrideCursor().    To set a cursor shape use QCursor::setShape() or use the QCursor    constructor which takes the shape as argument, or you can use one    of the predefined cursors defined in the \l Qt::CursorShape enum.    If you want to create a cursor with your own bitmap, either use    the QCursor constructor which takes a bitmap and a mask or the    constructor which takes a pixmap as arguments.    To set or get the position of the mouse cursor use the static    methods QCursor::pos() and QCursor::setPos().    \img cursors.png Cursor Shapes    \section1 A Note for X11 Users    On X11, Qt supports the \link    http://www.xfree86.org/4.3.0/Xcursor.3.html Xcursor\endlink    library, which allows for full color icon themes. The table below    shows the cursor name used for each Qt::CursorShape value. If a    cursor cannot be found using the name shown below, a standard X11    cursor will be used instead. Note: X11 does not provide    appropriate cursors for all possible Qt::CursorShape values. It    is possible that some cursors will be taken from the Xcursor    theme, while others will use an internal bitmap cursor.    \table    \header \o Qt::CursorShape Values   \o Cursor Names    \row \o Qt::ArrowCursor             \o \c left_ptr    \row \o Qt::UpArrowCursor           \o \c up_arrow    \row \o Qt::CrossCursor             \o \c cross    \row \o Qt::WaitCursor              \o \c wait    \row \o Qt::BusyCursor              \o \c left_ptr_watch    \row \o Qt::IBeamCursor             \o \c ibeam    \row \o Qt::SizeVerCursor           \o \c size_ver    \row \o Qt::SizeHorCursor           \o \c size_hor    \row \o Qt::SizeBDiagCursor         \o \c size_bdiag    \row \o Qt::SizeFDiagCursor         \o \c size_fdiag    \row \o Qt::SizeAllCursor           \o \c size_all    \row \o Qt::SplitVCursor            \o \c split_v    \row \o Qt::SplitHCursor            \o \c split_h    \row \o Qt::PointingHandCursor      \o \c pointing_hand    \row \o Qt::ForbiddenCursor         \o \c forbidden    \row \o Qt::WhatsThisCursor         \o \c whats_this    \endtable    \sa QWidget, {fowler}{GUI Design Handbook: Cursors}*//*!    \fn HCURSOR_or_HANDLE QCursor::handle() const    Returns a handle to the cursor.    \warning Using the value returned by this function is not    portable.    \sa Qt::HANDLE*//*!    \fn QCursor::QCursor(HCURSOR cursor)    Constructs a Qt cursor from the given Windows \a cursor.    \warning This function is only available on Windows.    \sa handle()*//*!    \fn QCursor::QCursor(Qt::HANDLE handle)    Constructs a Qt cursor from the given \a handle.    \warning This function is only available on X11.    \sa handle()*//*****************************************************************************  QCursor stream functions *****************************************************************************/#ifndef QT_NO_DATASTREAM/*!    \fn QDataStream &operator<<(QDataStream &stream, const QCursor &cursor)    \relates QCursor    Writes the \a cursor to the \a stream.    \sa {Format of the QDataStream operators}*/QDataStream &operator<<(QDataStream &s, const QCursor &c){    s << (qint16)c.shape();                        // write shape id to stream    if (c.shape() == Qt::BitmapCursor) {                // bitmap cursor        bool isPixmap = false;        if (s.version() >= 7) {            isPixmap = !c.pixmap().isNull();            s << isPixmap;        }        if (isPixmap)            s << c.pixmap();        else            s << *c.bitmap() << *c.mask();        s << c.hotSpot();    }    return s;}/*!    \fn QDataStream &operator>>(QDataStream &stream, QCursor &cursor)    \relates QCursor    Reads the \a cursor from the \a stream.    \sa {Format of the QDataStream operators}*/QDataStream &operator>>(QDataStream &s, QCursor &c){    qint16 shape;    s >> shape;                                        // read shape id from stream    if (shape == Qt::BitmapCursor) {                // read bitmap cursor        bool isPixmap = false;        if (s.version() >= 7)            s >> isPixmap;        if (isPixmap) {            QPixmap pm;            QPoint hot;            s >> pm >> hot;            c = QCursor(pm, hot.x(), hot.y());        } else {            QBitmap bm, bmm;            QPoint hot;            s >> bm >> bmm >> hot;            c = QCursor(bm, bmm, hot.x(), hot.y());        }    } else {        c.setShape((Qt::CursorShape)shape);                // create cursor with shape    }    return s;}#endif // QT_NO_DATASTREAM/*!    Constructs a custom pixmap cursor.    \a pixmap is the image. It is usual to give it a mask (set using    QPixmap::setMask()). \a hotX and \a hotY define the cursor's hot    spot.    If \a hotX is negative, it is set to the \c{pixmap().width()/2}.    If \a hotY is negative, it is set to the \c{pixmap().height()/2}.    Valid cursor sizes depend on the display hardware (or the    underlying window system). We recommend using 32 x 32 cursors,    because this size is supported on all platforms. Some platforms    also support 16 x 16, 48 x 48, and 64 x 64 cursors.    \sa QPixmap::QPixmap(), QPixmap::setMask()*/QCursor::QCursor(const QPixmap &pixmap, int hotX, int hotY)    : d(0){    QImage img = pixmap.toImage().convertToFormat(QImage::Format_Indexed8, Qt::ThresholdDither|Qt::AvoidDither);    QBitmap bm = QBitmap::fromImage(img, Qt::ThresholdDither|Qt::AvoidDither);    QBitmap bmm = pixmap.mask();    if (!bmm.isNull()) {        QBitmap nullBm;        bm.setMask(nullBm);    }    else if (!pixmap.mask().isNull()) {        QImage mimg = pixmap.mask().toImage().convertToFormat(QImage::Format_Indexed8, Qt::ThresholdDither|Qt::AvoidDither);        bmm = QBitmap::fromImage(mimg, Qt::ThresholdDither|Qt::AvoidDither);    }    else {        bmm = QBitmap(bm.size());        bmm.fill(Qt::color1);    }    d = QCursorData::setBitmap(bm, bmm, hotX, hotY);    d->pixmap = pixmap;}/*!    Constructs a custom bitmap cursor.    \a bitmap and    \a mask make up the bitmap.    \a hotX and    \a hotY define the cursor's hot spot.    If \a hotX is negative, it is set to the \c{bitmap().width()/2}.    If \a hotY is negative, it is set to the \c{bitmap().height()/2}.    The cursor \a bitmap (B) and \a mask (M) bits are combined like this:    \list    \o B=1 and M=1 gives black.    \o B=0 and M=1 gives white.    \o B=0 and M=0 gives transparent.    \o B=1 and M=0 gives an XOR'd result.    \endlist    Use the global Qt color Qt::color0 to draw 0-pixels and Qt::color1 to    draw 1-pixels in the bitmaps.    Valid cursor sizes depend on the display hardware (or the    underlying window system). We recommend using 32 x 32 cursors,    because this size is supported on all platforms. Some platforms    also support 16 x 16, 48 x 48, and 64 x 64 cursors.    \sa QBitmap::QBitmap(), QBitmap::setMask()*/QCursor::QCursor(const QBitmap &bitmap, const QBitmap &mask, int hotX, int hotY)    : d(0){    d = QCursorData::setBitmap(bitmap, mask, hotX, hotY);}QCursorData *qt_cursorTable[Qt::LastCursor + 1];bool QCursorData::initialized = false;/*! \internal */void QCursorData::cleanup(){    if(!QCursorData::initialized)        return;    for (int shape = 0; shape <= Qt::LastCursor; ++shape) {        delete qt_cursorTable[shape];        qt_cursorTable[shape] = 0;    }    QCursorData::initialized = false;}/*! \internal */void QCursorData::initialize(){    if (QCursorData::initialized)        return;#ifdef Q_WS_MAC    InitCursor();#endif    for (int shape = 0; shape <= Qt::LastCursor; ++shape)        qt_cursorTable[shape] = new QCursorData((Qt::CursorShape)shape);    QCursorData::initialized = true;}/*!    Constructs a cursor with the default arrow shape.*/QCursor::QCursor(){    if (!QCursorData::initialized) {        if (qApp->startingUp()) {            d = 0;            return;        }        QCursorData::initialize();    }    QCursorData *c = qt_cursorTable[0];    c->ref.ref();    d = c;}/*!    Constructs a cursor with the specified \a shape.    See \l Qt::CursorShape for a list of shapes.    \sa setShape()*/QCursor::QCursor(Qt::CursorShape shape)    : d(0){    if (!QCursorData::initialized)        QCursorData::initialize();    setShape(shape);}/*!    Returns the cursor shape identifier. The return value is one of    the \l Qt::CursorShape enum values (cast to an int).    \sa setShape()*/Qt::CursorShape QCursor::shape() const{    if (!QCursorData::initialized)        QCursorData::initialize();    return d->cshape;}/*!    Sets the cursor to the shape identified by \a shape.    See \l Qt::CursorShape for the list of cursor shapes.    \sa shape()*/void QCursor::setShape(Qt::CursorShape shape){    if (!QCursorData::initialized)        QCursorData::initialize();    QCursorData *c = uint(shape) <= Qt::LastCursor ? qt_cursorTable[shape] : 0;    if (!c)        c = qt_cursorTable[0];    c->ref.ref();    if (!d) {        d = c;    } else {        c = qAtomicSetPtr(&d, c);        if (!c->ref.deref())            delete c;    }}/*!    Returns the cursor bitmap, or 0 if it is one of the standard    cursors.*/const QBitmap *QCursor::bitmap() const{    if (!QCursorData::initialized)        QCursorData::initialize();    return d->bm;}/*!    Returns the cursor bitmap mask, or 0 if it is one of the standard    cursors.*/const QBitmap *QCursor::mask() const{    if (!QCursorData::initialized)        QCursorData::initialize();    return d->bmm;}/*!    Returns the cursor pixmap. This is only valid if the cursor is a    pixmap cursor.*/QPixmap QCursor::pixmap() const{    if (!QCursorData::initialized)        QCursorData::initialize();    return d->pixmap;}/*!    Returns the cursor hot spot, or (0, 0) if it is one of the    standard cursors.*/QPoint QCursor::hotSpot() const{    if (!QCursorData::initialized)        QCursorData::initialize();    return QPoint(d->hx, d->hy);}/*!    Constructs a copy of the cursor \a c.*/QCursor::QCursor(const QCursor &c){    if (!QCursorData::initialized)        QCursorData::initialize();    d = c.d;    d->ref.ref();}/*!    Destroys the cursor.*/QCursor::~QCursor(){    if (d && !d->ref.deref())        delete d;}/*!    Assigns \a c to this cursor and returns a reference to this    cursor.*/QCursor &QCursor::operator=(const QCursor &c){    if (!QCursorData::initialized)        QCursorData::initialize();    qAtomicAssign(d, c.d);    return *this;}/*!   Returns the cursor as a QVariant.*/QCursor::operator QVariant() const{    return QVariant(QVariant::Cursor, this);}#endif // QT_NO_CURSOR

?? 快捷鍵說明

復(fù)制代碼 Ctrl + C
搜索代碼 Ctrl + F
全屏模式 F11
切換主題 Ctrl + Shift + D
顯示快捷鍵 ?
增大字號(hào) Ctrl + =
減小字號(hào) Ctrl + -
亚洲欧美第一页_禁久久精品乱码_粉嫩av一区二区三区免费野_久草精品视频
天天色 色综合| www.成人网.com| 成人av在线网| 8v天堂国产在线一区二区| 久久久久久亚洲综合| 亚洲综合激情小说| 国产成人午夜电影网| 欧美色中文字幕| 国产精品国产自产拍在线| 乱一区二区av| 欧美午夜免费电影| 国产精品久久久久影院亚瑟| 日本中文字幕不卡| 精品视频色一区| 成人免费小视频| 国产成人av影院| 欧美精品一区二区三区在线播放 | 久久蜜桃av一区精品变态类天堂| 国产精品国产自产拍高清av| 激情综合网天天干| 91精品国产综合久久精品麻豆 | 日韩一区二区精品葵司在线| 一区二区三区资源| 99久久er热在这里只有精品15 | 日韩一区二区在线看| 亚洲精品视频在线| 色婷婷国产精品综合在线观看| 国产精品网站一区| 成人精品小蝌蚪| 中文字幕免费一区| 国产精品一级片在线观看| 26uuu欧美| 国产精品1区二区.| 中文字幕巨乱亚洲| 91亚洲午夜精品久久久久久| 中文字幕一区二区三区不卡在线| 99久久国产综合精品色伊| 日韩一区中文字幕| 日本精品视频一区二区三区| 亚洲无人区一区| 欧美乱熟臀69xxxxxx| 日韩1区2区日韩1区2区| 日韩免费性生活视频播放| 九九九精品视频| 日本一区二区三级电影在线观看 | 欧美性一区二区| 亚洲一区二区三区四区在线| 欧美私模裸体表演在线观看| 日韩av网站在线观看| 欧美不卡一二三| 成人中文字幕电影| 中文字幕在线一区| 欧美亚洲禁片免费| 美女久久久精品| 国产欧美1区2区3区| 91麻豆国产福利精品| 一区二区三区在线视频播放| 欧美日韩久久不卡| 狠狠色丁香久久婷婷综合_中| 亚洲国产精品传媒在线观看| 色综合中文字幕| 男人的j进女人的j一区| 国产欧美一区二区三区网站| 成人激情免费视频| 亚洲18影院在线观看| 精品国产精品一区二区夜夜嗨| 春色校园综合激情亚洲| 亚洲在线观看免费| 精品国产伦一区二区三区观看方式| 成人黄色软件下载| 午夜国产精品影院在线观看| 国产午夜精品一区二区| 欧美三级欧美一级| 国内成人自拍视频| 亚洲午夜免费视频| 精品久久五月天| 91行情网站电视在线观看高清版| 久久99九九99精品| 亚洲一区二区视频在线| 国产午夜精品一区二区三区嫩草 | 一区二区高清视频在线观看| 日韩欧美国产精品| 91精品福利视频| 国产成人一区二区精品非洲| 婷婷丁香激情综合| 亚洲青青青在线视频| 久久久久亚洲蜜桃| 日韩午夜在线播放| 欧美日韩亚洲不卡| 99久久久免费精品国产一区二区| 狠狠色综合日日| 午夜久久电影网| 亚洲图片欧美激情| 久久久久久久久久久久电影| 欧美一级免费大片| 91久久精品午夜一区二区| 成人一区二区三区中文字幕| 精品综合免费视频观看| 天堂成人国产精品一区| 一区二区视频在线看| 国产精品丝袜在线| 国产亚洲精品超碰| www国产成人| 日韩欧美在线影院| 在线不卡中文字幕播放| 色天使久久综合网天天| 成人av网址在线观看| 东方aⅴ免费观看久久av| 久草中文综合在线| 麻豆精品在线看| 久久国产精品露脸对白| 日本人妖一区二区| 男女男精品网站| 日韩精品视频网| 天堂在线一区二区| 日本网站在线观看一区二区三区| 亚洲一本大道在线| 一区二区三区四区乱视频| 亚洲日本青草视频在线怡红院| 国产精品久久久久久久久久免费看| 久久久久久电影| 国产精品毛片久久久久久| 国产精品久线在线观看| 中文字幕一区二区三区精华液| 亚洲同性同志一二三专区| 综合久久一区二区三区| 中文字幕一区日韩精品欧美| 国产精品亲子乱子伦xxxx裸| 亚洲欧洲在线观看av| 国产精品视频在线看| 中文字幕 久热精品 视频在线 | 亚洲欧美一区二区三区极速播放 | 免费日本视频一区| 精品一区二区免费视频| 大胆欧美人体老妇| 色激情天天射综合网| 欧美高清视频不卡网| 日韩欧美一区二区三区在线| 久久毛片高清国产| 成人免费在线播放视频| 亚洲成人午夜电影| 国内不卡的二区三区中文字幕| 成人一级黄色片| 91久久精品一区二区二区| 欧美精品免费视频| 久久精品日韩一区二区三区| 一区二区中文字幕在线| 日本不卡在线视频| 成人免费观看视频| 欧美三级电影在线观看| 欧美www视频| 亚洲精选视频免费看| 蜜臀久久久99精品久久久久久| 福利电影一区二区| 欧美精品在线一区二区| 中国色在线观看另类| 首页国产欧美日韩丝袜| 福利一区在线观看| 欧美精品三级日韩久久| 国产精品欧美一区二区三区| 五月婷婷另类国产| 不卡一区二区中文字幕| 91精品国产欧美一区二区成人| 国产精品免费av| 日本伊人精品一区二区三区观看方式| 国产1区2区3区精品美女| 欧美猛男超大videosgay| 国产精品情趣视频| 九九精品视频在线看| 在线中文字幕一区| 国产偷国产偷亚洲高清人白洁| 亚洲成av人片一区二区梦乃| 99国产精品视频免费观看| 欧美成人伊人久久综合网| 亚洲视频一区在线| 国产成人免费视频一区| 日韩精品一区二区三区中文精品| 亚洲女人小视频在线观看| 国产乱码一区二区三区| 欧美一区二区三区日韩视频| 亚洲卡通欧美制服中文| 韩国v欧美v日本v亚洲v| 91精品国产综合久久精品性色| 一区二区三区中文字幕精品精品| 国产电影一区二区三区| 日韩一区二区麻豆国产| 日韩av网站免费在线| 欧美美女直播网站| 亚洲第一电影网| 欧美最猛性xxxxx直播| 亚洲视频网在线直播| 99久久精品情趣| 中文字幕成人网| 国产99久久久精品| 国产精品视频在线看| 国产suv一区二区三区88区| 久久一夜天堂av一区二区三区 | 夫妻av一区二区| 久久人人爽爽爽人久久久| 久久99国产精品麻豆|