Text Formattingbeamer | Horizontal Alignment in itemized List

Information and discussion about LaTeX's general text formatting features (e.g. bold, italic, enumerations, ...)
Post Reply
ferry2
Posts: 2
Joined: Sat Feb 25, 2012 4:20 pm

beamer | Horizontal Alignment in itemized List

Post by ferry2 »

Hy, everybody. I makе a presentation using beamer class. In one slide I have a tikzpicture and an itemize list. I want the list to be right-aligned to fit on the slide. I try to do that with \hfill, but it's not working. Here is the code of the frame:

Code: Select all

\begin{frame}
\begin{block}{Subprogram Solver}
\end{block}


\begin{itemize}
\item It's running n -- times; \\
\item $\overline{F}(\varphi) = -\varphi \, '' + \sin \varphi - \gamma$; \\
\item $\varepsilon$ -- stop--criteria. \\
\end{itemize}


\tikzstyle{my loop}=[->,to path={
.. controls +(300:1) and +(560:1) .. (\tikztotarget) \tikztonodes}]


\begin{tikzpicture}

\path (0, 0) node(a) [ellipse, draw] {$\varphi_0$};
\path (0, -1) node(b) [rectangle, draw] {$\varphi^n = \varphi^{n-1} + \tau_n \cdot w^n$};
\path (0, -3) node(c) [diamond, draw] {$\| \overline{F}(\varphi^n) \| < \varepsilon$};
\path (6, -3) node(d) [rectangle, draw] {Continue (we have a solution)};

\draw[->] (a) to (b);
\draw[->] (b) to (c);
\draw[->] (c) to node[above] {yes} (d);
\draw[->] (c) to (0, -5) node[right] {no} to (-2.5, -5) to (-2.5, 0) to (a);

\end{tikzpicture}

\end{frame}
I would be very grateful if someone could tell me a solution because I have a deadline for submission of presentation.

Recommended reading 2024:

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

NEW: TikZ book now 40% off at Amazon.com for a short time.

Stefan Kottwitz
Site Admin
Posts: 10345
Joined: Mon Mar 10, 2008 9:44 pm

beamer | Horizontal Alignment in itemized List

Post by Stefan Kottwitz »

Hi,

welcome to the board!

You could use \parbox or a {minipage} environment, which contains the {itemize} environment, and use \hfill before to push it to the right.

Code: Select all

\hfill
\parbox{.43\textwidth}{
  \begin{itemize}
    \item It's running n -- times;
    \item $\overline{F}(\varphi) = -\varphi \, '' + \sin \varphi - \gamma$;
    \item $\varepsilon$ -- stop--criteria.
  \end{itemize}}
slide.png
slide.png (11.87 KiB) Viewed 6926 times
There are ways to calculate the width of the box or to auto-size such as box, for example with the pbox package, but I guess here it might be sufficient for now to adjust the width manually as long as your longest list line doesn't break.

Stefan
LaTeX.org admin
ferry2
Posts: 2
Joined: Sat Feb 25, 2012 4:20 pm

Re: beamer | Horizontal Alignment in itemized List

Post by ferry2 »

Thaks a lot. It's working :) .
Post Reply