1

Afte reading the post about Importing a Single Symbol From a Different Font I was curious how the people know the symbol's font slot, like "80 in that example.

\DeclareMathSymbol{\varsubset}{3}{matha}{"80}

I'd like to do the similar replacement for \cap and \cup, but I don't know their slots.

3
  • 1
    if as there you are copying the character from an existing font setup then simply take it from the package the line you quote has the comment % Define a subset character from that font (from mathabx.dcl) that file also has the lines \DeclareMathSymbol{\cap} {2}{matha}{"58} \DeclareMathSymbol{\cup} {2}{matha}{"59} – David Carlisle Sep 24 '20 at 18:53
  • I like using the fonttable package for such things, for example tex.stackexchange.com/questions/486288/… – Steven B. Segletes Sep 24 '20 at 22:31
  • In the linked question, you could look at the file "mathabx.dcl" to be found in your TexLive distribution (in general in a hidden folder), and here it is: "\DeclareMathSymbol{\subset} {3}{matha}{"80}" – Watson Feb 2 at 20:13
1

You can, in order of decreasing convenience:

  • Use unicode-math, where you can replace any math symbol with \setmathfont[range=\symbol]{...}. Many OpenType math fonts have variants in stylistic sets.
  • Check the package documentation for a font table.
  • Check whether it uses a standard LaTeX encoding. If it does, it probably has files with names likeoms*.fd and omx*.fd.
  • Search the .sty file for the symbol and copy-paste the commands needed to define it. Usually this is \DeclareSymbolFont, and sometimes \SetSymbolFont for bold, followed by \DeclareMathSymbol.
  • Make font tables for all the package’s symbol fonts and look for the symbol in there.

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

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