I need to insert a ⚓ into my latex document. (More info about the symbol can be found here) I have tried to use some other answers here but I have not been successful, including the question Entering Unicode characters in LaTeX, but I couldn't get anything to work. I installed texlive-xetex (Should say I am using ubuntu 10.04) but that didn't like the custom document class I am using.
This is XeTeX, Version 3.1415926-2.2-0.9995.2 (TeX Live 2009/Debian)
entering extended mode
(./design.tex
! Undefined control sequence.
l.1 \documentclass
{project}
I also tried
\usepackage[utf8]{inputenc}
and
\usepackage[utf8x]{inputenc}
but they just bombed out without an error (however they were ok for the The vorticity $ω$ is defined as $ω = ∇ × u$.
text.
So anything else I can try?
Edit: Ok so using the right command helped... (I'm relativly new to latex and never heard of xetex before!) Martigan: I don't know what a MWE is... :(
So I have commented out inputenc and it runs / compiles / what ever the proper word is when I run xelatex design.tex
but the ⚓ doesn't show up.
I have also just discovered that with \usepackage[utf8x]{inputenc}
and using PDFLaTeX, although kile says pdflatex finished with exit code 1 , it does generate a pdf, but instead of the ⚓ it shows [U+2693]
. So maybe a font issue???
Finally: I downloaded the font PLK suggested, and after extracting and renaming to unifont
I can get xelatex design.tex
to find the font, but it says
! Text line contains an invalid character.
l.1 ^^@
^^A^^@^^@^^@
! Text line contains an invalid character.
l.1 ^^@^^A
^^@^^@^^@
! Text line contains an invalid character.
l.1 ^^@^^A^^@
^^@^^@
! Text line contains an invalid character.
l.1 ^^@^^A^^@^^@
^^@
! Text line contains an invalid character.
l.1 ^^@^^A^^@^^@^^@
! Unable to read an entire line---bufsize=200000.
I have this in my 'preamble' (very possibly I am doing this wrong...)
\usepackage{fontspec}
\fontspec{unifont.ttf}
I tried to read the documentation on CTAN but found it a bit hard to understand...
Here is (an extract) of my doc at the moment (forgot to past the \end{document} )
Thanks for the suggestions so far.
xetex
instead ofxelatex
; but something other is needed, for example loadingfontspec
. However it's definitely wrong usinginputenc
with XeLaTeX.inputenc
only a subset of unicode is understood (from what I understand). So it might be that the symbol isn't understood. And even if it is, how many fonts will have that symbol? You might be better off inserting it as a little picture?