Google Groups no longer supports new Usenet posts or subscriptions. Historical content remains viewable.
Dismiss

Missing the long 's'

106 views
Skip to first unread message

Peter Flynn

unread,
Oct 6, 2011, 4:35:31 PM10/6/11
to
There has been a discussion over on the Google 'latexusersgroup' list
about getting the long 'ſ' to work. Users have been directed to the
kpfonts package, but I believe it should be possible without this (but
then I have believed lots of things which turned out not to be true :-)

There is a definition for the long s in uni-1.def:

\uc@dclc{383}{autogenerated}{\unichar{115}}%

but it wasn't immediately clear to me where the autogenerated option was
supposed to go, so I tried this MN-WE:

\documentclass{article}
\usepackage[utf8x]{inputenc}
\usepackage[T1]{fontenc}
\usepackage{lmodern}
\begin{document}
This is a long `ſ'
\end{document}

That gives me the error below, and typing 'h' does indeed tell me that
it needs the autogenerated option:

> ! Package ucs Error: Unknown Unicode character 383 = U+017F,
> (ucs) possibly declared in uni-1.def.
> (ucs) Type H to see if it is available with options.
>
> See the ucs package documentation for explanation.
> Type H <return> for immediate help.
> ...
>
> l.6 This is a long `ſ
> '
> ? h
> Unicode character 383 = U+017F:
> LATIN SMALL LETTER LONG S
> Character available with following options:
> autogenerated.
> Enter I!<RET> to define the glyph.
> ?

So I added (as a new line 2 in my file)

\usepackage[autogenerated]{ucs}

(because utf8x preloads ucs, so putting this before it should make it
preload with the autogenerated option). This now runs without error, but
creates a PDF with the normal lowercase curly 's' instead.

What am I doing wrong?

///Peter

Robin Fairbairns

unread,
Oct 6, 2011, 6:28:46 PM10/6/11
to
i've never spotted a long "s" in the latin modern fonts, and it's
certainly not encoded in the t1 encoding[*], which is the encoding
you're using in the example above.

i don't doubt that you've had long s using some other font package than
kpfonts, but off-hand i don't know what fonts _do_ have a long s. (cmoe
is for "old english" in the linguistic rather than the "common" sense;
tipa doesn't have that sort of thing; there are long s's in yannis h's
german fonts, but they're not much like english long s.)

[*] that's what we used to call the "cork encoding" ... how come you
don't know it? ;-)
--
Robin Fairbairns, Cambridge
my address is @cl.cam.ac.uk, regardless of the header. sorry about that.

j. 'mach' wust

unread,
Oct 7, 2011, 2:16:25 AM10/7/11
to
There certainly is a long s (ſ) character in Latin Modern. You can
access it through xelatex or lualatex:

\documentclass{article}
\usepackage{fontspec}
\usepackage{lmodern}
\begin{document}
This is a long `ſ'
\end{document}

See also p. 12 in:
http://ctan.org/tex-archive/fonts/lm/doc/fonts/lm/lm-info.pdf

The question is how to access that character in latex.

--
grüess
mach

Ulrike Fischer

unread,
Oct 7, 2011, 4:01:17 AM10/7/11
to
Well this example use the open type version of the fonts . pdflatex
uses the type1 version of the fonts. So the first question is if the
char is in this version of the fonts (it is). The second question if
it has been encoded somewhere. Looking at the char tables in
lm-info.pdf one can find it in the TS1-encoding. So you can get it
this way:

\documentclass{article}
\usepackage[TS1,T1]{fontenc}
\usepackage{lmodern}

\begin{document}
{\fontencoding{TS1}\selectfont \char115}
\end{document}



--
Ulrike Fischer

Robin Fairbairns

unread,
Oct 7, 2011, 5:35:05 AM10/7/11
to
"j. 'mach' wust" <j_mac...@shared-files.de> writes:

> There certainly is a long s (ſ) character in Latin Modern. You can
> access it through xelatex or lualatex:
>
> \documentclass{article}
> \usepackage{fontspec}
> \usepackage{lmodern}
> \begin{document}
> This is a long `ſ'
> \end{document}
>
> See also p. 12 in:
> http://ctan.org/tex-archive/fonts/lm/doc/fonts/lm/lm-info.pdf

