I could not find the symbol of the image below which is in a book in my possession. I honestly do not remember where I saw it. Could someone help me where this symbol is located? This symbol (red rectangle) does not exist in the Comprehensive LATEX Symbol List by Scott Pakin.
8 Answers
Here is a TikZ solution.
\documentclass{article}
\usepackage{blindtext}
\usepackage{tikz}
\newcommand{\glasses}{\resizebox{3em}{!}{%
\tikz{\draw(0,0) coordinate (Origin) --++(0.2,0) coordinate (endL) arc (180:0:0.05)--++(0.2,0) coordinate (endR) --++(45:0.25) arc (180-45:0:0.08) (endR) arc (0:-180:0.1) (endL) arc (0:-180:0.1) (Origin)--++(45:0.25) arc (180-45:0:0.08);
}}}
\begin{document}
\noindent
\glasses\ \textsc{Attention}. \blindtext
\end{document}
-
6
-
3
\documentclass{article}
\usepackage{tikzducks}
\begin{document}
\tikz{\duck[invisible,squareglasses]}
\tikz{\duck[invisible,glasses]}
\tikz{\duck[invisible,sunglasses]}
\end{document}
-
13
-
@DavidCarlisle How can you target them with your fork if you don't see them? Aug 23, 2018 at 20:18
-
2
-
15NOW I know what the
invisible
option is good for. ;-)– user121799Aug 24, 2018 at 5:27 -
The unicode character EYEGLASSES
, code U+1F453
👓
seems to be what you are looking for.
-
1I would also like to thank you very much for your answer, which I am obviously voting for +1. Aug 24, 2018 at 20:00
-
7
\documentclass{article}
\usepackage{fontawesome5}
\begin{document}
\faGlasses\textsc{Attention:}
\end{document}
-
Marcel thank you very much for your answer. I am young, they seem used glasses :-). I do not like are too showy. Aug 23, 2018 at 20:19
-
3@Sebastiano If you own Font Awesome Pro, you can also use [light] or [regular] glasses. They look much better with non-bold text. Aug 23, 2018 at 20:28
\documentclass{article}
\usepackage{graphicx}
\begin{document}
\noindent\includegraphics[height=1.5em]{zzz.png} \textsc{Attention} zzz
z zzz zzz zzzzzzz zzz z z z z zzzzz z z zzzzzzzzz zzz zzzz zzzzzzzz zzzzz.
\end{document}
where zzz.png
is just a cropped version of the image you posted.
-
2Thank you very much, but do not get angry with me politely. I'm not as good as you are but it's really ugly an image like this. It looks like a book from the '800 :-) Aug 23, 2018 at 20:17
-
3@Sebastiano yes but I cropped the image you posted, you could use a higher resolution scan of the original or as I said in the original comment use a google image search there are literally thousands of available line drawings you could use. Aug 23, 2018 at 20:19
-
3@Sebastiano An improved solution to David's would be to use a drawing software like Inkscape to trace the shape and convert it to a vector image. This should be rather easy with any similar software.– IanAug 24, 2018 at 8:25
-
3@Sebastiano This is the most general answer. Just google an image and use it. Or if you want something more fancy, search for fonts that have glasses as symbol (examples here) and import that symbol probably with XeLaTeX). Aug 24, 2018 at 11:33
-
@luchonacho I am writing a book together with a university colleague and there are many vector images. I was curious to know if there was a symbol of the glasses that I saw somewhere but I do not remember. Greetings. Aug 24, 2018 at 19:39
vector graphic = perfect quality
\documentclass{article}
\usepackage{graphicx}
\begin{document}
\includegraphics[height=1em]{glasses.pdf} Attention!
\end{document}
-
17
-
1@Arsenal On the web there are many vectorial pictures of glasses. It would be interesting to know where he found a beautiful vector image with glasses. Aug 25, 2018 at 21:30
-
-
2
-
No images, no unicode characters, not tikz, no invisible ducks :(
Macho programmers use only ASCII. :)
\documentclass{article}
\usepackage{graphicx}
\def\glasses{{\sffamily
\leavevmode\rlap{%
\rotatebox[origin=tr]{125}{J}\kern1ex%
\rotatebox[origin=tr]{125}{J}}%
\rotatebox[origin=c]{-90}{D}%
\rotatebox[origin=c]{-90}{D}}%
\def\ialy{\sffamily
\resizebox{1ex}{1.5ex}{\reflectbox{\rotatebox[origin=]{75}{J}}}\kern-1pt%
\rlap{\tiny$\ ^\bullet\kern2.5pt^\bullet$ }%
\rotatebox[origin=c]{-90}{D}%
\rotatebox[origin=c]{-90}{D}\kern-1pt%
\resizebox{1ex}{1.5ex}{\rotatebox[origin=]{75}{J}}}}
\begin{document}
My pure \TeX(t) glasses \glasses\par
I am looking you \ialy
\end{document}
-
:-) ;-) double smiles for you and thank you very much to your answer +1. Sep 6, 2018 at 12:34
Without any packages
\documentclass{standalone}
\begin{document}
\begin{picture}(100,60)
\put(20,20){\line(1,1){20}}
\put(60,20){\line(1,1){20}}
\put(20,20){\line(1,0){17.5}}
\put(42,20){\line(1,0){17.5}}
\put(28.5,20){\oval(17.5,15)[b]}
\put(51,20){\oval(17.5,15)[b]}
\put(39.7,20){\oval(5,5)[t]}
\put(80,35.2){\oval(10,10)[rt]}
\put(40,35.2){\oval(10,10)[rt]}
\end{picture}
\end{document}
-
Welcome to TeX.SX! - Maybe you could go on with Defining a custom symbol by path in TikZ. Thanks for your help. Sep 25, 2018 at 19:20
-
@Bobyandbob Thanks for welcome! About "Defining a custom symbol by path in TikZ": sorry, I don't know how scale :(– danielSep 25, 2018 at 19:35
-
An option could be
\resizebox{0.5cm}{!} { \begin{picture}(100,60) ... \end{picture} }
- See Is there a way to slightly shrink a table, including font size, to fit within the column boundaries?. If you can't solve it, you have to ask a new question. Sep 25, 2018 at 19:48 -
1@Bobyandbob I put answer to the "Defining a custom symbol by path in TikZ" question. Thank you for suggestion!– danielSep 25, 2018 at 20:05
\includegraphics{zzz}
for any picture of glasses that you find with a google image search