summaryrefslogtreecommitdiff
path: root/Master/texmf-dist/source/latex/fontspec/fontspec-interfaces.dtx
blob: 25eb3fb1a53ad599b990a206acf4635fb033b3ee (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
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
179
180
181
182
183
184
185
186
187
188
189
190
191
192
193
194
195
196
197
198
199
200
201
202
203
204
205
206
207
208
209
210
211
212
213
214
215
216
%%^^A%%  fontspec-interfaces.dtx -- part of FONTSPEC <wspr.io/fontspec>

% \section{User commands}\label{sec:codeuser}
%
% This section contains the definitions of the commands detailed in
% the user documentation.  Only the `top level' definitions of the
% commands are contained herein; they all use or define macros which
% are defined or used later on in \vref{sec:codeinternal}.
%
% \iffalse
%    \begin{macrocode}
%<*fontspec&(xetexx|luatex)>
%    \end{macrocode}
% \fi
%
%    \begin{macrocode}
\NewDocumentCommand \fontspec { O{} m O{} }
  {
    \@@_main_fontspec:nn {#1,#3} {#2}
  }
%    \end{macrocode}
%
%    \begin{macrocode}
\NewDocumentCommand \setmainfont { O{} m O{} }
  {
    \@@_main_setmainfont:nn {#1,#3} {#2}
  }
%    \end{macrocode}
%
%    \begin{macrocode}
\NewDocumentCommand \setsansfont { O{} m O{} }
  {
    \@@_main_setsansfont:nn {#1,#3} {#2}
  }
%    \end{macrocode}
%
%    \begin{macrocode}
\NewDocumentCommand \setmonofont { O{} m O{} }
  {
    \@@_main_setmonofont:nn {#1,#3} {#2}
  }
%    \end{macrocode}
%
%    \begin{macrocode}
\NewDocumentCommand \setmathrm { O{} m O{} }
  {
    \@@_main_setmathrm:nn {#1,#3} {#2}
  }
%    \end{macrocode}
%
%    \begin{macrocode}
\NewDocumentCommand \setboldmathrm { O{} m O{} }
  {
    \@@_main_setboldmathrm:nn {#1,#3} {#2}
  }
%    \end{macrocode}
%
%    \begin{macrocode}
\NewDocumentCommand \setmathsf { O{} m O{} }
  {
    \@@_main_setmathsf:nn {#1,#3} {#2}
  }
%    \end{macrocode}
%
%    \begin{macrocode}
\NewDocumentCommand \setmathtt { O{} m O{} }
  {
    \@@_main_setmathtt:nn {#1,#3} {#2}
  }
%    \end{macrocode}
%
% \begin{macro}{\setromanfont}
% This is the old name for \cs{setmainfont}, retained \emph{ad infinitum}
% for backwards compatibility. It was deprecated in 2010.
%    \begin{macrocode}
\NewDocumentCommand \setromanfont { O{} m O{} }
  {
    \@@_main_setmainfont:nn {#1,#3} {#2}
  }
%    \end{macrocode}
% \end{macro}
%
%    \begin{macrocode}
\NewDocumentCommand \newfontfamily { m O{} m O{} }
  {
    \@@_main_newfontfamily:nnn {#1} {#2,#4} {#3}
  }
%    \end{macrocode}
%
%    \begin{macrocode}
\NewDocumentCommand \newfontface { m O{} m O{} }
  {
    \@@_main_newfontface:nnn {#1} {#2,#4} {#3}
  }
%    \end{macrocode}
%
%    \begin{macrocode}
\NewDocumentCommand \defaultfontfeatures { t+ o m }
  {
    \@@_main_defaultfontfeatures:nnn {#1} {#2} {#3}
  }
%    \end{macrocode}
%
%    \begin{macrocode}
\NewDocumentCommand \addfontfeatures {m}
  {
    \@@_main_addfontfeatures:n {#1}
  }
\NewDocumentCommand \addfontfeature  {m}
  {
    \@@_main_addfontfeatures:n {#1}
  }
%    \end{macrocode}
%
%    \begin{macrocode}
\NewDocumentCommand \newfontfeature {mm}
  {
    \@@_main_newfontfeature:nn {#1} {#2}
  }
%    \end{macrocode}
%
%    \begin{macrocode}
\NewDocumentCommand \newAATfeature {mmmm}
  {
    \@@_main_newAATfeature:nnnn {#1} {#2} {#3} {#4}
  }
%    \end{macrocode}
%
%    \begin{macrocode}
\NewDocumentCommand \newopentypefeature {mmm}
  {
    \@@_main_newopentypefeature:nnn {#1} {#2} {#3}
  }
%    \end{macrocode}
%
% \begin{macro}{\newICUfeature}
% Deprecated.
%    \begin{macrocode}
\NewDocumentCommand \newICUfeature {mmm}
  {
    \@@_main_newopentypefeature:nnn {#1} {#2} {#3}
  }
%    \end{macrocode}
% \end{macro}
%
%    \begin{macrocode}
\NewDocumentCommand \aliasfontfeature {mm}
  {
    \@@_main_aliasfontfeature:nn {#1} {#2}
  }
%    \end{macrocode}
%
%    \begin{macrocode}
\NewDocumentCommand \aliasfontfeatureoption {mmm}
  {
    \@@_main_aliasfontfeatureoption:nnn {#1} {#2} {#3}
  }
%    \end{macrocode}
%
% \begin{macro}{\newfontscript}
% Mostly used internally, but also possibly useful for users, to define new OpenType
% `scripts', mapping logical names to OpenType script tags.
%    \begin{macrocode}
\NewDocumentCommand \newfontscript {mm}
  {
    \fontspec_new_script:nn {#1} {#2}
  }
%    \end{macrocode}
% \end{macro}
%
% \begin{macro}{\newfontlanguage}
% Mostly used internally, but also possibly useful for users, to define new OpenType
% `languages', mapping logical names to OpenType language tags.
%    \begin{macrocode}
\NewDocumentCommand \newfontlanguage {mm}
  {
    \fontspec_new_lang:nn {#1} {#2}
  }
%    \end{macrocode}
% \end{macro}
%
%    \begin{macrocode}
\NewDocumentCommand \DeclareFontsExtensions {m}
  {
    \@@_main_DeclareFontsExtensions:n {#1}
  }
%    \end{macrocode}
%
%    \begin{macrocode}
\NewDocumentCommand \IfFontFeatureActiveTF {mmm}
  {
    \@@_main_IfFontFeatureActiveTF:nnn {#1} {#2} {#3}
  }
%    \end{macrocode}
%
% \iffalse
%    \begin{macrocode}
%</fontspec&(xetexx|luatex)>
%    \end{macrocode}
% \fi


\endinput

% /©
% ------------------------------------------------
% The FONTSPEC package  <wspr.io/fontspec>
% ------------------------------------------------
% Copyright  2004-2017  Will Robertson, LPPL "maintainer"
% Copyright  2009-2013  Khaled Hosny
% ------------------------------------------------
% This package is free software and may be redistributed and/or modified under
% the conditions of the LaTeX Project Public License, version 1.3c or higher
% (your choice): <http://www.latex-project.org/lppl/>.
% ------------------------------------------------
% ©/