# Matching the font size in standalone with IEEEtran

I have a tex file in IEEEtran with its default font size, which is 8pt. I want to include an image PDF, generated by standalone with font size 12pt. I set the scaling to be scale=0.666667, which is 2/3, to change the font size of the image to match with the main text. However, what I see at the end is that the text in the image is much smaller than 8pt. Why? For example, the image is generated by

\documentclass[12pt]{standalone}
\usepackage{tikz}
\begin{document}
\begin{tikzpicture}
\node [draw, align=center] {This is\\12 pt\\before scaling};
\end{tikzpicture}
\end{document}


and the main file is

\documentclass{IEEEtran}
\usepackage{tikz}
\begin{document}
This is a sample text to show the default font size
in IEEEtran document class, which is 8pt.

\includegraphics[scale=0.666667]{image.pdf}
\end{document}

• Default fotn size of IEEEtran is 10pt. In standalone you define 12pt. Also you scale image ... on such a way is very difficult to obtain the same size of fonts. – Zarko May 12 '20 at 15:41

Note that scaling text is bad, as different font sizes might have different drawings and then do not look identical if scaled down.

Not sure if this is an option, but you can make standalone to use IEEEtran class internally which then uses the font defined there.

\documentclass[class={IEEEtran}]{standalone}
\usepackage{tikz}
\begin{document}
\begin{tikzpicture}
\node [draw, align=center] {This is\\the same pt\\before scaling};
\end{tikzpicture}
\end{document}


Thanks to @Zarko , the default size of IEEEtran is 10pt. Thus, by setting the sacling to scale=0.83333 it matches perfectly.

• why not use the default font size of standalone which is the same as your main class, at 10pt, why use 12pt and scale (which produces different fonts) – David Carlisle May 12 '20 at 16:05