Another implementation would have been to use the lspace and rspace attributes in MathML, but they require to give the exact spacing before and after the operator instead of relying on rules like TeX.
For instance, `$a\mathbin{+}b$` resulted in this MathML output before the patch:
```
<math xmlns='http://www.w3.org/1998/Math/MathML'>
<mrow>
<mi>a</mi><!-- -->
<mi>[mathbin [char + mathalpha]]</mi>
<mi>b</mi>
</mrow>
</math>
```
For comparison, this was the output with LyX 2.3.7
```
<math xmlns="http://www.w3.org/1998/Math/MathML">
<mrow>
<mrow><mi>a</mi><!-- -->
<mi>[mathbin [char + mathalpha]]
</mi><mi>b</mi>
</mrow>
</mrow></math>
```
After this patch, it looks like:
```
<math xmlns='http://www.w3.org/1998/Math/MathML'>
<mstyle class='math'>
<mrow>
<mi>a</mi>
<mo>+</mo>
<mi>b</mi>
</mrow>
</mstyle>
</math>
```
This does now apply to the whole inset or paragraph group (not to the
current paragraph only) unless the new boolean AllowedOccurrencesPerItem
is set and we are in a list-type environment.
Amends 729ab602ca
This allows to restrict the use of flex insets to specific contexts.
Note that this is currently very basis. It only considers immediately
containing insets/layouts and can be surpassed via cut and paste.
The use case that made me finally implement this are macros in covington
that make sense only in specific environments (but also consider \inst
in some article classes)
A new counter type \superarabic is introduced, that transforms the
counter into superscript Unicode numbers.
This is used for the footnote counter.
The Foot inset layout is modified to use an empty LabelString (in size
Normal, since the numbers could be too small).
We use this occasion to set footnote text in footnotesize, as it should.
A couple of changes are done to the code to make the button label and
tooltip look better.
Fixes bug #12238.
* put the code that is called both from Buffer and InsetBrach in the
two helper methods Buffer::branchActivationStatus() and
Buffer::branchActivationDispatch().
* Cleanup the code so that _MASTER_ lfuns are disabled when there is
no master document.
* When changing branches in the master buffer, make the buffer visible
if it is not, and make sure that undo information is recorded.
* The code in Buffer::dispatch is used first, and it gives control to
the branch inset code if no branch name has been specified.
Fixes bug #12588.
* do not try to dissolve a macro template inset (avoids a crash)
* disable inset-dissolve when an argument is given
* when triggered by the AtPoint mechanism, make sur to dissolve the
right inset.
Fixes bug #12562.
Each removed inheritFont method is replaced by a 'InheritFont false'
line in the relevant InsetLayout entry.
Add code to layout2layout that does this automatically when the entry
is missing.
The case of InsetScript is special, since the inheritFont() was not
needed here: the default is indeed true.
Fixes bug #12238.
The font inside the inset is inherited from the parent for LaTeX
export if this parameter is true, as well as on screen. Otherwise
the document default font is used.
The default value is true.
Update tufte layouts to use this tag for sidenote and marginnote flex
insets.
Increase layout format to 101.
Fixes bug #12238.
Change KeyMap::getBinding to return FuncRequest::prefix in this case.
Add handling of this case in PrefShortcuts::validateNewShortcut.
What does not seem to work is that if, for example, accent-acute is
bound to M-s (which is a prefix for size-related bindings), and then
the binding is removed, the functions are not visibly restored.
Part of bug #10131.
It turns out that it is possible to use macros with parameters in lib/symbols.
I use this to simplify the use of mod-like macros.
Update documentation.