MathMLViewer
Symbolica documentation for getting started, symbolic expressions, numerical evaluation, pattern matching, and APIs in Python and Rust.
MathMLViewer
class MathMLViewerShared streaming MathML viewer for Python and PyO3 expression providers.
Reuses popup pagination, inspection/back, keyboard zoom and notebook display. Responsive layouts and in-place expansion are optional source capabilities.
Methods
| Name | Description |
|---|---|
__init__ |
|
_repr_html_ |
|
_repr_mimebundle_ |
|
close |
Release the retained source, widget and cached pages. |
handle_message |
Process a frontend request; return (field, payload), or None. |
javascript |
Return the pager ES module with a dependency-free mount() export. |
page |
Return a bounded page and responsive layouts without widget dependencies. |
__init__
MathMLViewer.__init__(
source: MathMLPageSource,
page_size: int = 25,
*,
layout_count: int = 1,
supports_expansion: bool = False,
_automatic_product_preview: bool = False,
) -> None_repr_html_
MathMLViewer._repr_html_() -> str_repr_mimebundle_
MathMLViewer._repr_mimebundle_(
include: list[str] | None = None,
exclude: list[str] | None = None,
) -> dict[str, Any]close
MathMLViewer.close() -> NoneRelease the retained source, widget and cached pages.
handle_message
MathMLViewer.handle_message(message: dict[str, Any]) -> tuple[str, dict[str, Any]] | NoneProcess a frontend request; return (field, payload), or None.
javascript
MathMLViewer.javascript() -> strReturn the pager ES module with a dependency-free mount() export.
page
MathMLViewer.page() -> dict[str, Any]Return a bounded page and responsive layouts without widget dependencies.