use of com.perl5.lang.perl.psi.mixins.PerlStringBareMixin in project Perl5-IDEA by Camelcade.
the class PerlSpellCheckingStrategy method getTokenizer.
@NotNull
@Override
public Tokenizer getTokenizer(PsiElement element) {
if (STRING_CONTENT_TOKENSET.contains(PsiUtilCore.getElementType(element))) {
PsiElement lightNameIdentifierOwner = PerlTargetElementEvaluatorEx2.getLightNameIdentifierOwner(element);
if (lightNameIdentifierOwner != null) {
return IDENTIFIER_TOKENIZER;
}
;
if (element.getParent() instanceof PerlStringBareMixin) {
return TEXT_TOKENIZER;
}
PsiLanguageInjectionHost injectionHost = PsiTreeUtil.getParentOfType(element, PsiLanguageInjectionHost.class);
if (PerlInjectionUtil.hasInjections(injectionHost)) {
return EMPTY_TOKENIZER;
}
return TEXT_TOKENIZER;
}
return super.getTokenizer(element);
}
Aggregations