In XeXeX I can input a glyph by the glyph ID \XeTeXglyph4185\relax
However, when I try to define a math character, no character is inserted: \Umathchardef\myint 0 0 4185
If I instead use \Umathchardef\myint 0 0 "222B then I get the standard unicode integral. However, I of course want a different symbol.
I have tried reading the XeTeX reference pdf, but I am unable to figure out what values for ⟨math type⟩ ⟨fam.⟩ I should use.
\documentclass[]{report}
\usepackage[no-math]{fontspec}
\setmainfont[]{TeX Gyre Pagella Math}
\usepackage{amsmath,amssymb,amsthm}
\usepackage{unicode-math}
\setmathfont[
mathrm = sym,
mathup = sym,
mathit = sym,
mathbf = sym,
mathbf = sym,
math-style = TeX,
bold-style = TeX,
]{TeX Gyre Pagella Math}
\AtBeginDocument{%
\Umathchardef\myint 0 0 4185
}
\begin{document}
{\XeTeXglyph4185\relax
( \myint )
\end{document}
\textin mathmode. – overfull hbox May 10 '22 at 20:11