Re: [XeTeX] fonts and diacritics

2015-08-09 Thread François Patte
-BEGIN PGP SIGNED MESSAGE-
Hash: SHA1

Le 29/06/2015 20:01, FC a écrit :
> Long time ago I wrote a small package that was not worth uploading
> to CTAN but did the job for me when I had to use Garamond and still
> be able to transliterate Arabic from an input document that was
> already encoded in UTF-8 (my editor has custom key mappings for
> that). With that package, characters such as ? (U+1E6D), when not
> present in a font, would be automatically composed by XeTeX in the
> traditional way. I attach it here, in case it might be useful to
> others.
> 
> In general I try to avoid using such tricks, but as I said,
> sometimes you just have no choice.

Bonjour,

I tried to use your xdiacomp package with garamond but failed to get
the missing characters (?, ?, etc.)

What did I miss?

Thank you.

- -- 
François Patte
UFR de mathématiques et informatique
Laboratoire CNRS MAP5, UMR 8145
Université Paris Descartes
45, rue des Saints Pères
F-75270 Paris Cedex 06
Tél. +33 (0)1 8394 5849
http://www.math-info.univ-paris5.fr/~patte
-BEGIN PGP SIGNATURE-
Version: GnuPG v2

iEYEARECAAYFAlXHX/0ACgkQdE6C2dhV2JVVZgCfUROtV3uIahTTPflBfMly86LH
oIwAn0ABymN3W23/EC5Kj0jevmtVN7Ss
=Pegp
-END PGP SIGNATURE-


--
Subscriptions, Archive, and List information, etc.:
  http://tug.org/mailman/listinfo/xetex


Re: [XeTeX] fonts and diacritics

2015-07-01 Thread FC
I absolutely agree! I have also written such a script (and library) some
years ago in Perl. After adopting XeTeX I also wanted my input files to be
more readable. It is available here:
https://metacpan.org/release/LaTeX-Decode
It supports the convertion of pretty much all accents, macros, diacritics
and symbols you can imagine.

Regards,
François Charette

2015-07-01 15:50 GMT+02:00 Robert Zydenbos :

> Please do not use the traditional TeX codes for the Indic diacritics
> (things like \={a} etc.)! One of the big advantages of XeTeX is precisely
> that it uses Unicode. This means that your input file can be typed using
> any Unicode-supporting text editor (I use TeXShop on a Mac, TeXworks on
> Linux). It is obviously much more efficient to write and read
> "prajñāvādāṃśca bhāṣase" than "praj\~{n}\={a}v\={a}d\={a}\d{m}\'{s}ca
> bh\={a}\d{s}ase". There are numerous good Unicode fonts, also such that are
> freely available, that produce fine results, both onscreen and on paper.
>
> Because I had a number of files containing all those TeX codes and wanted
> to switch to XeTeX, I wrote a simple program (or 'script', as some people
> say) in Python (the older version 2.7, which is still the standard version
> on many machines; but it can be rather quickly adapted for version 3, I
> imagine) that takes a (La)TeX or ConTeXt input file with the TeX codes for
> Indic diacritical marks and creates an output file with all those codes
> turned into Unicode. (The one condition is that each letter with a
> diacritical mark is placed between braces. "\={a}" etc. will be recognized,
> but "\=a" will not, and therefore will remain unconverted.)
>
> Should anyone be interested in receiving a copy of the program, please
> write to me off-list.
>
> Robert Zydenbos
>
> --
> Prof. Dr. Robert J. Zydenbos
> Institut für Indologie und Tibetologie
> Universität München
>
> On Jun 13, 2015, at 10:23 , hanne...@staff.uni-marburg.de wrote:
>
> > [...]
> >
> > The problem is that I need diacritics for Indian languages. In pdflatex
> I use ucs for the
> > utf-input, which is not perfect, but works with a few tweaks.  Of course
> there can be no serious
> > problem in normal TeX, where you can in the worst case just type things
> like \.n \d{t} and the
> > like, which gives you the diacritics with any font (and mostly looks
> quite good).
> >
> > In XeTeX a considerable number of otf-fonts does not yield the expected
> result. In the ADF fonts,
> > for instance, regardless whether you use ṅ or \.n, it does not work.
> Usually the macron \=a works,
> > but not the underdot ṭ (\d{t}) or the dot above the ṅ (\.n). [...]
>
>
>
>
>
> --
> Subscriptions, Archive, and List information, etc.:
>   http://tug.org/mailman/listinfo/xetex
>


--
Subscriptions, Archive, and List information, etc.:
  http://tug.org/mailman/listinfo/xetex


Re: [XeTeX] fonts and diacritics

