Re: [NTG-context] Ligatures in EB Garamond

2016-01-19 Thread Hans Hagen

On 1/19/2016 8:13 AM, Jan U. Hasecke wrote:


I was disappointed to learn that there is no package like selnolig for
ConTeXt but the book I am now typesetting is only 120 pages long and
I'll switch ligatures off manually with the ZWNJ replacement. (The
ConTeXt notation is a bit uncomfortable, but as I only have to use it
once...)


I have no clue what a package is supposed to do but any solution has to 
come up with a list if words.


\replaceword[sellig][auflösen][auf{-}{}{\zwnj}lösen]

The {-}{}{\zwnj} is in fact a discretionary spec because you probably 
would like to permit hyphenation. You could inject just a \nzwj .


Btw, keep in mind that in context this kind of manipulations happens in 
ways that don't interfere too much with macro expansion and other trickery.


Hans


-
  Hans Hagen | PRAGMA ADE
  Ridderstraat 27 | 8061 GH Hasselt | The Netherlands
  tel: 038 477 53 69 | www.pragma-ade.com | www.pragma-pod.nl
-
___
If your question is of interest to others as well, please add an entry to the 
Wiki!

maillist : ntg-context@ntg.nl / http://www.ntg.nl/mailman/listinfo/ntg-context
webpage  : http://www.pragma-ade.nl / http://tex.aanhet.net
archive  : http://foundry.supelec.fr/projects/contextrev/
wiki : http://contextgarden.net
___

Re: [NTG-context] Ligatures in EB Garamond

2016-01-19 Thread Arthur Reutenauer
> I have no clue what a package is supposed to do but any solution has to come
> up with a list if words.

  I think the point is that often in German, breakpoints for hyphenation
also break ligatures.  I mentioned that in Nasbinals.

Best,

Arthur
___
If your question is of interest to others as well, please add an entry to the 
Wiki!

maillist : ntg-context@ntg.nl / http://www.ntg.nl/mailman/listinfo/ntg-context
webpage  : http://www.pragma-ade.nl / http://tex.aanhet.net
archive  : http://foundry.supelec.fr/projects/contextrev/
wiki : http://contextgarden.net
___

Re: [NTG-context] Ligatures in EB Garamond

2016-01-19 Thread Hans Hagen

On 1/19/2016 5:41 PM, Jan U. Hasecke wrote:

Am 19.01.2016 um 16:31 schrieb Kate F:

On 19 January 2016 at 09:05, Arthur Reutenauer
 wrote:

I have no clue what a package is supposed to do but any solution has to come
up with a list if words.


   I think the point is that often in German, breakpoints for hyphenation
also break ligatures.  I mentioned that in Nasbinals.

 Best,

 Arthur


The guts of the selnolig package just call \hyphenation{...}:
http://anorien.csc.warwick.ac.uk/mirrors/CTAN/macros/luatex/latex/selnolig/selnolig-english-hyphex.sty


The interesting part for ligatures is in the patterns file

http://anorien.csc.warwick.ac.uk/mirrors/CTAN/macros/luatex/latex/selnolig/selnolig-english-patterns.sty

http://anorien.csc.warwick.ac.uk/mirrors/CTAN/macros/luatex/latex/selnolig/selnolig-german-patterns.sty

By using patterns they don't need a very huge word list, I think.


If patterns were the solution then making better pattern files would be 
the solution ... anyway, i just see a list of what are basically 
exceptions.


So just for the fun of it i'll add {} as shortcut for \zwnj

  \replaceword[more][shiffling] [shiff{}ling]

and this already was there

  \replaceword[more][shiffling] [shiffling]

to prevent messing with something but i'll add an equivalent

  \replaceword[more][shiffling] [{shiffling}]

variant (more explicit). The already existing replacement mechanism is 
good enough for this purpose and if needed we can always ship some lists.


Hans



-
  Hans Hagen | PRAGMA ADE
  Ridderstraat 27 | 8061 GH Hasselt | The Netherlands
  tel: 038 477 53 69 | www.pragma-ade.com | www.pragma-pod.nl
-
___
If your question is of interest to others as well, please add an entry to the 
Wiki!

