[Geany] Plugin Events Patch

blackdog blackdog at xxxxx
Tue Aug 7 12:11:41 UTC 2007


Hi Nick

Thanks for checking it out.

> > The one issue in the patch is I'm calling
> > on_plugin_notification from on_editor_notification, maybe it should 
> > be
> > a proper callback from g_signal_connect, just like
> > on_editor_notification?
> > 
> To me it seems better to do it like that (maybe more efficient).
> 

Something else to consider is whether the plugin get's to nullify
further events down the line. I'm not sure if this is applicable or not
but you do see sometimes, in other packages, a plugin event returning
false to indicate no further action required.

Cheers bd


On Tue, 07 Aug 2007 12:41:09 +0100
Nick Treleaven <nick.treleaven at btinternet.com> wrote:

> On 08/02/2007 02:25:46 PM, blackdog wrote:
> > 
> > Hi there
> > 
> > I've attached a patch for the last implementation that Nick 
> > suggested.
> > This is just in case the signals idea doesn't pan out, or it's not
> > implemented due to time issues etc. If we know that a plugin
> > implements
> > on_sci_notify the geany implementation can be changed later without
> > affecting anything else - so maybe this patch can suffice in the
> > meantime?
> 
> Thanks for the patch, I'm not sure about applying it yet but I'll
> sort something out in the next few days. I think a clean signals 
> implementation would mean that Geany wouldn't lookup on_sci_notify() 
> itself.
> 
> > The one issue in the patch is I'm calling
> > on_plugin_notification from on_editor_notification, maybe it should 
> > be
> > a proper callback from g_signal_connect, just like
> > on_editor_notification?
> > 
> To me it seems better to do it like that (maybe more efficient).
> 
> > Also, I added a sci_show_autocomplete in this patch too, as it's
> > needed
> > for my plugin.
> > 
> I think that because most filetypes don't need special autocompletion
> I don't think it should be in the plugin API, at least for now. Maybe
> if several plugins want it then it can be added. But I've added 
> scintilla_send_message to the API, so you can copy the wrapper
> function or use it unwrapped.
> 
> Regards,
> Nick
> 
> _______________________________________________
> Geany mailing list
> Geany at uvena.de
> http://uvena.de/cgi-bin/mailman/listinfo/geany


-- 
http://www.blackdog-haxe.com/

"It is no measure of health to be well adjusted to a profoundly sick
society." --Jiddu Krishnamurti


-- 
http://www.blackdog-haxe.com/

"It is no measure of health to be well adjusted to a profoundly sick
society." --Jiddu Krishnamurti



More information about the Users mailing list