Re: [NTG-context] hotkey and strut again

2007-05-09 Thread Hans Hagen
Vyatcheslav Yatskovsky wrote:
 Hello,

 I've found the following solution some time ago and I'm quietly satisfied 
 with it:

   \def\hotkey#1{\inframed[corner=00, offset=0pt]{\ #1\ }}

   

\def\hotkey#1{\inframed[corner=00, offset=0pt]{\enspace#1\enspace}}


-- 

-
  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] hotkey and strut again

2007-05-05 Thread Peter Münster
On Sat, 5 May 2007, Vyatcheslav Yatskovsky wrote:

 I've found the following solution some time ago and I'm quietly satisfied
 with it:
 
   \def\hotkey#1{\inframed[corner=00, offset=0pt]{\ #1\ }}

Strange, I remember that there were difficulties with offset=0pt, but now
it seems to be just fine.

Thanks, Peter

-- 
http://pmrb.free.fr/contact/
___
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
___


[NTG-context] hotkey and strut again

2007-05-04 Thread Peter Münster
Hello,

I'm using the following command for typesetting hotkeys:
\def\hotkey#1{\inframed[background=screen,offset=overlay,
height=\lineheight,corner=00]{~#1~}}
Now I realize, that with an argument without depth (\hotkey{Alt} for
example), the text is not aligned.
Same result with strut=no,yes,global.

With strut=local the text without depth is well aligned, but no more the
text *with* depth (Space for example). Here my test-file:

\setupcolors[state=start]
\def\Test#1{
  \def\hotkey##1{\inframed[background=screen,offset=overlay,
height=\lineheight,corner=00,strut=#1]{~##1~}}
  strut=#1: bla \hotkey{Alt} bla \hotkey{Space} bla\blank}
\starttext
\Test{no}
\Test{yes}
\Test{global}
\Test{local}
\stoptext

Any hint is appreciated!
Cheers, Peter

P.S.: My workaround:
\def\hotkey#1{\inframed[background=screen,offset=overlay,
height=\lineheight,corner=00]{~\vphantom{Sp}#1~}}

-- 
http://pmrb.free.fr/contact/
___
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] hotkey and strut again

2007-05-04 Thread Vyatcheslav Yatskovsky
Hello,

I've found the following solution some time ago and I'm quietly satisfied with 
it:

  \def\hotkey#1{\inframed[corner=00, offset=0pt]{\ #1\ }}

-- 
Best,
 Vyatcheslav Yatskovsky

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