ddoc latex/formulas?

Manu via Digitalmars-d digitalmars-d at puremagic.com
Thu Sep 15 04:02:40 PDT 2016


On 15 September 2016 at 19:50, Johan Engelen via Digitalmars-d
<digitalmars-d at puremagic.com> wrote:
> On Wednesday, 14 September 2016 at 11:36:11 UTC, Andrei Alexandrescu wrote:
>>
>> On 9/14/16 1:50 AM, Manu via Digitalmars-d wrote:
>>>
>>> Can we produce formulas, or latex in ddoc? Are there any examples in
>>> phobos I can refer to?
>>
>>
>> https://github.com/dlang/dlang.org/blob/master/latex.ddoc
>>
>> That's the macros file for generating the language spec in LaTeX format.
>
>
> I think what the man is asking for is a way to write formulas in DDoc,
> regardless of output format. Foremost, the math should display well on
> dlang.org.
>
> If you look at https://dlang.org/phobos/std_mathspecial.html#.gamma, there
> is some math there. But then if you look at the DDoc source,
> https://github.com/dlang/phobos/blob/master/std/mathspecial.d, it's pretty
> terrible how to get it done, and it is very limited (how would you get
> "sqrt(x+y)" to display well, or probably what Manu wants, how to get matrix
> math to display well?).
>
> A great addition to DDoc would be to allow LaTeX bits, like doxygen does,
> and render it nicely for both web and PDF output. You just mark a piece of
> text as <LatexStartsHere>....<LatexOut>.

Right, thank you.


More information about the Digitalmars-d mailing list