Hi,

Peter from the MathJax team here.

> Question 1

As you mentioned, the usual way (from a MathJax point of view) is to store 
your macros in a configuration/extension file and load this alongside any 
other configuration file.

Some pointers from our docs

* You already mentioned 
http://docs.mathjax.org/en/latest/tex.html#defining-tex-macros
* This explains the file structure: 
http://docs.mathjax.org/en/latest/extension-writing.html#extension-to-define-tex-macros
 
* This explains how to load it with the CDN copy: 
http://docs.mathjax.org/en/latest/configuration.html#using-a-local-configuration-file-with-the-cdn.
 
* And https://github.com/mathjax/MathJax-third-party-extensions for more 
examples.

> Question 2

I don't know TW unfortunately but it seems like 

line 3699: [...]   var 
n=document.getElementsByClassName('story-river')[0];t.observe(n,{subtree:false,attributes:true,childList:true})
 
[...]

looks like the place that needs modifying. Again, I don't know TW, but 
perhaps all that's needed is to add more DOM nodes that are then observed.

You might want to cross post to the MathJax User Group 
<http://groups.google.com/forum/#!forum/mathjax-users> just in case.

Peter.


On Thursday, October 9, 2014 2:21:25 AM UTC+2, Antonio Vargas wrote:
>
>
>
> *Question 2:*
>>
>> Another problem I'm having with the MathJax plugin from kantorsite is 
>> that it fails to render math inside, *e.g.*, a reveal widget 
>>
>
> I used the following test and verified that the reveal widget works well 
> with KaTeX plugin in common browsers. Unfortunately, I can use it only in a 
> small percentage of my tiddlers (hundreds of tiddlers with lots of math 
> expressions used at real time in the classroom). But, one day, it will 
> match the power of MathJax (might take some time). I was surprised that 
> mathML didn't work well in chrome. 
>
>
> !Equation rendering in a reveal widget.
>
> * Tested in Linux with:
> ** Firefox 32.0.3, Google Chrome 37.0.2062.120 and Opera 12.16.1860
> * No Windows, no IE.
>
> <hr/>
> TEST 1: ''Chrome'': yes; ''Firefox'': yes; ''Opera'': yes (not 
> perfect)<br/>
> <$button set="$:/SampleRevealState1" setTo="show">Show ~KaTeX</$button>
> <$button set="$:/SampleRevealState1" setTo="hide">Hide ~KaTeX</$button>
>
> <$reveal type="match" state="$:/SampleRevealState1" text="show">
>
> @@font-size:400%;line-height:100%;
> $$\frac{1}{2}=0,5$$<br/>
> @@
>
> </$reveal>
>
> <hr/>
> TEST 2:  ''Chrome'': no; ''Firefox'':  no; ''Opera'': no<br/>
> <$button set="$:/SampleRevealState2" setTo="show">Show ~MathJax</$button>
> <$button set="$:/SampleRevealState2" setTo="hide">Hide ~MathJax</$button>
>
> <$reveal type="match" state="$:/SampleRevealState2" text="show">
>
> @@font-size:400%;line-height:100%;
> $\frac{1}{5}=0,2$<br/>
> @@
>
> </$reveal>
>
> <hr/>
>  TEST 3: ''Chrome'': no; ''Firefox'': yes; ''Opera'': yes<br/>
> <$button set="$:/SampleRevealState3" setTo="show">Show ~MathML</$button>
> <$button set="$:/SampleRevealState3" setTo="hide">Hide ~MathML</$button>
>
>
> <$reveal type="match" state="$:/SampleRevealState3" text="show">
>
> @@font-size:400%;line-height:100%;
> <math xmlns="http://www.w3.org/1998/Math/MathML";>
>   <mfrac>
>     <mn>1</mn>
>     <mn>2</mn>
>   </mfrac>
>   <mo>=</mo>
>   <mfrac>
>     <mrow><mi>x</mi><mo>+</mo><mn>1</mn></mrow>
>     <mrow><mi>y</mi><mo>-</mo><mn>25</mn></mrow>
>   </mfrac>
> </math>
> @@
>
> </$reveal>
>
>

-- 
You received this message because you are subscribed to the Google Groups 
"TiddlyWiki" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to [email protected].
To post to this group, send email to [email protected].
Visit this group at http://groups.google.com/group/tiddlywiki.
For more options, visit https://groups.google.com/d/optout.

Reply via email to