ntg-context - mailing list for ConTeXt users
 help / color / mirror / Atom feed
From: Hans Hagen <j.hagen@xs4all.nl>
To: mailing list for ConTeXt users <ntg-context@ntg.nl>,
	Joey McCollum <jmccollum20140511@gmail.com>
Subject: Re: Unicode normalization and Hebrew in ConTeXt
Date: Tue, 28 Apr 2020 15:17:28 +0200	[thread overview]
Message-ID: <0c597527-8809-20b7-9ac9-fee80da73637@xs4all.nl> (raw)
In-Reply-To: <CAGxRUG8mR67ANkm8TSukO_hbq98wA+JWaTyCXQS-ZyPuTGErRQ@mail.gmail.com>

On 4/28/2020 1:59 PM, Joey McCollum wrote:
> \definefontfeature[f:pointedhebrew][default][
>      ccmp=yes,
>      mark=yes,
>      script=hebr
> ]
> \definefontfamily[hebrew] [rm] [SBL Hebrew] [features=f:pointedhebrew]
> %Set the body font:
> \setupbodyfont[hebrew]
> %Set up right-to-left alignment:
> \setupalign[r2l]
> \starttext
>      %Characters after normalization, in Unicode canonical order (bet + 
> segol + dagesh + final nun):
>      בֶּן
> 
>      %A word with characters in typographically recommended order (bet + 
> dagesh + segol + final nun):
>      בֶּן
> \stoptext

\startluacode
     fonts.handlers.otf.addfeature {
         name    = "normalizehebrew",
         type    = "chainsubstitution",
         prepend = 1,
         lookups = {
             {
                 type = "multiple",
                 data = {
                     [0x5B6] = { 0x5BC, 0x5B6 },
                 },
             },
         },
         data = {
             rules = {
                 {
                     current = { { 0x5B6 }, { 0x5BC } },
                     lookups = { 1, 0 },
                 },
             },
         },
     }
\stopluacode

\definefontfeature
   [f:pointedhebrew]
   [hebrew]
   [normalizehebrew=yes]

\definefontfamily[hebrew] [rm] [SBL Hebrew] [features=f:pointedhebrew]

\setupbodyfont[hebrew]

\setupalign[r2l]

\starttext
     בֶּן \quad בֶּן \par
\stoptext

How many such reorderings are there? (I saw some document about that 
font and it sounds like a bit messy wrt all these input variants.)

(there are several mechanisms in context to deal with such issues, it's 
all about getting specs from users i.e. tex is all about control so in 
principle it should be doable)

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
___________________________________________________________________________________

  reply	other threads:[~2020-04-28 13:17 UTC|newest]

Thread overview: 16+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2020-04-28 11:59 Joey McCollum
2020-04-28 13:17 ` Hans Hagen [this message]
     [not found]   ` <CAGxRUG_cyT1XfYTvTh23+LaVg4an8exL-LZYfbZUOf+s2XvRRQ@mail.gmail.com>
2020-04-28 16:16     ` Fwd: " Joey McCollum
2020-04-28 18:03       ` Hans Hagen
2020-04-28 18:21       ` Hans Hagen
2020-04-28 19:06         ` Joey McCollum
2020-04-30 19:40         ` Arthur Reutenauer
2020-04-30  9:26 ` Hans Hagen
2020-04-30 14:28   ` Joey McCollum
2020-04-30 15:14     ` Hans Hagen
2020-04-30 20:17       ` Joey McCollum
2021-08-17  0:07         ` Joey McCollum via ntg-context
2021-08-17  9:19           ` Hans Hagen via ntg-context
2021-08-17 12:56             ` Joey McCollum via ntg-context
2021-08-17 19:46               ` Joey McCollum via ntg-context
2021-08-18 13:19                 ` Hans Hagen via ntg-context

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=0c597527-8809-20b7-9ac9-fee80da73637@xs4all.nl \
    --to=j.hagen@xs4all.nl \
    --cc=jmccollum20140511@gmail.com \
    --cc=ntg-context@ntg.nl \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
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).