summaryrefslogtreecommitdiffstats
path: root/krita/ui/kis_cursor.h
blob: b4e7e3447dd23bb931e0aa2150dd082fb35e6a5b (plain)
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
/*
 *  kis_cursor.h - part of KImageShop
 *
 *  Copyright (c) 1999 Matthias Elter <elter@kde.org>
 *  Copyright (c) 2004 Adrian Page <adrian@pagenet.plus.com>
 *
 *  This program is free software; you can redistribute it and/or modify
 *  it under the terms of the GNU General Public License as published by
 *  the Free Software Foundation; either version 2 of the License, or
 *  (at your option) any later version.
 *
 *  This program is distributed in the hope that it will be useful,
 *  but WITHOUT ANY WARRANTY; without even the implied warranty of
 *  MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
 *  GNU General Public License for more details.
 *
 *  You should have received a copy of the GNU General Public License
 *  along with this program; if not, write to the Free Software
 *  Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA.
 */

#ifndef __kis_cursor_h__
#define __kis_cursor_h__
#include <koffice_export.h>
class QCursor;

class KRITACORE_EXPORT KisCursor
{

public:

    KisCursor();

    // Predefined Qt cursors.
    static QCursor arrowCursor();         // standard arrow cursor
    static QCursor upArrowCursor();       // upwards arrow
    static QCursor crossCursor();         // crosshair
    static QCursor waitCursor();          // hourglass/watch
    static QCursor ibeamCursor();         // ibeam/text entry
    static QCursor sizeVerCursor();       // vertical resize
    static QCursor sizeHorCursor();       // horizontal resize
    static QCursor sizeBDiagCursor();     // diagonal resize (/)
    static QCursor sizeFDiagCursor();     // diagonal resize (\)
    static QCursor sizeAllCursor();       // all directions resize
    static QCursor blankCursor();         // blank/invisible cursor
    static QCursor splitVCursor();        // vertical splitting
    static QCursor splitHCursor();        // horziontal splitting
    static QCursor pointingHandCursor();  // a pointing hand

    // Existing custom KimageShop cursors. Use the 'load' function for all new cursors.
    static QCursor moveCursor();          // move tool cursor
    static QCursor penCursor();           // pen tool cursor
    static QCursor brushCursor();         // brush tool cursor
    static QCursor airbrushCursor();      // airbrush tool cursor
    static QCursor eraserCursor();        // eraser tool cursor
    static QCursor fillerCursor();        // filler tool cursor
    static QCursor pickerCursor();        // color picker cursor
    static QCursor pickerPlusCursor();        // color picker cursor
    static QCursor pickerMinusCursor();        // color picker cursor
    static QCursor colorChangerCursor();  // color changer tool cursor
    static QCursor selectCursor();        // select cursor
    static QCursor zoomCursor();          // zoom tool cursor
    static QCursor handCursor();          // hand tool cursor
    static QCursor openHandCursor();      // Pan tool cursor
    static QCursor closedHandCursor();    // Pan tool cursor
    static QCursor rotateCursor();    // Transform tool cursor

    // Load a cursor from an image file. The image should have an alpha channel
    // and will be converted to black and white on loading. Any format loadable by
    // QImage can be used.
    static QCursor load(const QString & imageFilename, int hotspotX = -1, int hotspotY = -1);
};
#endif // __kis_cursor_h__