maillist : ntg-context@ntg.nl / http://www.ntg.nl/mailman/listinfo/ntg-context
webpage  : http://www.pragma-ade.nl / http://tex.aanhet.net
archive  : http://foundry.supelec.fr/projects/contextrev/
wiki : http://contextgarden.net
___

Re: [NTG-context] Ligatures in EB Garamond

2016-01-19 Thread Kate F
On 19 January 2016 at 09:05, Arthur Reutenauer
 wrote:
>> I have no clue what a package is supposed to do but any solution has to come
>> up with a list if words.
>
>   I think the point is that often in German, breakpoints for hyphenation
> also break ligatures.  I mentioned that in Nasbinals.
>
> Best,
>
> Arthur

The guts of the selnolig package just call \hyphenation{...}:
http://anorien.csc.warwick.ac.uk/mirrors/CTAN/macros/luatex/latex/selnolig/selnolig-english-hyphex.sty

Isn't this exactly the same for ConTeXt?
http://wiki.contextgarden.net/Command/hyphenation

-- 
Kate
___
If your question is of interest to others as well, please add an entry to the 
Wiki!

maillist : ntg-context@ntg.nl / http://www.ntg.nl/mailman/listinfo/ntg-context
webpage  : http://www.pragma-ade.nl / http://tex.aanhet.net
archive  : http://foundry.supelec.fr/projects/contextrev/
wiki : http://contextgarden.net
___

Re: [NTG-context] Ligatures in EB Garamond

2016-01-19 Thread Arthur Reutenauer
> The guts of the selnolig package just call \hyphenation{...}:
> http://anorien.csc.warwick.ac.uk/mirrors/CTAN/macros/luatex/latex/selnolig/selnolig-english-hyphex.sty

  That's not the core part of the package, it just sets a list of
