# OcrTextSpan

Detailed recognized line, word, or character with optional confidence and geometry.

Class 

`OfficeIMO.Ocr`

**Namespace**

`OfficeIMO.Ocr`

**Assembly**

`OfficeIMO.Ocr`

**Source revision**

`063fe3ee9839` with working tree changes

**Source**

[OcrModels.cs:185](https://github.com/EvotecIT/OfficeIMO/blob/063fe3ee9839db87940fc9ed8ae72f1f44b10982/OfficeIMO.Ocr/OcrModels.cs#L185)

**Modifiers**

sealed

Detailed recognized line, word, or character with optional confidence and geometry.

## Inheritance

- object
- OcrTextSpan

## Guides & Samples

Authored walkthroughs and practical samples linked to this API.

- [Charts, Barcodes, OCR and Provenance](/docs/foundations/) Guide
  
  Add ChartForgeX charts, Mermaid diagrams and CodeGlyphX barcodes to documents, recognize text with OCR engines, and verify C2PA Content Credentials.

## Usage

Explore 1 API references to this type

This type appears in these public API surfaces even when no hand-authored example is attached directly to the page.

### Returned or exposed by 1

- Property [OcrResult.Spans](/api/ocr/officeimo-ocr-ocrresult/#property-spans)

Filter members 

Show inherited

## Constructors

`public OcrTextSpan()` [#](#constructor-ctor)

[OcrModels.cs:185](https://github.com/EvotecIT/OfficeIMO/blob/063fe3ee9839db87940fc9ed8ae72f1f44b10982/OfficeIMO.Ocr/OcrModels.cs#L185)

## Inherited Methods

`public virtual bool Equals(object? obj)` [#](#method-equals-object)

Inherited from object

Parameters

**obj object? required**

Returns

`bool`

`public virtual int GetHashCode()` [#](#method-gethashcode)

Inherited from object

Returns

`int`

`public Type GetType()` [#](#method-gettype)

Inherited from object

Returns

`Type`

`public virtual string? ToString()` [#](#method-tostring)

Inherited from object

Returns

`string?`

## Properties

`public int Sequence { get; set; }` [#](#property-sequence)

[OcrModels.cs:181](https://github.com/EvotecIT/OfficeIMO/blob/063fe3ee9839db87940fc9ed8ae72f1f44b10982/OfficeIMO.Ocr/OcrModels.cs#L181)

Zero-based sequence within the provider's emitted reading order.

`public OcrTextSpanLevel Level { get; set; }` [#](#property-level)

[OcrModels.cs:183](https://github.com/EvotecIT/OfficeIMO/blob/063fe3ee9839db87940fc9ed8ae72f1f44b10982/OfficeIMO.Ocr/OcrModels.cs#L183)

Span granularity.

`public string Text { get; set; }` [#](#property-text)

[OcrModels.cs:185](https://github.com/EvotecIT/OfficeIMO/blob/063fe3ee9839db87940fc9ed8ae72f1f44b10982/OfficeIMO.Ocr/OcrModels.cs#L185)

Recognized text for this span.

`public double? Confidence { get; set; }` [#](#property-confidence)

[OcrModels.cs:187](https://github.com/EvotecIT/OfficeIMO/blob/063fe3ee9839db87940fc9ed8ae72f1f44b10982/OfficeIMO.Ocr/OcrModels.cs#L187)

Normalized confidence from zero through one, when available.

`public string? Language { get; set; }` [#](#property-language)

[OcrModels.cs:189](https://github.com/EvotecIT/OfficeIMO/blob/063fe3ee9839db87940fc9ed8ae72f1f44b10982/OfficeIMO.Ocr/OcrModels.cs#L189)

Detected or requested language identifier, when available.

`public int? PageNumber { get; set; }` [#](#property-pagenumber)

[OcrModels.cs:191](https://github.com/EvotecIT/OfficeIMO/blob/063fe3ee9839db87940fc9ed8ae72f1f44b10982/OfficeIMO.Ocr/OcrModels.cs#L191)

One-based source page within a multi-page payload, when applicable.

`public string? BlockId { get; set; }` [#](#property-blockid)

[OcrModels.cs:193](https://github.com/EvotecIT/OfficeIMO/blob/063fe3ee9839db87940fc9ed8ae72f1f44b10982/OfficeIMO.Ocr/OcrModels.cs#L193)

Provider-stable block identifier, when exposed.

`public string? ParagraphId { get; set; }` [#](#property-paragraphid)

[OcrModels.cs:195](https://github.com/EvotecIT/OfficeIMO/blob/063fe3ee9839db87940fc9ed8ae72f1f44b10982/OfficeIMO.Ocr/OcrModels.cs#L195)

Provider-stable paragraph identifier, when exposed.

`public string? LineId { get; set; }` [#](#property-lineid)

[OcrModels.cs:197](https://github.com/EvotecIT/OfficeIMO/blob/063fe3ee9839db87940fc9ed8ae72f1f44b10982/OfficeIMO.Ocr/OcrModels.cs#L197)

Provider-stable line identifier, when exposed.

`public OcrRegion? Region { get; set; }` [#](#property-region)

[OcrModels.cs:199](https://github.com/EvotecIT/OfficeIMO/blob/063fe3ee9839db87940fc9ed8ae72f1f44b10982/OfficeIMO.Ocr/OcrModels.cs#L199)

Bounding region in [OcrTextSpan.CoordinateUnit](/api/ocr/officeimo-ocr-ocrtextspan/), when available.

`public OcrCoordinateUnit CoordinateUnit { get; set; }` [#](#property-coordinateunit)

[OcrModels.cs:201](https://github.com/EvotecIT/OfficeIMO/blob/063fe3ee9839db87940fc9ed8ae72f1f44b10982/OfficeIMO.Ocr/OcrModels.cs#L201)

Coordinate unit used by [OcrTextSpan.Region](/api/ocr/officeimo-ocr-ocrtextspan/).

<!-- PowerForge markdown artifact sha256:EB1FBEBBDC3ADDAC7F95032E445A3FFD875C650C15C2ACF662926B69D32B61B9 -->
