ntg-context - mailing list for ConTeXt users
 help / color / mirror / Atom feed
From: "Tom" <Tom@tuxedo-press.com>
To: "'mailing list for ConTeXt users'" <ntg-context@ntg.nl>
Subject: Re: \stretched in chapter titles in MKII
Date: Tue, 22 Feb 2011 08:42:12 -0500	[thread overview]
Message-ID: <000501cbd296$4fa6a600$eef3f200$@com> (raw)
In-Reply-To: <905C79A4-3C5B-4F48-BFEB-11BCA765E436@gmail.com>

I'm sorry for being so thick but this code errors out when I run it under
TexLive 2010 MKIV. The problem seems to be in the processing of textcommand,
so I commented it out. The error went away and the \ChapterNumberCommand
seemed to execute correctly. However, I want to stretch the title as well as
the chapter number, so that is not a solution. I couldn't find documentation
for \structuretitle and \structurenumber and am completely lost.

Tom Benjey
717-258-9733 voice
717-243-0074 fax
blog: www.TomBenjey.com



-----Original Message-----
From: ntg-context-bounces@ntg.nl [mailto:ntg-context-bounces@ntg.nl] On
Behalf Of Wolfgang Schuster
Sent: Tuesday, February 22, 2011 3:40 AM
To: mailing list for ConTeXt users
Subject: Re: [NTG-context] \stretched in chapter titles in MKII


Am 22.02.2011 um 01:18 schrieb Tom:

> The code that follows works fine in MKII but doesn't stretch the chapter
> title in MKIV. What must I change? Also, I want to convert the chapter
> number to text before stretching it. Has anything been done to the
routines
> that convert numerals to alpha characters since last summer?

Use \structuretitle and \structurenumber to access the values.

\defineconversion [tom] [One,Two,Three,Four,Five,.]

\define[1]\ChapterTextCommand
  {\line{\expanded{\stretched{\structuretitle}}}}

\define[1]\ChapterNumberCommand
  {\line{\expanded{\stretched{Chapter
\convertnumber{tom}{\structurenumber}}}}}

\setuphead
  [chapter]
  [  alternative=middle,
           style=\ssc,
       textstyle=\bf,
     numberstyle=\tf,
     textcommand=\ChapterTextCommand,
   numbercommand=\ChapterNumberCommand]

\starttext
\chapter{Test Chapter Title}
\input knuth
\stoptext

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
____________________________________________________________________________
_______

___________________________________________________________________________________
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:[~2011-02-22 13:42 UTC|newest]

Thread overview: 11+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2010-07-05 19:15 Tom
2010-07-06 14:00 ` Tom
2010-07-06 14:06 ` Wolfgang Schuster
2010-07-06 16:18 ` Wolfgang Schuster
2010-07-06 17:52   ` Tom
2010-07-07  2:12   ` Tom
2011-02-22  0:18   ` Tom
2011-02-22  8:39     ` Wolfgang Schuster
2011-02-22 13:42       ` Tom [this message]
2011-02-22 22:14         ` Wolfgang Schuster
2011-02-23 12:13           ` Tom

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='000501cbd296$4fa6a600$eef3f200$@com' \
    --to=tom@tuxedo-press.com \
    --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).