Hi Bob
One of the examples at
http://tiddlywiki.com/plugins/tiddlywiki/katex/index.html shows one way of
doing what you want:
<div class="katex-display">
$$\displaystyle \left( \sum_{k=1}^n a_k b_k \right)^2 \leq \left( \sum_{k=1}^n
a_k^2 \right) \left( \sum_{k=1}^n b_k^2 \right)$$
</div>
But I agree that one might expect the “displaystyle” directive to do everything
necessary to centre the equation. There doesn’t appear to be any CSS class
assigned by default to indicate that the equation is in display style, though,
so it’s not clear that it could be implemented that way.
Best wishes
Jeremy
> On 3 Oct 2015, at 18:43, Bob Flandard <[email protected]> wrote:
>
> Hello,
>
> The KaTeX plugin is rather excellent and seems like magic, but I was
> expecting the \displaystyle mode to place the equation on a line of its own
> and centre-align it on the page (that's how they behave in LaTeX).
> I've tested this in TW5.1.9 and 5.1.10-prerelease with Firefox 41.0.1 on
> Windows 7.
>
> Here's some sample code that demonstrates the issue.
>
>
> This default "inline" equation works as expected
> $$f(x) = \int_{-\infty}^\infty\hat f(\xi)\,e^{2 \pi i \xi x}\,d\xi$$. Which
> is nice.
>
> ---
> But this "displaystyle" equation is not...
> $$\displaystyle f(x) = \int_{-\infty}^\infty\hat f(\xi)\,e^{2 \pi i \xi
> x}\,d\xi$$
> ...on a line of its own...
>
> ---
> ...and this "displaystyle" equation is not centre-aligned on the page.
>
>
> $$\displaystyle f(x) = \int_{-\infty}^\infty\hat f(\xi)\,e^{2 \pi i \xi
> x}\,d\xi$$
>
>
> Any workarounds?
>
> Thanks, Bob
>
>
>
>
>
>
> --
> 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]
> <mailto:[email protected]>.
> To post to this group, send email to [email protected]
> <mailto:[email protected]>.
> Visit this group at http://groups.google.com/group/tiddlywiki
> <http://groups.google.com/group/tiddlywiki>.
> To view this discussion on the web visit
> https://groups.google.com/d/msgid/tiddlywiki/cc53e10e-7040-4dd9-af05-6954e878b5fa%40googlegroups.com
>
> <https://groups.google.com/d/msgid/tiddlywiki/cc53e10e-7040-4dd9-af05-6954e878b5fa%40googlegroups.com?utm_medium=email&utm_source=footer>.
> For more options, visit https://groups.google.com/d/optout
> <https://groups.google.com/d/optout>.
--
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.
To view this discussion on the web visit
https://groups.google.com/d/msgid/tiddlywiki/B37BA09B-B64C-472D-B1A2-EF039E22A1B7%40gmail.com.
For more options, visit https://groups.google.com/d/optout.