ntg-context - mailing list for ConTeXt users
 help / color / mirror / Atom feed
* Symbols
@ 2012-11-20 16:21 Willi Egger
  2012-11-21  9:26 ` Symbols Hans Hagen
  0 siblings, 1 reply; 9+ messages in thread
From: Willi Egger @ 2012-11-20 16:21 UTC (permalink / raw)
  To: NTG-Context ConTeXt users

Hi all,

could someone bring light into the way how to use symbols…in MKIV

I wanted to extract a symbol from uzdr (Zapfdingbats).

In MIII the that worked like this:

\definefontsynonym[Dingbats][uzdr]
\definesymbol[box][\getglyph{Dingbats}{\char113}]

In MKIV this is not the case.
I tried to find out with the font-manual, unfortunately it only shows the content of the symb-imp-eur.mkiv. I tried to find the fonts mentioned in that file, but miserably failed.

I tried different approaches but get now result, except for the black diamond, but this is defined internally in ConTeXt (\definesymbol[blackdiamond]    [\textormathchar{"2666}].

\definefontsynonym[Dingbats][uzdr]
\definefontsynonym[MSAM][msam10]

 
\definesymbol[boxA]            [\getglyph{Dingbats}{\char113}] %Seems to be changed...
\definesymbol[boxB]            [\getglyph{Dingbats}{\char"274F}] % U+0274F, 00052, a74
\definesymbol[cuttingscissors] [\getglyph{Dingbats}{\utfchar{"2701}}]
\definesymbol[blackdiamond]    [\textormathchar{"2666}]

\definesymbol[blackdiamondvar][\textormathchar{"25C6}]
\definesymbol[diamondfilled]  [\getglyph{MSAM}{\utfchar{"F0067}}]

\starttext

Thanks for support…

Willi

\symbol{boxA}

\symbol{boxB}

\symbol{cuttingscissors}

\symbol{blackdiamond}

\symbol{blackdiamondvar}

\symbol{diamondfilled}

\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  : http://foundry.supelec.fr/projects/contextrev/
wiki     : http://contextgarden.net
___________________________________________________________________________________


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

* Re: Symbols
  2012-11-20 16:21 Symbols Willi Egger
@ 2012-11-21  9:26 ` Hans Hagen
  2012-11-21 13:05   ` Symbols Willi Egger
  0 siblings, 1 reply; 9+ messages in thread
From: Hans Hagen @ 2012-11-21  9:26 UTC (permalink / raw)
  To: mailing list for ConTeXt users; +Cc: Willi Egger

On 11/20/2012 5:21 PM, Willi Egger wrote:
> Hi all,
>
> could someone bring light into the way how to use symbols…in MKIV
>
> I wanted to extract a symbol from uzdr (Zapfdingbats).

(Somehow uzdr.afm and uzdr.pfb are not in my tex tree. I always thought 
that they were part of the standalone but nothing surprises me as these 
fonts have a history of instability.)

(Copied from an upcoming font manual:)

\startsection[title=Unicoding]

Nowadays we will mostly use fonts that ship with a \UNICODE\ aware 
encoding. And
in \CONTEXT, even if we use a \TYPEONE\ font, it gets mapped onto \UNICODE.
However, there are some exceptions, for instance the Zapf Dingbats in 
\TYPEONE\
format. These have a rather obscure private encoding and the glyph names 
run from
\type {a1} upto \type {a206} and have no relation to what the glyph 
represents.

In the case of Dingbats we're somewhat lucky that they ended up in 
\UNICODE, so
we can relocate the glyphs to match their rightful place. This is done 
by means
of a goodies file. We already discussed this in \in {section} [goodies] 
so we
only repeat the usage.

\startbuffer
\definefontfeature
   [dingbats]
   [mode=base,
    goodies=dingbats,
    unicoding=yes]

\definefontsynonym
   [ZapfDingbats]
   [file:uzdr.afm]
   [features=dingbats]
\stopbuffer

\typebuffer \getbuffer

I tend to qualify the Dingbat font in \TEX\ distributions as rather unstable
because of name changes and them either or not being included. Therefore 
it's best to
use the hard coded name because that triggers the most visible error 
message when
the font is not found.

A font like this can for instance be used with the glyph placement 
macros as is
demonstrated below. In the last line we see that a direct \UTF\ input 
also works
out well.

\starttabulate[|||]
\HL
\NC \type{\getglyphdirect     {ZapfDingbats*dingbats}{\number"2701}} \NC 
\getglyphdirect     {ZapfDingbats*dingbats}{\number"2701} \NC \NR
\NC \type{\getglyphdirect     {ZapfDingbats*dingbats}{\char"2701}}   \NC 
\getglyphdirect     {ZapfDingbats*dingbats}{\char"2701}   \NC \NR
\NC \type{\getnamedglyphdirect{ZapfDingbats*dingbats}{a1}}           \NC 
\getnamedglyphdirect{ZapfDingbats*dingbats}{a1}           \NC \NR
\NC \type{\getnamedglyphdirect{ZapfDingbats*dingbats}{a11}}          \NC 
\getnamedglyphdirect{ZapfDingbats*dingbats}{a11}          \NC \NR
\HL
\NC \type{\getglyphdirect     {ZapfDingbats}{\number"2701}}          \NC 
\getglyphdirect     {ZapfDingbats}{\number"2701}          \NC \NR
\NC \type{\getglyphdirect     {ZapfDingbats}{\char"2701}}            \NC 
\getglyphdirect     {ZapfDingbats}{\char"2701}            \NC \NR
\NC \type{\getnamedglyphdirect{ZapfDingbats}{a1}}                    \NC 
\getnamedglyphdirect{ZapfDingbats}{a1}                    \NC \NR
\NC \type{\getnamedglyphdirect{ZapfDingbats}{a11}}                   \NC 
\getnamedglyphdirect{ZapfDingbats}{a11}                   \NC \NR
\HL
\NC \type{\definedfont[ZapfDingbats*dingbats]✁}                      \NC 
\definedfont[ZapfDingbats*dingbats]✁                      \NC \NR
\HL
\stoptabulate

Keep in mind that fonts like Dejavu (that we use here as document font) 
already
has these characters which is why it shows up in the verbose part of the 
table.

\stopsection

-- 

-----------------------------------------------------------------
                                           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] 9+ messages in thread

* Re: Symbols
  2012-11-21  9:26 ` Symbols Hans Hagen
