Take the 2-minute tour ×
TeX - LaTeX Stack Exchange is a question and answer site for users of TeX, LaTeX, ConTeXt, and related typesetting systems. It's 100% free, no registration required.

When I attempt to use any kind of "long" arrow in the Lucida Bright font, it ends up coming out broken. For a MWE Consider the following:

\documentclass[10 pt]{article}

\usepackage{amsmath,amssymb}

\usepackage{fontspec}      
\usepackage{unicode-math}  

\setmainfont{Lucida Bright OT}
\setsansfont{Lucida Sans OT}
\setmonofont{Lucida Sans Typewriter OT}

\setmathfont{Lucida Bright Math OT}

\begin{document}

Here is an example of an arrow which looks weird:

\begin{gather}
\widehat{\mathcal{O}_v}\otimes_{\mathcal{O}_v} k\xrightarrow{\approx}\widehat{k}
\end{gather}

here is another example:

\begin{gather}
\varprojlim k[T]/(T^n)
\end{gather}

\end{document}
share|improve this question
add comment

2 Answers 2

up vote 3 down vote accepted

The \xrightarrow and \varprojlim commands use a minus sign for extending the arrow; in the Lucida Math font this has not the same height as the arrow; you can use a different symbol, though, namely "HORIZONTAL LINE EXTENSION U+23AF", that's available in unicode-math under the name \harrowextender; just redefine \relbar to use it:

\documentclass[10pt]{article}

\usepackage{amsmath}

\usepackage{fontspec}      
\usepackage{unicode-math}  

\setmainfont{Lucida Bright OT}
\setsansfont{Lucida Sans OT}
\setmonofont{Lucida Sans Typewriter OT}

\setmathfont{Lucida Bright Math OT}

\renewcommand{\relbar}{\mathrel{\harrowextender}}

\begin{document}


Here is an example of an arrow which looks weird:
\[
\widehat{\mathcal{O}_v}\otimes_{\mathcal{O}_v} k\xrightarrow{\approx}\widehat{k}
\]
here is another example:
\[
\varprojlim k[T]/(T^n)
\]

\end{document}

enter image description here

By the way, I don't think amssymb does any good with unicode-math.

share|improve this answer
    
Thank you so much! –  Alex Youcis Mar 23 '13 at 16:23
add comment

try this setting:

\usepackage{unicode-math}  
\setmainfont{Lucida Bright OT}
\setsansfont{Lucida Sans OT}
\setmonofont{Lucida Sans Typewriter OT}
\setmathfont{Lucida Bright Math OT}
\setmathfont[range={"2190,"2192,"2212}]{TeXGyrePagellaMath-Regular}

or alternatively to using Pagella

\makeatletter
\ams@def\relbar{\raisebox{-0.35pt}{$-$}}
\makeatother

(after loading amsmath). Here is my complete test example:

\documentclass{article}
\usepackage{amsmath}
\usepackage{unicode-math}  
\setmainfont{Lucida Bright OT}
\setsansfont{Lucida Sans OT}
\setmonofont{Lucida Sans Typewriter OT}
\setmathfont{Lucida Bright Math OT}
\setmathfont[range={"2190,"2192,"2212}]{XITS Math}
%\makeatletter
%\ams@def\relbar{\raisebox{-0.35pt}{$-$}}
%\makeatother

\begin{document}        
\begin{gather}
\widehat{\mathcal{O}_v}\otimes_{\mathcal{O}_v} k\xrightarrow{\approx}\widehat{k}
\end{gather}

\begin{gather}
\varprojlim k[T]/(T^n)
\end{gather}

\end{document}
share|improve this answer
    
Thank you very much! I am getting an error when I try to implement this code though. It says that the font "TeXGyrePagellaMath-Regular" cannot be found, and that I should reference the "fontspec" documentation (I am using fontspec). Also, when I try your second fix it says that "\relbar" is not defined. –  Alex Youcis Mar 23 '13 at 8:27
    
Which TeX-system do you have? And did you updated it? You can also use XITS Math instead. See my edited answer for a complete document –  Herbert Mar 23 '13 at 8:31
    
Herbert, I apologize if I am misunderstanding you. I am using Tex Shop for Mac. I don't know what XITS Math is, as well. –  Alex Youcis Mar 23 '13 at 8:33
    
XITS is a font and should be installed by default. With MacTeX you can also update your system. However, if you use xelatex (I used lualatex) you have to use as name xits-math.otf instead of the symbolic name XITS Math –  Herbert Mar 23 '13 at 8:38
    
Herbert, I apologize for being so dense, but I'm not exactly sure how to implement your suggestions. Is XITS Math some kind of package I need to include? Do I need to download it? Thanks! –  Alex Youcis Mar 23 '13 at 8:49
show 2 more comments

Your Answer

 
discard

By posting your answer, you agree to the privacy policy and terms of service.

Not the answer you're looking for? Browse other questions tagged or ask your own question.