Re: New buffers

From: Robert <ro....at.web.de>
Date: Fri, 25 Jun 2010 17:04:11 +0200

On Mon, Jun 14, 2010 at 8:11 PM, mitchell <mforal.n....at.gmail.com> wrote:
> Robert,
>
> On Jun 14, 3:03 am, Robert <ro....at.web.de> wrote:
>> Hi,
>>
>> before I close a buffer I check for it being a message buffer and
>> unsplit the view:
>> keys.cw  = { function() if buffer._type then view:unsplit() end
>> buffer:close() return true end }
>>
>> This works only as expected if the message buffer comes after the
>> originating buffer in the buffers table, so
>> I played around a bit and now have this:
>
> Try:
>
> buffer:close()
> textadept.goto_view(-1, false)
> view:unsplit()
>
> This works as long as the message buffer is in the same view it was
> opened in when splitting.
>
> Mitchell
>
Thanks, I added an entry to the Wiki:
http://caladbolg.net/textadeptwiki/index.php?n=Main.Closeunsplitview

Robert
Received on Fri 25 Jun 2010 - 11:04:11 EDT

This archive was generated by hypermail 2.2.0 : Thu 08 Mar 2012 - 11:48:11 EST