Table of Contents

Class ContextualRule

Namespace
iText.IO.Font.Otf
Assembly
itext.io.dll
public abstract class ContextualRule
Inheritance
ContextualRule
Derived
Inherited Members

Constructors

ContextualRule()

protected ContextualRule()

Methods

GetBacktrackContextLength()

Gets the length of the backtrack context glyph sequence defined by this rule

public virtual int GetBacktrackContextLength()

Returns

int

length of the backtrack context

GetContextLength()

Gets the length of the context glyph sequence defined by this rule

public abstract int GetContextLength()

Returns

int

length of the context

GetLookaheadContextLength()

Gets the length of the lookahead context glyph sequence defined by this rule

public virtual int GetLookaheadContextLength()

Returns

int

length of the lookahead context

IsGlyphMatchesBacktrack(int, int)

Checks if glyph line element matches element from backtrack sequence of the rule.

public virtual bool IsGlyphMatchesBacktrack(int glyphId, int atIdx)

Parameters

glyphId int

glyph code id

atIdx int

index in rule sequence. Shall be: 0 <= atIdx < GetBacktrackContextLength()

Returns

bool

true if glyph matches element from backtrack sequence

IsGlyphMatchesInput(int, int)

Checks if glyph line element matches element from input sequence of the rule.

public abstract bool IsGlyphMatchesInput(int glyphId, int atIdx)

Parameters

glyphId int

glyph code id

atIdx int

index in the rule sequence. Shall be: 0 < atIdx < GetContextLength()

Returns

bool

true if glyph matches element

Remarks

Checks if glyph line element matches element from input sequence of the rule.

NOTE: rules do not contain the first element of the input sequence, the first element is defined by rule position in substitution table. Therefore atIdx shall not be 0.

IsGlyphMatchesLookahead(int, int)

Checks if glyph line element matches element from lookahead sequence of the rule.

public virtual bool IsGlyphMatchesLookahead(int glyphId, int atIdx)

Parameters

glyphId int

glyph code id

atIdx int

index in rule sequence. Shall be: 0 <= atIdx < GetLookaheadContextLength()

Returns

bool

true if glyph matches element from lookahead sequence