@ 2012-11-21 13:05   ` Willi Egger
  0 siblings, 0 replies; 9+ messages in thread
From: Willi Egger @ 2012-11-21 13:05 UTC (permalink / raw)
  To: mailing list for ConTeXt users

Hans,

thank you very much for this section. - I see that the approach is different from what I was trying to do. - I will study and try it!

Willi

On Nov 21, 2012, at 10:26 AM, Hans Hagen wrote:

> On 11/20/2012 5:21 PM, Willi Egger wrote:
>> Hi all,
>> 
>> could someone bring light into the way how to use symbols…in MKIV
>> 
>> I wanted to extract a symbol from uzdr (Zapfdingbats).
> 
> (Somehow uzdr.afm and uzdr.pfb are not in my tex tree. I always thought that they were part of the standalone but nothing surprises me as these fonts have a history of instability.)
> 
> (Copied from an upcoming font manual:)
> 
> \startsection[title=Unicoding]
> 
> Nowadays we will mostly use fonts that ship with a \UNICODE\ aware encoding. And
> in \CONTEXT, even if we use a \TYPEONE\ font, it gets mapped onto \UNICODE.
> However, there are some exceptions, for instance the Zapf Dingbats in \TYPEONE\
> format. These have a rather obscure private encoding and the glyph names run from
> \type {a1} upto \type {a206} and have no relation to what the glyph represents.
> 
> In the case of Dingbats we're somewhat lucky that they ended up in \UNICODE, so
> we can relocate the glyphs to match their rightful place. This is done by means
> of a goodies file. We already discussed this in \in {section} [goodies] so we
> only repeat the usage.
> 
> \startbuffer
> \definefontfeature
>  [dingbats]
>  [mode=base,
>   goodies=dingbats,
>   unicoding=yes]
> 
> \definefontsynonym
>  [ZapfDingbats]
>  [file:uzdr.afm]
>  [features=dingbats]
> \stopbuffer
> 
> \typebuffer \getbuffer
> 
> I tend to qualify the Dingbat font in \TEX\ distributions as rather unstable
> because of name changes and them either or not being included. Therefore it's best to
> use the hard coded name because that triggers the most visible error message when
> the font is not found.
> 
> A font like this can for instance be used with the glyph placement macros as is
> demonstrated below. In the last line we see that a direct \UTF\ input also works
> out well.
> 
> \starttabulate[|||]
> \HL
> \NC \type{\getglyphdirect     {ZapfDingbats*dingbats}{\number"2701}} \NC \getglyphdirect     {ZapfDingbats*dingbats}{\number"2701} \NC \NR
> \NC \type{\getglyphdirect     {ZapfDingbats*dingbats}{\char"2701}}   \NC \getglyphdirect     {ZapfDingbats*dingbats}{\char"2701}   \NC \NR
> \NC \type{\getnamedglyphdirect{ZapfDingbats*dingbats}{a1}}           \NC \getnamedglyphdirect{ZapfDingbats*dingbats}{a1}           \NC \NR
> \NC \type{\getnamedglyphdirect{ZapfDingbats*dingbats}{a11}}          \NC \getnamedglyphdirect{ZapfDingbats*dingbats}{a11}          \NC \NR
> \HL
> \NC \type{\getglyphdirect     {ZapfDingbats}{\number"2701}}          \NC \getglyphdirect     {ZapfDingbats}{\number"2701}          \NC \NR
> \NC \type{\getglyphdirect     {ZapfDingbats}{\char"2701}}            \NC \getglyphdirect     {ZapfDingbats}{\char"2701}            \NC \NR
> \NC \type{\getnamedglyphdirect{ZapfDingbats}{a1}}                    \NC \getnamedglyphdirect{ZapfDingbats}{a1}                    \NC \NR
> \NC \type{\getnamedglyphdirect{ZapfDingbats}{a11}}                   \NC \getnamedglyphdirect{ZapfDingbats}{a11}                   \NC \NR
> \HL
> \NC \type{\definedfont[ZapfDingbats*dingbats]✁}                      \NC \definedfont[ZapfDingbats*dingbats]✁                      \NC \NR
> \HL
> \stoptabulate
> 
> Keep in mind that fonts like Dejavu (that we use here as document font) already
> has these characters which is why it shows up in the verbose part of the table.
> 
> \stopsection
> 
> -- 
> 
> -----------------------------------------------------------------
>                                          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
> ___________________________________________________________________________________

___________________________________________________________________________________
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] 9+ messages in thread

* Re: Symbols
  2007-02-21 12:42 ` Symbols Taco Hoekwater
  2007-02-21 13:31   ` Symbols Hans Hagen
@ 2007-02-21 14:05   ` Bernd Militzer
  1 sibling, 0 replies; 9+ messages in thread
