LaTeX bugs database
This is a search tool for the LaTeX bugs database.This search tool allows you to search the LaTeX3 project team's database of all bug reports for LaTeX. If you discover what you believe to be a bug with LaTeX, you can search this database to find out if it has already been reported.
Note that you can only search for bugs which were reported after December 1994, when we made the database public.
PR number: latex/4399
Synopsis: LGR changes font size, impacting preamble macros which rely on testing \f@size (for example)
Confidential: no
State: closed
Arrival date: Sun Sep 28 20:41:01 +0200 2014
Originator (email address hidden)
Sun, 28 Sep 2014 20:40:29 +0200
Description of bug:
Unlike other font encodings, loading the LGR encoding (e.g. \usepackage[LGR,T1]{fontenc}) resets the default font size to 10pt, and the fallback font to {cmr}{m}{n}{10}. This impacts any preamble macros which test the default font (e.g. using \f@size) unless they activate the document default first. Joseph Wright identified this issue in lgrenc.def which includes \DeclareErrorFont{LGR}{cmr}{m}{n}{10}. Other font encoding definitions do not do this. Details and workarounds at http://tex.stackexchange.com/q/203493/. Note that the use of etoolbox in the attached file is just to demonstrate the issue by printing out the font size at the end of the preamble. The bug does not depend on this package.
Sample file which indicates the problem:
========================================
% !TEX TS-program = pdflatex
% !TEX encoding = UTF-8 Unicode
% arara: pdflatex: { synctex: true }
\documentclass[12pt]{article}
\usepackage{etoolbox}
\usepackage[LGR,T1]{fontenc}
\makeatletter
\AtEndPreamble{%
\PackageWarning{mine}{font size is \f@size}
}
\makeatother
\begin{document}
some text
\end{document}
The log file from running LaTeX on the sample:
==============================================
This is pdfTeX, Version 3.14159265-2.6-1.40.15 (TeX Live 2014) (preloaded format=pdflatex 2014.9.15) 28 SEP 2014 19:37
entering extended mode
restricted \write18 enabled.
%&-line parsing enabled.
**prawf3.tex
(./prawf3.tex
LaTeX2e <2014/05/01>
Babel <3.9k> and hyphenation patterns for 79 languages loaded.
(/usr/local/texlive/2014/texmf-dist/tex/latex/base/article.cls
Document Class: article 2007/10/19 v1.4h Standard LaTeX document class
(/usr/local/texlive/2014/texmf-dist/tex/latex/base/size12.clo
File: size12.clo 2007/10/19 v1.4h Standard LaTeX file (size option)
)
\c@part=\count79
\c@section=\count80
\c@subsection=\count81
\c@subsubsection=\count82
\c@paragraph=\count83
\c@subparagraph=\count84
\c@figure=\count85
\c@table=\count86
\abovecaptionskip=\skip41
\belowcaptionskip=\skip42
\bibindent=\dimen102
)
(/usr/local/texlive/2014/texmf-dist/tex/latex/etoolbox/etoolbox.sty
Package: etoolbox 2011/01/03 v2.1 e-TeX tools for LaTeX
(/usr/local/texlive/2014/texmf-dist/tex/latex/etex-pkg/etex.sty
Package: etex 1998/03/26 v2.0 eTeX basic definition package (PEB)
\et@xins=\count87
)
\etb@tempcnta=\count88
)
(/usr/local/texlive/2014/texmf-dist/tex/latex/base/fontenc.sty
Package: fontenc 2005/09/27 v1.99g Standard LaTeX package
(/usr/local/texlive/2014/texmf-dist/tex/latex/greek-fontenc/lgrenc.def
File: lgrenc.def 2013/12/02 v0.11.2 LGR Greek font encoding definitions
(/usr/local/texlive/2014/texmf-dist/tex/latex/greek-fontenc/greek-fontenc.def
File: greek-fontenc.def 2013/11/28 v0.11 Common Greek font encoding definitions
)) (/usr/local/texlive/2014/texmf-dist/tex/latex/base/t1enc.def
File: t1enc.def 2005/09/27 v1.99g Standard LaTeX file
LaTeX Font Info: Redeclaring font encoding T1 on input line 43.
))
Package mine Warning: font size is 10 on input line 13.
(./prawf3.aux)
\openout1 = `prawf3.aux'.
LaTeX Font Info: Checking defaults for OML/cmm/m/it on input line 13.
LaTeX Font Info: ... okay on input line 13.
LaTeX Font Info: Checking defaults for T1/cmr/m/n on input line 13.
LaTeX Font Info: ... okay on input line 13.
LaTeX Font Info: Checking defaults for OT1/cmr/m/n on input line 13.
LaTeX Font Info: ... okay on input line 13.
LaTeX Font Info: Checking defaults for OMS/cmsy/m/n on input line 13.
LaTeX Font Info: ... okay on input line 13.
LaTeX Font Info: Checking defaults for OMX/cmex/m/n on input line 13.
LaTeX Font Info: ... okay on input line 13.
LaTeX Font Info: Checking defaults for U/cmr/m/n on input line 13.
LaTeX Font Info: ... okay on input line 13.
LaTeX Font Info: Checking defaults for LGR/cmr/m/n on input line 13.
LaTeX Font Info: Try loading font information for LGR+cmr on input line 13.
(/usr/local/texlive/2014/texmf-dist/tex/latex/cbfonts-fd/lgrcmr.fd
File: lgrcmr.fd 2013/09/01 v1.0 Greek European Computer Regular
)
LaTeX Font Info: ... okay on input line 13.
[1
{/usr/local/texlive/2014/texmf-var/fonts/map/pdftex/updmap/pdftex.map}] (./praw
f3.aux) )
Here is how much of TeX's memory you used:
1469 strings out of 493108
21907 string characters out of 6134853
62786 words of memory out of 5000000
4991 multiletter control sequences out of 15000+600000
5465 words of font info for 17 fonts, out of 8000000 for 9000
1141 hyphenation exceptions out of 8191
23i,4n,20p,799b,113s stack positions out of 5000i,500n,10000p,200000b,80000s
{/usr/local/texlive/2014/texmf-dist/fonts/enc/dvips/cm-super/cm-super-
t1.enc}</usr/local/texlive/2014/texmf-dist/fonts/type1/public/cm-super/sfrm1200
.pfb>
Output written on prawf3.pdf (1 page, 11338 bytes).
PDF statistics:
13 PDF objects out of 1000 (max. 8388607)
8 compressed objects within 1 object stream
0 named destinations out of 1000 (max. 500000)
1 words of extra memory for PDF output out of 10000 (max. 10000000)
>Fix:
Unknown
Address information Copyright 1994 — 2016 the LaTeX3 project and Alan Jeffrey.