Online LaTeX Editors

Vasilis Ververidis,123RF

Vasilis Ververidis,123RF

Sky Writing

You can edit your LaTeX documents with online editors that run across platforms and are device independent. Documents get saved online, thus giving you and other members of a work group easy access from anywhere.

Online editors for LaTeX documents cover a wide range of functionalities. At the most basic level, there is the formula editor, which uses LaTeX code for typesetting mathematical formulae. These formulae are then saved as image files for later use in an Office document. In addition, there are websites that simulate full LaTeX editors. These editors let you edit using LaTeX code and, typically, allow you to download the completed document as a PDF file afterwards.

Frequently, you will need to register, but once you do so, you will have access to a LaTeX editor and diverse templates, plus a storage location for your own documents. In many cases, you can share your documents with other users who have read and write permissions.

Formula Editors

A formula editor is actually not a full fledged LaTeX editor. These editors generate formulae from mathematical LaTeX code. You can download the formulae as image files and insert them into an Office document. These types of editors are interesting to users who as a rule use Office Suite to create documents, but who don't want to forego the excellent results achieved by LaTeX in typesetting formulae. From among the plethora of candidates available in this genre, I want to introduce two exceptional examples. These are the German language LaTeX-Formeleditor [1] and the English Daum Equation Editor [2].

The LaTeX-Formeleditor is tidy and plain, so it loads quickly. Despite the German language interface, it is very intuitive in its operation. Additionally, there is a brief set of instructions available as a PDF file. You can enter LaTeX code directly into the editor, or you can copy it to the editor. In addition, you have the option of clicking many formulae together using buttons for the most important mathematical symbols and functions. This lets novice users also use the program successfully.

You can download the finished formula as a PNG file using a link. This file will have a resolution ranging from 100 to 400 dpi. The editor makes the background transparent, or it fills it with a background color that you have defined in the RGB color model. The text color cannot be adjusted. Errors that occur when LaTeX code is edited get displayed by the editor. All of the formulae are stored permanently and can be downloaded as needed at any time via the corresponding link.

The Daum Equation Editor uses Adobe Flash and requires the corresponding plugin for your web browser. You can enter the code either directly or by combining the numerous templates from the large menu of symbols and formula. As with the LaTeX formula editor, you don't need LaTeX skills to use the Daum Equation Editor. You can save the LaTeX code and the finished expression as a PNG file. The program lets you select colors without restrictions for the text and the background from the RGB color model.

Admittedly, the Daum Equation Editor can only generate pure formulae. It will purposefully ignore LaTeX commands, such as \text{} for inserting text in a formula. It will typeset this text instead as a succession of variables in italics and without blank spaces.

Online Editors

Online LaTeX editors are web-based and simulate a full-fledged LaTeX editor. You type or copy your LaTeX code into the editor window and receive the finished document for downloading. These kind of online LaTeX editors are especially suitable for users who only occasionally use LaTeX to create simple documents and don't want to go to the effort of installing a complete LaTeX system on their computer. Regular LaTeX users can also profit from these online editors, since they can also work on a computer that is not equipped with the system and still use simple LaTeX documents. The most interesting specimen in this genre is TeXeR [3].

Other LaTeX services incorporate an online LaTeX editor into a complete platform that also makes templates and online storage space available. Ideally, this kind of package will let you share documents stored online for editing by other users. This makes it potentially possible for any member of a work group to work on a project. Examples in this category of editors include TeXonWeb [4], ShareLaTeX [5], and Overleaf [6].

TeXeR

The simple online LaTeX editor TeXeR offers a window with two panels. The editor sits in one of the panels and the preview in the other. This editor cannot open locally saved files. You will need to type or copy the LaTeX code into the editor panel. The finished LaTeX document is downloaded in PDF format. If an error occurs when LaTeX runs, you should take a closer look at the logfile for the LaTeX output and the error message.

Figure 1 shows TeXeR with the minimal example from Listing 1. Lines 5 and 17 to 19 have been commented out since TeXeR cannot incorporate images that have been stored locally. It takes two LaTeX runs to generate a table of contents for LaTeX documents. This does not work with TeXeR. In light of these restrictions, TeXeR is primarily suitable for the occasional user who does not want to install a LaTeX system locally but nonetheless wants the option of generating simple LaTeX documents.

