Reputation: 45
is there a way to compile a LaTeX document with C#?
I want to program a standalone Windows application, that gives you a pdf-file without installing any other programs like miktex/etc.
Thanks in advance.
Upvotes: 3
Views: 2582
Reputation: 33
You can try C\verb|#|, if this form suits your purpose.
C\verb|#|
Upvotes: 0
Reputation: 508
Using LaTeX is similar to using a programming language or markup language, like HTML. You'll have to reimplement everything from LaTeX that you want to support in your C# program. This might be possible for a very small subset of the LaTeX standard, but you'll be reinventing the wheel. LaTeX is the most extensive markup language around with an enormous feature set with decades of development, it's not feasible to create a C# converter out of the blue for it.
To put it bluntly, it would be probably easier for you to create your own C# compiler than to come up with a feature complete LaTeX compiler.
If you can't change your input data, i.e. a LaTeX source, then you should use one of the existing LaTeX converters. If you're looking for a way to convert text source files with some markup data to PDF with C# then better look into a lightweight markup language like Markdown.
Upvotes: 4