- break;
- }
- case MATH_HULL_CODE: {
- if (!doing_export)
- break;
- InsetMathHull * hull = insit.inset->asInsetMath()->asHullInset();
- hull->recordLocation(it);
- break;
- }
- case MATHMACRO_CODE: {
- // get macro data
- InsetMathMacroTemplate & macroTemplate =
- *insit.inset->asInsetMath()->asMacroTemplate();
- MacroContext mc(owner_, it);
- macroTemplate.updateToContext(mc);
-
- // valid?
- bool valid = macroTemplate.validMacro();
- // FIXME: Should be fixNameAndCheckIfValid() in fact,
- // then the BufferView's cursor will be invalid in
- // some cases which leads to crashes.
- if (!valid)
- break;
-
- // register macro
- // FIXME (Abdel), I don't understand why we pass 'it' here
- // instead of 'macroTemplate' defined above... is this correct?
- macros[macroTemplate.name()][it] =
- Impl::ScopeMacro(scope, MacroData(const_cast<Buffer *>(owner_), it));
- break;