Re: [code] [textadept] Language specific settings

From: Rob Kendrick <rjek+foicica.com.att.rjek.com>
Date: Mon, 27 Jan 2014 15:08:24 +0000

On Mon, Jan 27, 2014 at 03:39:01PM +0100, Robert Gieseke wrote:
> Hi Klaus,
>
> Am 27.01.14 03:32, schrieb Klaus Borges:
> >Hello,
> >
> >I'd like to know the appropriate way to put language specific settings,
> >such as tab indenting for one specific language and space for others.
> >Should I put those settings on the lexer file?
>
> if it's only tab indenting (or a few properties) you could put in
> your init.lua, e.g. for JavaScript:
>
> events.connect(events.LEXER_LOADED, function(lang)
> if lang == 'javascript' then buffer.tab_width = 4 end
> end)

This strikes me as a common enough desire that there should probably be
some built-in infrastructure for doing it that allows more succinct
configuration.

In such a thing, I believe it might be desirable to allow the
configuration of indentation rules not just based on lexer in use, but
path, as not all projects follow the same.

B.

-- 
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 27 Jan 2014 - 10:08:24 EST

This archive was generated by hypermail 2.2.0 : Tue 28 Jan 2014 - 06:53:49 EST