ntg-context - mailing list for ConTeXt users
 help / color / mirror / Atom feed
* Consequences of \zwnj for hyphenation
@ 2020-10-14 12:09 Denis Maier
  2020-10-14 12:47 ` Hans Hagen
  2020-10-14 12:58 ` Hans Hagen
  0 siblings, 2 replies; 3+ messages in thread
From: Denis Maier @ 2020-10-14 12:09 UTC (permalink / raw)
  To: mailing list for ConTeXt users

Hi,
has \zwnj (or the equivalent unicode character) bad consequences for 
hyphenation? Like, when you'd preprocess your files and add \zwnj in 
appropriate places, will that break hyphenation for these words?
Best,
Denis
___________________________________________________________________________________
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
___________________________________________________________________________________

^ permalink raw reply	[flat|nested] 3+ messages in thread

* Re: Consequences of \zwnj for hyphenation
  2020-10-14 12:09 Consequences of \zwnj for hyphenation Denis Maier
@ 2020-10-14 12:47 ` Hans Hagen
  2020-10-14 12:58 ` Hans Hagen
  1 sibling, 0 replies; 3+ messages in thread
From: Hans Hagen @ 2020-10-14 12:47 UTC (permalink / raw)
  To: mailing list for ConTeXt users, Denis Maier

On 10/14/2020 2:09 PM, Denis Maier wrote:
> Hi,
> has \zwnj (or the equivalent unicode character) bad consequences for 
> hyphenation? Like, when you'd preprocess your files and add \zwnj in 
> appropriate places, will that break hyphenation for these words?
yes, which is why we don't want to preprocess

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
-----------------------------------------------------------------
___________________________________________________________________________________
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
___________________________________________________________________________________

^ permalink raw reply	[flat|nested] 3+ messages in thread

* Re: Consequences of \zwnj for hyphenation
  2020-10-14 12:09 Consequences of \zwnj for hyphenation Denis Maier
  2020-10-14 12:47 ` Hans Hagen
@ 2020-10-14 12:58 ` Hans Hagen
  1 sibling, 0 replies; 3+ messages in thread
From: Hans Hagen @ 2020-10-14 12:58 UTC (permalink / raw)
  To: Denis Maier, mailing list for ConTeXt users

On 10/14/2020 2:09 PM, Denis Maier wrote:
> Hi,
> has \zwnj (or the equivalent unicode character) bad consequences for 
> hyphenation? Like, when you'd preprocess your files and add \zwnj in 
> appropriate places, will that break hyphenation for these words?
So, this:

\mainlanguage[nl]

\startexceptions[nl]
wis-kun-d{e-}{o}{eo}(e-o)n-der-wijs
\stopexceptions

wiskundeonderwijs

\hsize 1mm

wiskundeonderwijs

results in

wiskunde-onderwijs

wis-
kun-
de-
on-
der-
wijs

with proper kerning and ligatures when applicable and

\startexceptions[nl]
wis-kun-d{e-}{o}{eo}(e\zwj o)n-der-wijs
\stopexceptions

will do the same but no compound dash. It's actually mostly a matter of 
communicating with the font handler (without hard coding solutions in 
the engine).

As a side effect (teaser) you can do this in the upcoming lmtx:

\definefontfeature[whatever][default][mode=base]
\definefont[myfont][Serif*whatever]

{\myfont               test effe every}\quad
{                      test effe every}\par
{\myfont \nokerning    test effe every}\quad
{        \nokerning    test effe every}\par
{\myfont \noligaturing test effe every}\quad
{        \noligaturing test effe every}\par
{\myfont               test effe e{\nokerning v}ery}\quad
{                      test effe e{\nokerning v}ery}\par

with \nokerning and \noligaturing being macros that set some options 
(the old \noligs and \nokerns have therefore been dropped) ... so one 
has local control over matters (base mode and node mode).

one can even control left/right kerning/ligaturing this way but that's 
something to be explained in some article or at some user meeting or so 
(after all i occasionally need something new to tell)

so, in the end all you have to do is come up with a list of exceptions

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
-----------------------------------------------------------------
___________________________________________________________________________________
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
___________________________________________________________________________________

^ permalink raw reply	[flat|nested] 3+ messages in thread

end of thread, other threads:[~2020-10-14 12:58 UTC | newest]

Thread overview: 3+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2020-10-14 12:09 Consequences of \zwnj for hyphenation Denis Maier
2020-10-14 12:47 ` Hans Hagen
2020-10-14 12:58 ` Hans Hagen

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).