Copies the data from the defaults to the instance
The options for this font
Protected_Any styles needed for the font
A prefix to use for explicit font-family CSS settings
ProtectedcssThe data to use to make variants to default fonts and css for unknown characters
The prefix to use for font names (e.g., 'TEX')
ProtecteddelimitersThe actual delimiter information for this font
ProtectedoptionsThe font options
The actual font parameters for this font
ProtectedremapThe character maps
ProtectedsizeThe actual size variants to use for this font
Factor by which to multiply italic correction for computation of delta in munderover
ProtectedstretchThe actual stretchy variants to use for this font
ProtectedvariantThe actual variant information for this font
StaticdefaultThe default remappings
Protected StaticdefaultThe default character data
Protected StaticdefaultThe default prefix for explicit font-family settings
StaticdefaultThe family, style, and weight to use for each variant (for unknown characters) The 'unknown' family is replaced by options.unknownFamily
Protected StaticdefaultThe default delimiter data
Protected StaticdefaultDefault map for characters inside
Protected StaticdefaultDefault map for characters inside
StaticdefaultThe default font parameters for the font
Protected StaticdefaultThe default variants for the fixed size stretchy delimiters
Protected StaticdefaultThe default variants for the assembly parts for stretchy delimiters
StaticdefaultThe standard variants to define
StaticdynamicThe font extension dynamic data
Protected StaticdynamicThe dynamic file data
StaticJAXStaticNAMEThe name of the font that is being defined (used by extensions)
StaticOPTIONSStaticSmpCharacter ranges to remap into Math Alphanumerics
StaticSmpCharacters to map back to other Unicode positions (holes in the Math Alphanumeric ranges)
StaticSmpGreek lower-case variants
StaticSmpGreek upper-case variants
StaticVariantVariant locations in the Math Alphabnumerics block: [upper-alpha, lower-alpha, upper-Greek, lower-Greek, numbers]
The constructor for this object
Implemented in subclasses
The IDs for the fonts to add CSS for
Optional_root: stringThe root URL for the fonts (can be set by extensions)
Add an extension to an existing font instance (options will get their defaults).
The data for the font extension to merge into this font.
The [prefix] to add to all component names
The new CSS rules needed for this extension
Creates the data structure for a variant -- an object with prototype chain that includes a copy of the linked variant, and then the inherited variant chain.
The reason for this extra link is that for a mathvariant like bold-italic, you want to inherit from both the bold and italic variants, but the prototype chain can only inherit from one. So for bold-italic, we make an object that has a prototype consisting of a copy of the bold data, and add the italic data as the prototype chain. (Since this is a copy, we keep a record of this link so that if bold is changed later, we can update this copy. That is not needed for the prototype chain, since the prototypes are the actual objects, not copies.) We then use this bold-plus-italic object as the prototype chain for the bold-italic object
That means that bold-italic will first look in its own object for specifically bold-italic glyphs that are defined there, then in the copy of the bold glyphs (only its top level is copied, not its prototype chain), and then the specifically italic glyphs, and then the prototype chain for italics, which is the normal glyphs. Effectively, this means bold-italic looks for bold-italic, then bold, then italic, then normal glyphs in order to find the given character.
The new variant to create
The variant to use if a character is not in this one
A variant to search before the inherit one (but only its top-level object).
Create a collection of variants
Array of [name, inherit?, link?] values for the variants to define
Defines new character data in a given variant (We use Object.assign() here rather than the spread operator since the character maps are objeccts with prototypes, and we don't want to loose those by doing {...chars} or something similar.)
The variant for these characters
The characters to define
Defined the mapping of variants to CSS fonts for unknown characters in each variant.
The variants to define and their properties
Defines stretchy delimiters
The delimiters to define
Set up the dynamic characters to point to the proper dynamic data object
The data objects to process
Defines a character remapping map
The name of the map to define or augment
The characters to remap
ProtecteddynamicThe data for the dynamic file
The prefixed name for the file
ProtectedflattenTurn a DynamicRange into a mapping of character number to DynamicFile.
The ranges to be flattened
The DynamicFile to tie to the ranges
The map from character positions to dynamic file
The variant whose character data is being querried
The unicode number for the character to be found
The data for the given character (or undefined)
The name of the variant whose data is to be obtained
The CSS data for the requested variant
The delimiter character number whose data is desired
The data for that delimiter (or undefined)
The font camily to use
The family with the css prefix
The name of the map to query
The character to remap
The remapped character (or the original)
The delimiter character number whose variant is needed
The index in the size array of the size whose variant is needed
The variant of the i-th size for delimiter n
The delimiter character number whose variant is needed
The index in the stretch array of the part whose variant is needed
The variant of the i-th part for delimiter n
The delimiter character number whose variants are needed
The variants for the parts of the delimiter
The name of the variant whose data is to be obtained
The data for the requested variant (or undefined)
Load the data for the character from the proper file, and do any associated setup that needs access to the FontData instance.
The data for the file to load
The promise that is resolved when the file is loaded
Load all dynamic files.
A promise that is resolved after all the dynamic files are loaded.
Load all dynamic files synchronously, using mathjax.asyncLoad, when it is set to a synchronous loading function, as in util/asyncLoad/node.ts.
The dynamic file to load
ProtectedremapCreate the mapping from Basic Latin and Greek blocks to the Math Alphanumeric block for a given variant.
The character mapping to fill.
The new variant name.
The options to merge into the font options
ProtectedsmpMath Alphanumerics position for this remapping
The character data for the remapping
StaticaddProtected StaticadjustThe list of numbers to adjust
The pivot number
The list of adjusted numbers
StaticadjustThe delimiter list to modify
The ids of the delimiters to check
The original number of size variants
The original number ot stretch variants
StaticcharStaticdefineDefine the dynamic file information.
The definitions to make
The name of the extension for this file (or empty)
The object of dynamic file data
StaticdynamicCreate the setup function for a given dynamically loaded file
The CharOptions type
The DelimiterData type
The name of the font extension for this file
The file being loaded
The character data to be added
The delimiter data to be added
The fonts to add CSS to
The SVG FontData class