Closed physikerwelt closed 9 years ago
When I looked into this a long time ago, it didn't seem very possible in the add-on sdk to pass the desired mime types from lib/main.js to data/*.js to implement a generic handler:
https://developer.mozilla.org/en-US/Add-ons/SDK/High-Level_APIs/context-menu
It seems that we can either:
Anyway, I was waiting that you told me exactly which mime type mapping you want before trying anything.
@fred-wang good. I'll discuss that with @HowardCohl.
If you look for example at http://drmf-beta.wmflabs.org/wiki/Definition:AffqKrawtchouk
You see that there are two tex-annotations
`...
I think I found a way to provide generic support. I sent you a mail with the XPI.
I call it "Semantic LaTeX".
My mail with the XPI was rejected by NIST's server. Here is how it looks like:
As you can see, I simply reuse the value of the "encoding" attribute, so now it's really up to decide how to call it.
@fred-wang Thank you very much. It works for me... was not blocked by TUB. To make the content menu smaller one could remove the two default items and use the annotation name as localization key... but that's up to you
Note that the "copy annotation" only copies annotation to the text clipboard (either the text content of the annotation or the serialized annotation-xml). "Copy MathML" is different: it copies the whole MathML formula, both into the HTML clipboard (to paste into any HTML editor) or into the text clipboard (the source code). I think "copy TeX" is also a quick shorthand for the most popular case and it's better not to remove it.
OK, it has already been approved by the AMO reviewers: https://addons.mozilla.org/en-US/firefox/addon/mathml-copy/
think "copy TeX" is also a quick shorthand for the most popular case and it's better not to remove it.
@physikerwelt So I finally submitted for review a new verson removing that item to save space. Now we only have "copy MathML" (as source flavor + as HTML flavor) and the copy annotation submenu for tex and others.
Yes, there is a lot of submenu items already. I'm not sure if the mathml font settings (from your other plugin) really deserve a submenu item. Especially since they are also displayed on pages without any math.
However, why do you need the math font settings plugin enabled? I basically only use it for testing purpose, but you can use the standard font preference menu or custom user stylesheet to configure your math font.
I discussed with @HowardCohl, that it would be nice to allow coping of other annotations (http://www.w3.org/TR/MathML3/chapter5.html#mixing.elements.annotation) like for example OpenMath, Mathematica or a Semantic TeX markup.