2015-07-01 Thread Robert Zydenbos
I have experimented with a number of fonts in XeTeX for Indological use, with 
mixed results. If one wants to have a pleasant and clear distance between the 
letters and the diacritics, *and* also a correct positioning of the diacritics, 
*and* also the possibility to use italics and bold type (and both combined) by 
means of simple \textbf, \emph etc., without going into TeXy things (like 
declaring typefaces with "slanted=...", "extended=..." etc.), my personal 
favourite is Charis SIL. But also the Linux Libertine fonts are good, as are 
FreeSerif / FreeSans / FreeMono, and the Liberation series of fonts. Also most 
of the TeXGyre fonts are quite usable.

Not every one in the Gentium family of fonts (also SIL) supports bold and bold 
slanted, but they too can be recommended. SIL (www.sil.org) also has a very 
nice Nagari font named Annapurna, which has become my favourite for that script.

Robert Zydenbos
--
Prof. Dr. Robert J. Zydenbos
Institut für Indologie und Tibetologie
Universität München

On Jun 13, 2015, at 18:18 , Dominik Wujastyk  wrote:

> I think both Junicode and LM have charsets that cover Indological use well.  
> Personally, I'm not so keen on Times-like fonts, so I tend not to use 
> Junicode.  I have done books with CM (<>LM) fonts in the past, and I have the 
> highest respect for Don Knuth's work and the Modern style, but again, my 
> current tastes are towards more classic styles like Bembo, Palatino, 
> Baskerville, etc.  With Hermann Zapf's recent passing, I feel some loyalty to 
> using Palatino at the moment. 
> 
> Sanskrit 2003 is my favourite font containing Devanagari, if give a little 
> horizontal stretching*, and it also contains a Roman font (Times-Roman like). 
>  So it's quite convenient for typesetting mixed Roman/Nagari text in a simple 
> way, especially since the hyphenation tables for Sanskrit contain both 
> Devanagari and Roman at once.
> 
> Best,
> Dominik  
> 
> * For using the Devanagari on its own:
> \setmainfont[FakeStretch=1.08,
> Script=Devanagari,
> Language=Sanskrit,
> Mapping=velthuis-sanskrit]
> {Sanskrit 2003}
> 
> On 13 June 2015 at 13:26, Nathan Sidoli  wrote:
> Dear Dominik,
> 
> Do you have any opinion on Junicode or Latin Modern for transliteration from 
> Indic languages?
> 
> Best,
> 
> Nathan






--
Subscriptions, Archive, and List information, etc.:
  http://tug.org/mailman/listinfo/xetex


Re: [XeTeX] fonts and diacritics

2015-07-01 Thread Robert Zydenbos
I have experimented with a number of fonts in XeTeX for Indological use, with 
mixed results. If one wants to have a pleasant and clear distance between the 
letters and the diacritics, *and* also a correct positioning of the diacritics, 
*and* also the possibility to use italics and bold type (and both combined) by 
means of simple \textbf, \emph etc., without going into TeXy things (like 
declaring typefaces with "slant=...", "extended=..." etc.), my personal 
favourite is Charis SIL. But also the Linux Libertine fonts are good, as are 
FreeSerif / FreeSans / FreeMono, and the Liberation series of fonts. Also most 
of the TeXGyre fonts are quite usable.

Not every one in the Gentium family of fonts (also SIL) supports bold and bold 
slanted, but they too can be recommended. SIL (www.sil.org) also has a very 
nice Nagari font named Annapurna, which has become my favourite for that script.

Robert Zydenbos

On Jun 13, 2015, at 18:18 , Dominik Wujastyk  wrote:

> I think both Junicode and LM have charsets that cover Indological use well.  
> Personally, I'm not so keen on Times-like fonts, so I tend not to use 
> Junicode.  I have done books with CM (<>LM) fonts in the past, and I have the 
> highest respect for Don Knuth's work and the Modern style, but again, my 
> current tastes are towards more classic styles like Bembo, Palatino, 
> Baskerville, etc.  With Hermann Zapf's recent passing, I feel some loyalty to 
> using Palatino at the moment. 
> 
> Sanskrit 2003 is my favourite font containing Devanagari, if give a little 
> horizontal stretching*, and it also contains a Roman font (Times-Roman like). 
>  So it's quite convenient for typesetting mixed Roman/Nagari text in a simple 
> way, especially since the hyphenation tables for Sanskrit contain both 
> Devanagari and Roman at once.
> 
> Best,
> Dominik  
> 
> * For using the Devanagari on its own:
> \setmainfont[FakeStretch=1.08,
> Script=Devanagari,
> Language=Sanskrit,
> Mapping=velthuis-sanskrit]
> {Sanskrit 2003}
> 
> On 13 June 2015 at 13:26, Nathan Sidoli  wrote:
> Dear Dominik,
> 
> Do you have any opinion on Junicode or Latin Modern for transliteration from 
> Indic languages?
> 
> Best,
> 
> Nathan
> 
> 