From: Bernd Militzer @ 2007-02-21 14:05 UTC (permalink / raw)
  To: mailing list for ConTeXt users

Taco Hoekwater schrieb:
> These two lines in your preamble should fix the problem:
>
>    \definefontsynonym[fmvr8x][umvs]
>    \loadmapline[+][umvs MarVoSym <marvosym.pfb]
>
>   
thanks, Bernd

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

* Re: Symbols
  2007-02-21 12:42 ` Symbols Taco Hoekwater
@ 2007-02-21 13:31   ` Hans Hagen
  2007-02-21 14:05   ` Symbols Bernd Militzer
  1 sibling, 0 replies; 9+ messages in thread
From: Hans Hagen @ 2007-02-21 13:31 UTC (permalink / raw)
  To: mailing list for ConTeXt users

Taco Hoekwater wrote:
> Bernd Militzer wrote:
>   
>> Hi all!
>> in the past the following testfile works
>> but now ....
>>     
>
> These two lines in your preamble should fix the problem:
>
>    \definefontsynonym[fmvr8x][umvs]
>    \loadmapline[+][umvs MarVoSym <marvosym.pfb]
>
>   
is there a fix needed in source files? 

Hans 

-----------------------------------------------------------------
                                          Hans Hagen | PRAGMA ADE
              Ridderstraat 27 | 8061 GH Hasselt | The Netherlands
     tel: 038 477 53 69 | fax: 038 477 53 74 | www.pragma-ade.com
                                             | www.pragma-pod.nl
-----------------------------------------------------------------

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

* Re: Symbols
  2007-02-21 12:00 Symbols Bernd Militzer
@ 2007-02-21 12:42 ` Taco Hoekwater
  2007-02-21 13:31   ` Symbols Hans Hagen
  2007-02-21 14:05   ` Symbols Bernd Militzer
  0 siblings, 2 replies; 9+ messages in thread
From: Taco Hoekwater @ 2007-02-21 12:42 UTC (permalink / raw)
  To: mailing list for ConTeXt users

Bernd Militzer wrote:
> Hi all!
> in the past the following testfile works
> but now ....

