Hi.
I would like to place an image (a talking man) with a bubble text on it, just like in the image:
I followed some tutorials, but no luck.
Can you help me please?
Thank you.
Graphics, Figures & Tables ⇒ Bubble text
- Stefan Kottwitz
- Site Admin
- Posts: 10314
- Joined: Mon Mar 10, 2008 9:44 pm
Bubble text
Hi,
welcome to the forum!
This can be a start:
You can read about cloud callouts in the
tikz manual.
Stefan
welcome to the forum!
This can be a start:
Code: Select all
\documentclass{article}
\usepackage[demo]{graphicx}
\usepackage{tikz}
\usepackage{lipsum}
\usetikzlibrary{positioning,shapes.callouts}
\begin{document}
\begin{tikzpicture}
\node (man) {\includegraphics{man}};
\node [draw, align=center,
cloud callout, cloud puffs = 17, cloud puff arc=140,
callout pointer segments = 3, anchor = pointer,
callout relative pointer = {(330:2cm)},
aspect = 3, above left = 1.2 and 2 cm of man.north west]
{This is some text\\and some more in the next line.\\That's all.};
\end{tikzpicture}
\end{document}

Stefan
LaTeX.org admin
Bubble text
Hi Stefan,
I didn't even know that they are called "callouts".
Thank you so much for your help.
I didn't even know that they are called "callouts".
Thank you so much for your help.

Bubble text
Hi again,
I changed my preamble to this:
because it's much easier to switch languages inside my book.
Since then, my callout code:
shows me this error:
When I insert english text inside the callout, it works fine.
Why does greek text have problem with the tikzpicture?
I changed my preamble to this:
Code: Select all
\usepackage[Greek,Latin]{ucharclasses}
% Language declaration
\usepackage{xltxtra}
\usepackage{polyglossia}
\setmainlanguage{greek}
\setotherlanguages{english}
\setTransitionsForGreek{\selectlanguage{greek}}{\selectlanguage{english}}
% Fonts
\setmainfont[Kerning=On,Mapping=tex-text]{Myriad Pro}
Since then, my callout code:
Code: Select all
\begin{flushright}
\begin{tikzpicture}
\node (man) {\includegraphics{man}};
\node [draw, align=center,
cloud callout, cloud puffs = 19.5, cloud puff arc=90,
callout pointer segments = 2, anchor = pointer,
callout relative pointer = {(345:2.5cm)},
aspect = 3, above left = -1.5 and 2.5 cm of man.north west]
{Ένα δύο τρία\\
τέσσερα πέντε έξι\\
επτά οκτώ εννιά\\
δέκα έντεκα};
\end{tikzpicture}
\end{flushright}
Code: Select all
! Package tikz Error: Giving up on this path. Did you forget a semicolon?.
See the tikz package documentation for explanation.
Type H <return> for immediate help.
...
l.100 ^^Iτ
έσσερα πέντε έξι\\
This error message was generated by an \errmessage
command, so I can't give any explicit help.
Pretend that you're Hercule Poirot: Examine all clues,
and deduce the truth by order and method.
Missing character: There is no = in font nullfont!
! Illegal unit of measure (pt inserted).
<to be read again>
=
l.100 ^^Iτ
έσσερα πέντε έξι\\
Dimensions can be in units of em, ex, in, pt, pc,
cm, mm, dd, cc, bp, or sp; but yours is a new one!
I'll assume that you meant to say pt, for printer's points.
To recover gracefully from this error, it's best to
delete the erroneous units; e.g., type `2' to delete
two letters. (See Chapter 27 of The TeXbook.)
Missing character: There is no = in font nullfont!
Missing character: There is no ^^B in font nullfont!
Missing character: There is no τ in font nullfont!
Missing character: There is no έ in font nullfont!
Why does greek text have problem with the tikzpicture?
- Stefan Kottwitz
- Site Admin
- Posts: 10314
- Joined: Mon Mar 10, 2008 9:44 pm
Bubble text
It works when you hide it in a
Stefan
\parbox
:Code: Select all
\documentclass{article}
\usepackage[demo]{graphicx}
\usepackage{tikz}
\usepackage[Greek,Latin]{ucharclasses}
% Language declaration
\usepackage{xltxtra}
\usepackage{polyglossia}
\setmainlanguage{greek}
\setotherlanguages{english}
\setTransitionsForGreek{\selectlanguage{greek}}{\selectlanguage{english}}
% Fonts
\setmainfont[Kerning=On,Mapping=tex-text]{Times New Roman}
\usetikzlibrary{positioning,shapes.callouts}
\begin{document}
\begin{flushright}
\begin{tikzpicture}
\node (man) {\includegraphics{man}};
\node [draw, align=center,
cloud callout, cloud puffs = 19.5, cloud puff arc=90,
callout pointer segments = 2, anchor = pointer,
callout relative pointer = {(345:2.5cm)},
aspect = 3, above left = -1.5 and 2.5 cm of man.north west]
{\parbox{3cm}{\centering Ένα δύο τρία\\
τέσσερα πέντε έξι\\
επτά οκτώ εννιά\\
δέκα έντεκα}};
\end{tikzpicture}
\end{flushright}
LaTeX.org admin