# LaTeX with accented characters

Hungarian language has a few accented characters (one of them used exclusively by Hungarians) so when I decided to use LaTeX for text editing purposes (and getting PDF as result) I had to make use of UTF8, but I didn’t expect it to be so poorly documented. This is my first venture into the LaTeX territory.

The expectations were:

• allowing using accented chars natively, so no “\’a” for “á” as the text would be incomprehensible
• be simple to use (write, save, run, get PDF)

The options are:

1. using Ubuntu’s LuaLaTeX as it is advertised to allow UTF8 characters in the document
2. installing any of those LaTeXes manually
3. using Ubuntu’s default texlive packages, with some \usepackage config in the document

Option #1 sucks.

Upon entering some accented characters, lualatex whines that it does not find ‘eu2enc.def’. Every advise on the net tells me to use texlive’s package manager, ‘tlmgr’. But Ubuntu uses its own package manager (apt) to install everything therefore Ubuntu doesn’t provide ‘tlmgr’. But Ubuntu doesn’t provide the ‘euenc’ package itself neither. However it is possible to install manually only the ‘euenc’ package, but now lualatex whines that it cannot find ‘xunicode.sty’. Crap.

Option #2 sucks.

It can be done, but it would take me at least a day with googleing, stackexchanging and whatnot. If I’d hate to spend time with my kids, I probably would have done it.

Option #3 might work.

It works because I’m lucky and I entered the proper string into Google that gave me a tex.stackexchange answer (the 50th this day) that I tried and it worked.

Yes, I could have read tons of documentation before experimenting but that would assume I understand some part of LaTeX, which I don’t. I only wanted to enter a frikkin’ string “áéíóúüűöőÁÉÍÓÚÜŰÖŐ” as MWE and see it in a PDF, nothing more. In short, I hate stuff that has such a steep learning curve.

Anyway, the solution is this (obviously I don’t exactly know what those package instructions do but honestly I don’t care):

\documentclass{article}
\usepackage[utf8]{inputenc}
\usepackage[T1]{fontenc}
\usepackage{lmodern}

\begin{document}
áéíóúüűöőÁÉÍÓÚÜŰÖŐ
\end{document}


and to convert it to PDF (and viewing it altogether):

> pdflatex minimal.tex && evince minimal.pdf