[OS X TeX] Re: encoding and special characters in TexShop and BibDesk

Peter Dyballa Peter_Dyballa at Web.DE
Mon Sep 25 05:46:53 EDT 2006

Am 25.09.2006 um 07:45 schrieb Gordon Sick:

>> 	\usepackage{cmap}
>> helps to make the PDF output with accented characters searchable in
>> PDF viewers by mapping the well-known characters to the TeX  
>> constructs.
> I tried this and it doesn't make my Latex compilation choke. But,  
> I'm not sure if it is working because the documentation speaks of  
> teh font encodings T1, T2A, T2B, T2C and T5, while I think I'm  
> using LY1 for my Lucida. It then tells me to create a file  
> LY1.cmap, assuming that LY1 is my encoding. But, I don't know what  
> to put in that file.

That's almost simple: it's the encoding vector of LY1, written in  
Unicode. The file t1.cmap starts to encode T1 at line #34. The first  
column is the position in the vector, the second column is its  
mapping character in Unicode. U+201A (0D, line #47) is ``‚´´,  SINGLE  
LOW-9 QUOTATION MARK. T1 positions 1B-1F are something special: the  
ff, fi, fl, ffi, and ffl ligatures. They are not bound to a  
particular position in Unicode, so Vladimir Volovich expands them to  
the characters they are composed of: ff at 1B becomes f+f, i.e. U 
+0066 + U+0066, etc. Similarly for SS at DF.

Gaps in this encoding are filled by lines #22-31, which describe  
consecutive ranges of characters and their consecutive mappings:

	0E … OF are ‹ ›,         U+2039 U+203A (\guilsinglleft,  
	10 … 12 are “ ” „,       U+201C U+201D U+201E (\textquotedblleft,  
\textquotedblright, \quotedblbase)
	15 … 16 are – —,         U+2013 U+2014 (\textendash, \textemdash)
	21 … 26 are ! " # $ % &, U+0021 … U+0026
	28 … 5F are ( … _,       U+0028 … U+005F
	61 … 7E are a … ~,       U+0061 … U+007E
	C0 … D6 are À … Ö,       U+00C0 … U+00D6
	D8 … DE are Ø … Þ,       U+00D8 … U+00DE
	E0 … F6 are à … ö,       U+00E0 … U+00F6
	F8 … FE are ø … þ,       U+00F8 … U+00FE

One mapping is missing: 20 -> U+2423 (\textvisiblespace -> OPEN BOX)!

>> You probably know of
>> 	\usepackage{textcomp}
>> to use accented characters from the same font the other text is set
>> with?
> I gather this package is already in Latex2e. Once again, the  
> documentation refers to fints like Times and Baskerville. Do you  
> know if it works with the Y&Y Lucida fonts, or do I have to do more  
> work?

Yes, it is. And could be it fails: the textcomp package uses 8c or  
TS1 encoded virtual fonts to access the characters. Y&Y chose for  
their LY1 font encoding to be without virtual fonts. Make some  
minimal test with some accented characters, ø, æ, œ ... and see what  
comes out!

BTW: \usepackage[Latin1]{fontenc} won't work. First, Latin1, i.e.  
with a capital letter is not correct (lower case is right), second,  
only the text can be ISO 8859-1 (ISO Latin-1) or ISO 8859-15 (ISO  
Latin-9). The fonts are OT1 (not recommended, 7 bit only) or T1 or  
OT2, LY1, IL2, OML, OMS, ... encoded.



To be is to do.
                        -- I. Kant
To do is to be.
                        -- A. Sartre
                        -- F. Flintstone

------------------------- Info --------------------------
Mac-TeX Website: http://www.esm.psu.edu/mac-tex/
          & FAQ: http://latex.yauh.de/faq/
TeX FAQ: http://www.tex.ac.uk/faq
List Archive: http://tug.org/pipermail/macostex-archives/

More information about the MacOSX-TeX mailing list