# [pdftex] pdfbookmark problems with auto-greek or iso-8859-7

Jörg Ebeling joerg.ebeling at shbe.net
Mon Jun 30 18:45:10 CEST 2008

Hi Werner,

Werner LEMBERG schrieb:
>>> I've attached the UTF8.tex sample file from the CJK package.
>>>
>> Lot thanks for the ideas and the sample.
>> I played a little bit with it but I've some problems.
>>
>> 1.) I couldn't get the \pdfbookmarks working with it. Should
>>     \pdfbookmarks with mixed characters work also with CJK?
>>
>
>
Yeees ?! Ufff...

>> 2.) I got errors with:
>>       \DeclareFontFamily{T1}{song}{}
>>       \DeclareFontShape{T1}{song}{m}{n}{<-> cyberb00}{}
>>       \renewcommand\rmdefault{song}
>>     and disabled them for testing. Is this the reason why I only get
>>     "the bad" Type3 fonts in the output?
>>
>
> Well, you have to tell pdftex that cyberbit.ttf is a TrueType font.
> For license reasons, TeXLive doesn't come with that font, and your
> setup probably uses ttf2pk instead.  The CJK package (and pdftex)
> contains documentation which describes how to register TrueType fonts
> for pdftex.
>
Okay. Seems that I tested somewhat to hasty.

Even if I already started to implement an language script into my LaTeX
export, it would be too fantastic if your CJK Package would work for my
requirements.

So I tested again... and hurray !!!

In my first tries the \pdfbookmark has worked only before a \begin{CJK}
environment but not within or after.
Using the "CJKbookmarks" option for hyperref:

\usepackage[CJKbookmarks]{hyperref}

In Google I found an article about the CJK option "encapsulated" with
which it's working now .... Yipiii !

Hope I don't get the "save size" problem as indicated in your
documentation (the final PDF will have about 300 pages and 250MB in size).

Is this the right way to handle the bookmarks ?

BTW: The ttf font problem has been a easy writing/naming mistake of one
of my tfm files and is solved too !
But, even if the quality of the Truetype fonts is much better than the
Type3 ones, I'm in doubt if the Printing Office will demand type1
embedded ones.

I already took a more detailed look to the docs this time, but seems
that I'm not familiar enough with the TeX internals... too much words I
didn't understand :-/

Is it possible to embed type1 fonts instead of the truetypes ones ?

I also need to convert another one from one of the "Corporate Identity"
list. Can I do the same conversion with on of them (if they contain the
glyphs) as I made with the Cyberbit font ?

Lot lot thanks till now !
The current way with your CJK package is much better than the ugly
language switching with one of the other packages.
I immediately start to implement this new way as well as test the last
issues with texindy indexing and some other document specific issues.

In pleasant anticipation

Jörg

BTW: Here's my current test document

% This is the file UTF8.tex of the CJK package
%   for testing UTF 8 encoding.
%
% written by Werner Lemberg <wl at gnu.org>
%
% Version 4.8.0 (22-May-2008)

\documentclass[pdftex]{book}
\usepackage[encapsulated]{CJK}
\usepackage[unicode=true,pdftex]{hyperref}
\usepackage{ucs}
\usepackage[utf8x]{inputenc}
\usepackage[T1]{fontenc}

% we want the Unicode font for normal text also
\DeclareFontFamily{T1}{cyberbit}{}
\DeclareFontShape{T1}{cyberbit}{m}{n}{<-> cyberbit00}{}
\renewcommand\rmdefault{cyberbit}

\begin{document}

\pdfbookmark[1]{Λαμπτήρες Αλογόνων Test abc}{BM_4555}

\begin{CJK}{UTF8}{cyberbit}

Στιβαρής κατασκευής,χαμηλής πίεσης λαμπτήρας με UV Block (IEC~357)

% This one don't work here. Right ?
% \pdfbookmark[1]{Test 2 Λαμπτήρες Αλογόνων}{BM_4555}

Hello World!

Καλημέρα κόσμε

\end{CJK}

\pdfbookmark[2]{Λαμπτήρες 12V Αλογόνων}{BM_4556}

\end{document}

--
------------------------------------------------------------------------

Soft- & Hardware Beratung Ebeling
Jörg Ebeling
Weserstieg 6

_*21079 Hamburg*_

*Germany*

eMail: joerg.ebeling at shbe.net
Tel.:   +49 - 40 - 646 008 0