hyphenation exceptions (that's what \hyphenation does).  The main code is
in selnolig.lua.

Arthur
___
If your question is of interest to others as well, please add an entry to the 
Wiki!

maillist : ntg-context@ntg.nl / http://www.ntg.nl/mailman/listinfo/ntg-context
webpage  : http://www.pragma-ade.nl / http://tex.aanhet.net
archive  : http://foundry.supelec.fr/projects/contextrev/
wiki : http://contextgarden.net
___

Re: [NTG-context] Ligatures in EB Garamond

2016-01-19 Thread Jan U. Hasecke
Am 19.01.2016 um 16:31 schrieb Kate F:
> On 19 January 2016 at 09:05, Arthur Reutenauer
>  wrote:
>>> I have no clue what a package is supposed to do but any solution has to come
>>> up with a list if words.
>>
>>   I think the point is that often in German, breakpoints for hyphenation
>> also break ligatures.  I mentioned that in Nasbinals.
>>
>> Best,
>>
>> Arthur
> 
> The guts of the selnolig package just call \hyphenation{...}:
> http://anorien.csc.warwick.ac.uk/mirrors/CTAN/macros/luatex/latex/selnolig/selnolig-english-hyphex.sty

The interesting part for ligatures is in the patterns file

http://anorien.csc.warwick.ac.uk/mirrors/CTAN/macros/luatex/latex/selnolig/selnolig-english-patterns.sty

http://anorien.csc.warwick.ac.uk/mirrors/CTAN/macros/luatex/latex/selnolig/selnolig-german-patterns.sty

By using patterns they don't need a very huge word list, I think.

juh



___
If your question is of interest to others as well, please add an entry to the 
Wiki!

maillist : ntg-context@ntg.nl / http://www.ntg.nl/mailman/listinfo/ntg-context
webpage  : http://www.pragma-ade.nl / http://tex.aanhet.net
archive  : http://foundry.supelec.fr/projects/contextrev/
wiki : http://contextgarden.net
___

[NTG-context] Ligatures in EB Garamond (was: \replaceword and \setreplacements with xml files)

2016-01-18 Thread Jan U. Hasecke
Am 17.01.2016 um 20:05 schrieb Hans Hagen:
> On 1/16/2016 3:58 PM, Jan U. Hasecke wrote:
>> Am 16.01.2016 um 13:31 schrieb Schmitz Thomas A.:
>>>
>>> Please provide a minimal example of your problem. It’s impossible to
>>> help when we have no clue what you’re doing.
>>
>> Sorry, of course.
>>
>> After setting up a mwe I found that it is a font related issue.
>>
>> When I don't specify a font, it works. --> example.tex
>>
>> When I choose EB Garamond, it does not work. -- example-Garamond.tex
>>
>> I confirmed this behaviour in my real setup.
> 
> don't assume that ligatures are always real ligatures ... in that font
> it's just kerning .. this kind of works okay:
> 
> \replaceword[sellig][auflösen][auf{-}{}{\zwnj}lösen]

I am confused as the specimen of EB Garamond mentions (real) ligatures.
They are listed as glyphs.

https://github.com/georgd/EB-Garamond/blob/master/specimen/Specimen.pdf

juh
___
If your question is of interest to others as well, please add an entry to the 
Wiki!

maillist : ntg-context@ntg.nl / http://www.ntg.nl/mailman/listinfo/ntg-context
webpage  : http://www.pragma-ade.nl / http://tex.aanhet.net
archive  : http://foundry.supelec.fr/projects/contextrev/
wiki : http://contextgarden.net
___

Re: [NTG-context] Ligatures in EB Garamond

2016-01-18 Thread Hans Hagen

On 1/18/2016 10:16 AM, Jan U. Hasecke wrote:

Am 17.01.2016 um 20:05 schrieb Hans Hagen:

On 1/16/2016 3:58 PM, Jan U. Hasecke wrote:

Am 16.01.2016 um 13:31 schrieb Schmitz Thomas A.:


Please provide a minimal example of your problem. It’s impossible to
help when we have no clue what you’re doing.


Sorry, of course.

After setting up a mwe I found that it is a font related issue.

When I don't specify a font, it works. --> example.tex

When I choose EB Garamond, it does not work. -- example-Garamond.tex

I confirmed this behaviour in my real setup.


don't assume that ligatures are always real ligatures ... in that font
it's just kerning .. this kind of works okay:

\replaceword[sellig][auflösen][auf{-}{}{\zwnj}lösen]


I am confused as the specimen of EB Garamond mentions (real) ligatures.
They are listed as glyphs.

https://github.com/georgd/EB-Garamond/blob/master/specimen/Specimen.pdf


maybe the archaic st ligature is a precomposed but f f l i aren't done 
that way but by either kerning or replacement of individual glyphs + 
kerning (there are many methods for this) ... also, 'liga' might mean 
ligature but in practice is used for all kind of things ... in opentype 
'ligature substitution' is just a many-to-one replacement but that 
doesn't mean that 'liga' uses that ... welcome to the inconsistent open 
type mess


Hans


-
  Hans Hagen | PRAGMA ADE
  Ridderstraat 27 | 8061 GH Hasselt | The Netherlands
  tel: 038 477 53 69 | www.pragma-ade.com | www.pragma-pod.nl
-
___
If your question is of interest to others as well, please add an entry to the 
Wiki!

maillist : ntg-context@ntg.nl / http://www.ntg.nl/mailman/listinfo/ntg-context
webpage  : http://www.pragma-ade.nl / http://tex.aanhet.net
archive  : http://foundry.supelec.fr/projects/contextrev/
wiki : http://contextgarden.net
___

Re: [NTG-context] Ligatures in EB Garamond

2016-01-18 Thread Jan U. Hasecke
Am 18.01.2016 um 11:09 schrieb Hans Hagen:
> On 1/18/2016 10:16 AM, Jan U. Hasecke wrote:
>> Am 17.01.2016 um 20:05 schrieb Hans Hagen:
>>> On 1/16/2016 3:58 PM, Jan U. Hasecke wrote:
 Am 16.01.2016 um 13:31 schrieb Schmitz Thomas A.:
>
> Please provide a minimal example of your problem. It’s impossible to
> help when we have no clue what you’re doing.

 Sorry, of course.

 After setting up a mwe I found that it is a font related issue.

 When I don't specify a font, it works. --> example.tex

 When I choose EB Garamond, it does not work. -- example-Garamond.tex

 I confirmed this behaviour in my real setup.
>>>
>>> don't assume that ligatures are always real ligatures ... in that font
>>> it's just kerning .. this kind of works okay:
>>>
>>> \replaceword[sellig][auflösen][auf{-}{}{\zwnj}lösen]
>>
>> I am confused as the specimen of EB Garamond mentions (real) ligatures.
>> They are listed as glyphs.
>>
>> https://github.com/georgd/EB-Garamond/blob/master/specimen/Specimen.pdf
> 
> maybe the archaic st ligature is a precomposed but f f l i aren't done
> that way but by either kerning or replacement of individual glyphs +
> kerning (there are many methods for this) ... also, 'liga' might mean
> ligature but in practice is used for all kind of things ... in opentype
> 'ligature substitution' is just a many-to-one replacement but that
> doesn't mean that 'liga' uses that ... welcome to the inconsistent open
> type mess
> 

Mh, yes. :-(

Two additional questions. Shall I file a bugreport for this issue? What
would be the right words: please provide real ligature glyphs instead of
composed ones?

EB Garamond is a free font also in the sense free of charge. But what
can I expect when I buy a commercial font? I would be quite annoyed when
I buy a font which does not provide the features in a way that I can use
them in ConTeXt.

Is there a font quality page on the Wiki with a feature comparison?

juh

___
If your question is of interest to others as well, please add an entry to the 
Wiki!

maillist : ntg-context@ntg.nl / http://www.ntg.nl/mailman/listinfo/ntg-context
webpage  : http://www.pragma-ade.nl / http://tex.aanhet.net
archive  : http://foundry.supelec.fr/projects/contextrev/
wiki : http://contextgarden.net
___

Re: [NTG-context] Ligatures in EB Garamond

2016-01-18 Thread Hans Hagen

On 1/18/2016 1:46 PM, Jan U. Hasecke wrote:

Am 18.01.2016 um 11:09 schrieb Hans Hagen:

On 1/18/2016 10:16 AM, Jan U. Hasecke wrote:

Am 17.01.2016 um 20:05 schrieb Hans Hagen:

On 1/16/2016 3:58 PM, Jan U. Hasecke wrote:

Am 16.01.2016 um 13:31 schrieb Schmitz Thomas A.:


Please provide a minimal example of your problem. It’s impossible to
help when we have no clue what you’re doing.


Sorry, of course.

After setting up a mwe I found that it is a font related issue.

When I don't specify a font, it works. --> example.tex

When I choose EB Garamond, it does not work. -- example-Garamond.tex

I confirmed this behaviour in my real setup.


don't assume that ligatures are always real ligatures ... in that font
it's just kerning .. this kind of works okay:

\replaceword[sellig][auflösen][auf{-}{}{\zwnj}lösen]


I am confused as the specimen of EB Garamond mentions (real) ligatures.
They are listed as glyphs.

https://github.com/georgd/EB-Garamond/blob/master/specimen/Specimen.pdf


maybe the archaic st ligature is a precomposed but f f l i aren't done
that way but by either kerning or replacement of individual glyphs +
kerning (there are many methods for this) ... also, 'liga' might mean
ligature but in practice is used for all kind of things ... in opentype
'ligature substitution' is just a many-to-one replacement but that
doesn't mean that 'liga' uses that ... welcome to the inconsistent open
type mess



Mh, yes. :-(

Two additional questions. Shall I file a bugreport for this issue? What
would be the right words: please provide real ligature glyphs instead of
composed ones?


there are many fonts out that that do similar things replacing f an i by 
different shapes, or overlaying, or kerning, or replacing by one char, 
looking forward (from f to i) or backward (from i to f) ... as all is 
technically possible/permitted nothing is a bug (but there might be 
occasional differences between hyphenation although quite some effort 
went into getting that kind of right ... and it makes a good topic for 
complex hard to follow boring presentations (see attachment)


(btw, sometimes glyphs get funny non standard names in which case 
roundtrip copy/paste becomes a mess)



EB Garamond is a free font also in the sense free of charge. But what
can I expect when I buy a commercial font? I would be quite annoyed when
I buy a font which does not provide the features in a way that I can use
them in ConTeXt.


you can expect the same ... in fact you can also expect type1 -> otf 
converted fonts with hardly any use of opentype features



Is there a font quality page on the Wiki with a feature comparison?


that would be nice (has been discussed)

Hans

-
  Hans Hagen | PRAGMA ADE
  Ridderstraat 27 | 8061 GH Hasselt | The Netherlands
  tel: 038 477 53 69 | www.pragma-ade.com | www.pragma-pod.nl
-


ligatures.pdf
Description: Adobe PDF document
___
If your question is of interest to others as well, please add an entry to the 
Wiki!

maillist : ntg-context@ntg.nl / http://www.ntg.nl/mailman/listinfo/ntg-context
webpage  : http://www.pragma-ade.nl / http://tex.aanhet.net
archive  : http://foundry.supelec.fr/projects/contextrev/
wiki : http://contextgarden.net
___

Re: [NTG-context] Ligatures in EB Garamond

2016-01-18 Thread Jan U. Hasecke
Hi Georg,

thank you very much for this insight. I really like the EB Garamond.
It's a wonderful typeface for reading. I used it to typeset books with
more than 500 pages together with lualatex and the selnolig package
which produced good results with no effort.

I was disappointed to learn that there is no package like selnolig for
ConTeXt but the book I am now typesetting is only 120 pages long and
I'll switch ligatures off manually with the ZWNJ replacement. (The
ConTeXt notation is a bit uncomfortable, but as I only have to use it
once...)

I only found one issue with ZWNJ. It splits up the words so that they
are not found by the search.

If ZWNJ is the right way to do it, I'll start a tiny project on Github
with a replacement file.

First time I hear about the new keyboard layout. I think I want my T2
keyboard now! ;-)

juh

Am 18.01.2016 um 23:38 schrieb Georg Duffner:
> Hi Jan, hi Hans,
> 
> This is the developer of EB Garamond. I’m only now and then reading this
> list so I only learnt about your troubles now.
> 
> The way the ligatures are composed simplifies the creation of more
> ligatures after the same scheme while not blowing up the font by having
> to create one glyph per ligature combination but only one per component.
> In fact, it’s not just kerning, like Hans said, but one-by-one glyph
> substitutions. It might be seen as inconsistency that one feature can be
> executed in different ways. I know of that problem but it’s not that
> inconsistent at user level if you use the methods intended by unicode
> and opentype to deal with breaking up ligatures. The symbol ZWNJ (zero
> width non joiner) is exactly meant to do this so if you insert it, you
> should get what you want. What’s more, by inserting ZWNJ you should also
> be able to benefit from kerning between the non ligated f and the
> following letter or from contextual alternate forms that fit better than
> the long bowed f, if you want that. With EB Garamond, this should be
> true for both, engines that handle ZWNJ correctly or not.
> 
> By the way, the newly standardized German keyboard layout even has the
> ZWNJ on it and the norm recommends its use to prevent ligation.
> 
> Best regards
> Georg Duffner
> 
> Am 18.01.2016 um 11:09 schrieb Hans Hagen:
>   > On 1/18/2016 10:16 AM, Jan U. Hasecke wrote:
>>> Am 17.01.2016 um 20:05 schrieb Hans Hagen:
 On 1/16/2016 3:58 PM, Jan U. Hasecke wrote:
> Am 16.01.2016 um 13:31 schrieb Schmitz Thomas A.:
>>
>> Please provide a minimal example of your problem. It’s impossible to
>> help when we have no clue what you’re doing.
>
> Sorry, of course.
>
> After setting up a mwe I found that it is a font related issue.
>
> When I don't specify a font, it works. --> example.tex
>
> When I choose EB Garamond, it does not work. -- example-Garamond.tex
>
> I confirmed this behaviour in my real setup.

 don't assume that ligatures are always real ligatures ... in that font
 it's just kerning .. this kind of works okay:

 \replaceword[sellig][auflösen][auf{-}{}{\zwnj}lösen]
>>>
>>> I am confused as the specimen of EB Garamond mentions (real) ligatures.
>>> They are listed as glyphs.
>>>
>>> https://github.com/georgd/EB-Garamond/blob/master/specimen/Specimen.pdf
>>
>> maybe the archaic st ligature is a precomposed but f f l i aren't done
>> that way but by either kerning or replacement of individual glyphs +
>> kerning (there are many methods for this) ... also, 'liga' might mean
>> ligature but in practice is used for all kind of things ... in opentype
>> 'ligature substitution' is just a many-to-one replacement but that
>> doesn't mean that 'liga' uses that ... welcome to the inconsistent open
>> type mess
>>
> 
> Mh, yes. :-(
> 
> Two additional questions. Shall I file a bugreport for this issue? What
> would be the right words: please provide real ligature glyphs instead of
> composed ones?
> 
> EB Garamond is a free font also in the sense free of charge. But what
> can I expect when I buy a commercial font? I would be quite annoyed when
> I buy a font which does not provide the features in a way that I can use
> them in ConTeXt.
> 
> Is there a font quality page on the Wiki with a feature comparison?
> 
> juh
> 
> 
> 

___
If your question is of interest to others as well, please add an entry to the 
Wiki!

maillist : ntg-context@ntg.nl / http://www.ntg.nl/mailman/listinfo/ntg-context
webpage  : http://www.pragma-ade.nl / http://tex.aanhet.net
archive  : http://foundry.supelec.fr/projects/contextrev/
wiki : http://contextgarden.net
___

Re: [NTG-context] Ligatures in EB Garamond

2016-01-18 Thread Georg Duffner
Hi Jan, hi Hans,

This is the developer of EB Garamond. I’m only now and then reading this
list so I only learnt about your troubles now.

The way the ligatures are composed simplifies the creation of more
ligatures after the same scheme while not blowing up the font by having
to create one glyph per ligature combination but only one per component.
In fact, it’s not just kerning, like Hans said, but one-by-one glyph
substitutions. It might be seen as inconsistency that one feature can be
executed in different ways. I know of that problem but it’s not that
inconsistent at user level if you use the methods intended by unicode
and opentype to deal with breaking up ligatures. The symbol ZWNJ (zero
width non joiner) is exactly meant to do this so if you insert it, you
should get what you want. What’s more, by inserting ZWNJ you should also
be able to benefit from kerning between the non ligated f and the
following letter or from contextual alternate forms that fit better than
the long bowed f, if you want that. With EB Garamond, this should be
true for both, engines that handle ZWNJ correctly or not.

By the way, the newly standardized German keyboard layout even has the
ZWNJ on it and the norm recommends its use to prevent ligation.

Best regards
Georg Duffner

Am 18.01.2016 um 11:09 schrieb Hans Hagen:
> On 1/18/2016 10:16 AM, Jan U. Hasecke wrote:
>> Am 17.01.2016 um 20:05 schrieb Hans Hagen:
>>> On 1/16/2016 3:58 PM, Jan U. Hasecke wrote:
 Am 16.01.2016 um 13:31 schrieb Schmitz Thomas A.:
>
> Please provide a minimal example of your problem. It’s impossible to
> help when we have no clue what you’re doing.

 Sorry, of course.

 After setting up a mwe I found that it is a font related issue.

 When I don't specify a font, it works. --> example.tex

 When I choose EB Garamond, it does not work. -- example-Garamond.tex

 I confirmed this behaviour in my real setup.
>>>
>>> don't assume that ligatures are always real ligatures ... in that font
>>> it's just kerning .. this kind of works okay:
>>>
>>> \replaceword[sellig][auflösen][auf{-}{}{\zwnj}lösen]
>>
>> I am confused as the specimen of EB Garamond mentions (real) ligatures.
>> They are listed as glyphs.
>>
>> https://github.com/georgd/EB-Garamond/blob/master/specimen/Specimen.pdf
>
> maybe the archaic st ligature is a precomposed but f f l i aren't done
> that way but by either kerning or replacement of individual glyphs +
> kerning (there are many methods for this) ... also, 'liga' might mean
> ligature but in practice is used for all kind of things ... in opentype
> 'ligature substitution' is just a many-to-one replacement but that
> doesn't mean that 'liga' uses that ... welcome to the inconsistent open
> type mess
>

Mh, yes. :-(

Two additional questions. Shall I file a bugreport for this issue? What
would be the right words: please provide real ligature glyphs instead of
composed ones?

EB Garamond is a free font also in the sense free of charge. But what
can I expect when I buy a commercial font? I would be quite annoyed when
I buy a font which does not provide the features in a way that I can use
them in ConTeXt.

Is there a font quality page on the Wiki with a feature comparison?

juh



-- 
EB Garamond: http://www.georgduffner.at/ebgaramond
___
If your question is of interest to others as well, please add an entry to the 
Wiki!

maillist : ntg-context@ntg.nl / http://www.ntg.nl/mailman/listinfo/ntg-context
webpage  : http://www.pragma-ade.nl / http://tex.aanhet.net
archive  : http://foundry.supelec.fr/projects/contextrev/
wiki : http://contextgarden.net
___