Add svg and mathml support
This commit is contained in:
parent
cc3f85e6e1
commit
43b3236d3b
6 changed files with 150 additions and 8 deletions
50
src/mathml.rs
Normal file
50
src/mathml.rs
Normal file
|
|
@ -0,0 +1,50 @@
|
|||
//! Definitions for all non-deprecated MathML elements.
|
||||
//!
|
||||
//! <https://developer.mozilla.org/en-US/docs/Web/MathML/Element>
|
||||
|
||||
use crate::{Element, ElementKind};
|
||||
|
||||
macro_rules! element {
|
||||
( $name:ident ) => {
|
||||
element!($name, stringify!($name));
|
||||
};
|
||||
( $name:ident, $tag:expr ) => {
|
||||
pub fn $name() -> Element {
|
||||
Element::new($tag, ElementKind::Foreign)
|
||||
}
|
||||
};
|
||||
}
|
||||
|
||||
// MathML elements A to Z
|
||||
|
||||
// Deprecated and non-standard elements intentionally omitted.
|
||||
|
||||
element!(annotation);
|
||||
element!(annotation_xml, "annotation-xml");
|
||||
element!(math);
|
||||
element!(merror);
|
||||
element!(mfrac);
|
||||
element!(mi);
|
||||
element!(mmultiscripts);
|
||||
element!(mn);
|
||||
element!(mo);
|
||||
element!(mover);
|
||||
element!(mpadded);
|
||||
element!(mphantom);
|
||||
element!(mprescripts);
|
||||
element!(mroot);
|
||||
element!(mrow);
|
||||
element!(ms);
|
||||
element!(mspace);
|
||||
element!(msqrt);
|
||||
element!(mstyle);
|
||||
element!(msub);
|
||||
element!(msubsup);
|
||||
element!(msup);
|
||||
element!(mtable);
|
||||
element!(mtd);
|
||||
element!(mtext);
|
||||
element!(mtr);
|
||||
element!(munder);
|
||||
element!(munderover);
|
||||
element!(semantics);
|
||||
Loading…
Add table
Add a link
Reference in a new issue