5

The input

\documentclass{standalone}
\usepackage{type1cm}
\usepackage{amssymb}
\begin{document}
\noindent
Good: \(\Join \mathsf{\Join}\). 
Bad: \small\(\Join \mathsf{\Join}\)
\end{document}

produces

compilation with pdflatex

As you see, the symbol ⋈ in small sans maths is everything else than ideal. Of course, the above is simply an MWE, and in reality there are tons of other packages and requirements which make you use type1cm and amssymb (and not something else instead). Is it possible to repair the above issue already on the level of type1cm and/or amssymb?

2
  • 1
    type1cm is an obsolete package and should not be used in newer documents.
    – egreg
    Aug 9, 2018 at 19:53
  • Also note that \bowtie is defined in the LaTeX kernel itself, and \Join in latexsym.
    – Davislor
    Sep 7, 2018 at 6:04

2 Answers 2

4

The package type1cm is obsolete and only exists for back compatibility with older documents.

There is no need to use it with LaTeX distributions later than 2003 or so.

\documentclass{article}
\usepackage{amssymb}

\begin{document}

Normal: \(\Join\)

Small: {\small\(\Join\)}

\end{document}

This document uses Type1 fonts automatically. The output of pdffonts is

name                                 type              emb sub uni prob object ID
------------------------------------ ----------------- --- --- --- ---- ---------
QKGSKC+CMR10                         Type 1            yes yes no   X        4  0
OUKJHV+MSBM10                        Type 1            yes yes no   X        5  0

enter image description here

You can easily get a working definition for \Join that is unaffected by wrong font choices, anyhow.

\documentclass{article}
\usepackage{amssymb}

\makeatletter
\def\Join{\mathrel{\mathpalette\fix@Join\relax}}
\def\fix@Join#1#2{%
  \ooalign{%
    $\m@th#1\mathchar "056F$\cr
    $\m@th#1\mathchar "056E$\cr
  }%
}
\makeatother


\begin{document}

Normal: \(\Join_{\Join}\)

Small: {\small\(\Join_{\Join}\)}

Footnotesize: {\footnotesize\(\Join_{\Join}\)}

\end{document}

enter image description here

5
  • @user49915 You can use it, but it's not generally needed.
    – egreg
    Aug 9, 2018 at 20:35
  • I think this is misleading, the type1cm package never changed the format of the fonts embedded, that's up to the map configuration, it just removes the magstep size restrictions to allow cm to be used at any size, as is more natural if you have scalable versions of the fonts. As such it's more or less the same as the later fix-cm Sep 6, 2018 at 22:26
  • @DavidCarlisle I disagree: the type1cm also adjusts msam font definitions, which it shouldn't do.
    – egreg
    Sep 7, 2018 at 8:37
  • @egreg but you show the pdf using a type 1 font and mention 2003 but type1cm has never affected the font format used in the final pdf, so that is not relevant at all. It adjusts the ms[ab]m definitions for the same reason it adjusts the cm ones, the default fd files just load them at magstep sizes but Y&Y (who asked for the package) were distributing scalable versions of the fonts and wanted latex to be able to use them at all sizes. Sep 7, 2018 at 8:42
  • @DavidCarlisle No, sorry: the package chooses wrong sizes, and it is the cause for the wrong output. Fixing the definition of \Join is a different question.
    – egreg
    Sep 7, 2018 at 8:48
1

type1cm package doesn't make the embedded fonts be in Type 1 format, it just allows the cm fonts to be scaled to arbitrary sizes (like the later fix-cm package).

The problem here is that \Join in amsfonts is a very fragile definition that only works in one font: it is defined by setting ⋊ and ⋉ with a negative kern of -13.8mu between them. That -13.8 magic number isn't so magic if the font is not msbm10 (and with type1cm it ends up being msbm7 at 9pt) rather than redefine it completely you could adjust the -13.8 value when you change font size: -15 seems to work better for \small, but note this is only if you load type1cm, if you don't load it or load a different font package some other value would be needed, or better would be to use a font that has the character as a font glyph not requiring over-printing.

enter image description here

\documentclass{article}
\usepackage{type1cm}
\usepackage{amssymb}
\begin{document}


Good: \(\Join \mathsf{\Join}\)

$\mathchar "056F \qquad \mathchar "056E$

Bad: \small\(\Join \mathsf{\Join}\)

$\mathchar "056F \qquad \mathchar "056E$

\makeatletter
\xdef\Join{\mathrel{\mathchar"0\hexnumber@\symAMSb 6F\mkern-15mu%
  \mathchar"0\hexnumber@\symAMSb 6E}}



Better: \small\(\Join \mathsf{\Join}\)

$\mathchar "056F \qquad \mathchar "056E$

\end{document}

You must log in to answer this question.