ntg-context - mailing list for ConTeXt users
 help / color / mirror / Atom feed
* ∫ is not displayed correctly compared to $\int$.
@ 2011-06-12 13:06 Paul Menzel
  2011-06-12 21:52 ` Mojca Miklavec
  0 siblings, 1 reply; 7+ messages in thread
From: Paul Menzel @ 2011-06-12 13:06 UTC (permalink / raw)
  To: ntg-context


[-- Attachment #1.1.1: Type: text/plain, Size: 472 bytes --]

Dear ConTeXt folks,


using

ConTeXt  ver: 2011.05.18 22:26 MKIV  fmt: 2011.5.27  int: english/english

the following example produces different integral signs.

--- minimal example ---
\starttext
Using the NEO keyboard layout several math symbols can be inserted directly like $∫$ or $∩$.

But $\int$ and $∫$ look differently.
\stoptext
--- minimal example ---

Please find all files attached.


Thanks,

Paul


[1] http://neo-layout.org/

[-- Attachment #1.1.2: int.pdf --]
[-- Type: application/pdf, Size: 13196 bytes --]

[-- Attachment #1.1.3: int.tex --]
[-- Type: text/x-tex, Size: 163 bytes --]

\starttext
Using the NEO keyboard layout several math symbols can be inserted directly like $∫$ or $∩$.

But $\int$ and $∫$ look differently.
\stoptext

[-- Attachment #1.2: This is a digitally signed message part --]
[-- Type: application/pgp-signature, Size: 198 bytes --]

[-- Attachment #2: Type: text/plain, Size: 485 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
___________________________________________________________________________________

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

* Re:  ∫ is not displayed correctly compared to $\int$.
  2011-06-12 13:06 ∫ is not displayed correctly compared to $\int$ Paul Menzel
@ 2011-06-12 21:52 ` Mojca Miklavec
  2011-12-11 11:44   ` ∫ and $\intop$ " Paul Menzel
  0 siblings, 1 reply; 7+ messages in thread
From: Mojca Miklavec @ 2011-06-12 21:52 UTC (permalink / raw)
  To: mailing list for ConTeXt users

On Sun, Jun 12, 2011 at 15:06, Paul Menzel wrote:
> Dear ConTeXt folks,
>
> using
>
> ConTeXt  ver: 2011.05.18 22:26 MKIV  fmt: 2011.5.27  int: english/english
>
> the following example produces different integral signs.
>
> --- minimal example ---
> \starttext
> Using the NEO keyboard layout several math symbols can be inserted directly like $∫$ or $∩$.
>
> But $\int$ and $∫$ look differently.
> \stoptext
> --- minimal example ---

However the character ∫ looks the same as \intop and ∫\nolimits looks
the same as \int.

As to why \intop looks so weird, I have no idea. If you add
    \usetypescript[modern-base] \setupbodyfont[modern]
it will work ok. Cambria Math also results in two different heights of
the operator depending on whether limits are there or not. It might be
a bug somewhere in virtual font setup of LM. In pdfTeX \int and \intop
operators are positioned equally.

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

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

* Re:  ∫ and $\intop$ is not displayed correctly compared to $\int$.
  2011-06-12 21:52 ` Mojca Miklavec
@ 2011-12-11 11:44   ` Paul Menzel
  2011-12-11 12:28     ` Philipp A.
  0 siblings, 1 reply; 7+ messages in thread
From: Paul Menzel @ 2011-12-11 11:44 UTC (permalink / raw)
  To: ntg-context


