New fraction line definition

fractions

1) How can we control the vertical alignment of this fraction line?

2) I'm also looking for a way to make the ends of the fraction line round.

I know doing these will cause problems. I'm just wondering how to do something like this.

enter image description here

Best Answer

The font parameters 8,9,10,11,12 determine the position of numerator and denominator see

What do different \fontdimen<num> mean

You can not draw the rule using different style unless you abandon the TeX fraction primitives alltogether and draw the rule by hand using tikz or similar. (the rule thickness is however settable).

enter image description here

\documentclass{article}

\begin{document}


$\frac{1}{2}$
\quad
\fontdimen9\textfont2=10pt
$\frac{1}{2}$
\end{document}
Related Question