read_fonts

Trait FontRead

Source
pub trait FontRead<'a>: Sized {
    // Required method
    fn read(data: FontData<'a>) -> Result<Self, ReadError>;
}
Expand description

A type that can be read from raw table data.

This trait is implemented for all font tables that are self-describing: that is, tables that do not require any external state in order to interpret their underlying bytes. (Tables that require external state implement FontReadWithArgs instead)

Required Methods§

Source

fn read(data: FontData<'a>) -> Result<Self, ReadError>

Read an instance of Self from the provided data, performing validation.

In the case of a table, this method is responsible for ensuring the input data is consistent: this means ensuring that any versioned fields are present as required by the version, and that any array lengths are not out-of-bounds.

Dyn Compatibility§

This trait is not dyn compatible.

In older versions of Rust, dyn compatibility was called "object safety", so this trait is not object safe.

Implementors§

Source§

impl<'a> FontRead<'a> for read_fonts::tables::aat::Lookup<'a>

Source§

impl<'a> FontRead<'a> for BaseCoord<'a>

Source§

impl<'a> FontRead<'a> for IndexSubtable<'a>

Source§

impl<'a> FontRead<'a> for CmapSubtable<'a>

Source§

impl<'a> FontRead<'a> for ClipBox<'a>

Source§

impl<'a> FontRead<'a> for Paint<'a>

Source§

impl<'a> FontRead<'a> for CaretValue<'a>

Source§

impl<'a> FontRead<'a> for Glyph<'a>

Source§

impl<'a> FontRead<'a> for AnchorTable<'a>

Source§

impl<'a> FontRead<'a> for read_fonts::tables::gpos::ExtensionSubtable<'a>

Source§

impl<'a> FontRead<'a> for PairPos<'a>

Source§

impl<'a> FontRead<'a> for PositionLookup<'a>

Source§

impl<'a> FontRead<'a> for SinglePos<'a>

Source§

impl<'a> FontRead<'a> for read_fonts::tables::gsub::ExtensionSubtable<'a>

Source§

impl<'a> FontRead<'a> for SingleSubst<'a>

Source§

impl<'a> FontRead<'a> for SubstitutionLookup<'a>

Source§

impl<'a> FontRead<'a> for Ift<'a>

Source§

impl<'a> FontRead<'a> for ChainedSequenceContext<'a>

Source§

impl<'a> FontRead<'a> for ClassDef<'a>

Source§

impl<'a> FontRead<'a> for Condition<'a>

Source§

impl<'a> FontRead<'a> for CoverageTable<'a>

Source§

impl<'a> FontRead<'a> for DeviceOrVariationIndex<'a>

Source§

impl<'a> FontRead<'a> for SequenceContext<'a>

Source§

impl<'a> FontRead<'a> for FdSelect<'a>

Source§

impl<'a> FontRead<'a> for AxisValue<'a>

Source§

impl<'a> FontRead<'a> for DeltaSetIndexMap<'a>

Source§

impl<'a> FontRead<'a> for FontData<'a>

Source§

impl<'a> FontRead<'a> for StateTable<'a>

Source§

impl<'a> FontRead<'a> for SegmentMaps<'a>

Source§

impl<'a> FontRead<'a> for Cff2<'a>

Source§

impl<'a> FontRead<'a> for Cff<'a>

Source§

impl<'a> FontRead<'a> for ScriptLangTag<'a>

Source§

impl<'a> FontRead<'a> for PString<'a>

Source§

impl<'a> FontRead<'a> for ClassSubtable<'a>

Source§

impl<'a> FontRead<'a> for Lookup0<'a>

Source§

impl<'a> FontRead<'a> for Lookup2<'a>

Source§

impl<'a> FontRead<'a> for Lookup4<'a>

Source§

impl<'a> FontRead<'a> for Lookup6<'a>

Source§

impl<'a> FontRead<'a> for Lookup8<'a>

Source§

impl<'a> FontRead<'a> for Lookup10<'a>

Source§

impl<'a> FontRead<'a> for RawBytes<'a>

Source§

impl<'a> FontRead<'a> for RawWords<'a>

Source§

impl<'a> FontRead<'a> for StateHeader<'a>

Source§

impl<'a> FontRead<'a> for StxHeader<'a>

Source§

impl<'a> FontRead<'a> for Ankr<'a>

Source§

impl<'a> FontRead<'a> for GlyphDataEntry<'a>

Source§

impl<'a> FontRead<'a> for Avar<'a>

Source§

impl<'a> FontRead<'a> for Axis<'a>

Source§

impl<'a> FontRead<'a> for Base<'a>

Source§

impl<'a> FontRead<'a> for BaseCoordFormat1<'a>

Source§

impl<'a> FontRead<'a> for BaseCoordFormat2<'a>

Source§

impl<'a> FontRead<'a> for BaseCoordFormat3<'a>

Source§

impl<'a> FontRead<'a> for BaseScript<'a>

Source§

impl<'a> FontRead<'a> for BaseScriptList<'a>

Source§

impl<'a> FontRead<'a> for BaseTagList<'a>

Source§

impl<'a> FontRead<'a> for BaseValues<'a>

Source§

impl<'a> FontRead<'a> for MinMax<'a>

Source§

impl<'a> FontRead<'a> for IndexSubtable1<'a>

Source§

impl<'a> FontRead<'a> for IndexSubtable2<'a>

Source§

impl<'a> FontRead<'a> for IndexSubtable3<'a>

Source§

impl<'a> FontRead<'a> for IndexSubtable4<'a>

Source§

impl<'a> FontRead<'a> for IndexSubtable5<'a>

Source§

impl<'a> FontRead<'a> for IndexSubtableArray<'a>

Source§

impl<'a> FontRead<'a> for Cbdt<'a>

Source§

impl<'a> FontRead<'a> for Cblc<'a>

Source§

impl<'a> FontRead<'a> for Cff2Header<'a>

Source§

impl<'a> FontRead<'a> for CffHeader<'a>

Source§

impl<'a> FontRead<'a> for Cmap0<'a>

Source§

impl<'a> FontRead<'a> for Cmap2<'a>

Source§

impl<'a> FontRead<'a> for Cmap4<'a>

Source§

impl<'a> FontRead<'a> for Cmap6<'a>

Source§

impl<'a> FontRead<'a> for Cmap8<'a>

Source§

impl<'a> FontRead<'a> for Cmap10<'a>

Source§

impl<'a> FontRead<'a> for Cmap12<'a>

Source§

impl<'a> FontRead<'a> for Cmap13<'a>

Source§

impl<'a> FontRead<'a> for Cmap14<'a>

Source§

impl<'a> FontRead<'a> for Cmap<'a>

Source§

impl<'a> FontRead<'a> for DefaultUvs<'a>

Source§

impl<'a> FontRead<'a> for NonDefaultUvs<'a>

Source§

impl<'a> FontRead<'a> for Affine2x3<'a>

Source§

impl<'a> FontRead<'a> for BaseGlyphList<'a>

Source§

impl<'a> FontRead<'a> for ClipBoxFormat1<'a>

Source§

impl<'a> FontRead<'a> for ClipBoxFormat2<'a>

Source§

impl<'a> FontRead<'a> for ClipList<'a>

Source§

impl<'a> FontRead<'a> for ColorLine<'a>

Source§

impl<'a> FontRead<'a> for Colr<'a>

Source§

impl<'a> FontRead<'a> for LayerList<'a>

Source§

impl<'a> FontRead<'a> for PaintColrGlyph<'a>

Source§

impl<'a> FontRead<'a> for PaintColrLayers<'a>

Source§

impl<'a> FontRead<'a> for PaintComposite<'a>

Source§

impl<'a> FontRead<'a> for PaintGlyph<'a>

Source§

impl<'a> FontRead<'a> for PaintLinearGradient<'a>

Source§

impl<'a> FontRead<'a> for PaintRadialGradient<'a>

Source§

impl<'a> FontRead<'a> for PaintRotate<'a>

Source§

impl<'a> FontRead<'a> for PaintRotateAroundCenter<'a>

Source§

impl<'a> FontRead<'a> for PaintScale<'a>

Source§

impl<'a> FontRead<'a> for PaintScaleAroundCenter<'a>

Source§

impl<'a> FontRead<'a> for PaintScaleUniform<'a>

Source§

impl<'a> FontRead<'a> for PaintScaleUniformAroundCenter<'a>

Source§

impl<'a> FontRead<'a> for PaintSkew<'a>

Source§

impl<'a> FontRead<'a> for PaintSkewAroundCenter<'a>

Source§

impl<'a> FontRead<'a> for PaintSolid<'a>

Source§

impl<'a> FontRead<'a> for PaintSweepGradient<'a>

Source§

impl<'a> FontRead<'a> for PaintTransform<'a>

Source§

impl<'a> FontRead<'a> for PaintTranslate<'a>

Source§

impl<'a> FontRead<'a> for PaintVarLinearGradient<'a>

Source§

impl<'a> FontRead<'a> for PaintVarRadialGradient<'a>

Source§

impl<'a> FontRead<'a> for PaintVarRotate<'a>

Source§

impl<'a> FontRead<'a> for PaintVarRotateAroundCenter<'a>

Source§

impl<'a> FontRead<'a> for PaintVarScale<'a>

Source§

impl<'a> FontRead<'a> for PaintVarScaleAroundCenter<'a>

Source§

impl<'a> FontRead<'a> for PaintVarScaleUniform<'a>

Source§

impl<'a> FontRead<'a> for PaintVarScaleUniformAroundCenter<'a>

Source§

impl<'a> FontRead<'a> for PaintVarSkew<'a>

Source§

impl<'a> FontRead<'a> for PaintVarSkewAroundCenter<'a>

Source§

impl<'a> FontRead<'a> for PaintVarSolid<'a>

Source§

impl<'a> FontRead<'a> for PaintVarSweepGradient<'a>

Source§

impl<'a> FontRead<'a> for PaintVarTransform<'a>

Source§

impl<'a> FontRead<'a> for PaintVarTranslate<'a>

Source§

impl<'a> FontRead<'a> for VarAffine2x3<'a>

Source§

impl<'a> FontRead<'a> for VarColorLine<'a>

Source§

impl<'a> FontRead<'a> for Cpal<'a>

Source§

impl<'a> FontRead<'a> for Cvar<'a>

Source§

impl<'a> FontRead<'a> for Ebdt<'a>

Source§

impl<'a> FontRead<'a> for Eblc<'a>

Source§

impl<'a> FontRead<'a> for Feat<'a>

Source§

impl<'a> FontRead<'a> for Fvar<'a>

Source§

impl<'a> FontRead<'a> for Gasp<'a>

Source§

impl<'a> FontRead<'a> for AttachList<'a>

Source§

impl<'a> FontRead<'a> for AttachPoint<'a>

Source§

impl<'a> FontRead<'a> for CaretValueFormat1<'a>

Source§

impl<'a> FontRead<'a> for CaretValueFormat2<'a>

Source§

impl<'a> FontRead<'a> for CaretValueFormat3<'a>

Source§

impl<'a> FontRead<'a> for Gdef<'a>

Source§

impl<'a> FontRead<'a> for LigCaretList<'a>

Source§

impl<'a> FontRead<'a> for LigGlyph<'a>

Source§

impl<'a> FontRead<'a> for MarkGlyphSets<'a>

Source§

impl<'a> FontRead<'a> for CompositeGlyph<'a>

Source§

impl<'a> FontRead<'a> for Glyf<'a>

Source§

impl<'a> FontRead<'a> for SimpleGlyph<'a>

Source§

impl<'a> FontRead<'a> for AnchorFormat1<'a>

Source§

impl<'a> FontRead<'a> for AnchorFormat2<'a>

Source§

impl<'a> FontRead<'a> for AnchorFormat3<'a>

Source§

impl<'a> FontRead<'a> for CursivePosFormat1<'a>

Source§

impl<'a> FontRead<'a> for Gpos<'a>

Source§

impl<'a> FontRead<'a> for MarkArray<'a>

Source§

impl<'a> FontRead<'a> for MarkBasePosFormat1<'a>

Source§

impl<'a> FontRead<'a> for MarkLigPosFormat1<'a>

Source§

impl<'a> FontRead<'a> for MarkMarkPosFormat1<'a>

Source§

impl<'a> FontRead<'a> for PairPosFormat1<'a>

Source§

impl<'a> FontRead<'a> for PairPosFormat2<'a>

Source§

impl<'a> FontRead<'a> for SinglePosFormat1<'a>

Source§

impl<'a> FontRead<'a> for SinglePosFormat2<'a>

Source§

impl<'a> FontRead<'a> for AlternateSet<'a>

Source§

impl<'a> FontRead<'a> for AlternateSubstFormat1<'a>

Source§

impl<'a> FontRead<'a> for Gsub<'a>

Source§

impl<'a> FontRead<'a> for Ligature<'a>

Source§

impl<'a> FontRead<'a> for LigatureSet<'a>

Source§

impl<'a> FontRead<'a> for LigatureSubstFormat1<'a>

Source§

impl<'a> FontRead<'a> for MultipleSubstFormat1<'a>

Source§

impl<'a> FontRead<'a> for ReverseChainSingleSubstFormat1<'a>

Source§

impl<'a> FontRead<'a> for Sequence<'a>

Source§

impl<'a> FontRead<'a> for SingleSubstFormat1<'a>

Source§

impl<'a> FontRead<'a> for SingleSubstFormat2<'a>

Source§

impl<'a> FontRead<'a> for GlyphVariationDataHeader<'a>

Source§

impl<'a> FontRead<'a> for Gvar<'a>

Source§

impl<'a> FontRead<'a> for Head<'a>

Source§

impl<'a> FontRead<'a> for Hhea<'a>

Source§

impl<'a> FontRead<'a> for Hvar<'a>

Source§

impl<'a> FontRead<'a> for read_fonts::tables::ift::GlyphData<'a>

Source§

impl<'a> FontRead<'a> for GlyphKeyedPatch<'a>

Source§

impl<'a> FontRead<'a> for IdStringData<'a>

Source§

impl<'a> FontRead<'a> for MappingEntries<'a>

Source§

impl<'a> FontRead<'a> for PatchMapFormat1<'a>

Source§

impl<'a> FontRead<'a> for PatchMapFormat2<'a>

Source§

impl<'a> FontRead<'a> for TableKeyedPatch<'a>

Source§

impl<'a> FontRead<'a> for TablePatch<'a>

Source§

impl<'a> FontRead<'a> for ChainedClassSequenceRule<'a>

Source§

impl<'a> FontRead<'a> for ChainedClassSequenceRuleSet<'a>

Source§

impl<'a> FontRead<'a> for ChainedSequenceContextFormat1<'a>

Source§

impl<'a> FontRead<'a> for ChainedSequenceContextFormat2<'a>

Source§

impl<'a> FontRead<'a> for ChainedSequenceContextFormat3<'a>

Source§

impl<'a> FontRead<'a> for ChainedSequenceRule<'a>

Source§

impl<'a> FontRead<'a> for ChainedSequenceRuleSet<'a>

Source§

impl<'a> FontRead<'a> for CharacterVariantParams<'a>

Source§

impl<'a> FontRead<'a> for ClassDefFormat1<'a>

Source§

impl<'a> FontRead<'a> for ClassDefFormat2<'a>

Source§

impl<'a> FontRead<'a> for ClassSequenceRule<'a>

Source§

impl<'a> FontRead<'a> for ClassSequenceRuleSet<'a>

Source§

impl<'a> FontRead<'a> for ConditionFormat1<'a>

Source§

impl<'a> FontRead<'a> for ConditionFormat2<'a>

Source§

impl<'a> FontRead<'a> for ConditionFormat3<'a>

Source§

impl<'a> FontRead<'a> for ConditionFormat4<'a>

Source§

impl<'a> FontRead<'a> for ConditionFormat5<'a>

Source§

impl<'a> FontRead<'a> for ConditionSet<'a>

Source§

impl<'a> FontRead<'a> for CoverageFormat1<'a>

Source§

impl<'a> FontRead<'a> for CoverageFormat2<'a>

Source§

impl<'a> FontRead<'a> for Device<'a>

Source§

impl<'a> FontRead<'a> for FeatureList<'a>

Source§

impl<'a> FontRead<'a> for FeatureTableSubstitution<'a>

Source§

impl<'a> FontRead<'a> for FeatureVariations<'a>

Source§

impl<'a> FontRead<'a> for LangSys<'a>

Source§

impl<'a> FontRead<'a> for Script<'a>

Source§

impl<'a> FontRead<'a> for ScriptList<'a>

Source§

impl<'a> FontRead<'a> for SequenceContextFormat1<'a>

Source§

impl<'a> FontRead<'a> for SequenceContextFormat2<'a>

Source§

impl<'a> FontRead<'a> for SequenceContextFormat3<'a>

Source§

impl<'a> FontRead<'a> for SequenceRule<'a>

Source§

impl<'a> FontRead<'a> for SequenceRuleSet<'a>

Source§

impl<'a> FontRead<'a> for SizeParams<'a>

Source§

impl<'a> FontRead<'a> for StylisticSetParams<'a>

Source§

impl<'a> FontRead<'a> for VariationIndex<'a>

Source§

impl<'a> FontRead<'a> for Ltag<'a>

Source§

impl<'a> FontRead<'a> for Maxp<'a>

Source§

impl<'a> FontRead<'a> for Meta<'a>

Source§

impl<'a> FontRead<'a> for Mvar<'a>

Source§

impl<'a> FontRead<'a> for Name<'a>

Source§

impl<'a> FontRead<'a> for Os2<'a>

Source§

impl<'a> FontRead<'a> for Post<'a>

Source§

impl<'a> FontRead<'a> for FdSelectFormat0<'a>

Source§

impl<'a> FontRead<'a> for FdSelectFormat3<'a>

Source§

impl<'a> FontRead<'a> for FdSelectFormat4<'a>

Source§

impl<'a> FontRead<'a> for Index1<'a>

Source§

impl<'a> FontRead<'a> for Index2<'a>

Source§

impl<'a> FontRead<'a> for read_fonts::tables::sbix::GlyphData<'a>

Source§

impl<'a> FontRead<'a> for AxisValueFormat1<'a>

Source§

impl<'a> FontRead<'a> for AxisValueFormat2<'a>

Source§

impl<'a> FontRead<'a> for AxisValueFormat3<'a>

Source§

impl<'a> FontRead<'a> for AxisValueFormat4<'a>

Source§

impl<'a> FontRead<'a> for Stat<'a>

Source§

impl<'a> FontRead<'a> for SVGDocumentList<'a>

Source§

impl<'a> FontRead<'a> for Svg<'a>

Source§

impl<'a> FontRead<'a> for ConditionList<'a>

Source§

impl<'a> FontRead<'a> for MultiItemVariationData<'a>

Source§

impl<'a> FontRead<'a> for MultiItemVariationStore<'a>

Source§

impl<'a> FontRead<'a> for SparseVariationRegion<'a>

Source§

impl<'a> FontRead<'a> for SparseVariationRegionList<'a>

Source§

impl<'a> FontRead<'a> for Varc<'a>

Source§

impl<'a> FontRead<'a> for DeltaSetIndexMapFormat0<'a>

Source§

impl<'a> FontRead<'a> for DeltaSetIndexMapFormat1<'a>

Source§

impl<'a> FontRead<'a> for ItemVariationData<'a>

Source§

impl<'a> FontRead<'a> for ItemVariationStore<'a>

Source§

impl<'a> FontRead<'a> for VariationRegionList<'a>

Source§

impl<'a> FontRead<'a> for Vhea<'a>

Source§

impl<'a> FontRead<'a> for Vorg<'a>

Source§

impl<'a> FontRead<'a> for Vvar<'a>

Source§

impl<'a> FontRead<'a> for TTCHeader<'a>

Source§

impl<'a> FontRead<'a> for TableDirectory<'a>

Source§

impl<'a, T> FontRead<'a> for VarLenArray<'a, T>

Source§

impl<'a, T> FontRead<'a> for ExtendedStateTable<'a, T>

Source§

impl<'a, T> FontRead<'a> for TypedLookup<'a, T>

Source§

impl<'a, T> FontRead<'a> for ExtensionPosFormat1<'a, T>

Source§

impl<'a, T> FontRead<'a> for ExtensionSubstFormat1<'a, T>

Source§

impl<'a, T> FontRead<'a> for read_fonts::tables::layout::Lookup<'a, T>

Source§

impl<'a, T> FontRead<'a> for LookupList<'a, T>

Source§

impl<'a, T: AnyBitPattern + FixedSize> FontRead<'a> for StateEntry<T>