--
Prof. Dr. Robert J. Zydenbos
Institut für Indologie und Tibetologie
Universität München





--
Subscriptions, Archive, and List information, etc.:
  http://tug.org/mailman/listinfo/xetex


Re: [XeTeX] fonts and diacritics

2015-07-01 Thread Robert Zydenbos
Please do not use the traditional TeX codes for the Indic diacritics (things 
like \={a} etc.)! One of the big advantages of XeTeX is precisely that it uses 
Unicode. This means that your input file can be typed using any 
Unicode-supporting text editor (I use TeXShop on a Mac, TeXworks on Linux). It 
is obviously much more efficient to write and read "prajñāvādāṃśca bhāṣase" 
than "praj\~{n}\={a}v\={a}d\={a}\d{m}\'{s}ca bh\={a}\d{s}ase". There are 
numerous good Unicode fonts, also such that are freely available, that produce 
fine results, both onscreen and on paper.

Because I had a number of files containing all those TeX codes and wanted to 
switch to XeTeX, I wrote a simple program (or 'script', as some people say) in 
Python (the older version 2.7, which is still the standard version on many 
machines; but it can be rather quickly adapted for version 3, I imagine) that 
takes a (La)TeX or ConTeXt input file with the TeX codes for Indic diacritical 
marks and creates an output file with all those codes turned into Unicode. (The 
one condition is that each letter with a diacritical mark is placed between 
braces. "\={a}" etc. will be recognized, but "\=a" will not, and therefore will 
remain unconverted.)

Should anyone be interested in receiving a copy of the program, please write to 
me off-list.

Robert Zydenbos

--
Prof. Dr. Robert J. Zydenbos
Institut für Indologie und Tibetologie
Universität München

On Jun 13, 2015, at 10:23 , hanne...@staff.uni-marburg.de wrote:

> [...]
> 
> The problem is that I need diacritics for Indian languages. In pdflatex I use 
> ucs for the
> utf-input, which is not perfect, but works with a few tweaks.  Of course 
> there can be no serious
> problem in normal TeX, where you can in the worst case just type things like 
> \.n \d{t} and the
> like, which gives you the diacritics with any font (and mostly looks quite 
> good).
> 
> In XeTeX a considerable number of otf-fonts does not yield the expected 
> result. In the ADF fonts,
> for instance, regardless whether you use ṅ or \.n, it does not work. Usually 
> the macron \=a works,
> but not the underdot ṭ (\d{t}) or the dot above the ṅ (\.n). [...]





--
Subscriptions, Archive, and List information, etc.:
  http://tug.org/mailman/listinfo/xetex


Re: [XeTeX] fonts and diacritics

2015-06-30 Thread Dominik Wujastyk
Very nice.  Thanks, François.  The active char hack.  I've used it often :-)
​


--
Subscriptions, Archive, and List information, etc.:
  http://tug.org/mailman/listinfo/xetex


Re: [XeTeX] fonts and diacritics

2015-06-29 Thread FC
Long time ago I wrote a small package that was not worth uploading to CTAN
but did the job for me when I had to use Garamond and still be able to
transliterate Arabic from an input document that was already encoded in
UTF-8 (my editor has custom key mappings for that). With that package,
characters such as ṭ (U+1E6D), when not present in a font, would be
automatically composed by XeTeX in the traditional way. I attach it here,
in case it might be useful to others.

In general I try to avoid using such tricks, but as I said, sometimes you
just have no choice.

Best regards,
François Charette

2015-06-14 8:28 GMT+02:00 :

