[X] Put an X in this box if you have done the following:
Ensured the issue has not already been raised
Ensured the issue is caused by this package
Description
Text inside the brackets after the \hyphenationcommand are processed as normal text and therefore get spell-checked.
Steps to reproduce & Minimum working example
Put \hyphenation{op-tical net-works semi-conduc-tor} near the top of your file.
Spell check with linter-spell and linter-spell-latex
Expected behaviour
tical and conduc are marked as mispelled.
Actual behaviour
tical and conduc are marked as mispelled.
Additional information
I have solved the issue by adding the following to grammars/latex.cson.
EDIT: This seems to work the first time I relaunch Atom, then it doesn't work after....
{
'captures':
'1':
'name': 'support.function.be.latex'
'2':
'name': 'punctuation.definition.function.latex'
'3':
'name': 'support.function.general.tex'
'comment': 'This matches the hyphenation command to force proper hyphenation'
'match': '(?:\\s*)((\\\\)hyphenation)({(.{1,1000})})'
'name': 'meta.function.hyphenation.latex'
}
This should be added to the code, but I'm not very good at RegEx, so I wanted to post here. There is probably a better way than what I did. Obviously if you have over 1000 characters to correct hyphenation on, you should probably use shorter words as this fix won't work. Is there a better RegEx to use? (the 1,1000 seems clunky)
Prerequisites
X
in this box if you have done the following:Description
Text inside the brackets after the
\hyphenation
command are processed as normal text and therefore get spell-checked.Steps to reproduce & Minimum working example
\hyphenation{op-tical net-works semi-conduc-tor}
near the top of your file.Expected behaviour
tical
andconduc
are marked as mispelled.Actual behaviour
tical
andconduc
are marked as mispelled.Additional information
I have solved the issue by adding the following to
grammars/latex.cson
.EDIT: This seems to work the first time I relaunch Atom, then it doesn't work after....
This should be added to the code, but I'm not very good at RegEx, so I wanted to post here. There is probably a better way than what I did. Obviously if you have over 1000 characters to correct hyphenation on, you should probably use shorter words as this fix won't work. Is there a better RegEx to use? (the 1,1000 seems clunky)