summaryrefslogtreecommitdiff
path: root/Master/texmf-dist/tex/latex/unicode-math
diff options
context:
space:
mode:
authorKarl Berry <karl@freefriends.org>2010-07-14 22:58:48 +0000
committerKarl Berry <karl@freefriends.org>2010-07-14 22:58:48 +0000
commitea749b653478cc14465055c40a20f8f221add0c5 (patch)
treeb6e23f5492818996e2f5201a4bc2e24afa249052 /Master/texmf-dist/tex/latex/unicode-math
parent827000f2ceadd8c4bd3fa95705d6f8eb1e5d4a7c (diff)
unicode-math update (14jul10)
git-svn-id: svn://tug.org/texlive/trunk@19459 c570f23f-e606-0410-a88d-b1316a301751
Diffstat (limited to 'Master/texmf-dist/tex/latex/unicode-math')
-rw-r--r--Master/texmf-dist/tex/latex/unicode-math/unicode-math-table.tex48
-rw-r--r--Master/texmf-dist/tex/latex/unicode-math/unicode-math.sty643
2 files changed, 467 insertions, 224 deletions
diff --git a/Master/texmf-dist/tex/latex/unicode-math/unicode-math-table.tex b/Master/texmf-dist/tex/latex/unicode-math/unicode-math-table.tex
index d45209ee187..d91f7706c53 100644
--- a/Master/texmf-dist/tex/latex/unicode-math/unicode-math-table.tex
+++ b/Master/texmf-dist/tex/latex/unicode-math/unicode-math-table.tex
@@ -15,7 +15,7 @@
\UnicodeMathSymbol{"0003D}{\equal }{\mathrel}{equals sign r:}%
\UnicodeMathSymbol{"0003E}{\greater }{\mathrel}{greater-than sign r:}%
\UnicodeMathSymbol{"0003F}{\question }{\mathord}{question mark}%
-\UnicodeMathSymbol{"0003F}{\atsign }{\mathord}{commercial at}%
+\UnicodeMathSymbol{"00040}{\atsign }{\mathord}{commercial at}%
\UnicodeMathSymbol{"0005B}{\lbrack }{\mathopen}{left square bracket}%
\UnicodeMathSymbol{"0005C}{\backslash }{\mathord}{reverse solidus}%
\UnicodeMathSymbol{"0005D}{\rbrack }{\mathclose}{right square bracket}%
@@ -44,8 +44,6 @@
\UnicodeMathSymbol{"0030C}{\check }{\mathaccent}{caron}%
\UnicodeMathSymbol{"00310}{\candra }{\mathaccent}{candrabindu (non-spacing)}%
\UnicodeMathSymbol{"00312}{\oturnedcomma }{\mathaccent}{combining turned comma above}%
-\UnicodeMathSymbol{"00313}{\osmooth }{\mathaccent}{greek psili (smooth breathing) (non-spacing)}%
-\UnicodeMathSymbol{"00314}{\orough }{\mathaccent}{greek dasia (rough breathing) (non-spacing)}%
\UnicodeMathSymbol{"00315}{\ocommatopright }{\mathaccent}{combining comma above right}%
\UnicodeMathSymbol{"0031A}{\droang }{\mathaccent}{left angle above (non-spacing)}%
\UnicodeMathSymbol{"00330}{\wideutilde }{\mathaccent}{under tilde accent (multiple characters and non-spacing)}%
@@ -70,6 +68,7 @@
\UnicodeMathSymbol{"003A1}{\upRho }{\mathalpha}{capital rho, greek}%
\UnicodeMathSymbol{"003A3}{\upSigma }{\mathalpha}{capital sigma, greek}%
\UnicodeMathSymbol{"003A4}{\upTau }{\mathalpha}{capital tau, greek}%
+\UnicodeMathSymbol{"003A5}{\upUpsilon }{\mathalpha}{capital upsilon, greek}%
\UnicodeMathSymbol{"003A6}{\upPhi }{\mathalpha}{capital phi, greek}%
\UnicodeMathSymbol{"003A7}{\upChi }{\mathalpha}{capital chi, greek}%
\UnicodeMathSymbol{"003A8}{\upPsi }{\mathalpha}{capital psi, greek}%
@@ -125,10 +124,8 @@
\UnicodeMathSymbol{"02020}{\dagger }{\mathbin}{dagger relation}%
\UnicodeMathSymbol{"02021}{\ddagger }{\mathbin}{double dagger relation}%
\UnicodeMathSymbol{"02022}{\smblkcircle }{\mathbin}{/bullet b: round bullet, filled}%
-\UnicodeMathSymbol{"02024}{\enleaderonedot }{\mathord}{one dot leader}%
\UnicodeMathSymbol{"02025}{\enleadertwodots }{\mathord}{double baseline dot (en leader)}%
\UnicodeMathSymbol{"02026}{\unicodeellipsis }{\mathord}{ellipsis (horizontal)}%
-\UnicodeMathSymbol{"02027}{\hyphenpoint }{\mathord}{hyphenation point}%
\UnicodeMathSymbol{"02032}{\prime }{\mathord}{prime or minute, not superscripted}%
\UnicodeMathSymbol{"02033}{\dprime }{\mathord}{double prime or second, not superscripted}%
\UnicodeMathSymbol{"02034}{\trprime }{\mathord}{triple prime (not superscripted)}%
@@ -166,7 +163,6 @@
\UnicodeMathSymbol{"020EF}{\underrightarrow }{\mathaccent}{combining right arrow below}%
\UnicodeMathSymbol{"020F0}{\asteraccent }{\mathaccent}{combining asterisk above}%
\UnicodeMathSymbol{"02102}{\BbbC }{\mathalpha}{/bbb c, open face c}%
-\UnicodeMathSymbol{"02105}{\incare }{\mathord}{in-care-of symbol}%
\UnicodeMathSymbol{"02107}{\Eulerconst }{\mathord}{euler constant}%
\UnicodeMathSymbol{"0210A}{\mscrg }{\mathalpha}{/scr g, script letter g}%
\UnicodeMathSymbol{"0210B}{\mscrH }{\mathalpha}{hamiltonian (script capital h)}%
@@ -309,7 +305,6 @@
\UnicodeMathSymbol{"021E8}{\rightwhitearrow }{\mathord}{rightwards white arrow}%
\UnicodeMathSymbol{"021E9}{\downwhitearrow }{\mathord}{downwards white arrow}%
\UnicodeMathSymbol{"021EA}{\whitearrowupfrombar }{\mathord}{upwards white arrow from bar}%
-\UnicodeMathSymbol{"021F3}{\updownwhitearrow }{\mathord}{up and down white arrow}%
\UnicodeMathSymbol{"021F4}{\circleonrightarrow }{\mathrel}{right arrow with small circle}%
\UnicodeMathSymbol{"021F5}{\downuparrows }{\mathrel}{downwards arrow leftwards of upwards arrow}%
\UnicodeMathSymbol{"021F6}{\rightthreearrows }{\mathrel}{three rightwards arrows}%
@@ -384,7 +379,7 @@
\UnicodeMathSymbol{"0223B}{\kernelcontraction }{\mathrel}{homothetic}%
\UnicodeMathSymbol{"0223C}{\sim }{\mathrel}{similar}%
\UnicodeMathSymbol{"0223D}{\backsim }{\mathrel}{reverse similar}%
-\UnicodeMathSymbol{"0223E}{\ac }{\mathbin}{most positive [inverted lazy s]}%
+\UnicodeMathSymbol{"0223E}{\invlazys }{\mathbin}{most positive [inverted lazy s]}%
\UnicodeMathSymbol{"0223F}{\sinewave }{\mathord}{sine wave}%
\UnicodeMathSymbol{"02240}{\wr }{\mathbin}{wreath product}%
\UnicodeMathSymbol{"02241}{\nsim }{\mathrel}{not similar}%
@@ -590,12 +585,8 @@
\UnicodeMathSymbol{"02311}{\sqlozenge }{\mathord}{square lozenge}%
\UnicodeMathSymbol{"02312}{\profline }{\mathord}{profile of a line}%
\UnicodeMathSymbol{"02313}{\profsurf }{\mathord}{profile of a surface}%
-\UnicodeMathSymbol{"02315}{\recorder }{\mathord}{telephone recorder symbol}%
-\UnicodeMathSymbol{"02316}{\target }{\mathord}{register mark or target; position}%
\UnicodeMathSymbol{"02317}{\viewdata }{\mathord}{viewdata square}%
-\UnicodeMathSymbol{"02318}{\cloverleaf }{\mathord}{cloverleaf [command key]}%
\UnicodeMathSymbol{"02319}{\turnednot }{\mathord}{turned not sign}%
-\UnicodeMathSymbol{"0231A}{\watchicon }{\mathord}{watch icon}%
\UnicodeMathSymbol{"0231C}{\ulcorner }{\mathopen}{upper left corner}%
\UnicodeMathSymbol{"0231D}{\urcorner }{\mathclose}{upper right corner}%
\UnicodeMathSymbol{"0231E}{\llcorner }{\mathopen}{lower left corner}%
@@ -605,8 +596,6 @@
\UnicodeMathSymbol{"02322}{\frown }{\mathrel}{down curve}%
\UnicodeMathSymbol{"02323}{\smile }{\mathrel}{up curve}%
\UnicodeMathSymbol{"0232C}{\varhexagonlrbonds }{\mathord}{six carbon ring, corner down, double bonds lower right etc}%
-\UnicodeMathSymbol{"0232D}{\cylcty }{\mathord}{cylindricity}%
-\UnicodeMathSymbol{"0232E}{\profalar }{\mathord}{all-around profile}%
\UnicodeMathSymbol{"02332}{\conictaper }{\mathord}{conical taper }%
\UnicodeMathSymbol{"02336}{\topbot }{\mathord}{top and bottom}%
\UnicodeMathSymbol{"0233D}{\obar }{\mathbin}{circle with vertical bar}%
@@ -615,7 +604,6 @@
\UnicodeMathSymbol{"02353}{\APLboxupcaret }{\mathord}{boxed up caret}%
\UnicodeMathSymbol{"02370}{\APLboxquestion }{\mathord}{boxed question mark}%
\UnicodeMathSymbol{"0237C}{\rangledownzigzagarrow }{\mathord}{right angle with downwards zigzag arrow}%
-\UnicodeMathSymbol{"02393}{\dircurrent }{\mathord}{line over dashed line (direct current symbol form 2)}%
\UnicodeMathSymbol{"02394}{\hexagon }{\mathord}{horizontal benzene ring [hexagon flat open]}%
\UnicodeMathSymbol{"0239B}{\lparenuend }{\mathord}{left parenthesis upper hook}%
\UnicodeMathSymbol{"0239C}{\lparenextender }{\mathord}{left parenthesis extension}%
@@ -642,16 +630,17 @@
\UnicodeMathSymbol{"023B1}{\rmoustache }{\mathord}{upper right or lower left curly bracket section}%
\UnicodeMathSymbol{"023B2}{\sumtop }{\mathord}{summation top}%
\UnicodeMathSymbol{"023B3}{\sumbottom }{\mathord}{summation bottom}%
-\UnicodeMathSymbol{"023B4}{\overbracket }{\mathord}{top square bracket}%
-\UnicodeMathSymbol{"023B5}{\underbracket }{\mathord}{bottom square bracket}%
+\UnicodeMathSymbol{"023B4}{\overbracket }{\mathover}{top square bracket}%
+\UnicodeMathSymbol{"023B5}{\underbracket }{\mathunder}{bottom square bracket}%
\UnicodeMathSymbol{"023B6}{\bbrktbrk }{\mathord}{bottom square bracket over top square bracket}%
\UnicodeMathSymbol{"023B7}{\sqrtbottom }{\mathord}{radical symbol bottom}%
\UnicodeMathSymbol{"023B8}{\lvboxline }{\mathord}{left vertical box line}%
\UnicodeMathSymbol{"023B9}{\rvboxline }{\mathord}{right vertical box line}%
\UnicodeMathSymbol{"023CE}{\varcarriagereturn }{\mathord}{return symbol}%
-\UnicodeMathSymbol{"023D0}{\varrowextender }{\mathord}{vertical line extension (used to extend arrows)}%
-\UnicodeMathSymbol{"023DC}{\overparen }{\mathord}{top parenthesis (mathematical use)}%
-\UnicodeMathSymbol{"023DD}{\underparen }{\mathord}{bottom parenthesis (mathematical use)}%
+\UnicodeMathSymbol{"023DC}{\overparen }{\mathover}{top parenthesis (mathematical use)}%
+\UnicodeMathSymbol{"023DD}{\underparen }{\mathunder}{bottom parenthesis (mathematical use)}%
+\UnicodeMathSymbol{"023DE}{\overbrace }{\mathover}{top curly bracket (mathematical use)}%
+\UnicodeMathSymbol{"023DF}{\underbrace }{\mathunder}{bottom curly bracket (mathematical use)}%
\UnicodeMathSymbol{"023E0}{\obrbrak }{\mathord}{top tortoise shell bracket (mathematical use)}%
\UnicodeMathSymbol{"023E1}{\ubrbrak }{\mathord}{bottom tortoise shell bracket (mathematical use)}%
\UnicodeMathSymbol{"023E2}{\trapezium }{\mathord}{white trapezium}%
@@ -768,26 +757,13 @@
\UnicodeMathSymbol{"02605}{\bigstar }{\mathord}{star, filled}%
\UnicodeMathSymbol{"02606}{\bigwhitestar }{\mathord}{star, open}%
\UnicodeMathSymbol{"02609}{\astrosun }{\mathord}{sun}%
-\UnicodeMathSymbol{"0260C}{\conjunction }{\mathord}{conjunction}%
-\UnicodeMathSymbol{"0260E}{\phone }{\mathord}{telephone symbol}%
-\UnicodeMathSymbol{"02612}{\XBox }{\mathord}{ballot cross}%
\UnicodeMathSymbol{"02621}{\danger }{\mathord}{dangerous bend (caution sign)}%
-\UnicodeMathSymbol{"02639}{\frownie }{\mathord}{sad smiley}%
-\UnicodeMathSymbol{"0263A}{\smiley }{\mathord}{happy smiley}%
\UnicodeMathSymbol{"0263B}{\blacksmiley }{\mathord}{black smiling face}%
\UnicodeMathSymbol{"0263C}{\sun }{\mathord}{white sun with rays}%
\UnicodeMathSymbol{"0263D}{\rightmoon }{\mathord}{first quarter moon}%
\UnicodeMathSymbol{"0263E}{\leftmoon }{\mathord}{last quarter moon}%
-\UnicodeMathSymbol{"0263F}{\mercury }{\mathord}{mercury}%
\UnicodeMathSymbol{"02640}{\female }{\mathord}{venus, female}%
-\UnicodeMathSymbol{"02641}{\earth }{\mathord}{earth}%
\UnicodeMathSymbol{"02642}{\male }{\mathord}{mars, male}%
-\UnicodeMathSymbol{"02643}{\jupiter }{\mathord}{jupiter}%
-\UnicodeMathSymbol{"02644}{\saturn }{\mathord}{saturn}%
-\UnicodeMathSymbol{"02646}{\neptune }{\mathord}{neptune}%
-\UnicodeMathSymbol{"02647}{\pluto }{\mathord}{pluto}%
-\UnicodeMathSymbol{"02648}{\aries }{\mathord}{aries}%
-\UnicodeMathSymbol{"02649}{\taurus }{\mathord}{taurus}%
\UnicodeMathSymbol{"02660}{\spadesuit }{\mathord}{spades suit symbol}%
\UnicodeMathSymbol{"02661}{\heartsuit }{\mathord}{heart suit symbol}%
\UnicodeMathSymbol{"02662}{\diamondsuit }{\mathord}{diamond suit symbol}%
@@ -813,14 +789,11 @@
\UnicodeMathSymbol{"02687}{\circledtwodots }{\mathord}{white circle with two dots}%
\UnicodeMathSymbol{"02688}{\blackcircledrightdot }{\mathord}{black circle with white dot right}%
\UnicodeMathSymbol{"02689}{\blackcircledtwodots }{\mathord}{black circle with two white dots}%
-\UnicodeMathSymbol{"026A0}{\triangleexclam }{\mathord}{warning sign}%
\UnicodeMathSymbol{"026A5}{\Hermaphrodite }{\mathord}{male and female sign}%
\UnicodeMathSymbol{"026AA}{\mdwhtcircle }{\mathord}{medium white circle}%
\UnicodeMathSymbol{"026AB}{\mdblkcircle }{\mathord}{medium black circle}%
\UnicodeMathSymbol{"026AC}{\mdsmwhtcircle }{\mathord}{medium small white circle}%
\UnicodeMathSymbol{"026B2}{\neuter }{\mathord}{neuter}%
-\UnicodeMathSymbol{"02702}{\scissors }{\mathord}{scissors, solid open}%
-\UnicodeMathSymbol{"02709}{\envelope }{\mathord}{envelope}%
\UnicodeMathSymbol{"02713}{\checkmark }{\mathord}{tick, check mark}%
\UnicodeMathSymbol{"02720}{\maltese }{\mathord}{maltese cross}%
\UnicodeMathSymbol{"0272A}{\circledstar }{\mathord}{circled white star}%
@@ -1468,7 +1441,6 @@
\UnicodeMathSymbol{"03018}{\Lbrbrak }{\mathopen}{left white tortoise shell bracket}%
\UnicodeMathSymbol{"03019}{\Rbrbrak }{\mathclose}{right white tortoise shell bracket}%
\UnicodeMathSymbol{"03030}{\hzigzag }{\mathord}{zigzag}%
-\UnicodeMathSymbol{"0306E}{\hiraganano }{\mathord}{hiragana letter no}%
\UnicodeMathSymbol{"1D400}{\mbfA }{\mathalpha}{mathematical bold capital a}%
\UnicodeMathSymbol{"1D401}{\mbfB }{\mathalpha}{mathematical bold capital b}%
\UnicodeMathSymbol{"1D402}{\mbfC }{\mathalpha}{mathematical bold capital c}%
@@ -1521,7 +1493,7 @@
\UnicodeMathSymbol{"1D431}{\mbfx }{\mathalpha}{mathematical bold small x}%
\UnicodeMathSymbol{"1D432}{\mbfy }{\mathalpha}{mathematical bold small y}%
\UnicodeMathSymbol{"1D433}{\mbfz }{\mathalpha}{mathematical bold small z}%
-\UnicodeMathSymbol{"1D434}{\mitA }{\mathalpha}{mathematical italic capital a`25}%
+\UnicodeMathSymbol{"1D434}{\mitA }{\mathalpha}{mathematical italic capital a}%
\UnicodeMathSymbol{"1D435}{\mitB }{\mathalpha}{mathematical italic capital b}%
\UnicodeMathSymbol{"1D436}{\mitC }{\mathalpha}{mathematical italic capital c}%
\UnicodeMathSymbol{"1D437}{\mitD }{\mathalpha}{mathematical italic capital d}%
diff --git a/Master/texmf-dist/tex/latex/unicode-math/unicode-math.sty b/Master/texmf-dist/tex/latex/unicode-math/unicode-math.sty
index 3e86a619ba1..dc8c72ececc 100644
--- a/Master/texmf-dist/tex/latex/unicode-math/unicode-math.sty
+++ b/Master/texmf-dist/tex/latex/unicode-math/unicode-math.sty
@@ -4,7 +4,9 @@
%%
%% The original source files were:
%%
-%% unicode-math.dtx (with options: `package')
+%% unicode-math.dtx (with options: `preamble')
+%% unicode-math.dtx (with options: `msg')
+%% unicode-math.dtx (with options: `package,stix')
%% Copyright 2006-2010 by Will Robertson <will.robertson@latex-project.org>
%%
%% This package is free software and may be redistributed and/or modified under
@@ -13,7 +15,7 @@
%%
%% This work is "author-maintained" by Will Robertson.
\ProvidesPackage{unicode-math}
- [2010/06/03 v0.5 Unicode maths in XeLaTeX]
+ [2010/07/14 v0.5a Unicode maths in XeLaTeX]
\usepackage{ifxetex,ifluatex}
\ifxetex\else\ifluatex\else
\PackageError{unicode-math}{%
@@ -25,6 +27,7 @@
\RequirePackage{xparse}[2009/08/31]
\RequirePackage{l3keys2e}
\RequirePackage{fontspec}[2010/05/18]
+\RequirePackage{catchfile}
\ExplSyntaxOn
\@ifclassloaded{memoir}{
\cs_set_eq:NN \um_after_pkg:nn \AtEndPackage
@@ -95,6 +98,43 @@
\um_cs_compat:n {mathaccent}
\um_cs_compat:n {delimiter}
\cs_generate_variant:Nn \fontspec_select:nn {x}
+\cs_new:Npn \um_warning:n { \msg_warning:nn {unicode-math} }
+\cs_new:Npn \um_trace:n { \msg_trace:nn {unicode-math} }
+\cs_new:Npn \um_trace:nx { \msg_trace:nnx {unicode-math} }
+\msg_new:nnn {unicode-math} {maths-feature-only}
+{
+ The~ '#1'~ font~ feature~ can~ only~ be~ used~ for~ maths~ fonts.
+}
+\msg_new:nnn {unicode-math} {disable-beamer}
+{
+ Disabling~ beamer's~ math~ setup.\\
+ Please~ load~ beamer~ with~ the~ [professionalfonts]~ class~ option.
+}
+\msg_new:nnn {unicode-math} {no-tfrac}
+{
+ Small~ fraction~ command~ \protect\tfrac\ not~ defined.\\
+ Load~ amsmath~ or~ define~ it~ manually~ before~ loading~ unicode-math.
+}
+\msg_new:nnn {unicode-math} {default-math-font}
+{
+ Defining~ the~ default~ maths~ font~ as~ '#1'.
+}
+\msg_new:nnn {unicode-math} {setup-implicit}
+{
+ Setup~ alphabets:~ implicit~ mode.
+}
+\msg_new:nnn {unicode-math} {setup-explicit}
+{
+ Setup~ alphabets:~ explicit~ mode.
+}
+\msg_new:nnn {unicode-math} {alph-initialise}
+{
+ Initialising~ \@backslashchar math#1.
+}
+\msg_new:nnn {unicode-math} {setup-alph}
+{
+ Setup~ alphabet:~ #1.
+}
\cs_new:Npn \usv_set:nnn #1#2#3 {
\tl_set:cn { \um_to_usv:nn {#1}{#2} } {#3}
}
@@ -112,6 +152,7 @@
\usv_set:nnn {bb}{Latin}{"1D538}
\usv_set:nnn {bb}{latin}{"1D552}
\usv_set:nnn {scr}{Latin}{"1D49C}
+\usv_set:nnn {cal}{Latin}{"1D49C}
\usv_set:nnn {scr}{latin}{"1D4B6}
\usv_set:nnn {frak}{Latin}{"1D504}
\usv_set:nnn {frak}{latin}{"1D51E}
@@ -141,6 +182,7 @@
\usv_set:nnn {bffrak}{Latin}{"1D56C}
\usv_set:nnn {bffrak}{latin}{"1D586}
\usv_set:nnn {bfscr}{Latin}{"1D4D0}
+\usv_set:nnn {bfcal}{Latin}{"1D4D0}
\usv_set:nnn {bfscr}{latin}{"1D4EA}
\usv_set:nnn {bfsf}{num}{"1D7EC}
\usv_set:nnn {bfsfup}{num}{"1D7EC}
@@ -314,11 +356,191 @@
\usv_set:nnn {scr}{e}{"212F}
\usv_set:nnn {scr}{g}{"210A}
\usv_set:nnn {scr}{o}{"2134}
+\usv_set:nnn {cal}{B}{"212C}
+\usv_set:nnn {cal}{E}{"2130}
+\usv_set:nnn {cal}{F}{"2131}
+\usv_set:nnn {cal}{H}{"210B}
+\usv_set:nnn {cal}{I}{"2110}
+\usv_set:nnn {cal}{L}{"2112}
+\usv_set:nnn {cal}{M}{"2133}
+\usv_set:nnn {cal}{R}{"211B}
\usv_set:nnn {frak}{C}{"212D}
\usv_set:nnn {frak}{H}{"210C}
\usv_set:nnn {frak}{I}{"2111}
\usv_set:nnn {frak}{R}{"211C}
\usv_set:nnn {frak}{Z}{"2128}
+\usv_set:nnn {stixsfup}{partial}{"E17C}
+\usv_set:nnn {stixsfup}{Greek}{"E17D}
+\usv_set:nnn {stixsfup}{greek}{"E196}
+\usv_set:nnn {stixsfup}{varTheta}{"E18E}
+\usv_set:nnn {stixsfup}{varepsilon}{"E1AF}
+\usv_set:nnn {stixsfup}{vartheta}{"E1B0}
+\usv_set:nnn {stixsfup}{varkappa}{0000} % ???
+\usv_set:nnn {stixsfup}{varphi}{"E1B1}
+\usv_set:nnn {stixsfup}{varrho}{"E1B2}
+\usv_set:nnn {stixsfup}{varpi}{"E1B3}
+\usv_set:nnn {stixupslash}{Greek}{"E2FC}
+\usv_set:nnn {stixbbit}{A}{"E154}
+\usv_set:nnn {stixbbit}{B}{"E155}
+\usv_set:nnn {stixbbit}{E}{"E156}
+\usv_set:nnn {stixbbit}{F}{"E157}
+\usv_set:nnn {stixbbit}{G}{"E158}
+\usv_set:nnn {stixbbit}{I}{"E159}
+\usv_set:nnn {stixbbit}{J}{"E15A}
+\usv_set:nnn {stixbbit}{K}{"E15B}
+\usv_set:nnn {stixbbit}{L}{"E15C}
+\usv_set:nnn {stixbbit}{M}{"E15D}
+\usv_set:nnn {stixbbit}{O}{"E15E}
+\usv_set:nnn {stixbbit}{S}{"E15F}
+\usv_set:nnn {stixbbit}{T}{"E160}
+\usv_set:nnn {stixbbit}{U}{"E161}
+\usv_set:nnn {stixbbit}{V}{"E162}
+\usv_set:nnn {stixbbit}{W}{"E163}
+\usv_set:nnn {stixbbit}{X}{"E164}
+\usv_set:nnn {stixbbit}{Y}{"E165}
+\usv_set:nnn {stixbbit}{a}{"E166}
+\usv_set:nnn {stixbbit}{b}{"E167}
+\usv_set:nnn {stixbbit}{c}{"E168}
+\usv_set:nnn {stixbbit}{f}{"E169}
+\usv_set:nnn {stixbbit}{g}{"E16A}
+\usv_set:nnn {stixbbit}{h}{"E16B}
+\usv_set:nnn {stixbbit}{k}{"E16C}
+\usv_set:nnn {stixbbit}{l}{"E16D}
+\usv_set:nnn {stixbbit}{m}{"E16E}
+\usv_set:nnn {stixbbit}{n}{"E16F}
+\usv_set:nnn {stixbbit}{o}{"E170}
+\usv_set:nnn {stixbbit}{p}{"E171}
+\usv_set:nnn {stixbbit}{q}{"E172}
+\usv_set:nnn {stixbbit}{r}{"E173}
+\usv_set:nnn {stixbbit}{s}{"E174}
+\usv_set:nnn {stixbbit}{t}{"E175}
+\usv_set:nnn {stixbbit}{u}{"E176}
+\usv_set:nnn {stixbbit}{v}{"E177}
+\usv_set:nnn {stixbbit}{w}{"E178}
+\usv_set:nnn {stixbbit}{x}{"E179}
+\usv_set:nnn {stixbbit}{y}{"E17A}
+\usv_set:nnn {stixbbit}{z}{"E17B}
+\usv_set:nnn {stixsfit}{Numerals}{"E1B4}
+\usv_set:nnn {stixsfit}{partial}{"E1BE}
+\usv_set:nnn {stixsfit}{Greek}{"E1BF}
+\usv_set:nnn {stixsfit}{greek}{"E1D8}
+\usv_set:nnn {stixsfit}{varTheta}{"E1D0}
+\usv_set:nnn {stixsfit}{varepsilon}{"E1F1}
+\usv_set:nnn {stixsfit}{vartheta}{"E1F2}
+\usv_set:nnn {stixsfit}{varkappa}{0000} % ???
+\usv_set:nnn {stixsfit}{varphi}{"E1F3}
+\usv_set:nnn {stixsfit}{varrho}{"E1F4}
+\usv_set:nnn {stixsfit}{varpi}{"E1F5}
+\usv_set:nnn {stixcal}{Latin}{"E22D}
+\usv_set:nnn {stixcal}{num}{"E262}
+\usv_set:nnn {scr}{num}{48}
+\usv_set:nnn {it}{num}{48}
+\usv_set:nnn {stixsfitslash}{Latin}{"E294}
+\usv_set:nnn {stixsfitslash}{latin}{"E2C8}
+\usv_set:nnn {stixsfitslash}{greek}{"E32C}
+\usv_set:nnn {stixsfitslash}{varepsilon}{"E37A}
+\usv_set:nnn {stixsfitslash}{vartheta}{"E35E}
+\usv_set:nnn {stixsfitslash}{varkappa}{"E374}
+\usv_set:nnn {stixsfitslash}{varphi}{"E360}
+\usv_set:nnn {stixsfitslash}{varrho}{"E376}
+\usv_set:nnn {stixsfitslash}{varpi}{"E362}
+\usv_set:nnn {stixsfitslash}{digamma}{"E36A}
+\usv_set:nnn {stixbfupslash}{Greek}{"E2FD}
+\usv_set:nnn {stixbfupslash}{Digamma}{"E369}
+\usv_set:nnn {stixbfbb}{A}{"E38A}
+\usv_set:nnn {stixbfbb}{B}{"E38B}
+\usv_set:nnn {stixbfbb}{E}{"E38D}
+\usv_set:nnn {stixbfbb}{F}{"E38E}
+\usv_set:nnn {stixbfbb}{G}{"E38F}
+\usv_set:nnn {stixbfbb}{I}{"E390}
+\usv_set:nnn {stixbfbb}{J}{"E391}
+\usv_set:nnn {stixbfbb}{K}{"E392}
+\usv_set:nnn {stixbfbb}{L}{"E393}
+\usv_set:nnn {stixbfbb}{M}{"E394}
+\usv_set:nnn {stixbfbb}{O}{"E395}
+\usv_set:nnn {stixbfbb}{S}{"E396}
+\usv_set:nnn {stixbfbb}{T}{"E397}
+\usv_set:nnn {stixbfbb}{U}{"E398}
+\usv_set:nnn {stixbfbb}{V}{"E399}
+\usv_set:nnn {stixbfbb}{W}{"E39A}
+\usv_set:nnn {stixbfbb}{X}{"E39B}
+\usv_set:nnn {stixbfbb}{Y}{"E39C}
+\usv_set:nnn {stixbfbb}{a}{"E39D}
+\usv_set:nnn {stixbfbb}{b}{"E39E}
+\usv_set:nnn {stixbfbb}{c}{"E39F}
+\usv_set:nnn {stixbfbb}{f}{"E3A2}
+\usv_set:nnn {stixbfbb}{g}{"E3A3}
+\usv_set:nnn {stixbfbb}{h}{"E3A4}
+\usv_set:nnn {stixbfbb}{k}{"E3A7}
+\usv_set:nnn {stixbfbb}{l}{"E3A8}
+\usv_set:nnn {stixbfbb}{m}{"E3A9}
+\usv_set:nnn {stixbfbb}{n}{"E3AA}
+\usv_set:nnn {stixbfbb}{o}{"E3AB}
+\usv_set:nnn {stixbfbb}{p}{"E3AC}
+\usv_set:nnn {stixbfbb}{q}{"E3AD}
+\usv_set:nnn {stixbfbb}{r}{"E3AE}
+\usv_set:nnn {stixbfbb}{s}{"E3AF}
+\usv_set:nnn {stixbfbb}{t}{"E3B0}
+\usv_set:nnn {stixbfbb}{u}{"E3B1}
+\usv_set:nnn {stixbfbb}{v}{"E3B2}
+\usv_set:nnn {stixbfbb}{w}{"E3B3}
+\usv_set:nnn {stixbfbb}{x}{"E3B4}
+\usv_set:nnn {stixbfbb}{y}{"E3B5}
+\usv_set:nnn {stixbfbb}{z}{"E3B6}
+\usv_set:nnn {stixbfsfup}{Numerals}{"E3B7}
+\usv_set:nnn {stixbfsfit}{Numerals}{"E1F6}
+\usv_set:nnn {stixbfbbit}{A}{"E200}
+\usv_set:nnn {stixbfbbit}{B}{"E201}
+\usv_set:nnn {stixbfbbit}{E}{"E203}
+\usv_set:nnn {stixbfbbit}{F}{"E204}
+\usv_set:nnn {stixbfbbit}{G}{"E205}
+\usv_set:nnn {stixbfbbit}{I}{"E206}
+\usv_set:nnn {stixbfbbit}{J}{"E207}
+\usv_set:nnn {stixbfbbit}{K}{"E208}
+\usv_set:nnn {stixbfbbit}{L}{"E209}
+\usv_set:nnn {stixbfbbit}{M}{"E20A}
+\usv_set:nnn {stixbfbbit}{O}{"E20B}
+\usv_set:nnn {stixbfbbit}{S}{"E20C}
+\usv_set:nnn {stixbfbbit}{T}{"E20D}
+\usv_set:nnn {stixbfbbit}{U}{"E20E}
+\usv_set:nnn {stixbfbbit}{V}{"E20F}
+\usv_set:nnn {stixbfbbit}{W}{"E210}
+\usv_set:nnn {stixbfbbit}{X}{"E211}
+\usv_set:nnn {stixbfbbit}{Y}{"E212}
+\usv_set:nnn {stixbfbbit}{a}{"E213}
+\usv_set:nnn {stixbfbbit}{b}{"E214}
+\usv_set:nnn {stixbfbbit}{c}{"E215}
+\usv_set:nnn {stixbfbbit}{e}{"E217}
+\usv_set:nnn {stixbfbbit}{f}{"E218}
+\usv_set:nnn {stixbfbbit}{g}{"E219}
+\usv_set:nnn {stixbfbbit}{h}{"E21A}
+\usv_set:nnn {stixbfbbit}{k}{"E21D}
+\usv_set:nnn {stixbfbbit}{l}{"E21E}
+\usv_set:nnn {stixbfbbit}{m}{"E21F}
+\usv_set:nnn {stixbfbbit}{n}{"E220}
+\usv_set:nnn {stixbfbbit}{o}{"E221}
+\usv_set:nnn {stixbfbbit}{p}{"E222}
+\usv_set:nnn {stixbfbbit}{q}{"E223}
+\usv_set:nnn {stixbfbbit}{r}{"E224}
+\usv_set:nnn {stixbfbbit}{s}{"E225}
+\usv_set:nnn {stixbfbbit}{t}{"E226}
+\usv_set:nnn {stixbfbbit}{u}{"E227}
+\usv_set:nnn {stixbfbbit}{v}{"E228}
+\usv_set:nnn {stixbfbbit}{w}{"E229}
+\usv_set:nnn {stixbfbbit}{x}{"E22A}
+\usv_set:nnn {stixbfbbit}{y}{"E22B}
+\usv_set:nnn {stixbfbbit}{z}{"E22C}
+\usv_set:nnn {stixbfcal}{Latin}{"E247}
+\usv_set:nnn {stixbfitslash}{Latin}{"E295}
+\usv_set:nnn {stixbfitslash}{latin}{"E2C9}
+\usv_set:nnn {stixbfitslash}{greek}{"E32D}
+\usv_set:nnn {stixsfitslash}{varepsilon}{"E37B}
+\usv_set:nnn {stixsfitslash}{vartheta}{"E35F}
+\usv_set:nnn {stixsfitslash}{varkappa}{"E375}
+\usv_set:nnn {stixsfitslash}{varphi}{"E361}
+\usv_set:nnn {stixsfitslash}{varrho}{"E377}
+\usv_set:nnn {stixsfitslash}{varpi}{"E363}
+\usv_set:nnn {stixsfitslash}{digamma}{"E36B}
\DeclareDocumentCommand \unimathsetup {m} {
\clist_clear:N \l_um_unknown_keys_clist
\keys_set:nn {unicode-math} {#1}
@@ -563,25 +785,32 @@
\mathopen {
\tl_if_in:NnTF \l_um_radicals_tl {#2} {
\cs_gset:cpx {\cs_to_str:N #2 sign} { \um_radical:nn {#1} {#4} }
+ \tl_set:cn {l_um_radical_\cs_to_str:N #2_tl} {\use:c{sym #1}~ #4}
}{
- \um_set_delcode:n {#4}
+ \um_set_delcode:nnn {#1} {#4} {#4}
\um_set_mathcode:nnn {#4} \mathopen {#1}
\cs_gset:Npx #2 { \um_delimiter:Nnn \mathopen {#1} {#4} }
}
}
\mathclose {
- \um_set_delcode:n {#4}
+ \um_set_delcode:nnn {#1} {#4} {#4}
\um_set_mathcode:nnn {#4} \mathclose {#1}
\cs_gset:Npx #2 { \um_delimiter:Nnn \mathclose {#1} {#4} }
}
+ \mathaccent {
+ \cs_gset:Npx #2 { \um_accent:Nnn #3 {#1} {#4} }
+ }
\mathfence {
\um_set_mathcode:nnn {#4} {#3} {#1}
- \um_set_delcode:n {#4}
+ \um_set_delcode:nnn {#1} {#4} {#4}
\cs_gset:cpx {l \cs_to_str:N #2} { \um_delimiter:Nnn \mathopen {#1} {#4} }
\cs_gset:cpx {r \cs_to_str:N #2} { \um_delimiter:Nnn \mathclose {#1} {#4} }
}
- \mathaccent {
- \cs_gset:Npx #2 { \um_accent:Nnn #3 {#1} {#4} }
+ \mathover { % LuaTeX only
+ \cs_set:Npn #2 ##1 { \mathop { \um_overbrace:nnn {#1} {#4} {##1} } \limits }
+ }
+ \mathunder { % LuaTeX only
+ \cs_set:Npn #2 ##1 { \mathop { \um_underbrace:nnn {#1} {#4} {##1} } \limits }
}
}{
\um_set_mathcode:nnn {#4} {#3} {#1}
@@ -611,6 +840,9 @@
\Umathchardef #1 =
\mathchar@type#2 \csname sym#3\endcsname \intexpr_eval:n {#4} \scan_stop:
}
+\cs_new:Npn \um_set_delcode:nnn #1#2#3 {
+ \Udelcode#2 = \csname sym#1\endcsname #3
+}
\cs_new:Npn \um_radical:nn #1#2 {
\Uradical \csname sym#1\endcsname #2 \scan_stop:
}
@@ -621,6 +853,12 @@
\Umathaccent \mathchar@type#1 \csname sym#2\endcsname #3 \scan_stop:
}
\cs_generate_variant:Nn \um_set_mathchar:NNnn {c}
+\cs_set:Npn \um_overbrace:nnn #1#2#3 {
+ \luatexUdelimiterover \csname sym#1\endcsname #2 {#3}
+}
+\cs_set:Npn \um_underbrace:nnn #1#2#3 {
+ \luatexUdelimiterunder \csname sym#1\endcsname #2 {#3}
+}
\cs_new:Npn \char_gmake_mathactive:N #1 {
\global\mathcode `#1 = "8000 \scan_stop:
}
@@ -660,24 +898,25 @@
\bool_if:NTF \l_um_init_bool {
\tl_set:Nn \um_symfont_tl {um_allsym}
\msg_trace:nnx {unicode-math} {default-math-font} {#2}
- \cs_set_eq:NN \UnicodeMathSymbol \um_process_symbol_noparse:nnnn
+ \cs_set_eq:NN \_um_sym:nnn \um_process_symbol_noparse:nnn
\cs_set_eq:NN \um_set_mathalphabet_char:Nnn \um_mathmap_noparse:Nnn
\cs_set_eq:NN \um_remap_symbol:nnn \um_remap_symbol_noparse:nnn
\cs_set_eq:NN \um_maybe_init_alphabet:n \um_init_alphabet:n
\cs_set_eq:NN \um_map_char_single:nn \um_map_char_noparse:nn
+ \cs_set_eq:NN \um_assign_delcode:nn \um_assign_delcode_noparse:nn
}{
\int_incr:N \g_um_fam_int
\tl_set:Nx \um_symfont_tl {um_fam\int_use:N\g_um_fam_int}
- \cs_set_eq:NN \UnicodeMathSymbol \um_process_symbol_parse:nnnn
+ \cs_set_eq:NN \_um_sym:nnn \um_process_symbol_parse:nnn
\cs_set_eq:NN \um_set_mathalphabet_char:Nnn \um_mathmap_parse:Nnn
\cs_set_eq:NN \um_remap_symbol:nnn \um_remap_symbol_parse:nnn
\cs_set_eq:NN \um_maybe_init_alphabet:n \use_none:n
\cs_set_eq:NN \um_map_char_single:nn \um_map_char_parse:nn
+ \cs_set_eq:NN \um_assign_delcode:nn \um_assign_delcode_parse:nn
}
\DeclareSymbolFont{\um_symfont_tl}
{\encodingdefault}{\zf@family}{\mddefault}{\updefault}
- \@input{unicode-math-table.tex}
- \cs_set_eq:NN \UnicodeMathSymbol \use_none:nnnn
+ \um_input_math_symbol_table:
\um_remap_symbols:
\um_setup_mathactives:
\um_setup_delcodes:
@@ -688,6 +927,7 @@
\bool_set_true:N \l_um_fontspec_feature_bool
\fontspec_select:xn
{
+ \luatex_if_engine:T { Renderer = Basic, }
BoldFont = {}, ItalicFont = {},
Script = Math,
SizeFeatures = {
@@ -707,12 +947,12 @@
\tl_set_eq:NN \l_um_font \zf@basefont
\bool_set_false:N \l_um_fontspec_feature_bool
}
-\cs_set:Npn \um_process_symbol_noparse:nnnn #1#2#3#4 {
+\cs_set:Npn \um_process_symbol_noparse:nnn #1#2#3 {
\um_set_mathsymbol:nNNn {\um_symfont_tl} #2#3{#1}
}
-\cs_set:Npn \um_process_symbol_parse:nnnn #1#2#3#4 {
+\cs_set:Npn \um_process_symbol_parse:nnn #1#2#3 {
\um@parse@term{#1}{#2}{#3}{
- \um_process_symbol_noparse:nnnn{#1}{#2}{#3}{#4}
+ \um_process_symbol_noparse:nnn {#1}{#2}{#3}
}
}
\cs_new:Npn \um_remap_symbols: {
@@ -747,58 +987,51 @@
\um_set_mathchar:NNnn #2 #3 {\um_symfont_tl} {#1}
\char_gmake_mathactive:n {#1}
}
-\cs_new:Npn \um_setup_delcodes: {
- \um_set_delcode:nn {`\/} {\g_um_slash_delimiter_usv}
- \um_set_delcode:nn {"2044} {\g_um_slash_delimiter_usv} % fracslash
- \um_set_delcode:nn {"2215} {\g_um_slash_delimiter_usv} % divslash
- \um_set_delcode:n {"005C} % backslash
- \um_set_delcode:nn {`\<} {"27E8} % angle brackets with ascii notation
- \um_set_delcode:nn {`\>} {"27E9} % angle brackets with ascii notation
- \um_set_delcode:n {"2191} % up arrow
- \um_set_delcode:n {"2193} % down arrow
- \um_set_delcode:n {"2195} % updown arrow
- \um_set_delcode:n {"219F} % up arrow twohead
- \um_set_delcode:n {"21A1} % down arrow twohead
- \um_set_delcode:n {"21A5} % up arrow from bar
- \um_set_delcode:n {"21A7} % down arrow from bar
- \um_set_delcode:n {"21A8} % updown arrow from bar
- \um_set_delcode:n {"21BE} % up harpoon right
- \um_set_delcode:n {"21BF} % up harpoon left
- \um_set_delcode:n {"21C2} % down harpoon right
- \um_set_delcode:n {"21C3} % down harpoon left
- \um_set_delcode:n {"21C5} % arrows up down
- \um_set_delcode:n {"21F5} % arrows down up
- \um_set_delcode:n {"21C8} % arrows up up
- \um_set_delcode:n {"21CA} % arrows down down
- \um_set_delcode:n {"21D1} % double up arrow
- \um_set_delcode:n {"21D3} % double down arrow
- \um_set_delcode:n {"21D5} % double updown arrow
- \um_set_delcode:n {"21DE} % up arrow double stroke
- \um_set_delcode:n {"21DF} % down arrow double stroke
- \um_set_delcode:n {"21E1} % up arrow dashed
- \um_set_delcode:n {"21E3} % down arrow dashed
- \um_set_delcode:n {"21E7} % up white arrow
- \um_set_delcode:n {"21E9} % down white arrow
- \um_set_delcode:n {"21EA} % up white arrow from bar
- \um_set_delcode:n {"21F3} % updown white arrow
-}
-\cs_new:Npn \um_set_delcode:nn #1#2 {
- \Udelcode#1 = \csname sym\um_symfont_tl\endcsname #2
-}
-\cs_new:Npn \um_set_delcode:n #1 {
- \Udelcode#1 = \csname sym\um_symfont_tl\endcsname #1
+\cs_new:Npn \um_assign_delcode_noparse:nn #1#2 {
+ \um_set_delcode:nnn \um_symfont_tl {#1} {#2}
}
-\cs_set:Npn \um_mathmap_noparse:Nnn #1#2#3 {
- \clist_map_inline:nn {#2} {
- \tl_put_right:cx {um_switchto_\cs_to_str:N #1:} {
- \um_set_mathcode:nnnn{##1}{\mathalpha}{\um_symfont_tl}{#3}
- }
+\cs_new:Npn \um_assign_delcode_parse:nn #1#2 {
+ \um@parse@term {#2}{\@nil}{\@nil} {
+ \um_assign_delcode_noparse:nn {#1} {#2}
}
}
-\cs_set:Npn \um_mathmap_parse:Nnn #1#2#3 {
- \clist_if_in:NnT \l_um_char_num_range_clist {#3} {
- \um_mathmap_noparse:Nnn {#1}{#2}{#3}
- }
+\cs_new:Npn \um_assign_delcode:n #1 {
+ \um_assign_delcode:nn {#1} {#1}
+}
+\cs_new:Npn \um_setup_delcodes: {
+ \um_assign_delcode:nn {`\/} {\g_um_slash_delimiter_usv}
+ \um_assign_delcode:nn {"2044} {\g_um_slash_delimiter_usv} % fracslash
+ \um_assign_delcode:nn {"2215} {\g_um_slash_delimiter_usv} % divslash
+ \um_assign_delcode:n {"005C} % backslash
+ \um_assign_delcode:nn {`\<} {"27E8} % angle brackets with ascii notation
+ \um_assign_delcode:nn {`\>} {"27E9} % angle brackets with ascii notation
+ \um_assign_delcode:n {"2191} % up arrow
+ \um_assign_delcode:n {"2193} % down arrow
+ \um_assign_delcode:n {"2195} % updown arrow
+ \um_assign_delcode:n {"219F} % up arrow twohead
+ \um_assign_delcode:n {"21A1} % down arrow twohead
+ \um_assign_delcode:n {"21A5} % up arrow from bar
+ \um_assign_delcode:n {"21A7} % down arrow from bar
+ \um_assign_delcode:n {"21A8} % updown arrow from bar
+ \um_assign_delcode:n {"21BE} % up harpoon right
+ \um_assign_delcode:n {"21BF} % up harpoon left
+ \um_assign_delcode:n {"21C2} % down harpoon right
+ \um_assign_delcode:n {"21C3} % down harpoon left
+ \um_assign_delcode:n {"21C5} % arrows up down
+ \um_assign_delcode:n {"21F5} % arrows down up
+ \um_assign_delcode:n {"21C8} % arrows up up
+ \um_assign_delcode:n {"21CA} % arrows down down
+ \um_assign_delcode:n {"21D1} % double up arrow
+ \um_assign_delcode:n {"21D3} % double down arrow
+ \um_assign_delcode:n {"21D5} % double updown arrow
+ \um_assign_delcode:n {"21DE} % up arrow double stroke
+ \um_assign_delcode:n {"21DF} % down arrow double stroke
+ \um_assign_delcode:n {"21E1} % up arrow dashed
+ \um_assign_delcode:n {"21E3} % down arrow dashed
+ \um_assign_delcode:n {"21E7} % up white arrow
+ \um_assign_delcode:n {"21E9} % down white arrow
+ \um_assign_delcode:n {"21EA} % up white arrow from bar
+ \um_assign_delcode:n {"21F3} % updown white arrow
}
\tl_new:Nn \l_um_nolimits_tl {
\int\iint\iiint\iiiint\oint\oiint\oiiint
@@ -825,12 +1058,12 @@
}
}
}
-\um@zf@feature{ScriptStyle}{
- \zf@update@ff{+ssty=0}
-}
-\um@zf@feature{ScriptScriptStyle}{
- \zf@update@ff{+ssty=1}
-}
+\xetex_or_luatex:nnn { \um@zf@feature {ScriptStyle} }
+ { \zf@update@ff{+ssty=0} }
+ { \zf@update@ff{+ssty=1} }
+\xetex_or_luatex:nnn { \um@zf@feature {ScriptScriptStyle} }
+ { \zf@update@ff{+ssty=1} }
+ { \zf@update@ff{+ssty=2} }
\keys_define:nn {unicode-math}
{
script-features .tl_set:N = \l_um_script_features_tl ,
@@ -869,7 +1102,7 @@
\exp_after:wN \um_split_slash:w \l_um_tmpa_tl \q_nil
}
\tl_if_empty:NT \l_um_tmpc_tl { \tl_set_eq:NN \l_um_tmpc_tl \l_um_tmpa_tl }
- \seq_if_in:NVTF \g_um_mathalph_seq \l_um_tmpa_tl {
+ \seq_if_in:NVTF \g_um_mathstyles_seq \l_um_tmpa_tl {
\prg_return_true:
}{
\prg_return_false:
@@ -877,7 +1110,9 @@
}
\cs_set:Npn \um_split_arrow:w #1->#2 \q_nil {
\tl_set:Nn \l_um_tmpa_tl {#1}
- \tl_set:Nn \l_um_tmpc_tl {#2}
+ \tl_if_single:nTF {#2}
+ { \tl_set:Nn \l_um_tmpc_tl {#2} }
+ { \exp_args:NNc \tl_set:Nn \l_um_tmpc_tl {math#2} }
}
\cs_set:Npn \um_split_slash:w #1/#2 \q_nil {
\tl_set:Nn \l_um_tmpa_tl {#1}
@@ -953,19 +1188,38 @@
\bool_if:NTF \g_um_texgreek_bool \mitphi \mitvarphi
}
}
-\seq_new:N \g_um_mathalph_seq
+\cs_new:Npn \um_new_mathstyle:N #1 {
+ \um_prepare_mathstyle:f {\exp_after:wN \use_none:nnnnn \token_to_str:N #1}
+ \seq_put_right:Nn \g_um_mathstyles_seq {#1}
+}
+\seq_new:N \g_um_default_mathalph_seq
+\seq_new:N \g_um_mathstyles_seq
\AtEndOfPackage{
- \tl_map_inline:nn {
- \mathup\mathit\mathbb\mathbbit
- \mathscr\mathfrak\mathtt
- \mathsf\mathsfup\mathsfit
- \mathbf\mathbfup\mathbfit
- \mathbfscr\mathbffrak
- \mathbfsf\mathbfsfup\mathbfsfit
- }{
- \seq_put_right:Nn \g_um_mathalph_seq {#1}
- \um_prepare_mathstyle:f {\exp_after:wN \use_none:nnnnn \token_to_str:N #1}
- }
+\clist_map_inline:nn {
+ {\mathup } {latin,Latin,greek,Greek,num,misc} {\mathup } ,
+ {\mathit } {latin,Latin,greek,Greek,misc} {\mathit } ,
+ {\mathbb } {latin,Latin,num,misc} {\mathbb } ,
+ {\mathbbit } {misc} {\mathbbit } ,
+ {\mathscr } {latin,Latin} {\mathscr } ,
+ {\mathcal } {Latin} {\mathscr } ,
+ {\mathbfcal } {Latin} {\mathbfscr } ,
+ {\mathfrak } {latin,Latin} {\mathfrak } ,
+ {\mathtt } {latin,Latin,num} {\mathtt } ,
+ {\mathsfup } {latin,Latin,num} {\mathsfup } ,
+ {\mathsfit } {latin,Latin} {\mathsfit } ,
+ {\mathbfup } {latin,Latin,greek,Greek,num,misc} {\mathbfup } ,
+ {\mathbfit } {latin,Latin,greek,Greek,misc} {\mathbfit } ,
+ {\mathbfscr } {latin,Latin} {\mathbfscr } ,
+ {\mathbffrak} {latin,Latin} {\mathbffrak} ,
+ {\mathbfsfup} {latin,Latin,greek,Greek,num,misc} {\mathbfsfup} ,
+ {\mathbfsfit} {latin,Latin,greek,Greek,misc} {\mathbfsfit}
+}{
+ \seq_put_right:Nn \g_um_default_mathalph_seq {#1}
+ \exp_after:wN \um_new_mathstyle:N \use_i:nnn #1
+}
+\um_new_mathstyle:N \mathsf
+\um_new_mathstyle:N \mathbf
+\um_new_mathstyle:N \mathbfsf
}
\cs_new:Npn \um_prepare_mathstyle:n #1 {
\um_init_alphabet:x {#1}
@@ -992,26 +1246,6 @@
\cs_new:Npn \um_maybe_init_alphabet:V {
\exp_args:NV \um_maybe_init_alphabet:n
}
-\seq_new:N \g_um_default_mathalph_seq
-\clist_map_inline:nn {
- {\mathup } {latin,Latin,greek,Greek,num,misc} {\mathup } ,
- {\mathit } {latin,Latin,greek,Greek,misc} {\mathit } ,
- {\mathbb } {latin,Latin,num,misc} {\mathbb } ,
- {\mathbbit } {misc} {\mathbbit } ,
- {\mathscr } {latin,Latin} {\mathscr } ,
- {\mathfrak } {latin,Latin} {\mathfrak } ,
- {\mathtt } {latin,Latin,num} {\mathtt } ,
- {\mathsfup } {latin,Latin,num} {\mathsfup } ,
- {\mathsfit } {latin,Latin} {\mathsfit } ,
- {\mathbfup } {latin,Latin,greek,Greek,num,misc} {\mathbfup } ,
- {\mathbfit } {latin,Latin,greek,Greek,misc} {\mathbfit } ,
- {\mathbfscr } {latin,Latin} {\mathbfscr } ,
- {\mathbffrak} {latin,Latin} {\mathbffrak} ,
- {\mathbfsfup} {latin,Latin,greek,Greek,num,misc} {\mathbfsfup} ,
- {\mathbfsfit} {latin,Latin,greek,Greek,misc} {\mathbfsfit}
-}{
- \seq_put_right:Nn \g_um_default_mathalph_seq {#1}
-}
\seq_new:N \l_um_missing_alph_seq
\cs_new:Npn \um_setup_alphabets: {
\seq_if_empty:NTF \l_um_mathalph_seq {
@@ -1097,6 +1331,27 @@
}
}
\cs_generate_variant:Nn \um_setup_math_alphabet:Nnn {VVV}
+\cs_new:Npn \um_map_char_single:cc { \exp_args:Ncc \um_map_char_single:nn }
+\cs_new:Npn \um_map_char_noparse:nn #1#2 {
+ \um_set_mathcode:nnnn {#1}{\mathalpha}{\um_symfont_tl}{#2}
+}
+\cs_new:Npn \um_map_char_parse:nn #1#2 {
+ \um@parse@term {#1} {\@nil} {\mathalpha} {
+ \um_map_char_noparse:nn {#1}{#2}
+ }
+}
+\cs_new:Npn \um_map_char_single:nnn #1#2#3 {
+ \um_map_char_single:cc { \um_to_usv:nn {#1}{#3} }
+ { \um_to_usv:nn {#2}{#3} }
+}
+\cs_set:Npn \um_map_single:nnn #1#2#3 {
+ \cs_if_exist:cT { \um_to_usv:nn {#3} {#1} }
+ {
+ \clist_map_inline:nn {#2} {
+ \um_map_char_single:nnn {##1} {#3} {#1}
+ }
+ }
+}
\cs_set:Npn \um_map_chars_range:nnn #1#2#3 {
\prg_stepwise_inline:nnnn {0}{1}{#1-1} {
\um_map_char_single:nn {#2+##1}{#3+##1}
@@ -1107,14 +1362,6 @@
\um_map_chars_range:ncc {#1} { \um_to_usv:nn {#2}{#4} }
{ \um_to_usv:nn {#3}{#4} }
}
-\cs_new:Npn \um_map_char_noparse:nn #1#2 {
- \um_set_mathcode:nnnn {#1}{\mathalpha}{\um_symfont_tl}{#2}
-}
-\cs_new:Npn \um_map_char_parse:nn #1#2 {
- \um@parse@term {#1} {\@nil} {\mathalpha} {
- \um_map_char_noparse:nn {#1}{#2}
- }
-}
\cs_set:Npn \um_map_chars_Latin:nn #1#2 {
\clist_map_inline:nn {#1} {
\um_map_chars_range:nnnn {26} {##1} {#2} {Latin}
@@ -1145,25 +1392,35 @@
\cs_set:Npn \um_map_chars_numbers:nn #1#2 {
\um_map_chars_range:nnnn {10} {#1} {#2} {num}
}
-\cs_new:Npn \um_map_char_single:cc { \exp_args:Ncc \um_map_char_single:nn }
-\cs_new:Npn \um_map_char_single:nnn #1#2#3 {
- \um_map_char_single:cc { \um_to_usv:nn {#1}{#3} }
- { \um_to_usv:nn {#2}{#3} }
+\cs_new:Npn \um_set_mathalphabet_char:Ncc {
+ \exp_args:NNcc \um_set_mathalphabet_char:Nnn
}
-\cs_set:Npn \um_map_single:nnn #1#2#3 {
- \cs_if_exist:cT { \um_to_usv:nn {#3} {#1} }
- {
- \clist_map_inline:nn {#2} {
- \um_map_char_single:nnn {##1} {#3} {#1}
+\cs_set:Npn \um_mathmap_noparse:Nnn #1#2#3 {
+ \clist_map_inline:nn {#2} {
+ \tl_put_right:cx {um_switchto_\cs_to_str:N #1:} {
+ \um_set_mathcode:nnnn{##1}{\mathalpha}{\um_symfont_tl}{#3}
}
}
}
+\cs_set:Npn \um_mathmap_parse:Nnn #1#2#3 {
+ \clist_if_in:NnT \l_um_char_num_range_clist {#3} {
+ \um_mathmap_noparse:Nnn {#1}{#2}{#3}
+ }
+}
+\cs_new:Npn \um_set_mathalphabet_char:Nnnn #1#2#3#4 {
+ \um_set_mathalphabet_char:Ncc #1 { \um_to_usv:nn {#2} {#4} }
+ { \um_to_usv:nn {#3} {#4} }
+}
\cs_new:Npn \um_set_mathalph_range:nNnn #1#2#3#4 {
\prg_stepwise_inline:nnnn {0}{1}{#1-1} {
\um_set_mathalphabet_char:Nnn {#2} { ##1 + #3 } { ##1 + #4 }
}
}
\cs_generate_variant:Nn \um_set_mathalph_range:nNnn {nNcc}
+\cs_new:Npn \um_set_mathalph_range:nNnnn #1#2#3#4#5 {
+ \um_set_mathalph_range:nNcc {#1} #2 { \um_to_usv:nn {#3} {#5} }
+ { \um_to_usv:nn {#4} {#5} }
+}
\cs_new:Npn \um_set_mathalphabet_pos:Nnnn #1#2#3#4 {
\cs_if_exist:cT { \um_to_usv:nn {#4}{#2} } {
\clist_map_inline:nn {#3} {
@@ -1204,17 +1461,6 @@
\um_set_mathalphabet_char:Nnnn #1 {##1} {#3} {varpi}
}
}
-\cs_new:Npn \um_set_mathalphabet_char:Ncc {
- \exp_args:NNcc \um_set_mathalphabet_char:Nnn
-}
-\cs_new:Npn \um_set_mathalphabet_char:Nnnn #1#2#3#4 {
- \um_set_mathalphabet_char:Ncc #1 { \um_to_usv:nn {#2} {#4} }
- { \um_to_usv:nn {#3} {#4} }
-}
-\cs_new:Npn \um_set_mathalph_range:nNnnn #1#2#3#4#5 {
- \um_set_mathalph_range:nNcc {#1} #2 { \um_to_usv:nn {#3} {#5} }
- { \um_to_usv:nn {#4} {#5} }
-}
\cs_new:Npn \um_config_up_num:n #1 {
\um_map_chars_numbers:nn {up}{#1}
\um_set_mathalphabet_numbers:Nnn \mathup {up}{#1}
@@ -1393,6 +1639,17 @@
\um_set_mathalphabet_pos:Nnnn \mathscr {g}{up,it}{#1}
\um_set_mathalphabet_pos:Nnnn \mathscr {o}{up,it}{#1}
}
+\cs_new:Npn \um_config_cal_Latin:n #1 {
+ \um_set_mathalphabet_Latin:Nnn \mathcal {up,it}{#1}
+ \um_set_mathalphabet_pos:Nnnn \mathcal {B}{up,it}{#1}
+ \um_set_mathalphabet_pos:Nnnn \mathcal {E}{up,it}{#1}
+ \um_set_mathalphabet_pos:Nnnn \mathcal {F}{up,it}{#1}
+ \um_set_mathalphabet_pos:Nnnn \mathcal {H}{up,it}{#1}
+ \um_set_mathalphabet_pos:Nnnn \mathcal {I}{up,it}{#1}
+ \um_set_mathalphabet_pos:Nnnn \mathcal {L}{up,it}{#1}
+ \um_set_mathalphabet_pos:Nnnn \mathcal {M}{up,it}{#1}
+ \um_set_mathalphabet_pos:Nnnn \mathcal {R}{up,it}{#1}
+}
\cs_new:Npn \um_config_frak_Latin:n #1 {
\um_set_mathalphabet_Latin:Nnn \mathfrak {up,it}{#1}
\um_set_mathalphabet_pos:Nnnn \mathfrak {C}{up,it}{#1}
@@ -1657,6 +1914,9 @@
\cs_new:Npn \um_config_bfscr_latin:n #1 {
\um_set_mathalphabet_latin:Nnn \mathbfscr {up,it}{#1}
}
+\cs_new:Npn \um_config_bfcal_Latin:n #1 {
+ \um_set_mathalphabet_Latin:Nnn \mathbfcal {up,it}{#1}
+}
\cs_new:Npn \um_config_bfsfup_num:n #1 {
\um_set_mathalphabet_numbers:Nnn \mathbfsf {up}{#1}
\um_set_mathalphabet_numbers:Nnn \mathbfsfup {up}{#1}
@@ -1821,6 +2081,25 @@
}
}
}
+\xetex_or_luatex:nnn { \cs_set:Npn \um_symbol_setup: }
+ {
+ \def\mathfence{\mathfence}
+ \def\mathover{\mathover}
+ \def\mathunder{\mathunder}
+ \cs_set:Npn \UnicodeMathSymbol ##1##2##3##4 {
+ \prg_case_tl:Nnn ##3 { \mathover {} \mathunder {} }
+ {
+ \exp_not:n {\_um_sym:nnn{##1}{##2}{##3}}
+ }
+ }
+ }
+ {
+ \cs_set:Npn \UnicodeMathSymbol ##1##2##3##4 {
+ \exp_not:n {\_um_sym:nnn{##1}{##2}{##3}}
+ }
+ }
+\CatchFileEdef \g_um_mathtable_tl {unicode-math-table.tex} {\um_symbol_setup:}
+\cs_new:Npn \um_input_math_symbol_table: {\g_um_mathtable_tl}
\begingroup
\char_make_other:N \^
\cs_gset:Npn \um@scancharlet#1="#2\@nil {
@@ -1849,16 +2128,18 @@
\endgroup
\AtBeginDocument{
\group_begin:
- \char_make_math_superscript:N\^
- \def\UnicodeMathSymbol#1#2#3#4{
+ \char_make_math_superscript:N \^
+ \cs_set:Npn \_um_sym:nnn #1#2#3 {
\bool_if:nF { \cs_if_eq_p:NN #3 \mathaccent ||
\cs_if_eq_p:NN #3 \mathopen ||
- \cs_if_eq_p:NN #3 \mathclose } {
+ \cs_if_eq_p:NN #3 \mathclose ||
+ \cs_if_eq_p:NN #3 \mathover ||
+ \cs_if_eq_p:NN #3 \mathunder } {
\um@scancharlet#2=#1\@nil\ignorespaces
}
}
\char_make_other:N \#
- \@input{unicode-math-table.tex}
+ \um_input_math_symbol_table:
\group_end:
}
\group_begin:
@@ -1871,26 +2152,38 @@
}
}
|group_end:
+\cs_new:Nn \um_arg_i_before_egroup:n {#1\egroup}
+\cs_new:Nn \um_superscript:n {
+ ^\bgroup #1
+ \peek_meaning_remove:NTF ^
+ \um_arg_i_before_egroup:n \egroup
+}
\muskip_new:N \g_um_primekern_muskip
\muskip_gset:Nn \g_um_primekern_muskip { -\thinmuskip/2 }% arbitrary
\int_new:N \l_um_primecount_int
\cs_new:Npn \um_nprimes:Nn #1#2 {
- ^{
- #1
- \prg_replicate:nn {#2-1} { \mskip \g_um_primekern_muskip #1 }
- }
+ \um_superscript:n {
+ #1
+ \prg_replicate:nn {#2-1} { \mskip \g_um_primekern_muskip #1 }
+ }
}
\cs_new:Npn \um_nprimes_select:nn #1#2 {
\prg_case_int:nnn {#2}{
- {1} { ^{#1} }
+ {1} { \um_superscript:n {#1} }
{2} {
- \um_glyph_if_exist:nTF {"2033} { ^{\um_prime_double_mchar} } {\um_nprimes:Nn #1 {#2}}
+ \um_glyph_if_exist:nTF {"2033}
+ { \um_superscript:n {\um_prime_double_mchar} }
+ { \um_nprimes:Nn #1 {#2} }
}
{3} {
- \um_glyph_if_exist:nTF {"2034} {^{\um_prime_triple_mchar} } {\um_nprimes:Nn #1 {#2}}
+ \um_glyph_if_exist:nTF {"2034}
+ { \um_superscript:n {\um_prime_triple_mchar} }
+ { \um_nprimes:Nn #1 {#2} }
}
{4} {
- \um_glyph_if_exist:nTF {"2057} { ^{\um_prime_quad_mchar} } {\um_nprimes:Nn #1 {#2}}
+ \um_glyph_if_exist:nTF {"2057}
+ { \um_superscript:n {\um_prime_quad_mchar} }
+ { \um_nprimes:Nn #1 {#2} }
}
}{
\um_nprimes:Nn #1 {#2}
@@ -1898,12 +2191,16 @@
}
\cs_new:Npn \um_nbackprimes_select:nn #1#2 {
\prg_case_int:nnn {#2}{
- {1} { ^{#1} }
+ {1} { \um_superscript:n {#1} }
{2} {
- \um_glyph_if_exist:nTF {"2033} { ^{\um_backprime_double_mchar} } {\um_nprimes:Nn #1 {#2}}
+ \um_glyph_if_exist:nTF {"2036}
+ { \um_superscript:n {\um_backprime_double_mchar} }
+ { \um_nprimes:Nn #1 {#2} }
}
{3} {
- \um_glyph_if_exist:nTF {"2034} {^{\um_backprime_triple_mchar} } {\um_nprimes:Nn #1 {#2}}
+ \um_glyph_if_exist:nTF {"2037}
+ { \um_superscript:n {\um_backprime_triple_mchar} }
+ { \um_nprimes:Nn #1 {#2} }
}
}{
\um_nprimes:Nn #1 {#2}
@@ -2050,6 +2347,14 @@
\cs_set_eq:NN ^^^^2037 \um_scan_backtrprime:
}
\group_end:
+\luatex_if_engine:T {
+ \DeclareDocumentCommand \sqrt { O{} m } {
+ \luatexUroot \l_um_radical_sqrt_tl {#1} {#2}
+ }
+ \cs_set:Npn \root #1 \of #2 {
+ \luatexUroot \l_um_radical_sqrt_tl {#1} {#2}
+ }
+}
\cs_set_nopar:Npn \r@@t #1#2 {
\setbox\z@\hbox{$\m@th #1\sqrtsign{#2}$}
\um_mathstyle_scale:Nnn{#1}{\kern}{\fontdimen63\l_um_font}
@@ -2201,6 +2506,7 @@
}
\cs_new:Npn \um_setup_active_frac: {
\group_begin:
+ \um_define_active_frac:Nw ^^^^2189 0/3
\um_define_active_frac:Nw ^^^^2152 1/{10}
\um_define_active_frac:Nw ^^^^2151 1/9
\um_define_active_frac:Nw ^^^^215b 1/8
@@ -2240,7 +2546,6 @@
\bool_if:NTF \g_um_literal_colon_bool {:} { \mathpunct{:} }
}
}
-\def\mathcal{\mathscr}
\def\mathrm{\mathup}
\let\mathfence\mathord
\def\digamma{\updigamma}
@@ -2269,8 +2574,12 @@
}
\def\std@minus{\Umathcharnum\Umathcodenum`\-\relax}
\def\std@equal{\Umathcharnum\Umathcodenum`\=\relax}
- \def\@cdots{\mathinner{\cdots}}
+ \cs_set:Npn \@cdots {\mathinner{\cdots}}
\cs_set_eq:NN \dotsb@ \cdots
+ \def \resetMathstrut@ {%
+ \setbox\z@\hbox{$($}%
+ \ht\Mathstrutbox@\ht\z@ \dp\Mathstrutbox@\dp\z@
+ }
}
\um_patch_pkg:nn {amsopn} {
\cs_set:Npn \newmcodes@ {
@@ -2300,42 +2609,4 @@
\fi
}{}
}
-\cs_new:Npn \um_warning:n { \msg_warning:nn {unicode-math} }
-\cs_new:Npn \um_trace:n { \msg_trace:nn {unicode-math} }
-\cs_new:Npn \um_trace:nx { \msg_trace:nnx {unicode-math} }
-\msg_new:nnn {unicode-math} {maths-feature-only}
-{
- The~ '#1'~ font~ feature~ can~ only~ be~ used~ for~ maths~ fonts.
-}
-\msg_new:nnn {unicode-math} {disable-beamer}
-{
- Disabling~ beamer's~ math~ setup.\\
- Please~ load~ beamer~ with~ the~ [professionalfonts]~ class~ option.
-}
-\msg_new:nnn {unicode-math} {no-tfrac}
-{
- Small~ fraction~ command~ \protect\tfrac\ not~ defined.\\
- Load~ amsmath~ or~ define~ it~ manually~ before~ loading~ unicode-math.
-}
-\msg_new:nnn {unicode-math} {default-math-font}
-{
- Defining~ the~ default~ maths~ font~ as~ '#1'.
-}
-\msg_new:nnn {unicode-math} {setup-implicit}
-{
- Setup~ alphabets:~ implicit~ mode.
-}
-\msg_new:nnn {unicode-math} {setup-explicit}
-{
- Setup~ alphabets:~ explicit~ mode.
-}
-\msg_new:nnn {unicode-math} {alph-initialise}
-{
- Initialising~ \@backslashchar math#1.
-}
-\msg_new:nnn {unicode-math} {setup-alph}
-{
- Setup~ alphabet:~ #1.
-}
\ExplSyntaxOff
-\errorcontextlines=999