ntg-context - mailing list for ConTeXt users
 help / color / mirror / Atom feed
From: Roger Mason <rmason@mun.ca>
To: ntg-context@ntg.nl
Subject: (no subject)
Date: Mon, 22 Feb 2010 10:55:27 -0330	[thread overview]
Message-ID: <y65tyt98i08.fsf@perthite.esd.mun.ca> (raw)

Hello,

I'm working on a project to set up exams, basing the work on Aditya's
asignment class that was published in Practex in 2006.

I have a problem getting title information printed correctly.  This is a
cut-down version:

\setupcolors  [state=start]
\definecolor  [colorone]    [r=0.625,g=0,b=0] %dark red
\definecolor  [colortwo]    [b=0.625,g=0,r=0] %dark blue

\def\exam[#1]
  {\getrawparameters
    [Exam]
    [     title=
         course=,
           date=,
          start=,
           stop=,
              #1]
  \title{\Examtitle}}

\definefont [BigFontOne]  [RegularSlanted sa 2.5]
\definefont [BigFontTwo]  [Regular sa 1.5]

\setuphead[title]
 [  style=\BigFontOne,
  command=\examtitle,
   before={},
    after={\blank[big] \bgroup \colortwo
     Date: \expanded{\date[Examdate]}
    \hfill
    Start: \expanded{Examstart}
    Stop: \expanded{Examstop}
   \egroup\blank},
 ]

%D This macro does the actual typesetting of the title
\def\examtitle#1#2%
  {\framed[
              width=broad,
              frame=off,
              align=middle,
    foregroundcolor=colortwo,
         % I want a shadow around the title frame
         background=shadow]
      {#2\\{Examcourse}}}

\exam[
  title=Mid-term 2010,
  course=ES2917,
  date={d=17,m=2,y=2010},
  start={9:00 am},
  stop={11:00 am}
]

I'm processing this with Mark II.  The problems are that

(1) The literal 'Examcourse' is typeset;
(2) Today's date is typset, not the one entered in the interface;
(3) The start and stop times are typeset as literals 'Examstart' &
'Examstop'

Thanks for any help,
Roger


%%% Local Variables: 
%%% mode: context
%%% TeX-master: t
%%% End: 
___________________________________________________________________________________
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
___________________________________________________________________________________


             reply	other threads:[~2010-02-22 14:25 UTC|newest]

Thread overview: 86+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2010-02-22 14:25 Roger Mason [this message]
2011-09-10 15:39 ` Document title (was: (no subject)) Wolfgang Schuster
2011-09-10 16:20   ` Aditya Mahajan
2011-09-11  9:05     ` Wolfgang Schuster
2011-09-11 14:49       ` Aditya Mahajan
2011-09-11 16:21         ` Wolfgang Schuster
2011-09-11 23:20           ` Aditya Mahajan
2011-09-12 15:06             ` Wolfgang Schuster
  -- strict thread matches above, loose matches on Subject: below --
2021-09-08 12:26 (no subject) Marcus Vinicius Mesquita via ntg-context
2021-07-17  6:38 T. Kurt Bond
2021-07-18 16:49 ` Pablo Rodriguez
2021-07-18 17:08 ` Wolfgang Schuster
2021-03-20 22:43 Adam Reviczky
2021-03-13 17:08 Jeroen
2021-03-13 17:16 ` Jano Kula
2020-06-18  6:33 Malte Frank Gerdes
2020-06-17 11:31 Malte Frank Gerdes
2020-06-17 13:46 ` Taco Hoekwater
2020-06-17 16:50   ` Hans Hagen
2020-04-19  4:53 Jairo A. del Rio
2019-07-23 14:16 Denis Maier
2019-05-18  6:13 Dmitry Starostin
2019-04-04 19:30 Dmitry Starostin
2019-04-04 22:37 ` Hans Hagen
2019-03-22 15:22 Dmitry Starostin
2019-03-22 11:34 dstarostin
2019-03-22 15:14 ` Alan Braslau
2019-01-04  0:39 Lars
2019-01-04 18:40 ` Hans Hagen
2016-07-15 11:17 Fabrice Couvreur
2016-07-15 11:26 ` Wolfgang Schuster
2016-07-15 14:19   ` Fabrice Couvreur
2016-07-15 16:51     ` Otared Kavian
2016-07-15 22:44       ` Fabrice Couvreur
2016-07-16  9:28         ` Otared Kavian
2016-07-16 21:23           ` Fabrice Couvreur
2016-07-17  8:46             ` Otared Kavian
2016-07-18  8:36               ` Fabrice Couvreur
2014-10-13 16:21 Fabrice Couvreur
2014-01-28 21:54 DesdeChaves
2013-10-11  7:50 Xan
2013-03-20  2:22 non-null
2013-03-20  8:43 ` Wolfgang Schuster
2013-03-20 11:35 ` Sietse Brouwer
2013-03-20 12:09   ` Marcin Borkowski
2013-03-20 14:37     ` Sietse Brouwer
2013-01-24  0:59 Alfredo Catalina
2013-01-24  7:45 ` Taco hoekwater
2012-12-03  9:34 Peter Fiets
2012-12-03  9:38 ` Taco Hoekwater
2012-03-18 15:38 Alan Bowen
2011-09-10 13:35 Honza Hejzl
2011-03-27 11:12 David Abdurachmanov
2011-03-21 18:03 David Abdurachmanov
2011-03-02  3:40 Tom
2010-04-19  0:11 Tom
2008-04-24 13:10 richard.stephens
2008-03-25 18:27 Horacio Suarez
2008-03-25 19:32 ` Peter Rolf
2008-03-26  7:14 ` Wolfgang Schuster
2008-03-26 12:15   ` Horacio Suarez
2007-01-28  0:16 박내엽(NY Park)
2007-01-29 14:23 ` Mojca Miklavec
2005-11-18 10:44 Hans van der Meer
2005-03-14  4:42 wei jm
2004-07-24 15:28 Matt Gushee
2004-03-09 13:47 Adam Tee
2004-02-25 15:40 Mike Aizatsky
2004-02-05  6:15 Vit Zyka
2004-02-08 11:46 ` Hans Hagen
2004-02-01  4:43 Vit Zyka
2004-02-02 11:50 ` Giuseppe Bilotta
2004-02-03 21:49   ` Vit Zyka
2004-01-21  8:54 hl590we
2004-01-25  5:06 ` Nigel King
2003-12-09 17:28 David Arnold
2003-12-01 19:11 Severin Obertuefer
2003-09-22 19:26 Thomas A.Schmitz
2003-09-21 19:24 Severin Obertuefer
2003-09-22  7:45 ` Jens-Uwe Morawski
2003-09-20 21:28 Jean-Pierre Le Narzul
2003-09-19 12:37 Steffen Wolfrum
2003-06-16  8:31 Tim  t Hart
2003-03-14  1:06 Coydell Rivers
2003-03-14  8:15 ` Hans Hagen
2003-03-15  3:44   ` Coydell Rivers

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=y65tyt98i08.fsf@perthite.esd.mun.ca \
    --to=rmason@mun.ca \
    --cc=ntg-context@ntg.nl \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
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).