Code
Hub
Workspaces
Following
Trending
Connect
MCP
copy
Create free account
hub
/
github.com/KaTeX/KaTeX
/ functions
Functions
524 in github.com/KaTeX/KaTeX
⨍
Functions
524
◇
Types & classes
70
↓ 48 callers
Function
makeSpan
( classes?: string[], children?: HtmlDomNode[], options?: Options, style?: CssStyle, )
src/buildCommon.ts:355
↓ 41 callers
Function
defineFunction
( data: FunctionDefSpec<NODETYPE, NAMES>, )
src/defineFunction.ts:169
↓ 38 callers
Function
makeEm
(n: number)
src/units.ts:101
↓ 24 callers
Method
setAttribute
* Sets an attribute on a MathML node. MathML depends on attributes to convey a * semantic content, so this is used heavily.
src/mathMLTree.ts:68
↓ 23 callers
Method
setAttribute
* Sets an arbitrary attribute on the span. Warning: use this wisely. Not * all browsers support attributes the same, and having too many custom
src/domTree.ts:243
↓ 22 callers
Function
assertNodeType
( node: AnyParseNode | null | undefined, type: NODETYPE, )
src/parseNode.ts:8
↓ 22 callers
Method
has
* Detect whether `name` has a definition. Equivalent to * `get(name) != null`.
src/Namespace.ts:68
↓ 19 callers
Method
fontMetrics
* Return the font metrics for this size.
src/Options.ts:296
↓ 17 callers
Function
makeVList
(params: VListParam, options: Options)
src/buildCommon.ts:552
↓ 16 callers
Method
fetch
* Return the current lookahead token, or if there isn't one (at the * beginning, or if the previous lookahead token was consume()d), * fetch
src/Parser.ts:102
↓ 15 callers
Method
get
* Get the current value of a name, or `undefined` if there is no value. * * Note: Do not use `if (namespace.get(...))` to detect whether a m
src/Namespace.ts:81
↓ 14 callers
Method
consume
* Discards the current lookahead token, considering it consumed.
src/Parser.ts:93
↓ 14 callers
Method
havingStyle
* Return an options object with the given style. If `this.style === style`, * returns `this`.
src/Options.ts:127
↓ 13 callers
Method
set
* Set the current value of a name, and optionally set it globally too. * Local set() sets the current value and (when appropriate) adds an undo
src/Namespace.ts:96
↓ 12 callers
Function
calculateSize
( sizeValue: Measurement, options: Options)
src/units.ts:55
↓ 12 callers
Method
extend
* Returns a new options object with the same properties as "this". Properties * from "extension" will be copied to the new options object.
src/Options.ts:103
↓ 12 callers
Function
ordargument
(arg: AnyParseNode)
src/defineFunction.ts:218
↓ 12 callers
Method
parseExpression
* Parses an "expression", which is a list of atoms. * * `breakOnInfix`: Should the parsing stop when we hit infix nodes? This *
src/Parser.ts:189
↓ 9 callers
Function
makeFragment
( children: HtmlDomNode[], )
src/buildCommon.ts:412
↓ 8 callers
Function
escape
(text: unknown)
src/utils.ts:26
↓ 8 callers
Method
expect
* Checks a result to make sure it has the right type, and throws an * appropriate error otherwise.
src/Parser.ts:79
↓ 8 callers
Method
parse
* Main parsing function, which parses an entire input.
src/Parser.ts:120
↓ 8 callers
Method
withFont
* Creates a new options object with the given math font or old text font. * @type {[type]}
src/Options.ts:230
↓ 7 callers
Function
createClass
(classes: string[])
src/domTree.ts:27
↓ 7 callers
Method
endGroup
* End current nested group, restoring values before the group began.
src/Namespace.ts:39
↓ 7 callers
Function
isCharacterBox
(group: AnyParseNode)
src/utils.ts:61
↓ 7 callers
Function
makeSvgSpan
( classes?: string[], children?: SvgNode[], options?: Options, style?: CssStyle, )
src/buildCommon.ts:370
↓ 7 callers
Function
makeSymbol
( value: string, fontName: FontName, mode: Mode, options?: Options, classes?: string[], )
src/buildCommon.ts:64
↓ 7 callers
Method
reportNonstrict
* Report nonstrict (non-LaTeX-compatible) input. * Can safely not be called if `this.strict` is false in JavaScript.
src/Settings.ts:392
↓ 7 callers
Method
resolve
(name: string)
test/globals.d.ts:13
↓ 7 callers
Method
toMarkup
()
src/tree.ts:8
↓ 6 callers
Method
beginGroup
* Start a new nested group, affecting future local `set`s.
src/Namespace.ts:32
↓ 6 callers
Function
defineFunctionBuilders
({ type, htmlBuilder, mathmlBuilder, }: { type: NODETYPE; htmlBuilder?: HtmlBuilder<NODETYPE>;
src/defineFunction.ts:197
↓ 6 callers
Method
future
* Returns the topmost token on the stack, without expanding it. * Similar in behavior to TeX's `\futurelet`.
src/defineMacro.ts:22
↓ 6 callers
Method
hasClass
(className: string)
src/domTree.ts:192
↓ 5 callers
Method
consumeSpaces
* Consume all following space tokens, without expansion.
src/defineMacro.ts:32
↓ 5 callers
Method
future
* Returns the topmost token on the stack, without expanding it. * Similar in behavior to TeX's `\futurelet`.
src/MacroExpander.ts:88
↓ 5 callers
Method
havingBaseStyle
* Like `this.havingSize(BASESIZE).havingStyle(style)`. If `style` is omitted, * changes to at least `\textstyle`.
src/Options.ts:167
↓ 5 callers
Function
parseTree
( toParse: string | InstanceType<typeof String>, settings: Settings, )
src/parseTree.ts:11
↓ 5 callers
Method
pushToken
* Add a given token to the token stack. In particular, this get be used * to put back a token returned from one of the other methods.
src/MacroExpander.ts:107
↓ 5 callers
Function
r
(x: TemplateStringsArray | string | String)
test/helpers.ts:24
↓ 5 callers
Method
range
* Given a pair of tokens (this and endToken), compute a `Token` encompassing * the whole input range enclosed by these two.
src/Token.ts:43
↓ 5 callers
Method
sizingClasses
* Return the CSS sizing classes required to switch from enclosing options * `oldOptions` to `this`. Returns an array of classes.
src/Options.ts:265
↓ 5 callers
Method
sup
()
src/Style.ts:84
↓ 5 callers
Method
text
()
src/Style.ts:89
↓ 5 callers
Method
toNode
()
src/tree.ts:7
↓ 4 callers
Function
defineMacro
(name: string, body: MacroDefinition)
src/defineMacro.ts:122
↓ 4 callers
Function
expectKaTeX
(expr: any, settings?: any, mode?: any, isNot?: any, expectedError?: any)
test/helpers.ts:139
↓ 4 callers
Method
formatUnsupportedCmd
* Converts the textual input of an unsupported command into a text node * contained within a color node whose color is determined by errorColor
src/Parser.ts:313
↓ 4 callers
Method
getAttribute
* Gets an attribute on a MathML node.
src/mathMLTree.ts:75
↓ 4 callers
Method
getColor
* Gets the CSS color of the current options object
src/Options.ts:306
↓ 4 callers
Function
getCurrentSidebarWidth
()
static/main.js:121
↓ 4 callers
Function
isMobileViewport
()
static/main.js:53
↓ 4 callers
Function
lookupSymbol
( value: string, fontName: FontName, mode: Mode, )
src/buildCommon.ts:32
↓ 4 callers
Function
makeLineSpan
( className: string, options: Options, thickness?: number, )
src/buildCommon.ts:377
↓ 4 callers
Method
parseFunction
* Parses an entire function, including its base and all of its arguments.
src/Parser.ts:461
↓ 4 callers
Method
parseStringGroup
* Parses a group, essentially returning the string formed by the * brace-enclosed tokens plus some position information.
src/Parser.ts:630
↓ 4 callers
Method
popToken
* Remove and return the next unexpanded token.
src/defineMacro.ts:27
↓ 4 callers
Method
popToken
* Remove and return the next unexpanded token.
src/MacroExpander.ts:98
↓ 4 callers
Method
pushTokens
* Append an array of tokens to the token stack.
src/MacroExpander.ts:114
↓ 4 callers
Method
read_byte
(self)
src/metrics/parse_tfm.py:102
↓ 4 callers
Function
stretchyMathML
(label: string)
src/stretchy.ts:63
↓ 4 callers
Function
stretchySvg
( group: ParseNode<"accent"> | ParseNode<"accentUnder"> | ParseNode<"xArrow"> | ParseNode<"horizB
src/stretchy.ts:167
↓ 4 callers
Method
sub
()
src/Style.ts:85
↓ 4 callers
Method
toText
()
src/mathMLTree.ts:32
↓ 4 callers
Function
wrapFragment
( group: HtmlDomNode, options: Options, )
src/buildCommon.ts:426
↓ 3 callers
Function
assertSymbolNodeType
(node: AnyParseNode)
src/parseNode.ts:25
↓ 3 callers
Function
binrelClass
(arg: AnyParseNode)
src/functions/mclass.ts:81
↓ 3 callers
Function
buildMathML
( tree: AnyParseNode[], texExpression: string, options: Options, isDisplayMode: boolean, f
src/buildMathML.ts:283
↓ 3 callers
Method
callFunction
* Call a function handler with a suitable context and arguments.
src/Parser.ts:494
↓ 3 callers
Function
checkSymbolNodeType
(node: AnyParseNode)
src/parseNode.ts:39
↓ 3 callers
Function
cmd
()
dockers/screenshotter/screenshotter.js:98
↓ 3 callers
Method
consumeArg
* Consume an argument from the token stream, and return the resulting array * of tokens and start/end token.
src/defineMacro.ts:74
↓ 3 callers
Method
consumeSpaces
* Discard any space tokens, fetching the next non-space token.
src/Parser.ts:620
↓ 3 callers
Function
createConfig
* Create a webpack config for given target * @param {Target} target * @param {boolean} dev * @param {boolean} minimize * @returns {object}
webpack.common.js:66
↓ 3 callers
Function
cssStyleToString
(style: CssStyle)
src/domTree.ts:35
↓ 3 callers
Method
expandOnce
* Expand the next token only once if possible. * * If the token is expanded, the resulting tokens will be pushed onto * the stack in re
src/MacroExpander.ts:279
↓ 3 callers
Function
getCharacterMetrics
( character: string, font: string, mode: Mode, )
src/fontMetrics.ts:201
↓ 3 callers
Function
getCurrentMobileOptionsHeight
()
static/main.js:129
↓ 3 callers
Method
havingCrampedStyle
* Return an options object with a cramped version of the current style. If * the current style is cramped, returns `this`.
src/Options.ts:142
↓ 3 callers
Method
havingSize
* Return an options object with the given size and in at least `\textstyle`. * Returns `this` if appropriate.
src/Options.ts:150
↓ 3 callers
Method
isTight
()
src/Style.ts:90
↓ 3 callers
Method
isTrusted
* Check whether to test potentially dangerous input, and return * `true` (trusted) or `false` (untrusted). The sole argument `context` * sh
src/Settings.ts:464
↓ 3 callers
Function
makeOrd
( group: ParseNode<"spacing"> | ParseNode<"mathord"> | ParseNode<"textord">, options: Options, )
src/buildCommon.ts:169
↓ 3 callers
Function
mathsym
( value: string, mode: Mode, options: Options, classes: string[] = [], )
src/buildCommon.ts:109
↓ 3 callers
Function
normalizeArgument
(arg: AnyParseNode)
src/defineFunction.ts:212
↓ 3 callers
Method
parseGroup
* Parses an ordinary group, which is either a single nucleus (like "x") * or an expression in braces (like "{x+y}") or an implicit group, a group
src/Parser.ts:810
↓ 3 callers
Method
parseSizeGroup
* Parses a size specification, consisting of magnitude and unit.
src/Parser.ts:707
↓ 3 callers
Function
setMobileOptionsHeight
(height, shouldPersist)
static/main.js:99
↓ 3 callers
Function
setSidebarWidth
(width, shouldPersist)
static/main.js:67
↓ 3 callers
Function
sizeElementFromChildren
( elem: DomSpan | Anchor | HtmlDocumentFragment, )
src/buildCommon.ts:322
↓ 3 callers
Function
styleWrap
( delim: HtmlDomNode, toStyle: StyleInterface, options: Options, classes: string[], )
src/delimiter.ts:65
↓ 3 callers
Method
subparse
* Fully parse a separate sequence of tokens as a separate job. * Tokens should be specified in reverse order, as in a MacroDefinition.
src/Parser.ts:158
↓ 3 callers
Function
supportedCodepoint
(codepoint: number)
src/unicodeScripts.ts:117
↓ 3 callers
Function
syncSidebarWidthMode
()
static/main.js:152
↓ 3 callers
Method
withColor
* Create a new options object with the given color.
src/Options.ts:211
↓ 2 callers
Function
_match
(input, pattern)
contrib/mhchem/mhchem.js:380
↓ 2 callers
Function
assembleSupSub
( base: DomSpan | SymbolNode, supGroup: AnyParseNode | null | undefined, subGroup: AnyParseNode |
src/functions/utils/assembleSupSub.ts:12
↓ 2 callers
Function
buildA11yStrings
( tree: AnyParseNode | AnyParseNode[], a11yStrings: NestedArray<string> = [], atomType: Atom | "no
contrib/render-a11y-string/render-a11y-string.ts:689
↓ 2 callers
Function
buildExpression
( expression: AnyParseNode[], options: Options, isOrdgroup?: boolean, )
src/buildMathML.ts:168
next →
1–100 of 524, ranked by callers