Add non-word-characters to language package


#1

I’m trying to create a language package for Autolisp. I want to define the list of non-word-characters in the settings\language-autolisp.cson file.
However, when I add this to the file:


’.source.autolisp’:
’.editor’:
‘increaseIndentPattern’: ‘^.\(.[^)"]$’
‘nonWordCharacters’: “().”;’"

it has no affect.

Actually, several other editor settings (e.g. font size) did not take affect.

What am I missing?

Thanks,
Jeff


#2

Taking a look at the language-elixir package as an example, it looks like .editor in your example should be editor:

Also, font size isn’t a language-specific configuration setting. The list of language-specific configuration settings is here:

https://atom.io/docs/latest/using-atom-basic-customization#language-specific-configuration-settings


#3

leedohm, thanks for getting back to me. Actually, that is a left over. I tried using the setting without the period first and that also did not work.

So far, the only I was able to get the setting to work is in the basic settings for Atom.


#4

Ok. I figured it out. I cannot set the nonWordCharacters below the .source.autolisp key. I had to add a key using the same method as the config.cson file:

“*”:
editor:
nonWordCharacters: ‘"().’;’

“.source.autolisp”:
editor:
commentStart: ";“
increaseIndentPattern: '^.\(.[^)”]$’

This sets the nonWordCharacters only for this language and does not affect the general nonWordCharacter setting. Also, this is identified as the default on the language specific settings page.

However, this setting can be overridden on the language specific page which is saved in the config.cson file.


#5

Dang. It does work but, even though it does not look like it, it applies the nonWordCharacters everywhere and not just to the specific language.

Still no answer.