1

I'm writing a document with XeLaTeX where I often have to include stylised itemize environments as shown below (MWE follows):

Example itemize list

\documentclass[12pt]{book}

\usepackage{relsize}

\usepackage[quiet]{fontspec}
\setmainfont[Mapping=tex-text, Color=textcolor]{Arno Pro}
\newfontfamily\symbolsfont[Ligatures=TeX,Numbers=OldStyle,Scale=MatchLowercase]{AHLCGSymbol}
\newfontfamily\ornamentfont[Ligatures=TeX,Numbers=OldStyle,Scale=MatchLowercase]{Bodoni Ornaments ITC}

\usepackage[table]{xcolor}
\definecolor{ahTeal}{RGB}{36,72,64}

\newcommand{\ahcolor}{ahTeal}

\renewcommand\labelitemi{{\relsize{+4}\color{\ahcolor}\ornamentfont{Æ}}}
\renewcommand\labelitemii{{\relsize{+2}\symbolsfont{b}}}
\renewcommand\labelitemiii{{\relsize{+2}\symbolsfont{b}}}
\renewcommand\labelitemiv{{\relsize{+2}\symbolsfont{b}}}

\setcounter{secnumdepth}{-1}


\begin{document}

\begin{itemize}
  \item Step 1
  \begin{itemize}
    \item Option A
    \item Option B
    \begin{itemize}
      \item Sub\--option C
    \end{itemize}
  \end{itemize}
  \item Step 2
\end{itemize}

\end{document}

Every now and then, I need to show that some steps of these instructions are only required for an advanced setup. I was thinking to render such cases by superimposing the ornament on a round teal circle.

Using a special symbol for a item is quite easy:

...
\usepackage{wasysym}
...
\newcommand{\advanced}{{\relsize{+3}\color{\ahcolor}\CIRCLE}\hspace{-1em}{\relsize{+3}\color{white}\ornamentfont{Æ}}}
...
\item[\advanced] Step 2
...

However, the definition of \advanced is such that the two symbols are not properly aligned:

Misaligned symbols for Step 2

I've no idea how to fix this. What's the easiest way to properly render the symbol for the advanced steps? Shall I create a picture and use it instead? Thanks in advance!


The answer to the question "Alignment of custom item symbol in beamer" suggests a way to adjust symbols horizontally. Can it be done vertically as well?


In "itemize - alignment of custom bullet symbols" a few solutions with enumitem are reported, but can they be used when the symbols to align are two?

1 Answer 1

1

Inspired by the answers to the question "Vertically centering symbols and graphics inside math formulas", I've put together the following hacky solution:

\usepackage{amstext}

\newcommand*{\render}[1]{%
  \text{$\vcenter{\hbox{#1}}$}%
}

\newcommand{\advanced}{%
\render{\relsize{+2}\color{\ahcolor}\CIRCLE}%
\hskip-0.95em%
\render{\relsize{+3}\color{white}\ornamentfont{Æ}}}

...
\begin{itemize}
  ...
  \item[\advanced] Step 2
\end{itemize}

Which produces the following output:

Resulting output

I think it's not a very elegant solution (I'm talking to you, \hskip-0.95em) so if you have any better answer, please post it!

You must log in to answer this question.

Not the answer you're looking for? Browse other questions tagged .