These two lines in your preamble should fix the problem:

   \definefontsynonym[fmvr8x][umvs]
   \loadmapline[+][umvs MarVoSym <marvosym.pfb]


Best, Taco

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

* Symbols
@ 2007-02-21 12:00 Bernd Militzer
  2007-02-21 12:42 ` Symbols Taco Hoekwater
  0 siblings, 1 reply; 9+ messages in thread
From: Bernd Militzer @ 2007-02-21 12:00 UTC (permalink / raw)
  To: mailing list for ConTeXt users

Hi all!
in the past the following testfile works
but now ....

! Font \thedefinedfont=fmvr8x at 12.0pt not loadable: Metric (TFM) file 
not fou
nd.
<recently read> \scaledfont
                           
\symbolicsizedfont ...ntfontbodyscale \scaledfont
                                                  \thedefinedfont
\getglyph #1#2->{\symbolicfont {#1}
                                   \doifnumberelse {#2}\char \donothing #2}
\dodosymbol ...bol \csname \??ss :#1:#2\endcsname
                                                  \relax }\relax
\donormalsymbol ... {#1}{#2}{\dodosymbol {#1}{#2}}
                                                  \else \edef 
\currentsymbol...
l.20 ...n\dots\  \symbol[martinvogel 2][Telephone]
                                   
% TEST
    \enableregime[il2]
    \mainlanguage[de]
    \setupencoding[default=texnansi]
    \usetypescript[modern][\defaultencoding]
    \setupbodyfont[modern,rm,12pt]
%
\starttext
%
Telephon\dots\  \symbol[martinvogel 2][Telephone]
%
\stoptext

What have I to do?

thanks for help

Bernd

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

* Re: Symbols
       [not found] <OF260B86F5.44AAB781-ONCA256D10.0029553F@tk.jp.world.socgen >
@ 2003-04-22  9:24 ` Hans Hagen
  0 siblings, 0 replies; 9+ messages in thread
From: Hans Hagen @ 2003-04-22  9:24 UTC (permalink / raw)


At 18:33 22/04/2003 +1100, you wrote:
>Coming from a latex education, I am trying to insert the following symbols:
>
>section (\S)
>paragraph (\P)

\symbol[P]
\symbol[S]


-------------------------------------------------------------------------
                                   Hans Hagen | PRAGMA ADE | pragma@wxs.nl
                       Ridderstraat 27 | 8061 GH Hasselt | The Netherlands
  tel: +31 (0)38 477 53 69 | fax: +31 (0)38 477 53 74 | www.pragma-ade.com
-------------------------------------------------------------------------
                        information: http://www.pragma-ade.com/roadmap.pdf
                     documentation: http://www.pragma-ade.com/showcase.pdf
-------------------------------------------------------------------------

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

* Symbols
@ 2003-04-22  7:33 emmanuel.rialland
  0 siblings, 0 replies; 9+ messages in thread
From: emmanuel.rialland @ 2003-04-22  7:33 UTC (permalink / raw)


Coming from a latex education, I am trying to insert the following symbols:

section (\S)
paragraph (\P)
yen (\yen)

Are they already defined in Context? Is there a standard way to access
them?

Thanks in advance.

Emmanuel





**************************************************************************
Have you checked our new corporate website at  http://www.sgib.com ?

The information contained herein is confidential and is intended solely
for the addressee(s).  It shall not be construed as a recommendation to
buy or sell any security.  Any unauthorized access, use, reproduction,
disclosure or dissemination is prohibited.
Neither SGIB nor any of its subsidiaries or affiliates
shall assume any legal liability or responsibility for any incorrect,
misleading or altered information contained herein.
**************************************************************************

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

end of thread, other threads:[~2012-11-21 13:05 UTC | newest]

Thread overview: 9+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2012-11-20 16:21 Symbols Willi Egger
2012-11-21  9:26 ` Symbols Hans Hagen
2012-11-21 13:05   ` Symbols Willi Egger
  -- strict thread matches above, loose matches on Subject: below --
2007-02-21 12:00 Symbols Bernd Militzer
2007-02-21 12:42 ` Symbols Taco Hoekwater
2007-02-21 13:31   ` Symbols Hans Hagen
2007-02-21 14:05   ` Symbols Bernd Militzer
     [not found] <OF260B86F5.44AAB781-ONCA256D10.0029553F@tk.jp.world.socgen >
2003-04-22  9:24 ` Symbols Hans Hagen
2003-04-22  7:33 Symbols emmanuel.rialland

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