Take the 2-minute tour ×
TeX - LaTeX Stack Exchange is a question and answer site for users of TeX, LaTeX, ConTeXt, and related typesetting systems. It's 100% free, no registration required.

I'm not exactly familiar with how Anki processes the inline math expressions, but the developer advised me to ask this question on a Tex discussion platform:

The problem is that the rendered formulas are always placed a bit too high in the text. Like this:

enter image description here

How can I change this?

Edit:

All Anki does is combine the text on your card with the prefix and postfix in the deck options and send it to LaTeX, so if you're having layout problems you'll need to ask on a LaTeX forum.

The only related settings I could find are the LaTex header and footer:

Header:

\documentclass[12pt]{article}
\special{papersize=3in,5in}
\usepackage[utf8]{inputenc}
\usepackage{cancel}
\usepackage{amssymb,amsmath}
\pagestyle{empty}
\setlength{\parindent}{0in}
\begin{document}
\scriptsize

Footer:

\end{document}
share|improve this question

closed as off topic by diabonas, Seamus, Loop Space, Paulo Cereda, Marco Daniel Dec 15 '11 at 22:39

Questions on TeX - LaTeX Stack Exchange are expected to relate to TeX, LaTeX or related typesetting systems within the scope defined by the community. Consider editing the question or leaving comments for improvement if you believe the question can be reworded to fit within the scope. Read more about reopening questions here.If this question can be reworded to fit the rules in the help center, please edit the question.

8  
According to the Anki documentation - Advanced: LaTeX, Anki converts (La)TeX to PNG using dvipng, and even the documentation example shows the alignment you present. As such, I don't think this has anything to do with (La)TeX. It is perhaps the browsers default to insert images at the baseline the surrounding browser text. –  Werner Dec 14 '11 at 0:13
2  
The only solution I can think of is to place the text you want aligned in the LaTeX environment as well. i.e. [latex]$\sum_{n=0}^\infty a_n\cdot x^n$ \sf mit dem...[/latex] –  qubyte Dec 15 '11 at 4:01
    
This looks 'off topic' to me, as Werner says. –  Joseph Wright Dec 15 '11 at 8:33
    
I agree that this is off-topic. It is to do with the baseline adjustment for placing the image. You would need to find out the baseline for the text in the image relative to the bounding box (I guess, in principle, this would be information provided by TeX so that might be on-topic if you asked just that) and then pass those parameters to whatever-it-is that generates the HTML to adjust the placement of the image. –  Loop Space Dec 15 '11 at 11:40
    
The problem is not the LaTeX layout, though. It is the relative layout between the generated image and the surrounding text. The kind of "layout problem" that we could help you with would be one that was internal to the LaTeX, say if you wanted the subscript to be left-aligned on the summation. –  Loop Space Dec 15 '11 at 22:34

Browse other questions tagged or ask your own question.