Minutes: MathML meeting 8 April

Attendees:

David Carlisle

David Farmer

Patrick Ion

Paul Libbrecht

Louis Maher

Murray Sargent

Neil Soiffer

Laurence Zaysser

Moritz Schulbot

Deyan Ginev

Bruce Miller

Steve Noble

Thanks to Louis for once again taking notes.

Agenda:

1.  Announcements/updates

NS: Does not know if the call for a working group has been issued.

2. a) Paul will discuss how it works on MacOS (and iOS?)

# MathML in the clipboard: today's state

Paul Libbrecht, CC-BY-4.0

2021-04-08

---

## Questions

- can I copy a MathML expression and get MathML in the clipboard?

- can I paste this?

- can I operate on it?

---

## From markup in browsers

* Expecting MathML's non-strict requirement to export formulæ into the
clipboard as MathML-flavours

* E.g. from [the testsuite 1](
https://www.w3.org/Math/testsuite/build/main/General/Clipboard/clipboard1-full.xhtml)
or [2](
https://www.w3.org/Math/testsuite/build/main/General/Clipboard/clipboard2-full.xhtml
):

    * macOS: firefox: in HTML if done [in HTML5](
http://direct.hoplahup.net/tmp/tryMathmlCopy.html));

    * Safari: in HTML (without the math element)

  * iOS: (same as Safari apparently with continuity)

    * windows: TODO

    * Linux: TODO


---

## With JavaScript's Clipboard API

* Following the [test page](
http://direct.hoplahup.net/tmp/tryclipboardOps.html) and the Clipboard and
drag-and-drop spec of HTML5

  * Expect JavaScript to be able to export MathML flavours

* Test page shows it does transform the selection

* However no MathML-flavours in the clipboard (macOS, windows, Linux?)

  * ... but proprietary flavours containing the same

  * ... but HTML can be put (sanitised) inside

    * sanitisation looses MathML (currently)



---

## From Word-Processors

* Expecting a formula copied to be exported as MathML-flavours

  * Works with word (`public.mathml` and `public.mathml.presentation`)
(macOS, Windows?)

* Fails for OpenOffice, LibreOffice? TeXmacs?

* Fails for LaTeXIt (but copies plain-text MathML)

---

## To Web browsers?

* Expecting a formula as MathML-flavours to be pasted as MathML

  * JavaScript API?

    * no MathML from clipboard but full HTML apparently

  * Input-editors such as Wiris? Word365? GoogleDocs? Overleaf?

* similarly: Spreadsheets? Computer algebra systems? (in and out) Dynamic
geometry systems?

---

## Summary

* Very irregular support for MathML within clipboards:

  * very little for the MathML types

  * some presence in HTML and exotic types

  * Lots of experiences left to be made: a test-show?

* JavaScript rather poorer than markup copy or paste

* Long term strategy?

  * HTML to carry all of MathML (including all semantic alts)

  * MathML clipboard flavours (separate types)

* End-User's point of view: "it should work" (for getting evaluatable
formulæ: rather separate types)

* Author's point of view: "HTML can do it all" (and "let me put what I
want")

NS: We should write a paper on what should be done and who should do it.

PL: Browsers will not copy MathML into the clipboard.

PL: There is no clipboard specification.

NS: We should work with the HTML5 group to help solve this.

DC: You are not sure what you are selecting if you are using a wysiwyg
interface to copy math.

PL: This could be a browser-based selection problem.

BM: What do HTML5 people think should happen when selecting a math
expression.

LZ: we cannot be responsible for the structure of the tags that are copied.

NS: Says Chrome can copy a table from  a sub-table.

MS: If you select more than just the math expression, you may pick up the
MathML and be able to copy it into the clipboard.

DG: What do you do if you have presentation  MathML and content MathML in
the same expression?  Can you select it successfully?

MS: Says MS Word does this successfully because it only uses a single tree
to show a math expression.

PL: let this be solved by JavaScript if at all.

BM: Should the working group specify how math selection should be done in
browsers?

NS: The content tree might be able to guide the math selection process.

MS: Has a clipboard viewer to help him diagnose clipboard results.
(command-line tool “clip” on Windows)

   -

   Windows: ClipSpy <https://www.codeproject.com/articles/168/clipspy>
   -

   macOS: Clipboard Viewer <https://langui.net/clipboard-viewer/>




MS: We should  be able to specify that copying html5 should work.

NS: Said that once we are a working group, we should get more  browser
developer participation.

NS: We will have to be persuasive.  We can not make rules without developer
buy-in.

PL: We should keep a list of the problems we are encountering.

NS: E.g. inconsistencies, proposal to homogenize

<https://www.avast.com/sig-email?utm_medium=email&utm_source=link&utm_campaign=sig-email&utm_content=webmail&utm_term=icon>
Virus-free.
www.avast.com
<https://www.avast.com/sig-email?utm_medium=email&utm_source=link&utm_campaign=sig-email&utm_content=webmail&utm_term=link>
<#DAB4FAD8-2DD7-40BB-A1B8-4E2AA1F9FDF2>

Received on Thursday, 15 April 2021 04:58:12 UTC