* \char"xxxx not working as I expected
@ 2009-02-25 14:31 Maurício
2009-02-25 14:41 ` Wolfgang Schuster
` (2 more replies)
0 siblings, 3 replies; 4+ messages in thread
From: Maurício @ 2009-02-25 14:31 UTC (permalink / raw)
To: ntg-context
Hi,
I'm trying this small test on unicode characters, and
the result I get is this:
http://173.45.227.76/test3.pdf
I did check the font in 'gucharmap' and it does contain
all codes I'm using (U+2019, U+2610, U+226b, U+2115). But
the result is a blank (U+2610 and U+2115) or wrong
(U+226b) character. (U+2019 is shown properly.)
The test alternates lines where a unicode character is
inserted directly (using emacs 'ucs' input method) and
then insert the same character using '\char'. (So, if you
see strange chars in the code, it's because it does
contain utf-8 characters.) It's intersting that u+226b
is shown properly when typed, but not when using '\char'.
Am I doing something wrong?
Thanks,
Maurício
%%%%
\enableregime[utf]
\mainlanguage[en]
\definefontsynonym [myfont] [file:/home/mauricio/fontes/TITUSCBZ.ttf]
\definefont [tudo] [myfont at 15pt]
\starttext
\tudo
A few unicode characters: ó ñ ï ỳ
(’) is character U+2019
(\char"2019 ) is also character U+2019
(☐) is character U+2610
(\char"2610 ) is also character U+2610
(≫) is character U+226b
(\char"226b ) is also character U+226b
(ℕ) is character U+2115
(\char"2115 ) is also character U+2115
\stoptext
%%%%
___________________________________________________________________________________
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 : https://foundry.supelec.fr/projects/contextrev/
wiki : http://contextgarden.net
___________________________________________________________________________________
^ permalink raw reply [flat|nested] 4+ messages in thread
* Re: \char"xxxx not working as I expected
2009-02-25 14:31 \char"xxxx not working as I expected Maurício
@ 2009-02-25 14:41 ` Wolfgang Schuster
2009-02-25 14:42 ` Taco Hoekwater
2009-02-25 14:54 ` Khaled Hosny
2 siblings, 0 replies; 4+ messages in thread
From: Wolfgang Schuster @ 2009-02-25 14:41 UTC (permalink / raw)
To: mailing list for ConTeXt users
Am 25.02.2009 um 15:31 schrieb Maurí cio:
> I did check the font in 'gucharmap' and it does contain
> all codes I'm using (U+2019, U+2610, U+226b, U+2115). But
> the result is a blank (U+2610 and U+2115) or wrong
> (U+226b) character. (U+2019 is shown properly.)
>
> The test alternates lines where a unicode character is
> inserted directly (using emacs 'ucs' input method) and
> then insert the same character using '\char'. (So, if you
> see strange chars in the code, it's because it does
> contain utf-8 characters.) It's intersting that u+226b
> is shown properly when typed, but not when using '\char'.
>
> Am I doing something wrong?
1. You need a font with the chars, e.g. Arial Unicode
2. Use uppercase letters for hex numbers (lowercase is used for ^^..)
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 : https://foundry.supelec.fr/projects/contextrev/
wiki : http://contextgarden.net
___________________________________________________________________________________
^ permalink raw reply [flat|nested] 4+ messages in thread
* Re: \char"xxxx not working as I expected
2009-02-25 14:31 \char"xxxx not working as I expected Maurício
2009-02-25 14:41 ` Wolfgang Schuster
@ 2009-02-25 14:42 ` Taco Hoekwater
2009-02-25 14:54 ` Khaled Hosny
2 siblings, 0 replies; 4+ messages in thread
From: Taco Hoekwater @ 2009-02-25 14:42 UTC (permalink / raw)
To: mailing list for ConTeXt users
Maurício wrote:
> Hi,
>
> I'm trying this small test on unicode characters, and
> the result I get is this:
>
> http://173.45.227.76/test3.pdf
>
> I did check the font in 'gucharmap' and it does contain
> all codes I'm using (U+2019, U+2610, U+226b, U+2115). But
> the result is a blank (U+2610 and U+2115) or wrong
I have no idea what gucharmap is, but the font *does not*
have U+2115, nor U+2610. I verified that in fontforge.
> (U+226b) character.
The "b" should be a "B". TeX-style hexadecimal
values are always uppercase (\char"226B works for me).
Best wishes,
Taco
___________________________________________________________________________________
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 : https://foundry.supelec.fr/projects/contextrev/
wiki : http://contextgarden.net
___________________________________________________________________________________
^ permalink raw reply [flat|nested] 4+ messages in thread
* Re: \char"xxxx not working as I expected
2009-02-25 14:31 \char"xxxx not working as I expected Maurício
2009-02-25 14:41 ` Wolfgang Schuster
2009-02-25 14:42 ` Taco Hoekwater
@ 2009-02-25 14:54 ` Khaled Hosny
2 siblings, 0 replies; 4+ messages in thread
From: Khaled Hosny @ 2009-02-25 14:54 UTC (permalink / raw)
To: mailing list for ConTeXt users
On Wed, Feb 25, 2009 at 4:31 PM, Maurício <briqueabraque@yahoo.com> wrote:
> Hi,
>
> I'm trying this small test on unicode characters, and
> the result I get is this:
>
> http://173.45.227.76/test3.pdf
>
> I did check the font in 'gucharmap' and it does contain
> all codes I'm using (U+2019, U+2610, U+226b, U+2115). But
> the result is a blank (U+2610 and U+2115) or wrong
> (U+226b) character. (U+2019 is shown properly.)
gucharmap will fallback to another font if the selected font don't
have the required character, so this doesn't necessarily mean the font
has those characters.
--
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 : https://foundry.supelec.fr/projects/contextrev/
wiki : http://contextgarden.net
___________________________________________________________________________________
^ permalink raw reply [flat|nested] 4+ messages in thread
end of thread, other threads:[~2009-02-25 14:54 UTC | newest]
Thread overview: 4+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2009-02-25 14:31 \char"xxxx not working as I expected Maurício
2009-02-25 14:41 ` Wolfgang Schuster
2009-02-25 14:42 ` Taco Hoekwater
2009-02-25 14:54 ` Khaled Hosny
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).