> Thank you all for the valuable comments, I learnt quite a bit on XeTeX!
>
> Like Dominic I also thought out of loyality to use a Zapf font. I like
> and have once used Aldus, so let us hope the otf-version contains all
> the glyphs needed.
>
> Best
> Jürgen
>
>
>
>
> - Nachricht von Dominik Wujastyk  -
>  Datum: Sat, 13 Jun 2015 18:18:23 +0200
>Von: Dominik Wujastyk 
> Antwort an: "XeTeX (Unicode-based TeX) discussion." 
>Betreff: Re: [XeTeX] fonts and diacritics
> An: "XeTeX (Unicode-based TeX) discussion." 
>
>
>
>  I think both Junicode and LM have charsets that cover Indological use
>> well.  Personally, I'm not so keen on Times-like fonts, so I tend not to
>> use Junicode.  I have done books with CM (<>LM) fonts in the past, and I
>> have the highest respect for Don Knuth's work and the Modern style, but
>> again, my current tastes are towards more classic styles like Bembo,
>> Palatino, Baskerville, etc.  With Hermann Zapf's recent passing, I feel
>> some loyalty to using Palatino at the moment.
>>
>> Sanskrit 2003 is my favourite font containing Devanagari, if give a little
>> horizontal stretching*, and it also contains a Roman font (Times-Roman
>> like).  So it's quite convenient for typesetting mixed Roman/Nagari text
>> in
>> a simple way, especially since the hyphenation tables for Sanskrit contain
>> both Devanagari and Roman at once.
>>
>> Best,
>> Dominik
>>
>> * For using the Devanagari on its own:
>> \setmainfont[FakeStretch=1.08,
>> Script=Devanagari,
>> Language=Sanskrit,
>> Mapping=velthuis-sanskrit]
>> {Sanskrit 2003}
>>
>> On 13 June 2015 at 13:26, Nathan Sidoli 
>> wrote:
>>
>>   Dear Dominik,
>>>
>>> Do you have any opinion on Junicode or Latin Modern for transliteration
>>> from Indic languages?
>>>
>>> Best,
>>>
>>> Nathan
>>>
>>>
>>>
>
> - Ende der Nachricht von Dominik Wujastyk  -
>
>
>
> ---
>
> Prof. Dr. Juergen Hanneder
> Philipps-Universitaet Marburg
> FG Indologie u. Tibetologie
> Deutschhausstr.12
> 35032 Marburg
> Germany
> Tel. 0049-6421-28-24930
> hanne...@staff.uni-marburg.de
>
>
>
> --
> Subscriptions, Archive, and List information, etc.:
>  http://tug.org/mailman/listinfo/xetex
>


xdiacomp.sty
Description: Binary data


--
Subscriptions, Archive, and List information, etc.:
  http://tug.org/mailman/listinfo/xetex


Re: [XeTeX] fonts and diacritics

2015-06-13 Thread hanneder

Thank you all for the valuable comments, I learnt quite a bit on XeTeX!

Like Dominic I also thought out of loyality to use a Zapf font. I like
and have once used Aldus, so let us hope the otf-version contains all
the glyphs needed.

Best
Jürgen




- Nachricht von Dominik Wujastyk  -
 Datum: Sat, 13 Jun 2015 18:18:23 +0200
   Von: Dominik Wujastyk 
Antwort an: "XeTeX (Unicode-based TeX) discussion." 
   Betreff: Re: [XeTeX] fonts and diacritics
An: "XeTeX (Unicode-based TeX) discussion." 



I think both Junicode and LM have charsets that cover Indological use
well.  Personally, I'm not so keen on Times-like fonts, so I tend not to
use Junicode.  I have done books with CM (<>LM) fonts in the past, and I
have the highest respect for Don Knuth's work and the Modern style, but
again, my current tastes are towards more classic styles like Bembo,
Palatino, Baskerville, etc.  With Hermann Zapf's recent passing, I feel
some loyalty to using Palatino at the moment.

Sanskrit 2003 is my favourite font containing Devanagari, if give a little
horizontal stretching*, and it also contains a Roman font (Times-Roman
like).  So it's quite convenient for typesetting mixed Roman/Nagari text in
a simple way, especially since the hyphenation tables for Sanskrit contain
both Devanagari and Roman at once.

Best,
Dominik

* For using the Devanagari on its own:
\setmainfont[FakeStretch=1.08,
Script=Devanagari,
Language=Sanskrit,
Mapping=velthuis-sanskrit]
{Sanskrit 2003}

On 13 June 2015 at 13:26, Nathan Sidoli  wrote:


 Dear Dominik,

Do you have any opinion on Junicode or Latin Modern for transliteration
from Indic languages?

Best,

Nathan





- Ende der Nachricht von Dominik Wujastyk  -



---

Prof. Dr. Juergen Hanneder
Philipps-Universitaet Marburg
FG Indologie u. Tibetologie
Deutschhausstr.12
35032 Marburg
Germany
Tel. 0049-6421-28-24930
hanne...@staff.uni-marburg.de



--
Subscriptions, Archive, and List information, etc.:
 http://tug.org/mailman/listinfo/xetex


Re: [XeTeX] fonts and diacritics

2015-06-13 Thread Dominik Wujastyk
I think both Junicode and LM have charsets that cover Indological use
well.  Personally, I'm not so keen on Times-like fonts, so I tend not to
use Junicode.  I have done books with CM (<>LM) fonts in the past, and I
have the highest respect for Don Knuth's work and the Modern style, but
again, my current tastes are towards more classic styles like Bembo,
Palatino, Baskerville, etc.  With Hermann Zapf's recent passing, I feel
some loyalty to using Palatino at the moment.