quote that as

http://mirror.ctan.org/fonts/lm/doc/fonts/lm/lm-info.pdf

that way we spread our load over the ctan mirrors

> The question is how to access that character in latex.

easy thing to forget if you only use regular (pdf)tex: forget that lm
comes in opentype, now. (i ought to use luatex for the faq, but have
never got around to sorting out the immediate problems. the faq is the
*only* big tex doc that i regularly process ... most of my writing, day
to day, is email ... such is the life of a sysadmin ;-)

Dan Luecking

unread,
Oct 7, 2011, 11:28:42 AM10/7/11
to
On Fri, 7 Oct 2011 10:01:17 +0200, Ulrike Fischer <ne...@nililand.de>
wrote:

>Am Thu, 6 Oct 2011 23:16:25 -0700 (PDT) schrieb j. 'mach' wust:
>
>> There certainly is a long s (?) character in Latin Modern. You can
>> access it through xelatex or lualatex:
>>
>> \documentclass{article}
>> \usepackage{fontspec}
>> \usepackage{lmodern}
>> \begin{document}
>> This is a long `?'
>> \end{document}
>>
>> See also p. 12 in:
>> http://ctan.org/tex-archive/fonts/lm/doc/fonts/lm/lm-info.pdf
>>
>> The question is how to access that character in latex.
>
>Well this example use the open type version of the fonts . pdflatex
>uses the type1 version of the fonts. So the first question is if the
>char is in this version of the fonts (it is). The second question if
>it has been encoded somewhere. Looking at the char tables in
>lm-info.pdf one can find it in the TS1-encoding. So you can get it
>this way:
>
>\documentclass{article}
>\usepackage[TS1,T1]{fontenc}
>\usepackage{lmodern}
>
>\begin{document}
>{\fontencoding{TS1}\selectfont \char115}
>\end{document}

Or
\documentclass{article}
\usepackage[TS1,T1]{fontenc}
\usepackage{lmodern}
\DeclareTextSymbolDefault{\textlongs}{TS1}
\DeclareTextSymbol{\textlongs}{TS1}{115}

\begin{document}
When in the cour\textlongs e of human events\dots.

\itshape
When in the cour\textlongs e of human events\dots.

\end{document}


Dan
To reply by email, change LookInSig to luecking

Peter Flynn

unread,
Oct 7, 2011, 6:25:13 PM10/7/11
to
On 07/10/11 09:01, Ulrike Fischer wrote:
> Am Thu, 6 Oct 2011 23:16:25 -0700 (PDT) schrieb j. 'mach' wust:
>
>> There certainly is a long s (ſ) character in Latin Modern. You can
>> access it through xelatex or lualatex:
>>
>> \documentclass{article}
>> \usepackage{fontspec}
>> \usepackage{lmodern}
>> \begin{document}
>> This is a long `ſ'
>> \end{document}
>>
>> See also p. 12 in:
>> http://ctan.org/tex-archive/fonts/lm/doc/fonts/lm/lm-info.pdf
>>
>> The question is how to access that character in latex.
>
> Well this example use the open type version of the fonts . pdflatex
> uses the type1 version of the fonts. So the first question is if the
> char is in this version of the fonts (it is). The second question if
> it has been encoded somewhere. Looking at the char tables in
> lm-info.pdf one can find it in the TS1-encoding.

That's the piece of information I was missing, thank you.
I don't seem to have lm-info.pdf on my systems.

> So you can get it this way:
>
> \documentclass{article}
> \usepackage[TS1,T1]{fontenc}
> \usepackage{lmodern}
>
> \begin{document}
> {\fontencoding{TS1}\selectfont \char115}
> \end{document}

What is the effect of the [autogenerated] parameter in uni-1.def for
this character? In other words, *what* process is supposed to
auto-generate it?

Is it possible to re-work the definition

\uc@dclc{383}{autogenerated}{\unichar{115}}%

so that the character itself (ſ) would invoke TS1 on itself?

///Peter

Robin Fairbairns

unread,
Oct 8, 2011, 8:00:52 AM10/8/11
to
Peter Flynn <pe...@silmaril.ie> writes:

