Re: Scripting in Gnome



On Thu, 2004-02-05 at 16:03 +0000, jamie wrote:
> > Well, Bonobo is just a set of standard CORBA interfaces, along with some 
> > conventions on how to tie interfaces together into a component, so it 
> > isn't really separable.  Bonobo without CORBA wouldn't be Bonobo.
> 
> perhaps but looking at it it just seems to be very similar to COM
> (IUnknown interface). An interface could be mapped to a back end.
> 
and one of those standard interfaces, as was mentioned before, is
Bonobo::Application, which I just had a look at. And really, it seems
very well suited for scripting. An app just has to implement that
interface, which is:

		any         message      (in string  msg,
                                          in ArgList args);
                long        newInstance  (in argv_t argv);
                MessageList listMessages ();
                string      getName      ();

so, you can get the list of messages an app accepts very easily from a
client, and then call those messages. The MessageList type contains all
info for every message, such as its name, the argument types, return
type, a description. So, you can even do a GUI frontend to quickly write
scripts and do code completion on the message calling.

So, an app will just have to define the set of messages it will
implement, like OpenNewDocument, SaveCurrentDocument, etc, and clients
can just call those messages.

It looks quite straightforward to me.

cheers




[Date Prev][Date Next]   [Thread Prev][Thread Next]   [Thread Index] [Date Index] [Author Index]