[prev in list] [next in list] [prev in thread] [next in thread] 

List:       kde-core-devel
Subject:    Re: RFC: ideas for a simple OpenDocument API
From:       Sebastian Sauer <mail () dipe ! org>
Date:       2007-01-12 3:50:12
Message-ID: 200701120450.12965.mail () dipe ! org
[Download RAW message or body]

Kevin Krammer wrote:
>> So, that's
>> possible already and you don't need to go through Kross since the
>> KWord2+KSpread2 scripting plugins (in trunk (kword|
>> kspread)/plugins/scripting/Module.(h|cpp) - see also e.g.
>> http://wiki.koffice.org/index.php?title=KSpread/Scripting ) offer a nice
>> on Qt's meta* based interface. So, pure calling of slots should do the
>> trick without the need to link against those libs. IMO it should also be
>> quit possible to use also QtScript to access those both libs and there
>> functionality dynamic...
> 
> Hmm, I am afraid I don't understand. Do you mean applications should (try
> to) dlopen the plugins and use them for ODF manipulation when successfull?
> 
> Don't they require a running KWord/KSpread instantance?

No running instance is needed. So, all that would be needed for the case of 
KSpread is to have KSpread installed and then you are able to dlopen the
	extern QObject* krossmodule()
(located in koffice/kspread/plugins/scripting/ScriptingModule.cpp) within the 
module. The returned QObject then provides all we need to 
load/save/manipulate ODS files by using Qt's Meta-Object system. Compared to 
my prev posting I see even one more way to use it then;
* via Kross
* via KjsEmbed
* via QtScript (I didn't test yet if it's mature enough)
* via pure Qt with some dirty-hacks using QMetaObject::invokeMethod, etc. (ok, 
that's very dirty since there are no compiletime-checks, but I expect to have 
that API for a long time stable once KO 2.0 is released anyway).

-- 
Sebastian Sauer aka dipesh[sebsauer]
http://www.dipe.org/public_key.asc
Fingerprint: 8F1E 219B 16E6 4EC7 29CC F408 E193 65E2 9134 2221
Coder in http://www.koffice.org && http://www.kmldonkey.org
[prev in list] [next in list] [prev in thread] [next in thread] 

Configure | About | News | Add a list | Sponsored by KoreLogic