* Missing °C symbol in math mode with dejavu font @ 2013-05-20 20:29 Romain Diss 2013-05-20 20:57 ` Alan BRASLAU 0 siblings, 1 reply; 10+ messages in thread From: Romain Diss @ 2013-05-20 20:29 UTC (permalink / raw) To: ntg-context Hi all, The °C symbol is missing in math mode with the dejavu font. I thought that this should be handled by using the '°' + 'C' symbols instead but it is not the case. Is that a bug? What can I do to get the °C symbol with this font? %% MWE \setupbodyfont[dejavu] \starttext Temperature : \unit{100 celsius} works.\par Temperature : \m{\unit{100 celsius}} doesn't work. \stoptext -- Romain Diss <romain.diss@yahoo.fr> ___________________________________________________________________________________ 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] 10+ messages in thread
* Re: Missing °C symbol in math mode with dejavu font 2013-05-20 20:29 Missing °C symbol in math mode with dejavu font Romain Diss @ 2013-05-20 20:57 ` Alan BRASLAU 2013-05-20 21:03 ` Khaled Hosny 2013-05-20 21:04 ` Romain Diss 0 siblings, 2 replies; 10+ messages in thread From: Alan BRASLAU @ 2013-05-20 20:57 UTC (permalink / raw) To: mailing list for ConTeXt users On Mon, 20 May 2013 22:29:22 +0200 Romain Diss <romain.diss@yahoo.fr> wrote: > The °C symbol is missing in math mode with the dejavu font. I thought > that this should be handled by using the '°' + 'C' symbols instead > but it is not the case. > Is that a bug? > What can I do to get the °C symbol with this font? With dejavu, A, B, and D all work, but C is missing a symbol. A 100℃ B 100°C C $100℃$ D $100°C$ Alan ___________________________________________________________________________________ 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] 10+ messages in thread
* Re: Missing °C symbol in math mode with dejavu font 2013-05-20 20:57 ` Alan BRASLAU @ 2013-05-20 21:03 ` Khaled Hosny 2013-05-20 21:04 ` Romain Diss 1 sibling, 0 replies; 10+ messages in thread From: Khaled Hosny @ 2013-05-20 21:03 UTC (permalink / raw) To: mailing list for ConTeXt users On Mon, May 20, 2013 at 10:57:16PM +0200, Alan BRASLAU wrote: > On Mon, 20 May 2013 22:29:22 +0200 > Romain Diss <romain.diss@yahoo.fr> wrote: > > > The °C symbol is missing in math mode with the dejavu font. I thought > > that this should be handled by using the '°' + 'C' symbols instead > > but it is not the case. > > Is that a bug? > > What can I do to get the °C symbol with this font? > > With dejavu, A, B, and D all work, but C is missing a symbol. > > A 100℃ > > B 100°C > > C $100℃$ Since this is compatibility character, I think ConTeXt should just degree + plain capital C. Regards, Khaled ___________________________________________________________________________________ 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] 10+ messages in thread
* Re: Missing °C symbol in math mode with dejavu font 2013-05-20 20:57 ` Alan BRASLAU 2013-05-20 21:03 ` Khaled Hosny @ 2013-05-20 21:04 ` Romain Diss 2013-05-20 21:13 ` Wolfgang Schuster 1 sibling, 1 reply; 10+ messages in thread From: Romain Diss @ 2013-05-20 21:04 UTC (permalink / raw) To: mailing list for ConTeXt users Le lundi 20 mai 2013, Alan BRASLAU a écrit : > On Mon, 20 May 2013 22:29:22 +0200 > Romain Diss <romain.diss@yahoo.fr> wrote: > > The °C symbol is missing in math mode with the dejavu font. I thought > > that this should be handled by using the '°' + 'C' symbols instead > > but it is not the case. > > Is that a bug? > > What can I do to get the °C symbol with this font? > With dejavu, A, B, and D all work, but C is missing a symbol. > A 100℃ > B 100°C > C $100℃$ > D $100°C$ The question is: do \unit is supposed to handle this case and automatically switch from C to D if C is missing. If not, how can I tell \unit that C is missing and that I want \unit{celsius} to use D? Thanks -- Romain Diss <romain.diss@yahoo.fr> ___________________________________________________________________________________ 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] 10+ messages in thread
* Re: Missing °C symbol in math mode with dejavu font 2013-05-20 21:04 ` Romain Diss @ 2013-05-20 21:13 ` Wolfgang Schuster 2013-05-20 21:22 ` Khaled Hosny 0 siblings, 1 reply; 10+ messages in thread From: Wolfgang Schuster @ 2013-05-20 21:13 UTC (permalink / raw) To: mailing list for ConTeXt users Am 20.05.2013 um 23:04 schrieb Romain Diss <romain.diss@yahoo.fr>: > Le lundi 20 mai 2013, Alan BRASLAU a écrit : >> On Mon, 20 May 2013 22:29:22 +0200 >> Romain Diss <romain.diss@yahoo.fr> wrote: >>> The °C symbol is missing in math mode with the dejavu font. I thought >>> that this should be handled by using the '°' + 'C' symbols instead >>> but it is not the case. >>> Is that a bug? >>> What can I do to get the °C symbol with this font? >> With dejavu, A, B, and D all work, but C is missing a symbol. >> A 100℃ >> B 100°C >> C $100℃$ >> D $100°C$ > The question is: do \unit is supposed to handle this case and automatically > switch from C to D if C is missing. > If not, how can I tell \unit that C is missing and that I want \unit{celsius} > to use D? Hans can add a check for math mode for the symbol: \unprotect \unexpanded\def\checkedtextcelsius {\ifmmode \phys_units_text_celsius \else\iffontchar\font"2103\relax ℃\else\phys_units_text_celsius \fi\fi} \unexpanded\def\checkedtextfahrenheit {\ifmmode \phys_units_text_fahrenheit \else\iffontchar\font"2109\relax ℉\else\phys_units_text_fahrenheit \fi\fi} \protect \setupbodyfont[dejavu] \starttext Temperature : \unit{100 celsius} works.\par Temperature : \m{\unit{100 celsius}} doesn't work. \stoptext Wolfgang ___________________________________________________________________________________ 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] 10+ messages in thread
* Re: Missing °C symbol in math mode with dejavu font 2013-05-20 21:13 ` Wolfgang Schuster @ 2013-05-20 21:22 ` Khaled Hosny 2013-05-20 21:36 ` Khaled Hosny 0 siblings, 1 reply; 10+ messages in thread From: Khaled Hosny @ 2013-05-20 21:22 UTC (permalink / raw) To: mailing list for ConTeXt users On Mon, May 20, 2013 at 11:13:16PM +0200, Wolfgang Schuster wrote: > > Am 20.05.2013 um 23:04 schrieb Romain Diss <romain.diss@yahoo.fr>: > > > Le lundi 20 mai 2013, Alan BRASLAU a écrit : > >> On Mon, 20 May 2013 22:29:22 +0200 > >> Romain Diss <romain.diss@yahoo.fr> wrote: > >>> The °C symbol is missing in math mode with the dejavu font. I thought > >>> that this should be handled by using the '°' + 'C' symbols instead > >>> but it is not the case. > >>> Is that a bug? > >>> What can I do to get the °C symbol with this font? > >> With dejavu, A, B, and D all work, but C is missing a symbol. > >> A 100℃ > >> B 100°C > >> C $100℃$ > >> D $100°C$ > > The question is: do \unit is supposed to handle this case and automatically > > switch from C to D if C is missing. > > If not, how can I tell \unit that C is missing and that I want \unit{celsius} > > to use D? > > > Hans can add a check for math mode for the symbol: > > \unprotect > > \unexpanded\def\checkedtextcelsius > {\ifmmode > \phys_units_text_celsius > \else\iffontchar\font"2103\relax > ℃\else\phys_units_text_celsius > \fi\fi} > > \unexpanded\def\checkedtextfahrenheit > {\ifmmode > \phys_units_text_fahrenheit > \else\iffontchar\font"2109\relax > ℉\else\phys_units_text_fahrenheit > \fi\fi} > > \protect My suggestion is to just use \phys_units_text_* always, since the decomposed, two characters is the preferred form for those two units. Regards, Khaled ___________________________________________________________________________________ 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] 10+ messages in thread
* Re: Missing °C symbol in math mode with dejavu font 2013-05-20 21:22 ` Khaled Hosny @ 2013-05-20 21:36 ` Khaled Hosny 2013-05-21 8:01 ` Hans Hagen 0 siblings, 1 reply; 10+ messages in thread From: Khaled Hosny @ 2013-05-20 21:36 UTC (permalink / raw) To: mailing list for ConTeXt users On Mon, May 20, 2013 at 11:22:41PM +0200, Khaled Hosny wrote: > > My suggestion is to just use \phys_units_text_* always, since the > decomposed, two characters is the preferred form for those two units. “In normal use, it is better to represent degrees Celsius ‘°C’ with a sequence of U+00B0 DEGREE SIGN + U+0043 LATIN CAPITAL LETTER C, rather than U+2103 DEGREE CELSIUS. For searching, treat these two sequences as identical. Similarly, the sequence U+00B0 DEGREE SIGN + U+0046 LATIN CAPITAL LETTER F is preferred over U+2109 DEGREE FAHRENHEIT, and those two sequences should be treated as identical for searching.” http://www.unicode.org/versions/Unicode6.2.0/ch15.pdf#G20445 Regards, Khaled ___________________________________________________________________________________ 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] 10+ messages in thread
* Re: Missing °C symbol in math mode with dejavu font 2013-05-20 21:36 ` Khaled Hosny @ 2013-05-21 8:01 ` Hans Hagen 2013-05-21 8:09 ` Khaled Hosny 0 siblings, 1 reply; 10+ messages in thread From: Hans Hagen @ 2013-05-21 8:01 UTC (permalink / raw) To: ntg-context On 5/20/2013 11:36 PM, Khaled Hosny wrote: > On Mon, May 20, 2013 at 11:22:41PM +0200, Khaled Hosny wrote: >> >> My suggestion is to just use \phys_units_text_* always, since the >> decomposed, two characters is the preferred form for those two units. > > “In normal use, it is better to represent degrees Celsius ‘°C’ with a > sequence of U+00B0 DEGREE SIGN + U+0043 LATIN CAPITAL LETTER C, rather > than U+2103 DEGREE CELSIUS. For searching, treat these two sequences as > identical. Similarly, the sequence U+00B0 DEGREE SIGN + U+0046 LATIN > CAPITAL LETTER F is preferred over U+2109 DEGREE FAHRENHEIT, and those > two sequences should be treated as identical for searching.” > > http://www.unicode.org/versions/Unicode6.2.0/ch15.pdf#G20445 Searching should be ok due to the tonunicode that mentions the two characters ... how about the visual aspect? Should we care about? It's no problem to make an option to always use the split version. Hans ----------------------------------------------------------------- Hans Hagen | PRAGMA ADE Ridderstraat 27 | 8061 GH Hasselt | The Netherlands tel: 038 477 53 69 | voip: 087 875 68 74 | www.pragma-ade.com | 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://tex.aanhet.net archive : http://foundry.supelec.fr/projects/contextrev/ wiki : http://contextgarden.net ___________________________________________________________________________________ ^ permalink raw reply [flat|nested] 10+ messages in thread
* Re: Missing °C symbol in math mode with dejavu font 2013-05-21 8:01 ` Hans Hagen @ 2013-05-21 8:09 ` Khaled Hosny 2013-05-21 12:01 ` Arthur Reutenauer 0 siblings, 1 reply; 10+ messages in thread From: Khaled Hosny @ 2013-05-21 8:09 UTC (permalink / raw) To: mailing list for ConTeXt users On Tue, May 21, 2013 at 10:01:30AM +0200, Hans Hagen wrote: > On 5/20/2013 11:36 PM, Khaled Hosny wrote: > >On Mon, May 20, 2013 at 11:22:41PM +0200, Khaled Hosny wrote: > >> > >>My suggestion is to just use \phys_units_text_* always, since the > >>decomposed, two characters is the preferred form for those two units. > > > >“In normal use, it is better to represent degrees Celsius ‘°C’ with a > > sequence of U+00B0 DEGREE SIGN + U+0043 LATIN CAPITAL LETTER C, rather > > than U+2103 DEGREE CELSIUS. For searching, treat these two sequences as > > identical. Similarly, the sequence U+00B0 DEGREE SIGN + U+0046 LATIN > > CAPITAL LETTER F is preferred over U+2109 DEGREE FAHRENHEIT, and those > > two sequences should be treated as identical for searching.” > > > > http://www.unicode.org/versions/Unicode6.2.0/ch15.pdf#G20445 > > Searching should be ok due to the tonunicode that mentions the two > characters ... how about the visual aspect? Should we care about? I think for ConTeXt purposes we should just ignore the composed form, it is there only for compatibility with some legacy CJK encodings and their use is almost discouraged. If user enters those code points directly, then he on his own, so nothing to be done here either. In short, this is just some of the compatibility nonsense crippling Unicode, we are better off pretending they do not exist Regards, Khaled ___________________________________________________________________________________ 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] 10+ messages in thread
* Re: Missing °C symbol in math mode with dejavu font 2013-05-21 8:09 ` Khaled Hosny @ 2013-05-21 12:01 ` Arthur Reutenauer 0 siblings, 0 replies; 10+ messages in thread From: Arthur Reutenauer @ 2013-05-21 12:01 UTC (permalink / raw) To: Mailing list for ConTeXt users > In short, this is just some of the compatibility nonsense crippling > Unicode, we are better off pretending they do not exist Second that. Arthur ___________________________________________________________________________________ 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] 10+ messages in thread
end of thread, other threads:[~2013-05-21 12:01 UTC | newest] Thread overview: 10+ messages (download: mbox.gz / follow: Atom feed) -- links below jump to the message on this page -- 2013-05-20 20:29 Missing °C symbol in math mode with dejavu font Romain Diss 2013-05-20 20:57 ` Alan BRASLAU 2013-05-20 21:03 ` Khaled Hosny 2013-05-20 21:04 ` Romain Diss 2013-05-20 21:13 ` Wolfgang Schuster 2013-05-20 21:22 ` Khaled Hosny 2013-05-20 21:36 ` Khaled Hosny 2013-05-21 8:01 ` Hans Hagen 2013-05-21 8:09 ` Khaled Hosny 2013-05-21 12:01 ` Arthur Reutenauer
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).