On Thu, 01 May 2014 07:18:50 +0200, Lex Trotman <[email protected]> wrote:

On 29 April 2014 22:53, j. van den hoff <[email protected]> wrote:
On Tue, 29 Apr 2014 14:29:53 +0200, Lex Trotman <[email protected]> wrote:

On 29 April 2014 21:16, jvdh <[email protected]> wrote:

Hi,

I've had another look at how to reasonably integrate mathematical (LaTeX) equations in my documents with the additional constraint of getting them
into pdf through the dblatex backend as well as into (x)html.

my understanding is that right now the only route to do that is to use
latexmath passthrough blocks (restricted to what latexmathML can do) and
use
xhtml output. while the dblatex/pdf output is fine, rendering in html
leaves
things to be desired (and in fact currently it stopped working for me at
all
for whatever reason the `latexmath' attribute is no longer
recognized...).
it also prevents inclusion of equations into the html output generated by
asciidoc directly.

I now have had a look at MathJax (for the first time) and it seems that
it
is quite powerful and that it should be quite easy to accommodate support for it in the latexmath macro (AFAICS): essentially what would be needed
is
to add something like

<script type="text/x-mathjax-config">
   MathJax.Hub.Config({tex2jax: {inlineMath: [['$','$'],
['\\(','\\)']]}});
</script>
<script type="text/javascript"


src="https://c328740.ssl.cf1.rackcdn.com/mathjax/latest/MathJax.js?config=TeX-AMS-MML_HTMLorMML";>
</script>

to the <head> section and to just reduce things like
latexmath:[$\sqrt(x)$]
in the source code to $\sqrt(x)$ in the asciidoc html (or a2x xhtml)
output
(or some other delimiter like the `\(, \)' defined above, if more
suitable).
the rest then would be taken care of by mathjax. in order not to
introduce
incompatibility with the present behaviour the above might be triggered
by a
new attribute `mathjax' or some such.

would this be feasible? or a bad idea?


I believe its been done several times before, for example here
http://comments.gmane.org/gmane.text.formats.asciidoc/3761 and other
earlier examples, but nobody has actually submitted it.  Asciidoc is


ah yes, thank you. that sounds very similar to what I have in mind.


now in github https://github.com/asciidoc/asciidoc so you can submit a
pull request.  Don't forget to do the documentation though :)


pull request in git(hub?)-speak meaning exactly what (not a git fanboy/user
here: I liked the previous choice (mercurial) much more)?
I presume you propose that I modify the asciidoc source code myself? I'd
rather would avoid that (zero experience with python, zero experience with css-stuff as well...). if everything else fails I might try to do this but
would prefer if someone in the know looks into this. my suspicion
is that it would be very easy for someone from the "core group" (inject a
bit of stuff in the <head> section and remove the passthrough block
indicator/delimiters around the LaTeX equations: probably not a big deal if you know you way around the source code). if that definitely would not be an
option I'd appreciate some advice, which files would need modification?

Well, since Stuarts retirement there is no "core group" so if users
don't submit changes they probably won't happen.

understood. I was not aware of the fact that asciidoc is no longer actively maintained.


Your description above is pretty right at first glance, the changes
would be in xhtml11.conf and html5.conf I think.

I had a short look but obviously these are specific config files parsed by asciidoc and I don't really understand the syntax and logic behind it. this obviously would require to dive deeper into asciidoc design and code then I would like to do. also, I would think that the `conf' files only allow to adjust the way the pass through blocks are treated but not the injection of stuff into the <head> section. where would that be done?

thanks

joerg


Cheers
Lex



thanks

joerg



Cheers
Lex


I believe that improving support for mathematical typesetting could
increase
asciidocs popularity in the corresponding communities.

thank you

joerg

--
You received this message because you are subscribed to the Google Groups
"asciidoc" 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/asciidoc.
For more options, visit https://groups.google.com/d/optout.




--
Using Opera's revolutionary email client: http://www.opera.com/mail/


--
You received this message because you are subscribed to the Google Groups
"asciidoc" 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/asciidoc.
For more options, visit https://groups.google.com/d/optout.



--
Using Opera's revolutionary email client: http://www.opera.com/mail/

--
You received this message because you are subscribed to the Google Groups 
"asciidoc" 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/asciidoc.
For more options, visit https://groups.google.com/d/optout.

Reply via email to