Sanskrit 2003 is my favourite font containing Devanagari, if give a little
horizontal stretching*, and it also contains a Roman font (Times-Roman
like).  So it's quite convenient for typesetting mixed Roman/Nagari text in
a simple way, especially since the hyphenation tables for Sanskrit contain
both Devanagari and Roman at once.

Best,
Dominik

* For using the Devanagari on its own:
\setmainfont[FakeStretch=1.08,
Script=Devanagari,
Language=Sanskrit,
Mapping=velthuis-sanskrit]
{Sanskrit 2003}

On 13 June 2015 at 13:26, Nathan Sidoli  wrote:

>  Dear Dominik,
>
> Do you have any opinion on Junicode or Latin Modern for transliteration
> from Indic languages?
>
> Best,
>
> Nathan
>
>


--
Subscriptions, Archive, and List information, etc.:
  http://tug.org/mailman/listinfo/xetex


Re: [XeTeX] fonts and diacritics

2015-06-13 Thread David M. Jones
In addition to the other fonts that have been mentioned here, version
2 of the STIX fonts, due out later this year, should provide a very
attractive option:

http://www.stixfonts.org/

They also have a less restrictive license than even the Brill fonts.

David.

P.S. Full disclosure: The AMS is a major funder of the STIX fonts.


--
Subscriptions, Archive, and List information, etc.:
  http://tug.org/mailman/listinfo/xetex


Re: [XeTeX] fonts and diacritics

2015-06-13 Thread Pander
On 06/13/2015 04:10 PM, Zdenek Wagner wrote:
> 2015-06-13 11:54 GMT+02:00 Pander :
>> ...
>>
>> Why don't you use UTF-8? In that way the content of your document is
>> better searchable and exchangeable.

Sorry, I meant searchability/reusability of the text in the source of
your document, not the output in PDF.

>>
> Searchability has nothing to do with input. I can input \v{c}  and the
> generated PDF will contain č. There are cases where macros are needed.
> If I need dot below as an accent, I have to type \d{d} because I do
> not have it on my keyboard and do not know how to add the dotbelow
> accent to the XKB map.
> 
>> For intuitively entering characters with diacritics in UTF-8, have a
>> look at https://www.createspace.com/3758226 Despite the title the
>> content is still valid. At the time of publication it was even further
>> than compose key bindings that were shipped with operating systems.
>>
>> To be able to show as many as possible characters with diacritics, I
>> used https://www.gnu.org/software/freefont/ Even some characters were
>> specially added upon my request for the creation of the book. Probably
>> all characters you need are already supported.
>>
>> I am using the upstream version of these fonts to have as many
>> characters as possible. For that I use a script with the following commands:
>>
>>
>>
>> TL=/usr/local/texlive/2014/texmf-dist/fonts
>> rm -rf $TL/truetype/public/gnu-freefont
>> if [ ! -e freefont ]
>> then
>> svn co svn://svn.savannah.gnu.org/freefont/trunk/freefont
>> fi
>> cd freefont
>> svn update
>> cd sfd
>> make otf
>> cp -f *otf $TL/opentype/public/gnu-freefont/
>>
>>
> And do not forget to uninstall the version from TeX Live, if you have
> two versions, you may get into serious problems.

The is taken care of by the above commands. The TTF is removed and the
OTF is overriden. To also disable the fonts shipped from your
distribution you can use:


rm -rf /usr/share/fonts/truetype/freefont


but of course you can to it the other way around and override the fonts
from the distro.

>>
>> Regards,
>>
>> Pander
>>
>>> Jürgen
>>>
>>> ---
>>>
>>> Prof. Dr. Juergen Hanneder
>>> Philipps-Universitaet Marburg
>>> FG Indologie u. Tibetologie
>>> Deutschhausstr.12
>>> 35032 Marburg
>>> Germany
>>> Tel. 0049-6421-28-24930
>>> hanne...@staff.uni-marburg.de
>>>
>>>
>>>
>>> --
>>> Subscriptions, Archive, and List information, etc.:
>>>  http://tug.org/mailman/listinfo/xetex
>>
>>
> 
> Zdeněk Wagner
> http://hroch486.icpf.cas.cz/wagner/
> http://icebearsoft.euweb.cz
> 
> 
> 
>>
>> --
>> Subscriptions, Archive, and List information, etc.:
>>   http://tug.org/mailman/listinfo/xetex
> 
> 
> 
> --
> Subscriptions, Archive, and List information, etc.:
>   http://tug.org/mailman/listinfo/xetex
> 



--
Subscriptions, Archive, and List information, etc.:
  http://tug.org/mailman/listinfo/xetex


Re: [XeTeX] fonts and diacritics

