can qtscript plasmoids load C++ qtscript plugins
Richard Dale
richard.j.dale at gmail.com
Fri Nov 13 11:44:16 CET 2009
On Fri, Nov 13, 2009 at 7:32 AM, Pekka Reijula <reijula at gmail.com> wrote:
> On Monday 09 November 2009, Ian Monroe wrote:
>> I suspect the answer to the subject is "no" since I haven't found a
>> mention of a method to do it. But I also haven't found comprehensive
>> QtScript API docs. :)
> QtScript apidocs are generated in Qt labs project qtscriptgenerator.
>
>> My situation is that I want to write a full chat solution in a
>> qtscript plasmoid using the QtScript Telepathy bindings I wrote. (I'm
>> guessing a dataengine or service for buddy presence and chatting would
>> be pretty crazy right?)
>
> We have created couple of soulutions where this kind of importing bindings
> is possible, so I'm more than a willing to start a discussion how to proceed
> with this kind of ideas in plasma.
>
> Our idea allows creation of plasmoids that have qtscript inside to your own
> plama desktop environment. We can extend plasma in a way that allows user to
> write own script with for example Kate or download it from http url. The
> basic idea is that only text is read and script is evaluated. All that you
> need for this is the qtscript-bindings that for example amarok uses.
>
> What this could offer, would be pretty much the same that the Qt-lively
> project offers in here: http://lively.cs.tut.fi/qt/videos.html
> All the widgets can be run also in our system.
> What do you deveopers think? Should plasma be able add these kind of
> widgets. Or should it be better to just create plasmoid that enables
> importing this kind of functionality inside. I could upload the plasmoid
> sources to kde, but I'm not yet a plasma developer.
The QtScript bindings based on the language indpendent Smoke libraries
are going well, and I'm not far short of being able to wrap the Plasma
apis.
http://gitorious.org/qtscript-smoke/qtscript-smoke
The following items need to be implemented:before we can start on
Plasma support:
* Add a thread to periodically sweep the hash of C++ pointers to
QtScript instances, and delete any entries where 'isValid()' is no
longer true
* Split the bindings up so that there is one QtScript plugin per smoke library
* Rename the project 'JSmoke' (well that's my suggestion for a more
catchy name anyway)
The smoke bindings have a much lower memory footprint and are faster
than the Qt Labs ones. The api is very similar with only minor
differences. Nearly all the Qt Labs QtScript examples now run fine
under the Smoke based version.
I think these bindings would be the most suitable for Ian's telepathy
client, although we would need to implement support for writing
plugins in QtScript.
-- Richard
More information about the Plasma-devel
mailing list