Text FormattingWhy does my itemize render wrong?

Information and discussion about LaTeX's general text formatting features (e.g. bold, italic, enumerations, ...)
Post Reply
rain
Posts: 12
Joined: Thu Jan 28, 2016 9:00 pm

Why does my itemize render wrong?

Post by rain »

Hi. Why does my itemize render the wrong way? Like MRQ is more left than others.

Code: Select all

\begin{itemize}
\item[MRQ] How to publish personal data in a way that preserves privacy?
\item[RQ1] What are the risks of publishing personal data and what methods can be used to mitigate these risks?
\item[RQ2] What anonymization operations implement privacy-preserving methods?
\item[RQ3] What is the prototype for learning these privacy-preserving methods?
\item[RQ4] What is usability of the prototype?
\end{itemize}
itemize.png
itemize.png (69.93 KiB) Viewed 2329 times
And how I could fix it?
Last edited by cgnieder on Fri May 19, 2017 4:40 pm, edited 1 time in total.

Recommended reading 2024:

LaTeXguide.org • LaTeX-Cookbook.net • TikZ.org

Learn LaTeX easily with newest books:

The LaTeX Beginner's Guide: 2nd edition and perfect for students writing a thesis

The LaTeX Cookbook: 2nd edition full of practical examples for mathematics, physics, chemistry, and more

LaTeX Graphics with TikZ: the first book about TikZ for perfect drawings in your LaTeX thesis

User avatar
Stefan Kottwitz
Site Admin
Posts: 10359
Joined: Mon Mar 10, 2008 9:44 pm

Why does my itemize render wrong?

Post by Stefan Kottwitz »

You could use the enumitem package for customizing lists, such as:

Code: Select all

\documentclass{article}
\usepackage{enumitem}
\setlist[itemize]{align=left,leftmargin=*,itemindent=!}
\begin{document}
\noindent text
\begin{itemize}
  \item[MRQ] How to publish personal data in a way that
             preserves privacy?
  \item[RQ1] What are the risks of publishing personal data and
             what methods can be used to mitigate these risks?
  \item[RQ2] What anonymization operations implement
             privacy-preserving methods?
  \item[RQ3] What is the prototype for learning these
             privacy-preserving methods?
  \item[RQ4] What is usability of the prototype?
\end{itemize}
\end{document}
Btw. it would be great if you would post code like I did: using the Code button (the LaTeX button is for inline LaTeX, code within text), and posting as small compilable example for easy testing. Code boxes are automatically linked to the online LaTeX editor Overleaf, so readers can test and improve starting with a single click. That improves the chance to get a solution. ;-)

By the way, I think a description list would be better than itemize here.

Without any package:

Code: Select all

\documentclass{article}
\begin{document}
\noindent text
\begin{description}
  \item[MRQ] How to publish personal data in a way that
             preserves privacy?
  \item[RQ1] What are the risks of publishing personal data and
             what methods can be used to mitigate these risks?
  \item[RQ2] What anonymization operations implement
             privacy-preserving methods?
  \item[RQ3] What is the prototype for learning these
             privacy-preserving methods?
  \item[RQ4] What is usability of the prototype?
\end{description}
\end{document}
Stefan
LaTeX.org admin
Post Reply