From owner-freebsd-doc@FreeBSD.ORG Wed Jun 18 12:26:45 2008 Return-Path: Delivered-To: freebsd-doc@FreeBSD.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:4f8:fff6::34]) by hub.freebsd.org (Postfix) with ESMTP id CF5D61065673 for ; Wed, 18 Jun 2008 12:26:45 +0000 (UTC) (envelope-from keramida@FreeBSD.org) Received: from igloo.linux.gr (igloo.linux.gr [62.1.205.36]) by mx1.freebsd.org (Postfix) with ESMTP id 42D518FC24 for ; Wed, 18 Jun 2008 12:26:45 +0000 (UTC) (envelope-from keramida@FreeBSD.org) Received: from kobe.laptop (adsl156-194.kln.forthnet.gr [62.1.247.194]) (authenticated bits=128) by igloo.linux.gr (8.14.3/8.14.3/Debian-4) with ESMTP id m5ICF4I8011957 (version=TLSv1/SSLv3 cipher=DHE-RSA-AES256-SHA bits=256 verify=NOT); Wed, 18 Jun 2008 15:15:11 +0300 Received: from kobe.laptop (kobe.laptop [127.0.0.1]) by kobe.laptop (8.14.2/8.14.2) with ESMTP id m5ICF0fb003740; Wed, 18 Jun 2008 15:15:00 +0300 (EEST) (envelope-from keramida@freebsd.org) Received: (from keramida@localhost) by kobe.laptop (8.14.2/8.14.2/Submit) id m5ICExam003739; Wed, 18 Jun 2008 15:14:59 +0300 (EEST) (envelope-from keramida@freebsd.org) From: Giorgos Keramidas To: Hiroki Sato References: <87wskptbb2.fsf@kobe.laptop> <20080618.144751.42861091.hrs@allbsd.org> Date: Wed, 18 Jun 2008 15:14:58 +0300 In-Reply-To: <20080618.144751.42861091.hrs@allbsd.org> (Hiroki Sato's message of "Wed, 18 Jun 2008 14:47:51 +0900 (JST)") Message-ID: <873anb0wjh.fsf@kobe.laptop> User-Agent: Gnus/5.13 (Gnus v5.13) Emacs/23.0.60 (berkeley-unix) MIME-Version: 1.0 Content-Type: text/plain; charset=iso-8859-7 Content-Transfer-Encoding: quoted-printable X-MailScanner-ID: m5ICF4I8011957 X-Hellug-MailScanner: Found to be clean X-Hellug-MailScanner-SpamCheck: not spam, SpamAssassin (not cached, score=-4.96, required 5, autolearn=not spam, ALL_TRUSTED -1.80, AWL -0.56, BAYES_00 -2.60) X-Hellug-MailScanner-From: keramida@freebsd.org X-Spam-Status: No Cc: freebsd-doc@FreeBSD.org Subject: Re: Language support in jadetex? X-BeenThere: freebsd-doc@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: Documentation project List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Wed, 18 Jun 2008 12:26:45 -0000 On Wed, 18 Jun 2008 14:47:51 +0900 (JST), Hiroki Sato wro= te: > Giorgos Keramidas wrote > in <87wskptbb2.fsf@kobe.laptop>: > > ke> I don't know if this is a FAQ, but I've been trying to find a way to > ke> create readable Greek PDF output with jadetex, and I'm kind of stuck > ke> there. > ke> > ke> The PDF file *is* created, but the Greek text is typeset with fonts t= hat > ke> look likeISO 8859-1, so the text is unreadable. > ke> > ke> Does anyone know how I can tweak jadetex to use a different charset? > ke> > ke> A pointer to jadetex docs would be sufficient, but a quick search at > ke> Google didn't produce something that looks useful :-/ > > Could you tell me what is needed for TeX to process Greek? I am not > familiar with Greek but I think it is possible to adjust JadeTeX to > Greek if TeX is working with Greek text. A sample .tex file in Greek > and the typeset PDF would help. XeLaTeX supports UTF-8 input of Greek text. With a proper fontset, that includes Greek characters, one can type directly into a XeLaTeX document text in Greek. Unfortunately, we don't have TeXlive in the ports, so that can't be used in the doc/ tree. Out other option is the {babel} package, but there's a catch there too. With the current teTeX ports, one can use the {babel} package like this: \documentclass[12pt]{article} \usepackage[english,greek]{babel} % Pull in both English and % Greek language support. \usepackage[iso-8859-7]{inputenc} % Allow ISO 8859-7 input of % Greek text. \begin{document} \section{=C5=E9=F3=E1=E3=F9=E3=DE} =D3=DE=EC=E5=F1=E1 =E5=DF=E4=E1 =E3=E9=E1 =F0=F1=FE=F4=E7 =F6=EF=F1=DC = =C5=EB=EB=E7=ED=E9=EA=FC =EA=E5=DF=EC=E5=ED=EF =E4=DF=F0=EB=E1 =E1=F0=FC \selectlanguage{english} English text \selectlanguage{greek} =F3=F4=EF \LaTeX{}. \end{document} Roughly translated to English, the text above would read: \section{Introduction} Today I saw, for the first time, Greek text side by side with \selectlanguage{english} English text \selectlanguage{greek} in \LaTeX{}. The tricky part is that switching between languages for every English term has to be done with a filter. Otherwise, we will end up with the odd result of typesetting English text with Greek fonts. A good way to start making changes to support Greek would be to: * Make sure that jadetex adds the two preamble commands shown above: \usepackage[english,greek]{babel} \usepackage[iso-8859-7]{inputenc} * Find a way to 'filter' the text and replace non-command sequences of English text with `\selectlanguage{english} ... \selectlanguage{greek}'. We can probably keep the bloat to a semi-reasonable size by also making jadetex define short-hand aliases in the document preamble, like: \newcommand{GR}{\selectlanguage{greek}} \newcommand{EN}{\selectlanguage{english}}