2015-06-13 Thread Zdenek Wagner
2015-06-13 11:54 GMT+02:00 Pander :
> ...
>
> Why don't you use UTF-8? In that way the content of your document is
> better searchable and exchangeable.
>
Searchability has nothing to do with input. I can input \v{c}  and the
generated PDF will contain č. There are cases where macros are needed.
If I need dot below as an accent, I have to type \d{d} because I do
not have it on my keyboard and do not know how to add the dotbelow
accent to the XKB map.

> For intuitively entering characters with diacritics in UTF-8, have a
> look at https://www.createspace.com/3758226 Despite the title the
> content is still valid. At the time of publication it was even further
> than compose key bindings that were shipped with operating systems.
>
> To be able to show as many as possible characters with diacritics, I
> used https://www.gnu.org/software/freefont/ Even some characters were
> specially added upon my request for the creation of the book. Probably
> all characters you need are already supported.
>
> I am using the upstream version of these fonts to have as many
> characters as possible. For that I use a script with the following commands:
>
>
>
> TL=/usr/local/texlive/2014/texmf-dist/fonts
> rm -rf $TL/truetype/public/gnu-freefont
> if [ ! -e freefont ]
> then
> svn co svn://svn.savannah.gnu.org/freefont/trunk/freefont
> fi
> cd freefont
> svn update
> cd sfd
> make otf
> cp -f *otf $TL/opentype/public/gnu-freefont/
>
>
And do not forget to uninstall the version from TeX Live, if you have
two versions, you may get into serious problems.
>
> Regards,
>
> Pander
>
>> Jürgen
>>
>> ---
>>
>> Prof. Dr. Juergen Hanneder
>> Philipps-Universitaet Marburg
>> FG Indologie u. Tibetologie
>> Deutschhausstr.12
>> 35032 Marburg
>> Germany
>> Tel. 0049-6421-28-24930
>> hanne...@staff.uni-marburg.de
>>
>>
>>
>> --
>> Subscriptions, Archive, and List information, etc.:
>>  http://tug.org/mailman/listinfo/xetex
>
>

Zdeněk Wagner
http://hroch486.icpf.cas.cz/wagner/
http://icebearsoft.euweb.cz



>
> --
> Subscriptions, Archive, and List information, etc.:
>   http://tug.org/mailman/listinfo/xetex



--
Subscriptions, Archive, and List information, etc.:
  http://tug.org/mailman/listinfo/xetex


Re: [XeTeX] fonts and diacritics

2015-06-13 Thread Pander
On 06/13/2015 10:23 AM, hanne...@staff.uni-marburg.de wrote:
> 
> I am planning my first publication formatted with XeLaTeX (rather than
> pdflatex) and have tried out
> a few fonts.
> 
> The problem is that I need diacritics for Indian languages. In pdflatex
> I use ucs for the
> utf-input, which is not perfect, but works with a few tweaks.  Of course
> there can be no serious
> problem in normal TeX, where you can in the worst case just type things
> like \.n \d{t} and the
> like, which gives you the diacritics with any font (and mostly looks
> quite good).
> 
> In XeTeX a considerable number of otf-fonts does not yield the expected
> result. In the ADF fonts,
> for instance, regardless whether you use ṅ or \.n, it does not work.
> Usually the macron \=a works,
> but not the underdot ṭ (\d{t}) or the dot above the ṅ (\.n).
> 
> 1. Did I miss anything (a trick in XeTeX)? Since other fonts (for
> instance all TeXGyre fonts) work
> just fine, I thought not.
> 
> 2. Or is it the case that some (actually many) fonts supposed to work
> with XeTeX are weak in
> diacritics?
> 
> 3. If so, is it possible to make any predictions whether a commercial
> font will or will not suffer
> the same fate. I would of course not want to buy one of the "Top Ten
> Typefaces" (1. Minion, 2. ITC
> Baskerville) only to find out that they are unusable for the purpose.
> 
> Any comments and experiences, tests if you have some of those fonts,
> would be most welcome!
> 

Why don't you use UTF-8? In that way the content of your document is
better searchable and exchangeable.

For intuitively entering characters with diacritics in UTF-8, have a
look at https://www.createspace.com/3758226 Despite the title the
content is still valid. At the time of publication it was even further
than compose key bindings that were shipped with operating systems.

To be able to show as many as possible characters with diacritics, I
used https://www.gnu.org/software/freefont/ Even some characters were
specially added upon my request for the creation of the book. Probably
all characters you need are already supported.

I am using the upstream version of these fonts to have as many
characters as possible. For that I use a script with the following commands:



TL=/usr/local/texlive/2014/texmf-dist/fonts
rm -rf $TL/truetype/public/gnu-freefont
if [ ! -e freefont ]
then
svn co svn://svn.savannah.gnu.org/freefont/trunk/freefont
fi
cd freefont
svn update
cd sfd
make otf
cp -f *otf $TL/opentype/public/gnu-freefont/



