Floating minipages and other wizardry

Inspired by a current issue from my friend the LaTeX Noob, I wanted to give a short explanation on how you can combine floats (i.e. figures) and minipages. Why should you care? Well, if you need tikzpicture or images placed besides eachother or beside text. So most people will probably need this at some point 😉 A great resource is the WikiBook, as always. If you want the lengthy account – that’s the way to go. For everybody else, an explanation of my own. Floats and non-floating boxes What are floats? Some fundamental explanations first: A figure is a float. A minipage is not a float but a box which sits at its fixed place. These are two fundamentally different things. When you combine them in a bad way, LaTeX might get fed up at this. So when planning your minipaging or floating situation, ask yourself which effects are really important to you and which aren’t. Do I even need

read more Floating minipages and other wizardry

Simple XML to LaTeX Transformation Tutorial

Today, I wanted to share this super simple XML to LaTeX tutorial. Using XSLT, you are going to transform XML data to LaTeX output which you can then go on to compile into your desired output PDF. There will be no fancy stuff whatsoever in this post, just the basics and what to keep in mind with these transformations. It is the quick intro to XML to LaTeX I did with my students a while ago which was done one day after they had their first contact with XSLT, so it should really be beginner-friendly. I labeled it “Advanced LaTeX” anyway because I think starting to automate things is always a step in the right direction 😉 Configuring the transformation scenario in Oxygen I am going to assume you use Oxygen now because that’s what a lot of people in the DH do and this post is directed towards my friends in the DH. Especially those who think print editions

read more Simple XML to LaTeX Transformation Tutorial

Fast typing LaTeX

I recently became aware of this post where somebody asked how you can become faster at typing LaTeX. Just a little post with a few recommendations. Experience from constantly using LaTeX for everything I have to say, I think it really gets better with experience. And experience from doing your everyday stuff in LaTeX (like to do lists, taking notes, etc.). Else you probably just won’t get enough experience to become really fast. Raise awareness But then again, slowing down might not be a bad thing if you’re supposed to produce high quality work. Using LaTeX, then, will force you to take the subconscious back into your conscious mind. Maybe not what you want when just quickly taking notes, but maybe something to reflect upon in the long term. I also found that, since I don’t constantly use MS Word’s auto-correct anymore, I’m actually better at spelling and grammar (even though, as someone holding a degree in Latin, I probably

read more Fast typing LaTeX

The power of simplicity, or: How to use tutorials

This is just a quick post, telling you to use tutorials selectively. If you don’t have time, don’t burden yourself with the not-so-short intro to LaTeX or 30 min introductions. Jumpstart in 3 minutes and go. This morning, I realized one thing: depending on what you want to do with LaTeX, you only need a very limited amount of commands. Even I use a very limited amout of commands for everyday tasks. Going through a whole tutorial might actually be a waste of time for you.   You only need 3-5 go-to commands What you always need (and, for example, an Overleaf blank document already supplies): You will typically need the general document setup (minimal example), \newpage, \maketitle, \tableofcontents, and \sections and \emph{}. For teaching documents, I will additionally need \textbf{boldface}, enumerate and itemize environments. Then maybe \href{http://latex-ninja.com}{links} (\usepackage{hyperref}), \texttt{typeface} for code or the verbatim environment. And, of course, I often use my cheatsheet template. For writing scientific articles, I

read more The power of simplicity, or: How to use tutorials

Jumpstarting: Learn LaTeX in 3 minutes

Inspired by the learn x in y minutes tutorials, here comes my contribution to starting LaTeX quickly. If you want to jumpstart learning LaTeX, open your Overleaf account (or get one, they just require your email, no other info, takes 30 seconds) and open a blank or example project. A blank project will give you the following output: You can now start typing text. Wherever you want, but for now, preferably below \section{Introduction} and in between \begin{document} and \end{document}. The stuff before is the settings which don’t interest you just yet. There you can see fields for title and author which \maketitle uses to make a title. This is what you can use to generate a title page later on. Now type a sentence below \section{Introduction}, then hit space twice. Write another test sentence. Hit space twice and write \subsection{test}. To see your changes, you need to ‘compile’ this source code into an output PDF. Do this in Overleaf by

read more Jumpstarting: Learn LaTeX in 3 minutes