Listing 1

Sample LaTeX file

§§number
01 \documentclass{scrartcl}
02 \usepackage[utf8]{inputenc}
03 \usepackage[T1]{fontenc}
04 \usepackage[english]{babel}
05 \usepackage{graphicx}
06 \title{Hello World}
07 \author{Paul Penguin}
08 \date{}
09 \begin{document}
10 \maketitle
11 \tableofcontents
12 \section{Hello Text World!}
13 This is a new sample text.
14 \section{Hello Math World!}
15 This is a new sample formula:\\
16 $ F(n) = \frac{(\varphi)^n - (-\frac{1}{\varphi})^n}{\sqrt{5}} $
17 \section{Hello Picture World!}
18 This is a new sample picture:\\
19 \includegraphics{pic.png}
20 \end{document}
Figure 1: The simple online LaTeX editor TeXeR does not incorporate data that is stored locally, nor does it generate a table of contents.

TeXonWeb

The Czech website TeXonWeb is also available in English. Although according to the developers, they are still fine tuning the corresponding localization. If you do not establish a user account, you will only have access to a simple LaTeX editor for entering LaTeX code by typing or copying.

You have the choice of generating the output file with either TeX or LaTeX. You can also select either one, two, or three program runs so that the program outputs documents like a table of contents correctly. The generated document can be downloaded as a Postscript or PDF file. There is a logfile for help with finding errors in the LaTeX code. It is not possible to incorporate locally stored images unless you have a user account.

Additional functions are made available to users with a user account. Providing a username and a password suffices to set up the account. TeXonWeb does not ask for an email address or personal data. Once logged into your account, you can open and edit locally saved files. In addition, the LaTeX files plus the images they incorporate can be stored on the TeXonWeb server. However,the website lacks a data privacy statement. Consequently, you should think carefully about what you want to upload to the server.

A menu and a function bar will appear in the editor. Both offer the possibility of adding LaTeX commands, a feature that is similar to locally installed versions of a LaTeX editor. There is also a spellchecker. Next to this is a very small selection of templates available for your use. These include a CD cover, a DVD cover, and a resume along with the curriculumvitae package. TeXonWeb does not offer the option of sharing data with other users. Figure 2 shows TeXonWeb with a minimal example from Listing 1.

Figure 2: TeXonWeb's editor window with expanded functions for users who are logged in. After registering, it is also possible to upload and incorporate images.

All in all, TeXonWeb has a rudimentary feel, but it is entirely suitable for individual users who don't want to install a local LaTeX system. This service is free to use and does not require personal data for setting up an account. On the other hand, it does not permit collaborative work, nor does it provide a data privacy statement for data that is stored on its server.

ShareLaTeX

The ShareLaTeX platform always requires that you register, and it comes with various pricing models. The free-of-charge version does not allow for collaborative project work with other registered users. The collaboration feature is part of the pay-to-play versions. These versions also maintain a document history for restoring earlier versions of a document, and they permit you to incorporate various online data storage services.

After registering and logging in, you can set up your first project. This can be done with an empty project, you can upload locally saved files, or if you are working with a paid version of the platform, also files from an online storage location. There are, in addition, a multitude of templates from which you can select a project. Figure 3 shows ShareLaTeX with the example from Listing 1.

Figure 3: The functions offered by the ShareLaTeX platform extend far beyond the requirements of a minimal example. This platform can even be used for complex projects.

The templates are primarily oriented to the needs of students and university faculty. Among other things, they include templates for bibliographies, books, theses, presentations, letters, resumes, business cards, class schedules, and barcodes. Many of the templates observe style guidelines for various colleges.

At its most basic, a project consists of a single LaTeX file. It can also contain multiple files and perhaps even images. There is a function for you to set up subfolders in a project where you can put things like images you have collected for storage.

The online editor ShareLaTeX offers a large variety of functions. One example would be tallying the word count for a project, something that is important in the university setting where there is often a minimum and maximum word count prescribed for an assignment. A spellcheck for various languages is also available. The autocomplete function simplifies use of the LaTeX commands. It would be great if there were a functions list that let you instantly add commands and LaTeX environments from the list.