Regards,

Pander

> Jürgen
> 
> ---
> 
> Prof. Dr. Juergen Hanneder
> Philipps-Universitaet Marburg
> FG Indologie u. Tibetologie
> Deutschhausstr.12
> 35032 Marburg
> Germany
> Tel. 0049-6421-28-24930
> hanne...@staff.uni-marburg.de
> 
> 
> 
> --
> Subscriptions, Archive, and List information, etc.:
>  http://tug.org/mailman/listinfo/xetex



--
Subscriptions, Archive, and List information, etc.:
  http://tug.org/mailman/listinfo/xetex


Re: [XeTeX] fonts and diacritics

2015-06-13 Thread Nathan Sidoli

Dear Dominik,

Do you have any opinion on Junicode or Latin Modern for transliteration 
from Indic languages?


Best,

Nathan


On 6/13/15 6:21 PM, Dominik Wujastyk wrote:

Dear Juergen,

Nice to see you here (I just read your 2011 I. Taurinensia paper last 
night!).


Yes, you are right, some fonts just don't have the right characters in 
them. Some of the font "pigeonholes" are empty.  If you make the 
character with a TeX macro (\.n) then usually things work even if the 
font lacks the char, because TeX puts together an accent from one 
place with the character from another.  If the overdot accent char is 
missing, then even TeX can't fix things.


I use the following at the start of my docs:

% XeLaTeX stuff:
% Normalize any residual Unicode combining accents,
% and write out error messages, if any:
%
\XeTeXinputnormalization=1
\tracinglostchars=1
\tracingonline=1

You can read up on what these do, but especially the \tracinglostchars 
is helpful so that missing chars are flagged in the log file.


And for complete fonts, I find the SIL fonts, like Gentium, the 
TeXGyre family, and the Brill font 
 (that is free to use but not 
for publishing with others than Brill without permission), are all 
complete for Indic work. Oh, and also John Smith's fonts, at 
http://Bombay.indology.info. DejaVu fonts are also very complete.  I'm 
sure there are many others: these are just my personal practical 
observations without a systematic survey or testing.


Yesterday, Alessandro Graheli was telling me that the Murty Library 
fonts  are 
excellent; especially he praised their Devanagari, that is explicitly 
modelled on the Nirnayasagara family.  Fiona Ross was involved in 
making the Murty fonts, and she is extremely experienced and 
knowledgeable about Indian fonts. The Murty fonts are like the Brill, 
you can use them freely, but if you want to publish a book with them, 
you have to ask permission.


Best,
Dominik



--
Subscriptions, Archive, and List information, etc.:
   http://tug.org/mailman/listinfo/xetex




--
Subscriptions, Archive, and List information, etc.:
  http://tug.org/mailman/listinfo/xetex


Re: [XeTeX] fonts and diacritics

2015-06-13 Thread Rembrandt Wolpert
On 6/13/15 9:23 AM, hanne...@staff.uni-marburg.de wrote:
> 
> I am planning my first publication formatted with XeLaTeX (rather than
> pdflatex) and have tried out
> a few fonts.
> 
> The problem is that I need diacritics for Indian languages. In pdflatex
> I use ucs for the
> utf-input, which is not perfect, but works with a few tweaks.  Of course
> there can be no serious
> problem in normal TeX, where you can in the worst case just type things
> like \.n \d{t} and the
> like, which gives you the diacritics with any font (and mostly looks
> quite good).
> 
> In XeTeX a considerable number of otf-fonts does not yield the expected
> result. In the ADF fonts,
> for instance, regardless whether you use ṅ or \.n, it does not work.
> Usually the macron \=a works,
> but not the underdot ṭ (\d{t}) or the dot above the ṅ (\.n).
> 
> 1. Did I miss anything (a trick in XeTeX)? Since other fonts (for
> instance all TeXGyre fonts) work
> just fine, I thought not.
> 
> 2. Or is it the case that some (actually many) fonts supposed to work
> with XeTeX are weak in
> diacritics?
> 
> 3. If so, is it possible to make any predictions whether a commercial
> font will or will not suffer
> the same fate. I would of course not want to buy one of the "Top Ten
> Typefaces" (1. Minion, 2. ITC
> Baskerville) only to find out that they are unusable for the purpose.
> 
> Any comments and experiences, tests if you have some of those fonts,
> would be most welcome!
> 
> Jürgen
> 
> ---
> 
> Prof. Dr. Juergen Hanneder
> Philipps-Universitaet Marburg
> FG Indologie u. Tibetologie
> Deutschhausstr.12
> 35032 Marburg
> Germany
> Tel. 0049-6421-28-24930
> hanne...@staff.uni-marburg.de
> 
> 
> 
> --
> Subscriptions, Archive, and List information, etc.:
>  http://tug.org/mailman/listinfo/xetex

