ntg-context - mailing list for ConTeXt users
 help / color / mirror / Atom feed
From: Aditya Mahajan <adityam@umich.edu>
To: mailing list for ConTeXt users <ntg-context@ntg.nl>
Subject: Re: some math symbols not working
Date: Thu, 11 Feb 2010 18:10:46 -0500 (EST)	[thread overview]
Message-ID: <alpine.LNX.2.01.1002111740430.20130@ybpnyubfg.ybpnyqbznva> (raw)
In-Reply-To: <4B6FD4ED.50704@gmx.de>

[-- Attachment #1: Type: TEXT/PLAIN, Size: 2142 bytes --]

On Mon, 8 Feb 2010, Warrence wrote:

> Hi,
> I was trying some math symbols and stumbled over the following commands, that 
> do not work in my context documents (the comments say what's not working 
> exactly). The pasted document works at http://live.contextgarden.net/ . I'm 
> using the latest context-minimals as provided on the website. Is this a MkIV 
> issue?

Yes. The mappings in MkIV are incomplete. Whenever you find a
missing symbol, send an email, and I will try to fix add it.

> \cong

The mapping in math-vfu is wrong and it was mapping the unicode slot of cong to
the glyph for dotplus. I am attaching a file that fixes this.

However, I do not know how to proceed for \cong. \cong is one of the symbols
thar are composed from other symbols in plain tex. So, most traditional tex math
fonts (including LM) do not have that symbol. However, opentype math fonts do.
Ideally, what we want to map \cong to a font glyph, if one exists; otherwise, we
should fall back to a composed character.

Hans, we need a mechanism to implement fallbacks for math characters.

> \mapsto
> \hookleftarrow
> \longleftarrow
> \Longleftarrow
> \longrightarrow
> \Longrightarrow
> \longleftrightarrow
> \Longleftrightarrow
> \longmapsto
> \hookrightarrow
> \bowtie
> \models
> \Join

Same thing as \cong.

> \blacksquare

Added

> In addition: \ncong is not aligned with = and \cong

I am not sure what \ncong should map to: 0x2246 or 0x2247? There is
inconsistency between the mappings in char-def and math-vfu which can be fixed
easily once I figure out what is the correct mapping.

> % the following give "Undefined control sequence":
> \gneq % \lneq works

Fixed.. was a typo

> \Diamond  \lozenge

I am not sure which unicode slot this should map to (0x25C7?). What is the difference
between \diamond and \Diamond?

> \lhd
> \rhd
> \unlhd
> \unrhd

I am not sure which unicode slot they should map to. In ams mappings
\triangleleft is different from \lhd, and I cannot find the right symbols for
both.

I will investigate more for the last two sets. In the mean time, Hans can you
apply the attached patch for \blacksquare and \gneq.

Aditya

[-- Attachment #2: Type: TEXT/PLAIN, Size: 1444 bytes --]

diff --git a/char-def.lua b/char-def.lua
index 3aec401..5f768e3 100644
--- a/char-def.lua
+++ b/char-def.lua
@@ -54277,6 +54277,8 @@ characters.data={
   description="NORMAL SUBGROUP OF",
   direction="on",
   linebreak="al",
+  mathspec = {
+    class="bin", mathname="triangleleft",
   mathclass="bin",
   mathname="triangleleft",
   mirror=0x22B3,
@@ -59806,6 +59808,8 @@ characters.data={
   description="BLACK SQUARE",
   direction="on",
   linebreak="ai",
+  mathclass="ord",
+  mathname="blacksquare",
   unicodeslot=0x25A0,
  },
  [0x25A1]={
@@ -68185,7 +68189,7 @@ characters.data={
   direction="on",
   linebreak="al",
   mathclass="relation",
-  mathname="rneq",
+  mathname="gneq",
   unicodeslot=0x2A88,
  },
  [0x2A89]={
diff --git a/math-vfu.lua b/math-vfu.lua
index 9b16357..a2e3b58 100644
--- a/math-vfu.lua
+++ b/math-vfu.lua
@@ -1126,7 +1126,7 @@ fonts.enc.math["tex-ma"] = {
     [0x024C7] = 0x72, -- circleR               \circledR
     [0x024C8] = 0x73, -- circleS               \circledS
     [0x022D4] = 0x74, -- fork                  \pitchfork
-    [0x02245] = 0x75, -- dotplus               \dotplus
+    [0x02214] = 0x75, -- dotplus               \dotplus
     [0x0223D] = 0x76, -- revsimilar            \backsim
     [0x022CD] = 0x77, -- revasymptequal        \backsimeq -- AM: Check this! I mapped it to simeq.
     [0x0231E] = 0x78, -- rightanglesw          \llcorner

[-- Attachment #3: Type: text/plain, Size: 486 bytes --]

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

  reply	other threads:[~2010-02-11 23:10 UTC|newest]

Thread overview: 6+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2010-02-08  9:10 Warrence
2010-02-11 23:10 ` Aditya Mahajan [this message]
2010-02-11 23:37   ` Hans Hagen
2010-02-12  3:02     ` Aditya Mahajan
2010-02-12  8:21       ` Hans Hagen
     [not found] <mailman.271.1265959988.26807.ntg-context@ntg.nl>
2010-02-12 11:35 ` Warrence

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=alpine.LNX.2.01.1002111740430.20130@ybpnyubfg.ybpnyqbznva \
    --to=adityam@umich.edu \
    --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).