Class G4SyntaxColorisation
Provides a built-in syntax colorization profile for ANTLR4 grammar files (.g4).
public sealed class G4SyntaxColorisation : ISyntaxColorisation
- Inheritance
-
G4SyntaxColorisation
- Implements
- Inherited Members
- Extension Methods
Constructors
G4SyntaxColorisation()
Initializes a new instance of the G4SyntaxColorisation class.
public G4SyntaxColorisation()
Properties
FileExtensions
Gets the file extensions supported by this colorization profile.
public IReadOnlyList<string> FileExtensions { get; }
Property Value
Instance
Gets the singleton instance of the built-in G4 syntax colorization profile.
public static G4SyntaxColorisation Instance { get; }
Property Value
StringSyntaxExtensions
Gets the StringSyntaxAttribute names supported by this profile.
public IReadOnlyList<string> StringSyntaxExtensions { get; }
Property Value
Methods
GetClassification(IEnumerable<string>)
Gets the Visual Studio classification name for a grammar rule path. The path must be ordered from parent rule to most specific rule.
public string? GetClassification(IEnumerable<string> rulePath)
Parameters
rulePathIEnumerable<string>Ordered rule path from root to leaf.
Returns
GetClassification(string)
Gets the Visual Studio classification name for a single grammar rule.
public string? GetClassification(string ruleName)
Parameters
ruleNamestringGrammar rule name.