Brill (the publisher from Leiden) offers a (free, as in no cost) font with:

"complete coverage of the Latin script with the full range of diacritics
and linguistics (IPA) characters used to display any language from any
period correctly, and Greek and Cyrillic are also covered. [...] The
“Brill” fonts comply with all international standards, including Unicode."

See http://www.brill.com/about/brill-fonts

Hope this is useful.

Rembrandt

-- 
人生䘮亂世 無君欲誰仕
 - 劉因 (1249-1293)


--
Subscriptions, Archive, and List information, etc.:
  http://tug.org/mailman/listinfo/xetex


Re: [XeTeX] fonts and diacritics

2015-06-13 Thread Ulrike Fischer
Am Sat, 13 Jun 2015 10:23:01 +0200 schrieb
hanne...@staff.uni-marburg.de:


> The problem is that I need diacritics for Indian languages. In  
> pdflatex I use ucs for the
> utf-input, which is not perfect, but works with a few tweaks.  Of  
> course there can be no serious
> problem in normal TeX, where you can in the worst case just type  
> things like \.n \d{t} and the
> like, which gives you the diacritics with any font (and mostly looks  
> quite good).
> 
> In XeTeX a considerable number of otf-fonts does not yield the  
> expected result. In the ADF fonts,
> for instance, regardless whether you use ṅ or \.n, it does not work.  
> Usually the macron \=a works,
> but not the underdot ṭ (\d{t}) or the dot above the ṅ (\.n).
> 
> 1. Did I miss anything (a trick in XeTeX)? Since other fonts (for  
> instance all TeXGyre fonts) work just fine, I thought not.
 
> 2. Or is it the case that some (actually many) fonts supposed to work  
> with XeTeX are weak in diacritics?

Yes, it can happen that the default definition of e.g. \d  leads to
a non existing glyh. xunicode maps \d{t} to 

  \DeclareUTFcomposite[\UTFencname]{x1E6D}{\d}{t}

but if your font doesn't have U+1E6D it doesn't work. 

You can then try

  \UndeclareUTFcomposite[\UTFencname]{x1E6D}{\d}{t}

then xelatex will fall back to the default "dot below accent":

\DeclareEncodedCompositeCharacter{\UTFencname}{\d}{0323}{0323}  %
Combining dot below

But if the font doesn't have U+0323 than it doesn't work either.
Then one could fall back to some older definition adn put a dot
below the t like pdflatex would do in OT1 encoding.

But it is better to choose your font so that it has the glyphs you
need. 


-- 
Ulrike Fischer 
http://www.troubleshooting-tex.de/



--
Subscriptions, Archive, and List information, etc.:
  http://tug.org/mailman/listinfo/xetex


Re: [XeTeX] fonts and diacritics

2015-06-13 Thread Dominik Wujastyk
Dear Juergen,

Nice to see you here (I just read your 2011 I. Taurinensia paper last
night!).

Yes, you are right, some fonts just don't have the right characters in
them. Some of the font "pigeonholes" are empty.  If you make the character
with a TeX macro (\.n) then usually things work even if the font lacks the
char, because TeX puts together an accent from one place with the character
from another.  If the overdot accent char is missing, then even TeX can't
fix things.

I use the following at the start of my docs:

% XeLaTeX stuff:
% Normalize any residual Unicode combining accents,
% and write out error messages, if any:
%
\XeTeXinputnormalization=1
\tracinglostchars=1
\tracingonline=1

You can read up on what these do, but especially the \tracinglostchars is
helpful so that missing chars are flagged in the log file.

And for complete fonts, I find the SIL fonts, like Gentium, the TeXGyre
family, and the Brill font  (that
is free to use but not for publishing with others than Brill without
permission), are all complete for Indic work.  Oh, and also John Smith's
fonts, at http://Bombay.indology.info.  DejaVu fonts are also very
complete.  I'm sure there are many others: these are just my personal
practical observations without a systematic survey or testing.

Yesterday, Alessandro Graheli was telling me that the Murty Library fonts
 are excellent;
especially he praised their Devanagari, that is explicitly modelled on the
Nirnayasagara family.  Fiona Ross was involved in making the Murty fonts,
and she is extremely experienced and knowledgeable about Indian fonts. The
Murty fonts are like the Brill, you can use them freely, but if you want to
publish a book with them, you have to ask permission.

Best,
Dominik


--
Subscriptions, Archive, and List information, etc.:
  http://tug.org/mailman/listinfo/xetex