[-- Attachment #1.1.1: Type: text/plain, Size: 4047 bytes --]

[My former message was not delivered and awaits moderator approval
because it is bigger than 64 KB. I removed the PDF output using XITS.]

Am Sonntag, den 12.06.2011, 23:52 +0200 schrieb Mojca Miklavec:
> On Sun, Jun 12, 2011 at 15:06, Paul Menzel wrote:

> > ConTeXt  ver: 2011.05.18 22:26 MKIV  fmt: 2011.5.27  int: english/english
> >
> > the following example produces different integral signs.
> >
> > --- minimal example ---
> > \starttext
> > Using the NEO keyboard layout several math symbols can be inserted directly like $∫$ or $∩$.
> >
> > But $\int$ and $∫$ look differently.
> > \stoptext
> > --- minimal example ---

I just wanted to bring this topic up again since it is still
reproducible with ConTeXt MKIV 2011.11.25 21:29.

> However the character ∫ looks the same as \intop and ∫\nolimits looks
> the same as \int.

Yes, it does.

> As to why \intop looks so weird, I have no idea. If you add
>     \usetypescript[modern-base] \setupbodyfont[modern]
> it will work ok. Cambria Math also results in two different heights of
> the operator depending on whether limits are there or not. It might be
> a bug somewhere in virtual font setup of LM. In pdfTeX \int and \intop
> operators are positioned equally.

Using XITS it does also work although in display math mode(?) ∫ and
$\intop$ are not scaled.

I use the following example.

        \setupbodyfont[xits]
        
        \setupinteraction[state=start]
        
        \useurl[context2008][http://wiki.contextgarden.net/Context_2008.04.10][][\ConTeXt\ version 4/10/2008]
        
        \starttext
        Using the NEO keyboard layout several math symbols can be inserted directly like $∫$ or $∩$.
        
        But $\int$ by \type{\int} and $∫$ by UTF-8 character look differently. As Mojca pointed out \type{\intop} is also not type set correctly: $\intop$. This suggests that it is a problem with the Latin Modern font. \type{\intop} was added in \from[context2008].
        
        \blank
        
        • Using UTF-8 character:
        \startformula
          ∫_ℝ dx = ∞
        \stopformula
        
        • Using UTF-8 character with \type{\nolimits}:
        \startformula
          ∫\nolimits_ℝ dx = ∞
        \stopformula
        
        • Using \type{\intop}:
        \startformula
          \intop_ℝ dx = ∞
        \stopformula
        
        • Using \type{\intop\nolimits} does not work.
        \startformula
          \intop\nolimits_ℝ dx = ∞
        \stopformula
        
        • Using \type{\int}:
        \startformula
          \int_ℝ dx = ∞
        \stopformula
        
        • Using \type{\int_\limits_a}:
        \startformula
          \int\limits_a dx = ∞
        \stopformula
        
        \blank
        \CONTEXT\ \contextmark\ \contextversion
        \stoptext

Is there a chance to fix `\intop` in Latin Modern (and XITS).

Would it be a good idea to map ∫ to $\int$ instead of `\intop`? Do
people use `\intop` a lot?


Thanks,

Paul


PS: Although this seems font related, some more information just in
case. ∫ has the Unicode number(?) #222B [1] and `xev` returns the
following.

        KeyPress event, serial 33, synthetic NO, window 0x4c00001,
            root 0x102, subw 0x0, time 340829925, (244,21), root:(256,134),
            state 0x4000, keycode 39 (keysym 0x8bf, integral), same_screen YES,
            XLookupString gives 3 bytes: (e2 88 ab) "∫"
            XmbLookupString gives 3 bytes: (e2 88 ab) "∫"
            XFilterEvent returns: False
        
        KeyRelease event, serial 33, synthetic NO, window 0x4c00001,
            root 0x102, subw 0x0, time 340829989, (244,21), root:(256,134),
            state 0x4000, keycode 39 (keysym 0x8bf, integral), same_screen YES,
            XLookupString gives 3 bytes: (e2 88 ab) "∫"
            XFilterEvent returns: False

[1] http://unicode.org/charts/nameslist/n_2200.html


[-- Attachment #1.1.2: int.tex --]
[-- Type: text/x-tex, Size: 1156 bytes --]

\setupbodyfont[xits]

\setupinteraction[state=start]

\useurl[context2008][http://wiki.contextgarden.net/Context_2008.04.10][][\ConTeXt\ version 4/10/2008]

\starttext
Using the NEO keyboard layout several math symbols can be inserted directly like $∫$ or $∩$.

But $\int$ by \type{\int} and $∫$ by UTF-8 character look differently. As Mojca pointed out \type{\intop} is also not type set correctly: $\intop$. This suggests that it is a problem with the Latin Modern font. \type{\intop} was added in \from[context2008].

\blank

• Using UTF-8 character:
\startformula
  ∫_ℝ dx = ∞
\stopformula

• Using UTF-8 character with \type{\nolimits}:
\startformula
  ∫\nolimits_ℝ dx = ∞
\stopformula

• Using \type{\intop}:
\startformula
  \intop_ℝ dx = ∞
\stopformula

• Using \type{\intop\nolimits} does not work.
\startformula
  \intop\nolimits_ℝ dx = ∞
\stopformula

• Using \type{\int}:
\startformula
  \int_ℝ dx = ∞
\stopformula

• Using \type{\int_\limits_a}:
\startformula
  \int\limits_a dx = ∞
\stopformula

\blank
\CONTEXT\ \contextmark\ \contextversion
\stoptext

[-- Attachment #1.1.3: int_latin-modern.pdf --]
[-- Type: application/pdf, Size: 32896 bytes --]

[-- Attachment #1.2: This is a digitally signed message part --]
[-- Type: application/pgp-signature, Size: 198 bytes --]

[-- Attachment #2: Type: text/plain, Size: 485 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
___________________________________________________________________________________

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

* Re:  ∫ and $\intop$ is not displayed correctly compared to $\int$.
  2011-12-11 11:44   ` ∫ and $\intop$ " Paul Menzel
@ 2011-12-11 12:28     ` Philipp A.
  2011-12-11 12:54       ` Paul Menzel
  2011-12-11 14:02       ` Aditya Mahajan
  0 siblings, 2 replies; 7+ messages in thread
From: Philipp A. @ 2011-12-11 12:28 UTC (permalink / raw)
  To: mailing list for ConTeXt users


[-- Attachment #1.1: Type: text/plain, Size: 608 bytes --]

apart from this IMHO very useful change (mapping  to \int), maybe we should
create a unicode-math module which replaces some commands with symbols. i
find myself always using this for chemical and mathematical documents:

\catcode`→=\active
\def→{\xrightarrow}
\catcode`↔=\active
\def↔{\xleftrightarrow}
\catcode`√=\active
\def√{\sqrt}

PS: i recently posted two questions to this list which i got no
replies to:“simplefonts: math in headers” and“headers:
numberconversion=something or \definestructureconversionset”

do you see them or did they get lost in transmission?

[-- Attachment #1.2: Type: text/html, Size: 703 bytes --]

[-- Attachment #2: Type: text/plain, Size: 485 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
___________________________________________________________________________________

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

* Re:  ∫ and $\intop$ is not displayed correctly compared to $\int$.
  2011-12-11 12:28     ` Philipp A.
@ 2011-12-11 12:54       ` Paul Menzel
  2011-12-11 14:02       ` Aditya Mahajan
  1 sibling, 0 replies; 7+ messages in thread
From: Paul Menzel @ 2011-12-11 12:54 UTC (permalink / raw)
  To: ntg-context


[-- Attachment #1.1: Type: text/plain, Size: 1353 bytes --]

Am Sonntag, den 11.12.2011, 13:28 +0100 schrieb Philipp A.:
> apart from this IMHO very useful change (mapping  to \int), maybe we should
> create a unicode-math module which replaces some commands with symbols.

Do you mean symbols by commands?

> i find myself always using this for chemical and mathematical documents:
> 
> \catcode`→=\active
> \def→{\xrightarrow}
> \catcode`↔=\active
> \def↔{\xleftrightarrow}
> \catcode`√=\active
> \def√{\sqrt}

Sorry for being a noob. I thought for the first three that is somehow
done already. If not, such a mechanism would indeed be useful.

> PS: i recently posted two questions to this list which i got no
> replies to:“simplefonts: math in headers” and“headers:
> numberconversion=something or \definestructureconversionset”
> 
> do you see them or did they get lost in transmission?

The message were delivered to the subscribers. You can also check that
in the archive [1]. We just have to be patient. I hope Wolfgang is not
sick/ill and is doing fine by being on vacation or something similar.

PPS: Do you also use the Neo layout [4]?


[1] http://www.ntg.nl/pipermail/ntg-context/2011/thread.html
[2] http://www.ntg.nl/pipermail/ntg-context/2011/063723.html
[3] http://www.ntg.nl/pipermail/ntg-context/2011/063739.html
[4] http://neo-layout.org/

[-- Attachment #1.2: This is a digitally signed message part --]
[-- Type: application/pgp-signature, Size: 198 bytes --]

[-- Attachment #2: Type: text/plain, Size: 485 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
___________________________________________________________________________________

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

* Re:  ∫ and $\intop$ is not displayed correctly compared to $\int$.
  2011-12-11 12:28     ` Philipp A.
  2011-12-11 12:54       ` Paul Menzel
@ 2011-12-11 14:02       ` Aditya Mahajan
  2011-12-11 16:05         ` Philipp A.
  1 sibling, 1 reply; 7+ messages in thread
From: Aditya Mahajan @ 2011-12-11 14:02 UTC (permalink / raw)
  To: mailing list for ConTeXt users

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

On Sun, 11 Dec 2011, Philipp A. wrote:

> apart from this IMHO very useful change (mapping  to \int), maybe we should
> create a unicode-math module which replaces some commands with symbols. i
> find myself always using this for chemical and mathematical documents:
>
> \catcode`→=\active
> \def→{\xrightarrow}
> \catcode`↔=\active
> \def↔{\xleftrightarrow}
> \catcode`√=\active
> \def√{\sqrt}

Have a look at char-def.lua. All the symbol mappings are defined there. 
Please feel free to complete the table (it is a boring and time consuming 
process, and I have only managed to cover about half of the table).

Regarding your mappings, IIRC -> etc are mapped to \rightarrow etc, (not 
\xrightarrow). We can talk about including style variants for the 
mappings.

Aditya

[-- Attachment #2: Type: text/plain, Size: 485 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
___________________________________________________________________________________

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

* Re:  ∫ and $\intop$ is not displayed correctly compared to $\int$.
  2011-12-11 14:02       ` Aditya Mahajan
@ 2011-12-11 16:05         ` Philipp A.
  0 siblings, 0 replies; 7+ messages in thread
From: Philipp A. @ 2011-12-11 16:05 UTC (permalink / raw)
  To: mailing list for ConTeXt users


[-- Attachment #1.1: Type: text/plain, Size: 1065 bytes --]

wow, there is really much magic going on in context. one reason why i love
it.

i once wrote a script that showed some nice little gui for a similar file
(i.e. xkb/symbols/??) that displayed the characters on a grid similar to
the keyboard layout and allowed displaying of the different layers. i used
it to customize the standard ubuntu keyboard layout to have some much-used
symbols, but haven’t really got around to try switching to another layout
than quertz (as it would tie me even stronger to my own pc and would take
significant time to master)

maybe it would be nice to have a similar program that displays the mappings
in the char-def.lua since i can’t search for the symbols directly, have no
overview and editing would involve looking up the codes or names in a char
map, finding it in the file, and so on.

xrightarrow and friends are nice, because they adjust their length to the
over-and underscripts and work without parameters, too. so $A → B →{woo} C$
would work flawlessly and look nice both in code and the document.

[-- Attachment #1.2: Type: text/html, Size: 1073 bytes --]

[-- Attachment #2: Type: text/plain, Size: 485 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
___________________________________________________________________________________

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

end of thread, other threads:[~2011-12-11 16:05 UTC | newest]

Thread overview: 7+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2011-06-12 13:06 ∫ is not displayed correctly compared to $\int$ Paul Menzel
2011-06-12 21:52 ` Mojca Miklavec
2011-12-11 11:44   ` ∫ and $\intop$ " Paul Menzel
2011-12-11 12:28     ` Philipp A.
2011-12-11 12:54       ` Paul Menzel
2011-12-11 14:02       ` Aditya Mahajan
2011-12-11 16:05         ` Philipp A.

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).