> On 07/10/11 09:01, Ulrike Fischer wrote:
>> Am Thu, 6 Oct 2011 23:16:25 -0700 (PDT) schrieb j. 'mach' wust:
>>
>>> There certainly is a long s (ſ) character in Latin Modern. You can
>>> access it through xelatex or lualatex:
>>>
>>> \documentclass{article}
>>> \usepackage{fontspec}
>>> \usepackage{lmodern}
>>> \begin{document}
>>> This is a long `ſ'
>>> \end{document}
>>>
>>> See also p. 12 in:
>>> http://ctan.org/tex-archive/fonts/lm/doc/fonts/lm/lm-info.pdf
>>>
>>> The question is how to access that character in latex.
>>
>> Well this example use the open type version of the fonts . pdflatex
>> uses the type1 version of the fonts. So the first question is if the
>> char is in this version of the fonts (it is). The second question if
>> it has been encoded somewhere. Looking at the char tables in
>> lm-info.pdf one can find it in the TS1-encoding.
>
> That's the piece of information I was missing, thank you.
> I don't seem to have lm-info.pdf on my systems.

it's in tex live and miktex.

>> So you can get it this way:
>>
>> \documentclass{article}
>> \usepackage[TS1,T1]{fontenc}
>> \usepackage{lmodern}
>>
>> \begin{document}
>> {\fontencoding{TS1}\selectfont \char115}
>> \end{document}
>
> What is the effect of the [autogenerated] parameter in uni-1.def for
> this character? In other words, *what* process is supposed to
> auto-generate it?
>
> Is it possible to re-work the definition
>
> \uc@dclc{383}{autogenerated}{\unichar{115}}%
>
> so that the character itself (ſ) would invoke TS1 on itself?

no doubt. however, since you're using unicode to start with, you would
be far better off switching to xelatex. that way you get the letter
without hassle, and it's treated as a letter (so words containing it can
participate in hyphenation).

the alternative arrangements all treat the character as a symbol, as is
so often the case when you push the envelope with (la)tex.

Peter Flynn

unread,
Oct 8, 2011, 5:52:10 PM10/8/11
to
On 08/10/11 13:00, Robin Fairbairns wrote:
> Peter Flynn<pe...@silmaril.ie> writes:
[...]

>> I don't seem to have lm-info.pdf on my systems.
>
> it's in tex live and miktex.

I'm still using the TL2009 that Ubuntu supplies with 11.04.

[...]


> no doubt. however, since you're using unicode to start with, you would
> be far better off switching to xelatex.

I certainly would, and I plan to as soon as my current work dependencies
allow. Right now, I have too many multiple simultaneous ongoing projects
depending on the current installation to start breaking them by making
that switch. And XeLaTeX doesn't appear to have had quite all the bugs
knocked out of it yet, to judge by the posts here and elsewhere.

///Peter

Ulrike Fischer

unread,
Oct 9, 2011, 5:40:44 AM10/9/11
to
Am Fri, 07 Oct 2011 23:25:13 +0100 schrieb Peter Flynn:

> What is the effect of the [autogenerated] parameter in uni-1.def for
> this character? In other words, *what* process is supposed to
> auto-generate it?

I'm not using ucs.sty. It is unmaintained and imho it can lead to
problems with biblatex/csquotes. See e.g. here

http://groups.google.com/group/comp.text.tex/browse_thread/thread/e0b0bec4e0dbf8b5/5487c7b0a170b95f?q=utf8x+group%3acomp.text.tex#5487c7b0a170b95f


> Is it possible to re-work the definition
>
> \uc@dclc{383}{autogenerated}{\unichar{115}}%
>
> so that the character itself (ſ) would invoke TS1 on itself?

It is easy to add/change definitions with inputenc/utf8:

\documentclass[]{article}
\usepackage[utf8]{inputenc}
\DeclareUnicodeCharacter{20AC}{Euro-Sign}
\DeclareUnicodeCharacter{00C4}{Large A with Umlaut}
\begin{document}
€ Ä
\end{document}

Btw: You should be aware that switching the font encoding to TS1
means that you are using another font for this char and this will
destroy kernings.

--
Ulrike Fischer
0 new messages