From blalor at bravo5.org Sat Aug 6 14:41:16 2005 From: blalor at bravo5.org (Brian Lalor) Date: Sat, 6 Aug 2005 09:41:16 -0500 Subject: [TxMt Plugins] Re: Run command on Event and other stuff In-Reply-To: <8A6A7D66-CDFD-4849-8127-F9416F96CD32@macromates.com> References: <5207aba805080323472b04bada@mail.gmail.com> <8A6A7D66-CDFD-4849-8127-F9416F96CD32@macromates.com> Message-ID: On Aug 5, 2005, at 3:55 AM, Allan Odgaard wrote: > Currently there are no hooks for these things, but it could happen > through a plugin. Something which is soon to debut -- are you > familiar with writing Objective-C? if so, I'd suggest subscribing > to textmate-plugins [1] (and there should soon be the required > notifications by means of a plugin). Does this mean plugins will now be implemented in ObjC instead of Java? Can we use Python and PyObjC? -- Brian Lalor / blalor at bravo5.org Notmeflex (nŏt mē´ flěks) n. The involuntary act of hitting the brakes when you see a cop, regardless of whether you're speeding or not. From cryo at cyanite.org Sat Aug 6 14:56:43 2005 From: cryo at cyanite.org (Sune Foldager) Date: Sat, 6 Aug 2005 16:56:43 +0200 Subject: [TxMt Plugins] Re: Run command on Event and other stuff In-Reply-To: References: <5207aba805080323472b04bada@mail.gmail.com> <8A6A7D66-CDFD-4849-8127-F9416F96CD32@macromates.com> Message-ID: On 06/08/2005, at 16.41, Brian Lalor wrote: > On Aug 5, 2005, at 3:55 AM, Allan Odgaard wrote: >> Currently there are no hooks for these things, but it could happen >> through a plugin. Something which is soon to debut -- are you >> familiar with writing Objective-C? if so, I'd suggest subscribing >> to textmate-plugins [1] (and there should soon be the required >> notifications by means of a plugin). > > Does this mean plugins will now be implemented in ObjC instead of > Java? Can we use Python and PyObjC? Java? You mean JavaScript, and the html view extensions? -- Sune. From allan at macromates.com Sat Aug 6 15:06:24 2005 From: allan at macromates.com (Allan Odgaard) Date: Sat, 6 Aug 2005 17:06:24 +0200 Subject: [TxMt Plugins] Re: Run command on Event and other stuff In-Reply-To: References: <5207aba805080323472b04bada@mail.gmail.com> <8A6A7D66-CDFD-4849-8127-F9416F96CD32@macromates.com> Message-ID: On 06/08/2005, at 16.41, Brian Lalor wrote: >> Currently there are no hooks for these things, but it could happen >> through a plugin. Something which is soon to debut -- are you >> familiar with writing Objective-C? if so, I'd suggest subscribing >> to textmate-plugins [1] (and there should soon be the required >> notifications by means of a plugin). > Does this mean plugins will now be implemented in ObjC instead of > Java? Can we use Python and PyObjC? The plugin will be a bundle (OS bundle, not tmbundle) with a principal class that TM loads. AFAIK OS X allows this class to be written in either Java or Objective-C. In practice you could make a plugin that has the implementation in whatever language you want, as long as it's possible to bridge to the obj-c runtime. From timshadel at gmail.com Sat Aug 6 17:50:07 2005 From: timshadel at gmail.com (Tim Shadel) Date: Sat, 6 Aug 2005 10:50:07 -0700 Subject: [TxMt Plugins] Re: Run command on Event and other stuff In-Reply-To: References: <5207aba805080323472b04bada@mail.gmail.com> <8A6A7D66-CDFD-4849-8127-F9416F96CD32@macromates.com> Message-ID: <5207aba805080610503cb20fc9@mail.gmail.com> On 8/6/05, Allan Odgaard wrote: > On 06/08/2005, at 16.41, Brian Lalor wrote: > > >> Currently there are no hooks for these things, but it could happen > >> through a plugin. Something which is soon to debut -- are you > >> familiar with writing Objective-C? if so, I'd suggest subscribing > >> to textmate-plugins [1] (and there should soon be the required > >> notifications by means of a plugin). > > Does this mean plugins will now be implemented in ObjC instead of > > Java? Can we use Python and PyObjC? > > The plugin will be a bundle (OS bundle, not tmbundle) with a > principal class that TM loads. AFAIK OS X allows this class to be > written in either Java or Objective-C. In practice you could make a > plugin that has the implementation in whatever language you want, as > long as it's possible to bridge to the obj-c runtime. So I'll be able to write my plugin in Java? Any pointers to docs on how to do this or where to start? I know Java already, so I'd rather not try Objective-C for a small one-off project if I can avoid it (though I'm sure I'll want to at some point...). Thanks, Tim From allan at macromates.com Sat Aug 6 18:31:09 2005 From: allan at macromates.com (Allan Odgaard) Date: Sat, 6 Aug 2005 20:31:09 +0200 Subject: [TxMt Plugins] Re: Run command on Event and other stuff In-Reply-To: <5207aba805080610503cb20fc9@mail.gmail.com> References: <5207aba805080323472b04bada@mail.gmail.com> <8A6A7D66-CDFD-4849-8127-F9416F96CD32@macromates.com> <5207aba805080610503cb20fc9@mail.gmail.com> Message-ID: <4494917F-2589-4786-AF52-6A9B44944E38@macromates.com> On 06/08/2005, at 19.50, Tim Shadel wrote: > So I'll be able to write my plugin in Java? [...] I think so yes -- as for doc pointers, I'd have to find that at developer.apple.com myself ;) From chris at cjack.com Sat Aug 6 19:08:37 2005 From: chris at cjack.com (Chris Thomas) Date: Sat, 6 Aug 2005 12:08:37 -0700 Subject: [TxMt Plugins] Java (was Re: Run command on Event and other stuff) In-Reply-To: <5207aba805080610503cb20fc9@mail.gmail.com> References: <5207aba805080323472b04bada@mail.gmail.com> <8A6A7D66-CDFD-4849-8127-F9416F96CD32@macromates.com> <5207aba805080610503cb20fc9@mail.gmail.com> Message-ID: <17909BA3-7B61-4081-BA76-B7CF4ECD633C@cjack.com> On Aug 6, 2005, at 10:50 AM, Tim Shadel wrote: > So I'll be able to write my plugin in Java? I'm dubious about it, for several reasons. The most important one in this context is probably that the Cocoa Java bridge is designed for applications. Even if you can somehow manage to instantiate the Java VM from an Objective-C plugin, you may take an enormous performance hit when your plugin initializes. I think you'll have an easier time with Ruby, Perl, F-script, or Python, all of which are to some degree designed to embed in pre- existing applications, and all of which have some form of supported Objective-C bridge. I don't think it would be too difficult to get RubyCocoa, PyObjC, or F-Script working (no idea about the Perl one -- CamelBones?). (Another reason is that IIRC Apple has said that the Cocoa Java bridge is deprecated, or at least that they have no plans to update it in the future.) My 2¢, Chris