> For the complete documentation index, see [llms.txt](https://docs.yarnspinner.dev/llms.txt). Markdown versions of documentation pages are available by appending `.md` to page URLs; this page is available as [Markdown](https://docs.yarnspinner.dev/api/csharp/yarn.markup/yarn.markup.lineparser.md).

# LineParser

Class in [Yarn.Markup](/api/csharp/yarn.markup.md)

Inherits from `System.Object`

## Summary

Parses text and produces markup information.

```csharp
public sealed class LineParser : IDisposable
```

## Fields

| Name                                                                                                                                      | Description                                                                                                                                                                     |
| ----------------------------------------------------------------------------------------------------------------------------------------- | ------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- |
| [CharacterAttribute](/api/csharp/yarn.markup/yarn.markup.lineparser/yarn.markup.lineparser.characterattribute.md)                         | The name of the implicitly-generated `character` attribute.                                                                                                                     |
| [CharacterAttributeNameProperty](/api/csharp/yarn.markup/yarn.markup.lineparser/yarn.markup.lineparser.characterattributenameproperty.md) | The name of the 'name' property, on the implicitly-generated `character` attribute.                                                                                             |
| [NoMarkupAttribute](/api/csharp/yarn.markup/yarn.markup.lineparser/yarn.markup.lineparser.nomarkupattribute.md)                           | The name of the attribute to use to indicate that no marker processing should occur.                                                                                            |
| [ReplacementMarkerContents](/api/csharp/yarn.markup/yarn.markup.lineparser/yarn.markup.lineparser.replacementmarkercontents.md)           | The name of the property in replacement attributes that contains the text of the attribute.                                                                                     |
| [TrimWhitespaceProperty](/api/csharp/yarn.markup/yarn.markup.lineparser/yarn.markup.lineparser.trimwhitespaceproperty.md)                 | The name of the property to use to signify that trailing whitespace should be trimmed if a tag had preceding whitespace or begins the line. This property must be a bool value. |

## Methods

| Name                                                                                                                                                          | Description                                                                   |
| ------------------------------------------------------------------------------------------------------------------------------------------------------------- | ----------------------------------------------------------------------------- |
| [DeregisterMarkerProcessor(string)](/api/csharp/yarn.markup/yarn.markup.lineparser/yarn.markup.lineparser.deregistermarkerprocessor.md)                       | Removes any marker processor associated with a given marker name.             |
| [Dispose()](/api/csharp/yarn.markup/yarn.markup.lineparser/yarn.markup.lineparser.dispose.md)                                                                 |                                                                               |
| [ExpandSubstitutions(string,IList)](/api/csharp/yarn.markup/yarn.markup.lineparser/yarn.markup.lineparser.expandsubstitutions.md)                             | Replaces all substitution markers in a text with the given substitution list. |
| [ParseString(string,string,bool)](/api/csharp/yarn.markup/yarn.markup.lineparser/yarn.markup.lineparser.parsestring.md)                                       | Parses a string of text and produces a markup parse result.                   |
| [RegisterMarkerProcessor(string,IAttributeMarkerProcessor)](/api/csharp/yarn.markup/yarn.markup.lineparser/yarn.markup.lineparser.registermarkerprocessor.md) | Registers an object as a marker processor for a given marker name.            |

## Structs

| Name                                                                                                          | Description                                                     |
| ------------------------------------------------------------------------------------------------------------- | --------------------------------------------------------------- |
| [MarkupDiagnostic](/api/csharp/yarn.markup/yarn.markup.lineparser/yarn.markup.lineparser.markupdiagnostic.md) | Represents a diagnostic message produced during markup parsing. |
