You can use the \fontalternative command to check for the current alternative (upright, italic, bold etc.) of the font.
\def\Test
{\processaction
[\fontalternative]
[ tf=>Upright,
it=>Italic,
sl=>Slanted,
bf=>Bold,
bi=>Bolditalic,
bs=>Boldslanted,
unknown=>Unknown fontalternative]}
\starttext
“\Test” {\it “\Test”} {\bs “\Test”} {\sc “\Test”}
\stoptext
On 21.01.2014 21:34:17, Pablo Rodriguez <oinos@gmx.es> wrote:
On 01/19/2014 11:43 PM, Hans Hagen wrote:
> On 1/19/2014 6:51 PM, Pablo Rodriguez wrote:
>> [...]
>> Even in the case it could work, I would like to know how I could define
>> commands (\ConTeXt or \TeX) only referred to individual fonts.
>
> just use \def\ConTeXt{Con\-TeXt} then or \def\ConTeXt{Con\-text} or
> whatever you like ... we're not that picky about it.
Many thanks for your reply, Hans.
Sorry, only one more question on this topic: isn’t it possible to define
something such as the following pseudocode?
if emphasis (or italics):
(\ConTeXt}{definition}
elif smallcaps:
(\ConTeXt}{definition}
else:
(\ConTeXt}{definition}
Well, I guess Ι‘m that picky about it :-).
Many thanks for your help,
Pablo
--
http://www.ousia.tk
___________________________________________________________________________________
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
___________________________________________________________________________________