RE: [code] [textadept] Control-c to clear Message Buffer

From: Jay Young <jyng7.att.hotmail.com>
Date: Fri, 24 Jul 2015 19:44:07 -0500

Thank you Mitchell, this works perfect now! Seems I have a lot more to learn with Lua!

Jay

> Date: Fri, 24 Jul 2015 20:29:25 -0400
> From: m.att.foicica.com
> To: code.att.foicica.com
> Subject: Re: [code] [textadept] Control-c to clear Message Buffer
>
> Hi Jay,
>
> On Fri, 24 Jul 2015, Jay Young wrote:
>
> > I've been trying to figure out a way where I can press Control-c and make that clear the Message Buffer. Here's some code I've been testing with in my init.lua file. It doesn't work right though - it only clears whichever buffer is active.
> >
> > keys.cc = { function()
> > for k,v in ipairs(_BUFFERS) do
> > if v._type then
> > v.clear_all()
>
> This should be "v:clear_all()".
>
> Lua's ':' notation means to pass 'v' as a "self"-type argument to the
> "clear_all" buffer function.
>
> 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.
>
                                               

-- 
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 Fri 24 Jul 2015 - 20:44:07 EDT

This archive was generated by hypermail 2.2.0 : Sat 25 Jul 2015 - 06:41:31 EDT