Re: [code] [textadept] Textadept events

From: Mitchell <m.att.foicica.com>
Date: Tue, 17 Sep 2013 12:08:00 -0400 (Eastern Daylight Time)

Hi Richard,

On Tue, 17 Sep 2013, Richard Philips wrote:

> Hi,
>
> I'm working with textadept events.
>
> I try to connect a Lua function to the DOUBLE_CLICK event.
>
> That works.
>
> But it seems that there are other actions connected to this event (the
> word under the caret is highlighted).
> I'm unable to delete these actions: with '|disconnect|(/event, id/)' you
> need an id to disconnect.
>
> By the way, I am aware how to prevent firing other actions which are
> registered after mine, but this is exactly the opposite.
>
> Any advice to tackle this problem (especially with the DOUBLE_CLICK
> event on Ubuntu) would be much appreciated.

Highlighting the double-clicked word is default Scintilla behavior -- no
Textadept event is responsible for this. If you want to disable
highlighting, use something like this:

   events.connect(events.DOUBLE_CLICK,
                  function(pos) buffer:goto_pos(pos) end, 1)

Cheers,
Mitchell

-- 
You are subscribed to code.att.foicica.com.
To change subscription settings, send an e-mail to code+help.att.foicica.com.
To unsubscribe, send an e-mail to code+unsubscribe.att.foicica.com.
Received on Tue 17 Sep 2013 - 12:08:00 EDT

This archive was generated by hypermail 2.2.0 : Wed 18 Sep 2013 - 06:36:04 EDT