blob: c0e8ff60909b90f6cf7d6c96098cc6f4db2304cf (
plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
|
% sansmathaccent.sty
%
% Fixes a problem with accent placement in beamer and sfmath
%
% author: Ariel Barton
%
% Copyright Ariel Barton, 2012
%
% This work may be distributed and/or modified under the
% conditions of the LaTeX Project Public License, either
% version 1.3 of this license or (at your option) any
% later version.
% The latest version of the license is in
% http://www.latex-project.org/lppl.txt
% and version 1.3 or later is part of all distributions of
% LaTeX version 2003/06/01 or later.
%
% This work has the LPPL maintenance status "author-maintained".
%
% The complete list of files considered part of this work is in
% the file `sansmathaccent.pdf' and its source code `sansmathaccent.tex'.
%
\ProvidesPackage{sansmathaccent}[2012/04/26]
\def\sansmathaccent@warning{sansmathaccent is not a standalone package; it should be used with beamer or sfmath.}
% Check to see if we are a Beamer document
\@ifpackageloaded{beamerbasefont}{%
\def\sansmathaccent@warning{}
\AtBeginDocument{
\def\sansmathaccent@cmss{cmss}
\ifx\beamer@fmdef\sansmathaccent@cmss % Check to see if we are using cmss for math
\DeclareSymbolFont{pureletters}{OT1}{mathkerncmss}{m}{sl}
\fi
}
}{}
% Check to see if we are a sfmath document
\@ifpackageloaded{sfmath}{%
\def\sansmathaccent@warning{}
\edef\tmp@sfdefault{\math@sfdefault}
\def\tmp@compare{cmss}
\ifx\tmp@sfdefault\tmp@compare % Check to see if we are using cmss for math
\DeclareSymbolFont{SFMath}{OT1}{mathkerncmss}{m}{sl}
\SetSymbolFont{SFMath}{normal}{OT1}{mathkerncmss}{m}{sl}
\fi
}{}
\ifx \sansmathaccent@warning\empty \else \typeout{\sansmathaccent@warning} \fi
|