Return the MathML associated with the current (navigation) node. The returned result is the `id` of the node and the offset (0-based) from that node (not yet implemented) The offset is needed for token elements that have multiple characters.
()
| 313 | /// The returned result is the `id` of the node and the offset (0-based) from that node (not yet implemented) |
| 314 | /// The offset is needed for token elements that have multiple characters. |
| 315 | pub fn get_navigation_mathml() -> Result<(String, usize)> { |
| 316 | return MATHML_INSTANCE.with(|package_instance| { |
| 317 | let package_instance = package_instance.borrow(); |
| 318 | let mathml = get_element(&package_instance); |
| 319 | return NAVIGATION_STATE.with(|nav_stack| { |
| 320 | return match nav_stack.borrow_mut().get_navigation_mathml(mathml) { |
| 321 | Err(e) => Err(e), |
| 322 | Ok( (found, offset) ) => Ok( (mml_to_string(&found), offset) ), |
| 323 | } |
| 324 | } ) |
| 325 | }); |
| 326 | } |
| 327 | |
| 328 | /// Return the `id` and `offset` (0-based) associated with the current (navigation) node. |
| 329 | /// `offset` (not yet implemented) |
nothing calls this directly
no test coverage detected