Re: [NTG-context] \definecharacter

2008-11-13 Thread Thomas A. Schmitz

On Nov 13, 2008, at 8:43 AM, Hans Hagen wrote:

 Thomas A. Schmitz wrote:
 On Nov 11, 2008, at 11:58 PM, Wolfgang Schuster wrote:

 from enco-ini.mkiv

 \def\definecharacter#1 #2 %
  {}

 You could use \definecommand.

 Wolfgang

 Wolfgang, thanks for pointing me to this. What is the reason of this
 unfriendly behavior? I can understand if the \definecharacter command
 is gone in mkiv, but simply taking the arguments and sending them  
 into
 nirvana? It was a bit difficult for me to see where the errors in my
 environments came from, so I'm really wondering what this is supposed
 to do.

 well, i was not aware of users using \definecharacter

 (i can make it a chardef if needed)

Hey, you should know that your users use ConTeXt for all kinds of  
weird and deviant purposes :-)

I have it in some of my private modules/environments, e.g. for  
creating symbols and a metrical font. What would you suggest using  
instead?

Best

Thomas
___
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
___


Re: [NTG-context] \definecharacter

2008-11-13 Thread Hans Hagen
Thomas A. Schmitz wrote:
 On Nov 13, 2008, at 8:43 AM, Hans Hagen wrote:
 
 Thomas A. Schmitz wrote:
 On Nov 11, 2008, at 11:58 PM, Wolfgang Schuster wrote:

 from enco-ini.mkiv

 \def\definecharacter#1 #2 %
  {}

 You could use \definecommand.

 Wolfgang
 Wolfgang, thanks for pointing me to this. What is the reason of this
 unfriendly behavior? I can understand if the \definecharacter command
 is gone in mkiv, but simply taking the arguments and sending them  
 into
 nirvana? It was a bit difficult for me to see where the errors in my
 environments came from, so I'm really wondering what this is supposed
 to do.
 well, i was not aware of users using \definecharacter

 (i can make it a chardef if needed)

 Hey, you should know that your users use ConTeXt for all kinds of  
 weird and deviant purposes :-)
 
 I have it in some of my private modules/environments, e.g. for  
 creating symbols and a metrical font. What would you suggest using  
 instead?

\definecharacter etc were closely related to font encoding, so unless 
you defined them in 'default' encoding you had to replicate the 
definitions in each fotn encoding

a more natural variant for your case is \definesymbol or just 
\def\MyFunnySymbol{...}


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


Re: [NTG-context] \definecharacter

2008-11-13 Thread Mojca Miklavec
On Thu, Nov 13, 2008 at 9:12 AM, Hans Hagen wrote:
 Thomas A. Schmitz wrote:
 On Nov 13, 2008, at 8:43 AM, Hans Hagen wrote:

 well, i was not aware of users using \definecharacter

 (i can make it a chardef if needed)

 Hey, you should know that your users use ConTeXt for all kinds of
 weird and deviant purposes :-)

 I have it in some of my private modules/environments, e.g. for
 creating symbols and a metrical font. What would you suggest using
 instead?

 \definecharacter etc were closely related to font encoding, so unless
 you defined them in 'default' encoding you had to replicate the
 definitions in each fotn encoding

Even in XeTeX or LuaTeX one had to define a character only once.
\definecharacter worked just fine in both of them some time ago and I
find it a pitty to remove it (if there is no serious reason to do so).

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


Re: [NTG-context] \definecharacter

2008-11-13 Thread Hans Hagen
Mojca Miklavec wrote:
 On Thu, Nov 13, 2008 at 9:12 AM, Hans Hagen wrote:
 Thomas A. Schmitz wrote:
 On Nov 13, 2008, at 8:43 AM, Hans Hagen wrote:
 
 well, i was not aware of users using \definecharacter

 (i can make it a chardef if needed)

 Hey, you should know that your users use ConTeXt for all kinds of
 weird and deviant purposes :-)

 I have it in some of my private modules/environments, e.g. for
 creating symbols and a metrical font. What would you suggest using
 instead?
 \definecharacter etc were closely related to font encoding, so unless
 you defined them in 'default' encoding you had to replicate the
 definitions in each fotn encoding
 
 Even in XeTeX or LuaTeX one had to define a character only once.
 \definecharacter worked just fine in both of them some time ago and I
 find it a pitty to remove it (if there is no serious reason to do so).

\def\definecharacter#1 #2 %
   {\doifnumberelse{\string#2}
  {\setevalue{\string#1}{\utfchar{#2}}}
  {\unexpanded\setvalue {\string#1}{#2}}}

\def\definecommand#1 #2 %
   {\unexpanded\setvalue{\string#1}{#2}}


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


Re: [NTG-context] \definecharacter

2008-11-12 Thread Thomas A. Schmitz

On Nov 11, 2008, at 11:58 PM, Wolfgang Schuster wrote:

 from enco-ini.mkiv

 \def\definecharacter#1 #2 %
   {}

 You could use \definecommand.

 Wolfgang

Wolfgang, thanks for pointing me to this. What is the reason of this  
unfriendly behavior? I can understand if the \definecharacter command  
is gone in mkiv, but simply taking the arguments and sending them into  
nirvana? It was a bit difficult for me to see where the errors in my  
environments came from, so I'm really wondering what this is supposed  
to do.

Thomas
___
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
___


Re: [NTG-context] \definecharacter

2008-11-12 Thread Hans Hagen
Thomas A. Schmitz wrote:
 On Nov 11, 2008, at 11:58 PM, Wolfgang Schuster wrote:
 
 from enco-ini.mkiv

 \def\definecharacter#1 #2 %
   {}

 You could use \definecommand.

 Wolfgang
 
 Wolfgang, thanks for pointing me to this. What is the reason of this  
 unfriendly behavior? I can understand if the \definecharacter command  
 is gone in mkiv, but simply taking the arguments and sending them into  
 nirvana? It was a bit difficult for me to see where the errors in my  
 environments came from, so I'm really wondering what this is supposed  
 to do.

well, i was not aware of users using \definecharacter

(i can make it a chardef if needed)

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


Re: [NTG-context] \definecharacter

2008-11-11 Thread Wolfgang Schuster

Am 11.11.2008 um 23:51 schrieb Thomas A. Schmitz:

 Hi all,

 is the command \definecharacter deprecated in mkiv? Some of my
 environments stopped working. Minimal example:


 %\definecharacter mytest \char00F8
 \define\mytest{\getglyph{name:lmroman10book}{\char00F8}}

 \starttext

 Hello w\mytest rld!

 \stoptext

 I expected lines 1 and 2 to work, but line 1 gives an error
 (Undefined control sequence). So: is this command no longer
 available in mkiv?

from enco-ini.mkiv

\def\definecharacter#1 #2 %
   {}

You could use \definecommand.

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
___