[Panel-devel] Javascript Plasmoids

Henry Stanaland stanaland at gmail.com
Tue Nov 20 19:20:30 CET 2007


>
>
> On Tuesday 20 Nov 2007, Henry Stanaland wrote:
> > Hi plaz-masters:
> >
> > I am trying to re-write my crappy calculator in Javascript.  However,
> > I can't seem to find a way to add normal widgets to a plasmoid
> > using Javascript.  It seems using the .ui files causes the UI
> > definitions to open in a popup.  I think what I need is to be able to
> > define a .ui file for the plasmoid itself....or atleast to be able to
> > instantiate random QT widgets via Javascript.  Anybody have any
> > helpful info?
>
> Until Qt 4.4, you can't just put QWidgets on a QGraphicsScene, ie: you
> can't add "normal" widgets to a plasmoid.


I see.  That explains a couple of things.


>
> There are a number of Plasma widgets in libplasma that you _can_ add to
> a plasmoid, among them Plasma::PushButton [0] and Plasma::Label [1],
> which I'd guess would be the main ones you'd need.
>
>
Well, that still leaves me the question: how does one add Plasma::PushButton
and other Plasma widgets from Javascript.  Currently, the only objects
instantiated
from Javascript examples have a wrapper class here:

trunk/playground/base/plasma/applets/script/qtgui/*

Does somebody need to write a wrapper class for the Plasma widgets or
is this already done somewhere?

-Henry Stanaland
-------------- next part --------------
An HTML attachment was scrubbed...
URL: http://mail.kde.org/pipermail/panel-devel/attachments/20071120/85473b1c/attachment.html 


More information about the Panel-devel mailing list