ntg-context - mailing list for ConTeXt users
 help / color / mirror / Atom feed
* Title in margin example from the wiki not working?
@ 2014-08-07  6:38 Mica Semrick
  2014-08-07  8:36 ` Wolfgang Schuster
  0 siblings, 1 reply; 3+ messages in thread
From: Mica Semrick @ 2014-08-07  6:38 UTC (permalink / raw)
  To: mailing list for ConTeXt users

Hello,

I'm trying to get the subject heading in the margin. I found this code on the wiki, but it is not compiling with the latest version of ConTeXt.

\setuppapersize[A5]
\setuphead
   [subject]
   [alternative=text,distance=0pt,command=\MyHead,style=\sc]

\def\MyHead#1#2{\inmargin{#1 #2}}

\starttext

\subject{First Subject}
\input weisman

\subject{Second Subject}
\input ward

\stoptext

from http://wiki.contextgarden.net/Titles#Titles_in_margin

The error being thrown is  ! Argument of \MyHead has an extra }

Please help!

Best,
Mica
___________________________________________________________________________________
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] 3+ messages in thread

* Re: Title in margin example from the wiki not working?
  2014-08-07  6:38 Title in margin example from the wiki not working? Mica Semrick
@ 2014-08-07  8:36 ` Wolfgang Schuster
  2014-08-07 15:44   ` Mica Semrick
  0 siblings, 1 reply; 3+ messages in thread
From: Wolfgang Schuster @ 2014-08-07  8:36 UTC (permalink / raw)
  To: mailing list for ConTeXt users


Am 07.08.2014 um 08:38 schrieb Mica Semrick <mica@silentumbrella.com>:

> Hello,
> 
> I'm trying to get the subject heading in the margin. I found this code on the wiki, but it is not compiling with the latest version of ConTeXt.
> 
> \setuppapersize[A5]
> \setuphead
>  [subject]
>  [alternative=text,distance=0pt,command=\MyHead,style=\sc]
> 
> \def\MyHead#1#2{\inmargin{#1 #2}}

You have to use \define to create your custom layout for the heading, e.g.

\define[2]\MyHead
  {\inmargin{#1 #2}}

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


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

* Re: Title in margin example from the wiki not working?
  2014-08-07  8:36 ` Wolfgang Schuster
@ 2014-08-07 15:44   ` Mica Semrick
  0 siblings, 0 replies; 3+ messages in thread
From: Mica Semrick @ 2014-08-07 15:44 UTC (permalink / raw)
  To: mailing list for ConTeXt users

Thanks Wolfgang. I will test this later tonight and update the wiki when it is working.

Best,
Mica
___________________________________________________________________________________
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] 3+ messages in thread

end of thread, other threads:[~2014-08-07 15:44 UTC | newest]

Thread overview: 3+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2014-08-07  6:38 Title in margin example from the wiki not working? Mica Semrick
2014-08-07  8:36 ` Wolfgang Schuster
2014-08-07 15:44   ` Mica Semrick

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