Hi all, I know I can break ligatures with \/, like Auf\/lage, but is there a general dictionary approach, like \hyphenation{} ? Greetlings, Hraban --- http://www.fiee.net http://wiki.contextgarden.net GPG Key ID 1C9B22FD
On 27 September 2017 at 13:09, Henning Hraban Ramm
I know I can break ligatures with \/, like Auf\/lage, but is there a general dictionary approach, like \hyphenation{} ?
That's a nice idea. If something like that existed, it could be used to change 's' to 'ſ' in relevant places, too. Thomas -- Thomas Widmann Director Complexli Limited +44 789 444 3009
On 09/27/2017 02:16 PM, Thomas Widmann wrote:
That's a nice idea. If something like that existed, it could be used to change 's' to 'ſ' in relevant places, too.
This exists, see here: https://www.mail-archive.com/ntg-context@ntg.nl/msg79381.html
There is a LuaLaTeX-package "selnolig" to achieve this goal. Its wordlists and rules could probably be adapted. There is also a thorough discussion of this challenge in the documentation. https://www.ctan.org/pkg/selnolig Best regards, Florian ____________________________________________ Florian Grammel Copenhagen, Denmark
Am 2017-09-27 um 15:39 schrieb Thomas A. Schmitz
On 09/27/2017 02:16 PM, Thomas Widmann wrote:
That's a nice idea. If something like that existed, it could be used to change 's' to 'ſ' in relevant places, too.
This exists, see here: https://www.mail-archive.com/ntg-context@ntg.nl/msg79381.html
Thank you for the suggestion. I tried \replaceword[eka][Auflage][Au{fl}age] \setreplacements[eka] and even converted the german wordlist from the selnolig package, but it doesn’t help. If I try \replaceword[eka][Auflage][Au\noligature{fl}age] I get a literal "Au noligature fl age" in my text. Simply Au\noligature{fl}age doesn’t help either. My active features are: \definefontfeature[default] [mode=node,liga=yes,kern=yes,tlig=yes, ccmp=yes,language=dflt, protrusion=quality, expansion=quality] Greetlings, Hraban --- http://www.fiee.net http://wiki.contextgarden.net GPG Key ID 1C9B22FD
Am 27.09.2017 um 22:25 schrieb Henning Hraban Ramm:
Am 2017-09-27 um 15:39 schrieb Thomas A. Schmitz
: On 09/27/2017 02:16 PM, Thomas Widmann wrote:
That's a nice idea. If something like that existed, it could be used to change 's' to 'ſ' in relevant places, too.
This exists, see here: https://www.mail-archive.com/ntg-context@ntg.nl/msg79381.html
Thank you for the suggestion. I tried
\replaceword[eka][Auflage][Au{fl}age] \setreplacements[eka]
and even converted the german wordlist from the selnolig package, but it doesn’t help. If I try \replaceword[eka][Auflage][Au\noligature{fl}age] I get a literal "Au noligature fl age" in my text.
Simply Au\noligature{fl}age doesn’t help either.
My active features are: \definefontfeature[default] [mode=node,liga=yes,kern=yes,tlig=yes, ccmp=yes,language=dflt, protrusion=quality, expansion=quality]
\definefontfeature[default] [mode=node,liga=yes,kern=yes,tlig=yes, ccmp=yes,language=dflt, protrusion=quality, expansion=quality] \replaceword[eka][Auflage][Au{fl}age] \starttext Auflage Au\noligature{fl}age \setreplacements[eka] Auflage \stoptext no problem here, first with ligature the other two without Herbert
Greetlings, Hraban --- http://www.fiee.net http://wiki.contextgarden.net GPG Key ID 1C9B22FD
___________________________________________________________________________________ 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://context.aanhet.net archive : https://bitbucket.org/phg/context-mirror/commits/ wiki : http://contextgarden.net ___________________________________________________________________________________
Am 2017-09-27 um 23:02 schrieb Herbert Voss
Thank you for the suggestion. I tried \replaceword[eka][Auflage][Au{fl}age] \setreplacements[eka] and even converted the german wordlist from the selnolig package, but it doesn’t help. If I try \replaceword[eka][Auflage][Au\noligature{fl}age] I get a literal "Au noligature fl age" in my text. Simply Au\noligature{fl}age doesn’t help either. My active features are: \definefontfeature[default] [mode=node,liga=yes,kern=yes,tlig=yes, ccmp=yes,language=dflt, protrusion=quality, expansion=quality]
\definefontfeature[default] [mode=node,liga=yes,kern=yes,tlig=yes, ccmp=yes,language=dflt, protrusion=quality, expansion=quality]
\replaceword[eka][Auflage][Au{fl}age]
\starttext Auflage Au\noligature{fl}age \setreplacements[eka] Auflage \stoptext
no problem here, first with ligature the other two without
Yes, today it works. Thank you! Didn’t change anything. Strange. Greetlings, Hraban --- http://www.fiee.net http://wiki.contextgarden.net GPG Key ID 1C9B22FD
On 09/27/2017 10:25 PM, Henning Hraban Ramm wrote:
Thank you for the suggestion. I tried
\replaceword[eka][Auflage][Au{fl}age] \setreplacements[eka]
and even converted the german wordlist from the selnolig package, but it doesn’t help.
Works here. You'll have to make a real example. Thomas
On 9/27/2017 11:08 PM, Thomas A. Schmitz wrote:
On 09/27/2017 10:25 PM, Henning Hraban Ramm wrote:
Thank you for the suggestion. I tried
\replaceword[eka][Auflage][Au{fl}age] \setreplacements[eka]
and even converted the german wordlist from the selnolig package, but it doesn’t help.
Works here. You'll have to make a real example. I'll add an extra (simple) definition format:
\replaceword [eka] [Au{fl}age Shiff{f}ahrt] I leave it to others to collect (reasonable) lists of words. We can these to the distribution then. ----------------------------------------------------------------- Hans Hagen | PRAGMA ADE Ridderstraat 27 | 8061 GH Hasselt | The Netherlands tel: 038 477 53 69 | www.pragma-ade.nl | www.pragma-pod.nl -----------------------------------------------------------------
Hi Hraban, I am afraid that \/ will break not only the ligature but moreover it will erase the possible breakpoint between f and l. From this point of view, Auf{}lage seems better. General approach might be connected with font some features as Hans shown at ConTeXt Meeting this year. I recorded this case into the list of things we have to keep in mind for testing of free fonts. Best wishes, Tomas Wed, Sep 27, 2017 ve 02:09:50PM +0200 Henning Hraban Ramm napsal(a): # Hi all, # # I know I can break ligatures with \/, like Auf\/lage, but is there a general dictionary approach, like \hyphenation{} ? # # # Greetlings, Hraban # --- # http://www.fiee.net # http://wiki.contextgarden.net # GPG Key ID 1C9B22FD # # ___________________________________________________________________________________ # 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://context.aanhet.net # archive : https://bitbucket.org/phg/context-mirror/commits/ # wiki : http://contextgarden.net # ___________________________________________________________________________________ Tomáš Hála -------------------------------------------------------------------- Mendelova univerzita, Provozně ekonomická fakulta, ústav informatiky Zemědělská 1, CZ-613 00 Brno, tel. +420 545 13 22 28 -------------------------------------------------------------------- http://akela.mendelu.cz/~thala
Am Wed, 27 Sep 2017 15:10:33 +0200 schrieb Tomas Hala:
From this point of view, Auf{}lage seems better.
This doesn't prevent the ligature: \starttext Auflage Auf{}lage Auf\/lage \stoptext This also documented: "The most important change is that adding a brace group in the middle of a word (like in of{}fice) does not prevent ligature creation." With pdftex it does avoid ligatures, but not reliably. There are cases where the brace group disappear when pdftex tries out hyphenation points. -- Ulrike Fischer http://www.troubleshooting-tex.de/
On 9/27/2017 5:53 PM, Ulrike Fischer wrote:
Am Wed, 27 Sep 2017 15:10:33 +0200 schrieb Tomas Hala:
From this point of view, Auf{}lage seems better.
This doesn't prevent the ligature:
\starttext
Auflage Auf{}lage Auf\/lage
\stoptext
This also documented: "The most important change is that adding a brace group in the middle of a word (like in of{}fice) does not prevent ligature creation."
With pdftex it does avoid ligatures, but not reliably. There are cases where the brace group disappear when pdftex tries out hyphenation points. in traditional tex hyphenation is integrated in the par builder which comes after ligaturing and kerning and tex only hyphenated where it 'makes sense' and in the process (multi-pass, going into disc nodes) it will consult (deconstruct / reconstruct) ligatures and at that point it's not known that the input had a {}. Tricks like inserting something in between is also unreliable when done at the wrong time and it can also prevent for instance kerns of hyphenation.
Anyway, in addition to Thomas answer ... we already have this \blockligatures[fi,ff] \blockligatures[fl] \blockligatures[u:fl:age] \definefontfeature[default:nolig][default][blockligatures=yes] \startTEXpage[offset=1em] \definedfont[Serif*default:nolig] fi ff fl auflage \definedfont[Serif*default] fi ff fl auflage \stopTEXpage The \blockligatures[u:fl:age] is new and something of a joke experiment ... I can probably come up with a real advanced and robust mechanism if motivated enough Hans ----------------------------------------------------------------- Hans Hagen | PRAGMA ADE Ridderstraat 27 | 8061 GH Hasselt | The Netherlands tel: 038 477 53 69 | www.pragma-ade.nl | www.pragma-pod.nl -----------------------------------------------------------------
Am 2017-09-27 um 18:13 schrieb Hans Hagen
Anyway, in addition to Thomas answer ... we already have this
\blockligatures[fi,ff] \blockligatures[fl] \blockligatures[u:fl:age]
\definefontfeature[default:nolig][default][blockligatures=yes]
\startTEXpage[offset=1em] \definedfont[Serif*default:nolig] fi ff fl auflage \definedfont[Serif*default] fi ff fl auflage \stopTEXpage
The \blockligatures[u:fl:age] is new and something of a joke experiment ... I can probably come up with a real advanced and robust mechanism if motivated enough
Thank you, I tried it, and while blocking ligatures generally works (\blockligatures[fl]), the selective blocking (\blockligatures[u:fl:age]) doesn’t change anything. Do you have this only in your local version? Greetlings, Hraban --- http://www.fiee.net http://wiki.contextgarden.net GPG Key ID 1C9B22FD
On 09/27/2017 10:27 PM, Henning Hraban Ramm wrote:
Am 2017-09-27 um 18:13 schrieb Hans Hagen
: [...] The \blockligatures[u:fl:age] is new and something of a joke experiment ... I can probably come up with a real advanced and robust mechanism if motivated enough
Thank you, I tried it, and while blocking ligatures generally works (\blockligatures[fl]), the selective blocking (\blockligatures[u:fl:age]) doesn’t change anything. Do you have this only in your local version?
Hi Hraban, using latest beta (from 2017.09.25 19:19), the following sample works: \starttext \blockligatures[fi,ff] \blockligatures[fl] \blockligatures[u:fl:age, u:fl:eg] \definefontfeature[default:b][default][blockligatures=yes] \setupbodyfont[times]\showfontkerns \startTEXpage[offset=1em] fi ff fl Auflage auflegt \definedfont[Serif*default:b] fi ff fl Auflage auflegt \stopTEXpage \stoptext Just in case it helps, Pablo -- http://www.ousia.tk
Am 28.09.2017 um 08:40 schrieb Pablo Rodriguez:
using latest beta (from 2017.09.25 19:19), the following sample works:
\starttext \blockligatures[fi,ff] \blockligatures[fl] \blockligatures[u:fl:age, u:fl:eg]
\definefontfeature[default:b][default][blockligatures=yes]
\setupbodyfont[times]\showfontkerns
\startTEXpage[offset=1em] fi ff fl Auflage auflegt
\definedfont[Serif*default:b] fi ff fl Auflage auflegt
How do you catch "Aufl." (the abbreviation of Auflage), which is written _with_ a ligature? Herbert
\stopTEXpage \stoptext
Just in case it helps,
Pablo
On 09/28/2017 09:17 AM, Herbert Voss wrote:
Am 28.09.2017 um 08:40 schrieb Pablo Rodriguez:
using latest beta (from 2017.09.25 19:19), the following sample works: [...] How do you catch "Aufl." (the abbreviation of Auflage), which is written _with_ a ligature?
Herbert, I overlooked that \blockligatures[u:fl:age, u:fl:eg] only works if there is also a \blockligatures[fl]. Hans, is this a bug or is it intended? Pablo -- http://www.ousia.tk
On 9/28/2017 1:51 PM, Pablo Rodriguez wrote:
On 09/28/2017 09:17 AM, Herbert Voss wrote:
Am 28.09.2017 um 08:40 schrieb Pablo Rodriguez:
using latest beta (from 2017.09.25 19:19), the following sample works: [...] How do you catch "Aufl." (the abbreviation of Auflage), which is written _with_ a ligature?
Herbert,
I overlooked that \blockligatures[u:fl:age, u:fl:eg] only works if there is also a \blockligatures[fl].
Hans, is this a bug or is it intended? do you indeed use the latest beta? anyway, the \replaceword mechanism is a bit more flexible and efficient
Hans ----------------------------------------------------------------- Hans Hagen | PRAGMA ADE Ridderstraat 27 | 8061 GH Hasselt | The Netherlands tel: 038 477 53 69 | www.pragma-ade.nl | www.pragma-pod.nl -----------------------------------------------------------------
On 09/28/2017 03:54 PM, Hans Hagen wrote:
On 9/28/2017 1:51 PM, Pablo Rodriguez wrote:
[...] I overlooked that \blockligatures[u:fl:age, u:fl:eg] only works if there is also a \blockligatures[fl].
Hans, is this a bug or is it intended? do you indeed use the latest beta? anyway, the \replaceword mechanism is a bit more flexible and efficient
Hans, after updating to latest beta (from 2017.09.25 19:19 to 2017.09.28 10:07 [I didn’t realize that there was a newer beta yesterday]), it works. Just in case it may be relevant, \blockligatures[u:fl:age] blocks ligatures in auflegt and Aufl. Minimal sample: \starttext \blockligatures[u:fl:age] \definefontfeature[default:b][default][blockligatures=yes] \setupbodyfont[times]\showfontkerns \startTEXpage[offset=1em] fl Auflage auflegt Aufl. \definedfont[Serif*default:b] fl Auflage auflegt Aufl. \stopTEXpage \stoptext Pablo -- http://www.ousia.tk
Am 27.09.2017 um 14:09 schrieb Henning Hraban Ramm:
I know I can break ligatures with \/, like Auf\/lage, but is there a general dictionary approach, like \hyphenation{} ?
https://ctan.org/tex-archive/macros/luatex/latex/selnolig is a selnolig.lua which could be used for a solution with context. A list of all german words where a ligature should be suppressed is also there. Herbert
Greetlings, Hraban --- http://www.fiee.net http://wiki.contextgarden.net GPG Key ID 1C9B22FD
___________________________________________________________________________________ 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://context.aanhet.net archive : https://bitbucket.org/phg/context-mirror/commits/ wiki : http://contextgarden.net ___________________________________________________________________________________
participants (9)
-
Florian Grammel
-
Hans Hagen
-
Henning Hraban Ramm
-
Herbert Voss
-
Pablo Rodriguez
-
Thomas A. Schmitz
-
Thomas Widmann
-
Tomas Hala
-
Ulrike Fischer