pub enum CommandSpecItem {
Show 14 variants
Cmd(CmdShape),
Env(EnvShape),
Symbol,
Command0,
Command1,
Command2,
CmdLeft1,
EnvMatrix,
EnvNormal,
EnvGlob {
pattern: String,
alias: String,
ctx_feature: ContextFeature,
},
SymAlias {
alias: String,
},
CmdGreedy {
alias: String,
},
CmdInfix {
alias: String,
},
CmdGlob {
pattern: String,
alias: String,
},
}
Expand description
An item of command specification. This enum contains more sugar than the canonical representation.
See crate::CommandSpecItem
for more details.
Variants§
Cmd(CmdShape)
A canonical command item.
Env(EnvShape)
A canonical environment item.
Symbol
A command that takes no argument, and its handler is also a typst symbol.
Command0
A command that takes zero argument, and its handler is a typst function.
Command1
A command that takes one argument.
Command2
A command that takes two arguments.
CmdLeft1
A command that takes one argument and is a left-associative operator.
EnvMatrix
A command that takes no argument and is a matrix environment.
EnvNormal
A command that takes no argument and is a normal environment.
EnvGlob
A command that has a glob argument pattern and is an environment.
Fields
ctx_feature: ContextFeature
The context feature of the command.
SymAlias
A command that is aliased to a Typst symbol.
CmdGreedy
A command that is greedy and is aliased to a Typst handler.
CmdInfix
A command that is an infix operator and is aliased to a Typst handler.
CmdGlob
A command that has a glob argument pattern and is aliased to a Typst handler.
Trait Implementations§
Source§impl Clone for CommandSpecItem
impl Clone for CommandSpecItem
Source§fn clone(&self) -> CommandSpecItem
fn clone(&self) -> CommandSpecItem
1.0.0 · Source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
source
. Read more