Re: [code] Getting current selection start/end

From: Michael Richter <ttmrichter.att.gmail.com>
Date: Mon, 20 Jun 2016 20:35:38 +0800

D'oh! I was trying to use it as a function, not as a variable. I'm an
idiot.

On 20 June 2016 at 17:58, DrTebi <drtebi.att.gmail.com> wrote:

> It has been a while since I customized my TextEdit, but I think this
> should do the trick:
>
> local l = buffer.selection_n_end[0] - buffer.selection_n_start[0]
>
>
>
> On Sun, Jun 19, 2016 at 11:58 PM, Michael Richter <ttmrichter.att.gmail.com>
> wrote:
> > Let's say I make a call to select_enclosed(left, right). How do I go
> about
> > getting the start_pos and end_pos of the resulting selection? I just
> can't
> > see it in the API, but I'm sure it's there.
> >
> > --
> > "Perhaps people don't believe this, but throughout all of the
> discussions of
> > entering China our focus has really been what's best for the Chinese
> people.
> > It's not been about our revenue or profit or whatnot."
> > --Sergey Brin, demonstrating the emptiness of the "don't be evil" mantra.
>
>
>
> --
> "The bitterness of poor quality remains long after the sweetness of
> low price is forgotten."
> --
> 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.
>
>

-- 
"Perhaps people don't believe this, but throughout all of the discussions
of entering China our focus has really been what's best for the Chinese
people. It's not been about our revenue or profit or whatnot."
--Sergey Brin, demonstrating the emptiness of the "don't be evil" mantra.
-- 
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 Mon 20 Jun 2016 - 08:35:38 EDT

This archive was generated by hypermail 2.2.0 : Tue 21 Jun 2016 - 06:48:35 EDT