Page MenuHomePhabricator

Need a way to write multiscripts around an expression
Open, Needs TriagePublic

Description proposes some hacks to attach scripts around a base:

(1) \sideset{_1^2}{_3^4}\prod_a^b
(2) {}_1^2\!\Omega_3^4

Note that the scripts "1" and "2" are not semantically attached to the base (but to a dummy "empty base"). Same for 3 and 4 in (1). Also (2) results in the generation of a negative space to do "as if" the prescripts were attached to the base. This is discouraged by the MathML spec (

These hacks are in particular problematic for assistive technologies.

The MathML spec has the <mmultiscripts> and <munderover> element for that purpose, see "multiscripts
& greek alphabet" on Joe Java's test

Note that itex2MML proposes the commands \tensor or \mmultiscripts to generate several pre/post scripts:

Event Timeline

fredw created this task.Jul 9 2015, 11:56 AM
fredw raised the priority of this task from to Needs Triage.
fredw updated the task description. (Show Details)
fredw added projects: Math, Mathoid, Accessibility.
fredw added a subscriber: fredw.
Restricted Application added a subscriber: Aklapper. · View Herald TranscriptJul 9 2015, 11:56 AM
Physikerwelt set Security to None.Jul 20 2015, 12:22 AM
Physikerwelt added a subscriber: Pkra.
Physikerwelt added a subscriber: Physikerwelt.

@fredw: I guess this is a MathJax problem.

Can you give an example of how the MathJax looks now and how it should look like

fredw added a comment.Jul 22 2015, 6:47 PM

I don't know what you mean by "how MathJax looks now and how it should look like". As said in the first comment, it's not a problem with the visual rendering but with the way the generated MathML, which has bad semantics and so makes things hard for assistive technologies.

As a comparison, here is what LaTeXML generates:

    <mo symmetric="true" movablelimits="false" largeop="true">∏</mo>
  <mi mathvariant="normal">Ω</mi>

Then e.g. a screen reader like Orca will correctly read the sub/sup/presup/presub/under/over scripts.

Alternatively, we could add support for the \prescript command from the mathtools package (, but this will still not work well if people use the "empty base" hack:

Restricted Application added a subscriber: StudiesWorld. · View Herald TranscriptJan 22 2016, 11:07 PM
Pkra moved this task from Incoming to Mathoid on the Math board.