Marquee can now be paused and restarted.
5 #include <QQuickWindow>
8 class MiniDisplay : public QQuickItem
11 Q_DISABLE_COPY(MiniDisplay)
13 Q_PROPERTY(bool isOpen READ isOpen NOTIFY statusChanged)
14 Q_PROPERTY(bool offScreenMode READ offScreenMode WRITE setOffScreenMode NOTIFY offScreenModeChanged)
15 Q_PROPERTY(QFont font READ font WRITE setFont NOTIFY fontChanged)
16 Q_PROPERTY(QString vendor READ vendor)
17 Q_PROPERTY(QString product READ product)
18 Q_PROPERTY(QString serialNumber READ serialNumber)
19 Q_PROPERTY(int brightness READ brightness WRITE setBrightness NOTIFY brightnessChanged)
20 Q_PROPERTY(int maxBrightness READ maxBrightness NOTIFY opened)
21 Q_PROPERTY(int minBrightness READ minBrightness NOTIFY opened)
22 Q_PROPERTY(bool frameDifferencing READ frameDifferencing WRITE setFrameDifferencing NOTIFY frameDifferencingChanged)
24 Q_PROPERTY(QPoint framePosition READ framePosition WRITE setFramePosition NOTIFY closed)
28 Q_INVOKABLE void open();
29 Q_INVOKABLE void close();
31 Q_INVOKABLE void clear();
32 Q_INVOKABLE void fill();
33 Q_INVOKABLE void swapBuffers();
35 Q_INVOKABLE void requestPowerStatus();
36 Q_INVOKABLE void requestDeviceId();
37 Q_INVOKABLE void requestFirmwareVersion();
39 Q_INVOKABLE void renderOwnWindow();
40 Q_INVOKABLE void renderWindow(QQuickWindow* aWindow);
41 Q_INVOKABLE void renderImage(QImage* aImage);
43 Q_INVOKABLE void connectWindow(QQuickWindow* aWindow, QJSValue aFunction);
45 Q_INVOKABLE void setPixel(int x, int y, bool on);
53 QFont font() const {return iFont;}
54 void setFont(const QFont& aFont);
57 void setOffScreenMode(bool aOn);
61 QString serialNumber();
63 int maxBrightness() const;
64 int minBrightness() const;
65 int brightness() const;
66 void setBrightness(int aBrightness);
68 bool frameDifferencing() const;
69 void setFrameDifferencing(bool aOn);
71 QPoint framePosition() const;
72 void setFramePosition(const QPoint& aPoint);
75 void onAfterAnimating();
84 void brightnessChanged();
85 void offScreenModeChanged();
86 void frameDifferencingChanged();
88 void powerStatus(bool powerOn);
89 void deviceId(QString deviceId);
90 void firmwareVersion(QString version);
97 MiniDisplay(QQuickItem *parent = 0);
105 QPoint iFramePosition;
106 QJSValue iAfterAnimatingCallback;
107 QQuickWindow* iWindow;
110 #endif // MINIDISPLAY_H