Plasma
appletscript.cpp
Go to the documentation of this file.
155 void AppletScript::showMessage(const QIcon &icon, const QString &message, const MessageButtons buttons)
void setContainmentType(Containment::Type type)
Definition: appletscript.cpp:289
const Package * package() const
Accessor for the associated Package object if any.
Definition: applet.cpp:691
virtual void paintInterface(QPainter *painter, const QStyleOptionGraphicsItem *option, const QRect &contentsRect)
Called when the script should paint the applet.
Definition: appletscript.cpp:63
void setDrawWallpaper(bool drawWallpaper)
set if the containment draws its own wallpaper: it has no effect if the applet is not a containment ...
Definition: appletscript.cpp:269
void showMessage(const QIcon &icon, const QString &message, const MessageButtons buttons)
Definition: appletscript.cpp:155
void setDrawWallpaper(bool drawWallpaper)
Sets whether wallpaper is painted or not.
Definition: containment.cpp:1796
bool contains(const QString &str, Qt::CaseSensitivity cs) const
bool loadScript(const QString &path, const QString &prefix)
Definition: animationscriptengine.cpp:187
virtual void showConfigurationInterface()
Show a configuration dialog.
Definition: appletscript.cpp:130
void setHasConfigurationInterface(bool hasInterface)
Sets whether or not this applet provides a user interface for configuring the applet.
Definition: applet.cpp:1724
const char * name() const
void registerAsDragHandle(QGraphicsItem *item)
Register the widgets that manage mouse clicks but you still want to be able to drag the applet around...
Definition: applet.cpp:1647
void registerAsDragHandle(QGraphicsItem *item)
Definition: appletscript.cpp:162
void setFailedToLaunch(bool failed, const QString &reason=QString())
Definition: appletscript.cpp:116
void unregisterAsDragHandle(QGraphicsItem *item)
Unregister a widget registered with registerAsDragHandle.
Definition: applet.cpp:1657
void unregisterAsDragHandle(QGraphicsItem *item)
Definition: appletscript.cpp:169
bool isEmpty() const
void addRect(const QRectF &rectangle)
The base class for scripting interfaces to be used in loading plasmoids of a given language...
Definition: scriptengine.h:65
Q_INVOKABLE DataEngine * dataEngine(const QString &engine) const
Definition: appletscript.cpp:228
Containment::Type containmentType() const
Definition: appletscript.cpp:278
AppletScript(QObject *parent=0)
Default constructor for an AppletScript.
Definition: appletscript.cpp:40
Animation * loadAnimationFromPackage(const QString &name, QObject *parent)
Loads an animation from the applet package.
Definition: appletscript.cpp:184
Plasma::Applet * applet() const
Returns the Plasma::Applet associated with this script component.
Definition: appletscript.cpp:57
void setConfigurationRequired(bool req, const QString &reason=QString())
Definition: appletscript.cpp:109
void configNeedsSaving() const
Definition: appletscript.cpp:123
void setConfigurationRequired(bool needsConfiguring, const QString &reason=QString())
When the applet needs to be configured before being usable, this method can be called to show a stand...
Definition: applet.cpp:1010
void setFailedToLaunch(bool failed, const QString &reason=QString())
Call this method when the applet fails to launch properly.
Definition: applet.cpp:366
bool isRegisteredAsDragHandle(QGraphicsItem *item)
Definition: applet.cpp:1670
void setContainmentType(Containment::Type type)
Sets the type of this containment.
Definition: containment.cpp:506
virtual void constraintsEvent(Plasma::Constraints constraints)
Called when any of the geometry constraints have been updated.
Definition: appletscript.cpp:81
static QScriptValue type(QScriptContext *ctx, QScriptEngine *eng)
Definition: easingcurve.cpp:63
void setHasConfigurationInterface(bool hasInterface)
Sets whether or not this script has a configuration interface or not.
Definition: appletscript.cpp:102
static Plasma::Animation * create(Animator::Animation type, QObject *parent=0)
Factory to build new animation objects.
Definition: animator.cpp:61
bool isRegisteredAsDragHandle(QGraphicsItem *item)
Definition: appletscript.cpp:176
virtual QPainterPath shape() const
Returns the shape of the widget, defaults to the bounding rect.
Definition: appletscript.cpp:91
void showMessage(const QIcon &icon, const QString &message, const Plasma::MessageButtons buttons)
Shows a message as an overlay of the applet: the message has an icon, text and (optional) buttons...
Definition: applet.cpp:1062
void addStandardConfigurationPages(KConfigDialog *dialog)
This method should be called after a scripting applet has added its own pages to a configuration dial...
Definition: appletscript.cpp:148
bool isAnimationRegistered(const QString &anim)
Definition: animationscriptengine.cpp:60
The base class for plugins that provide backgrounds and applet grouping containers.
Definition: containment.h:72
void configNeedsSaving()
Emitted when an applet has changed values in its configuration and wishes for them to be saved at the...
void setApplet(Plasma::Applet *applet)
Sets the applet associated with this AppletScript.
Definition: appletscript.cpp:52
Q_INVOKABLE QSizeF size() const
Returns the area within which contents can be painted.
Definition: appletscript.cpp:72
QString filePath(const char *fileType, const QString &filename) const
Get the path to a given file.
Definition: package.cpp:213
KConfigDialog * standardConfigurationDialog()
Definition: appletscript.cpp:139
virtual QList< QAction * > contextualActions()
Returns a list of context-related QAction instances.
Definition: appletscript.cpp:86
This file is part of the KDE documentation.
Documentation copyright © 1996-2020 The KDE developers.
Generated on Mon Jun 22 2020 13:23:11 by doxygen 1.8.7 written by Dimitri van Heesch, © 1997-2006
Documentation copyright © 1996-2020 The KDE developers.
Generated on Mon Jun 22 2020 13:23:11 by doxygen 1.8.7 written by Dimitri van Heesch, © 1997-2006
KDE's Doxygen guidelines are available online.