Live data from Hacker News

I don't always use LaTeX, but when I do, I compile to HTML (2013)

peterkrautzberger.org

51–60 of 152 posts

Re: I don't always use LaTeX, but when I do, I compile to HTML (2013)

#51

Earlier quoted context omitted.

What's the advantage of that subshell redirection over a simple pipe?

I don't know if there's an advantage, haha. It was just the first thing that came to mind. Looks like a pipe is also supported; you just need to pass `-` as the name of the file to `latexmlpost`. latexml mydoc.tex | latexmlpost --dest=mydoc.html --format=html5 -

You can actually also use the latexmlc omni-executable [1] (that is part of the latexml distribution), which can convert to html in one command:

    latexmlc --dest=mydoc.html --format=html5 mydoc.tex

[1] https://math.nist.gov/~BMiller/LaTeXML/manual/commands/latex...

Re: I don't always use LaTeX, but when I do, I compile to HTML (2013)

#52
post #35

The recommendation to use Markdown+MathJAX fall short when you want to write longer documents with numbered section, subsection, and theorem/definition/figure etc tracking and referencing. I'm sure with Sphinx and reStructuredText you can get that large-scale document tracking stuff, but with LaTeX it just works for the most part and you don't need to juggle a bunch of different side-projects and extensions. Plus you…

I searched for a comment to supports the fact that LaTeX shines in certain areas.

My memory of LaTeX has weakened over the years, since I am not writing long texts with lots of figures and such, but I know it's more than this statement let's on in the article: "Something that is more modern than learning a hundred bits of print typesetting that your student will never, ever need?"

What exactly is, in the end, is 'modern'? Is it because there is less syntax in Markdown to remember and the Modern is syntax-adverse? :D Aren't there editors for these in the first place to avoid the daily grind of remembering syntax?

Re: I don't always use LaTeX, but when I do, I compile to HTML (2013)

#54

Earlier quoted context omitted.

I write a fair amount of reports professionally and I use word. Getting data from my Python analysis into the reports are tedious at best and updating numbers last minute is hair pulling frustrating. But because of the good wysiwyg I can cheat on my adjustments when I need a graph to go “just there”, I can edit my paragraph wording such that I don’t get a almost completely blank page in between sections, etc, etc whi…

There's a lot you can do with latex to automatically import data and update automatically from external sources, and while it might seem counter-intuitive it is much easier and less effort than Word's wysiwyg interface.

I'm jealous of how easy it is to import data when using a structured source code like format such as rst, markdown or latex. I'm sticking with word because I can easily do small layout adjustments like decreasing the margins of a table to make it fit on a page, or easily see when a paragraph is 1 or 2 words too long, causing it to shift all sorts of elements across pages.

Re: I don't always use LaTeX, but when I do, I compile to HTML (2013)

#55

Sphinx and reStructuredText are, IMHO, underrated power houses of document building. With extensions, you can hook them up to Zotero (or whatever)-managed bibtex files. You can render to beautiful HTML files, and you get latex PDFs and epubs for free. First class latex-math support, plenty of integrations with things like mermaid, graphviz, and the ability to build super-powerful custom directives to do basically any…

It is too complex compared to Markdown and hasn't got enough features to be comparable to Latex. And I still (almost) use the samé Latex templates that I used at university, 25 years ago.

Re: I don't always use LaTeX, but when I do, I compile to HTML (2013)

#56
post #27

Earlier quoted context omitted.

I guess latex is still unbeatable for writing complex math expressions. These days, when I don't need that, I'm happy with AsciiDoc.

Sphinx/reStructuredText supports math in LaTeX input format [1], so you can still go nuts with complex math expressions while still benefitting from the relative simplicity. [1] https://www.sphinx-doc.org/en/master/usage/restructuredtext/... Looks like AsciiDoc supports similar latex math blocks [2]. Are there reasons you can't stick with that when doing math? [2] https://docs.asciidoctor.org/asciidoc/latest/stem/#bl…

For example: writing complicated expression invovling calculus/matrix. That's not something I need everyday, though.

Re: I don't always use LaTeX, but when I do, I compile to HTML (2013)

#57

Sphinx and reStructuredText are, IMHO, underrated power houses of document building. With extensions, you can hook them up to Zotero (or whatever)-managed bibtex files. You can render to beautiful HTML files, and you get latex PDFs and epubs for free. First class latex-math support, plenty of integrations with things like mermaid, graphviz, and the ability to build super-powerful custom directives to do basically any…

I forced myself to use it recently, I mostly found it to be both limited (cannot have part of a link in bold or italics) and inconvenient (each line of inline code must be indented).

Re: I don't always use LaTeX, but when I do, I compile to HTML (2013)

#58

Tangently related, does anyone have experience with AsciiDoc? I've used reStructuredText before, but AsciiDoc is tempting, it looks cleaner.

You have also AsciiDoctor ( https://asciidoctor.org/ ) which is alive and well. I am using it for technical CS documentation internally, but only for single page documents. I did not try to deploy their whole multi-document setup called Antora ( https://antora.org/ ).

Re: I don't always use LaTeX, but when I do, I compile to HTML (2013)

#59

Earlier quoted context omitted.

There's a lot you can do with latex to automatically import data and update automatically from external sources, and while it might seem counter-intuitive it is much easier and less effort than Word's wysiwyg interface.

I'm jealous of how easy it is to import data when using a structured source code like format such as rst, markdown or latex. I'm sticking with word because I can easily do small layout adjustments like decreasing the margins of a table to make it fit on a page, or easily see when a paragraph is 1 or 2 words too long, causing it to shift all sorts of elements across pages.

You can do that with Latex as well? I use TexStudio which has a preview pane. Any time I make changes I hit f5 and it updates pretty quickly. It's not instantly but pretty close to it, and there are already less problems with things shifting around because it manages that better than Word does, by design.

Re: I don't always use LaTeX, but when I do, I compile to HTML (2013)

#60
I feel ambivalent to LaTeX.

I don't like the language, the ecosystem is too big, complicated and breaks, but the end result is hard to do any other way.

This applies both the equations part, and the text reflow part (I think them as separate things, but they usually go together).

It should be possible to write text in HTML or markdown, and write the equations in latex or asciimath, and turn it into a beautiful/article style pdf, but sadly it is not.

Although CSS (colored and rounded boxes and such) + MathJax-SVG also can look nice.

Post reply on HN