[latexrefman] it switches from one encoding to another with the @code{\selectfont} or @code{\fontencoding} command

Vincent Belaïche vincent.belaiche at gmail.com
Mon Sep 6 11:41:55 CEST 2021

Dear Karl,
I did some experiment (attached). If you pass options to fontenc in
the order OT1, T1, the two last rows will output <|> instead of ¡—¿.
This shows that without \selectfont the encoding is not activated.

Le dim. 5 sept. 2021 à 00:16, Karl Berry <karl at freefriends.org> a écrit :
>     My understanding is the \fontencoding does no immediate switching as
>     such,
> Yes it does. Maybe not at the user level, I'm not sure what the
> visible result is, but in the code the switch is made in \fontencoding.
>     it just sets the encoding to which the next \selectfont will
>     switch. So ``or'' should be replaced by ``and''.
> No it shouldn't.
> When I look at the actual definition of \fontencoding (in ltfssbas.dtx),
> the "text-setting" commands from \DeclareFontEncoding are executed:
> \DeclareRobustCommand\fontencoding[1]{%
> ..
>   \csname T@\f at encoding\endcsname
> ..
> }
> The \csname T@\f at encoding\endcsname cs is where the "text-setting"
> commands were saved.
> At a glance, I do not see them being executed as being part of
> \selectfont.
> So I suggest doing some experiments to find out the actual facts.
> Failing that, I suggest leaving it alone. -k
-------------- next part --------------
A non-text attachment was scrubbed...
Name: toto.tar.xz
Type: application/x-xz
Size: 184 bytes
Desc: not available
URL: <https://tug.org/pipermail/latexrefman/attachments/20210906/93bf144c/attachment.xz>

More information about the latexrefman mailing list.