The choices for generating a PDF file from your project include LaTeX, PDFLaTeX, XeLaTeX, and LuaLaTeX. ShareLaTeX also generates logfiles, which makes a search for errors easier. You can display the PDF file that has been generated with either the integrated viewer or with a locally installed PDF viewer. All of the documents that have been generated, as well as all of the project files, can be downloaded, so they can be archived locally.

The fee-based versions let you share projects with other registered users. You can decide whether these other users have read and write permissions. The documentation includes an introduction to LaTeX that is helpful for newbies and also a description of working with ShareLaTeX.

In general, ShareLaTeX makes a solid impression. Due to the template offering, it is especially well suited for academic clientele. It is too bad that collaborative work on projects is only available in the fee-based versions.

Overleaf

Like ShareLaTeX, Overleaf is also definitely better if you register. There are three price models to choose from. The free-to-use version limits the amount of online storage and the number of files per project, but it does support sharing projects with other users who can have read and write permissions. The fee-based versions let you integrate Dropbox, provide a document history for restoring earlier versions of documents, and let you secure a project. The platform offers student discounts.

As soon as you have registered and logged in, you can set up your first project. Depending on what you want, you can start with an empty project, upload locally stored files, or select from the large variety of templates. These include templates for articles, bibliographies, theses, books, presentations, calendars, resumes, and letters. Overleaf cooperates with the LaTeX Templates website [7], so you can open templates you find there directly in Overleaf.

A project consists of one or multiple LaTeX files and can also include images. subfolders inside of a project make file organization easier. The LaTeX editor integrates a preview, which displays changes to the LaTeX file in the completed document immediately (Figure 4). If you want to generate a PDF document from the project code, you can select from among LaTeX, PDFLaTeX, XeLaTeX, and LuaLaTeX. It is possible to download the generated PDF file, as well as the entire project.

Figure 4: Already in its free-use version, Overleaf makes it possible to collaboratively work on LaTeX documents and also use Git to synchronize project data between the server and local computer.

The fontspec [8] package lets you use several different fonts. Some well-known fonts are already available in Overleaf. You can upload your own from you computer. Comments are created in LaTeX files with the LaTeX command % or alternatively using a separate function in the editor that lets other users answer your comments.

The editor shows error messages as LaTeX runs. You can use the logfile to find the causes. An icon bar contains functions for use with editing and searches, as well as a small selection of LaTeX commands that you can insert with a press of the button. The autocomplete in LaTeX code makes it easier to use the commands. There is also a spellchecker for various languages.

Overleaf permits collaborative work even in the free-to-use version. Here the platform assigns three links to each project. One of these allows access for editing; the second contains a read permission. The third is a Git link via which you have the option of downloading project data from Overleaf as desired or synchronizing local changes to the project with the server(see the "Synchronizing Files with Git" box). The disadvantage is that anybody who knows the link has access to the project. Secured projects are those without links and are only available in the fee-based versions.

Synchronizing Files with Git

A Git link that is assigned to every Overleaf project allows the project to use Git [9] to synchronize between the server and a local computer. This makes it possible to also work on a project offline.

To synchronize, you should create or open a project and click in the header bar on the Share button. A dialog will appear where you will find the Git link for your project under the Clone With Git option. Now you should set up a local directory for the project using the mkdir from the command line and download the project from the server to this directory using:

git clone Git-Link

After making changes locally to the files, prepare them for the transfer to the server by using:

git commit -am "change"

Then you upload them with git push . If you have set up a new file locally that does not yet exist on the server, you can add it with git add <file> . Changes to the files on the server are downloaded to the local directory with git pull . Instead of using the command-line command, you can also use a graphical user interface for Git [10].

Conclusion

Both the occasional LaTeX user and the LaTeX professional will find what they need among the various online LaTeX editors that are available. The user who normally generates documents with an Office program does not need to forego the advantages offered by the formula set from LaTeX thanks to the existence of online formula editors. The user who doesn't have a LaTeX installation can still edit simple LaTeX documents using an online LaTeX editor. The user who regularly works with LaTeX can enjoy platforms that offer a multitude of templates, as well as integrated online storage space. This lets these users access their work at all times from anywhere. It also makes collaborative work possible.