* defining a subtitle?
@ 2002-09-10 3:37 Bruce D'Arcus
2002-09-10 8:24 ` David Antos
0 siblings, 1 reply; 6+ messages in thread
From: Bruce D'Arcus @ 2002-09-10 3:37 UTC (permalink / raw)
Can someone please tell me how I ought to define a subtitle command?
If I do this...
\def\subtitle{\switchtobodyfont[14pt,ss]\it}
and then invoke it with \subtitle{A Subtitle}
...I get all subsequent text with the font I've switched to...
In general, though, I get the feeling that this isn't the best
approach. Am I on the right track even?
Bruce
^ permalink raw reply [flat|nested] 6+ messages in thread
* Re: defining a subtitle?
2002-09-10 3:37 defining a subtitle? Bruce D'Arcus
@ 2002-09-10 8:24 ` David Antos
2002-09-10 13:49 ` Bruce D'Arcus
0 siblings, 1 reply; 6+ messages in thread
From: David Antos @ 2002-09-10 8:24 UTC (permalink / raw)
On Mon, Sep 09, 2002 at 11:37:40PM -0400, Bruce D'Arcus wrote:
>
> Can someone please tell me how I ought to define a subtitle command?
> If I do this...
>
> \def\subtitle{\switchtobodyfont[14pt,ss]\it}
>
> and then invoke it with \subtitle{A Subtitle}
>
> ...I get all subsequent text with the font I've switched to...
\def\subtitle#1{{\switchtobodyfont[14pt,ss] #1}}
Think about \def that it eats the {}, the {} after \def just tell what
the definition is. You must also pass the argument of the macro to the
``inner'' group.
D.A.
^ permalink raw reply [flat|nested] 6+ messages in thread
* Re: defining a subtitle?
2002-09-10 8:24 ` David Antos
@ 2002-09-10 13:49 ` Bruce D'Arcus
2002-09-11 17:18 ` Hans Hagen
0 siblings, 1 reply; 6+ messages in thread
From: Bruce D'Arcus @ 2002-09-10 13:49 UTC (permalink / raw)
Cc: ntg-context
On Tuesday, September 10, 2002, at 04:24 AM, David Antos wrote:
> On Mon, Sep 09, 2002 at 11:37:40PM -0400, Bruce D'Arcus wrote:
>>
>> Can someone please tell me how I ought to define a subtitle command?
>> If I do this...
>>
>> \def\subtitle{\switchtobodyfont[14pt,ss]\it}
>>
>> and then invoke it with \subtitle{A Subtitle}
>>
>> ...I get all subsequent text with the font I've switched to...
>
> \def\subtitle#1{{\switchtobodyfont[14pt,ss] #1}}
>
> Think about \def that it eats the {}, the {} after \def just tell what
> the definition is. You must also pass the argument of the macro to the
> ``inner'' group.
>
Thank you! And what if I want to first define the command "subtitle"
so that I can then use \setuphead{subtitle}. Is that the better
approach? And if yes, how do I do that?
Bruce
^ permalink raw reply [flat|nested] 6+ messages in thread
* Re: defining a subtitle?
2002-09-10 13:49 ` Bruce D'Arcus
@ 2002-09-11 17:18 ` Hans Hagen
2002-09-12 11:36 ` John Culleton
0 siblings, 1 reply; 6+ messages in thread
From: Hans Hagen @ 2002-09-11 17:18 UTC (permalink / raw)
Cc: David Antos, ntg-context
At 09:49 AM 9/10/2002 -0400, Bruce D'Arcus wrote:
>On Tuesday, September 10, 2002, at 04:24 AM, David Antos wrote:
>
>>On Mon, Sep 09, 2002 at 11:37:40PM -0400, Bruce D'Arcus wrote:
>>>
>>>Can someone please tell me how I ought to define a subtitle command?
>>>If I do this...
>>>
>>>\def\subtitle{\switchtobodyfont[14pt,ss]\it}
>>>
>>>and then invoke it with \subtitle{A Subtitle}
>>>
>>>...I get all subsequent text with the font I've switched to...
>>
>>\def\subtitle#1{{\switchtobodyfont[14pt,ss] #1}}
>>
>>Think about \def that it eats the {}, the {} after \def just tell what
>>the definition is. You must also pass the argument of the macro to the
>>``inner'' group.
>
>Thank you! And what if I want to first define the command "subtitle" so
>that I can then use \setuphead{subtitle}. Is that the better
>approach? And if yes, how do I do that?
\definehead[subtitle][subject] % subject being a head lower than title
\setuphead[subtitle][style={\switchtobodyfont[14pt,ss]\it}]
[this also give you better breaking etc]
Hans
-------------------------------------------------------------------------
Hans Hagen | PRAGMA ADE | pragma@wxs.nl
Ridderstraat 27 | 8061 GH Hasselt | The Netherlands
tel: +31 (0)38 477 53 69 | fax: +31 (0)38 477 53 74 | www.pragma-ade.com
-------------------------------------------------------------------------
information: http://www.pragma-ade.com/roadmap.pdf
documentation: http://www.pragma-ade.com/showcase.pdf
-------------------------------------------------------------------------
^ permalink raw reply [flat|nested] 6+ messages in thread
* Re: defining a subtitle?
2002-09-11 17:18 ` Hans Hagen
@ 2002-09-12 11:36 ` John Culleton
2002-09-12 17:14 ` Henning Hraban Ramm
0 siblings, 1 reply; 6+ messages in thread
From: John Culleton @ 2002-09-12 11:36 UTC (permalink / raw)
Cc: David Antos, ntg-context
On Wednesday 11 September 2002 01:18 pm, Hans Hagen wrote:
>
> \definehead[subtitle][subject] % subject being a head lower than
> title
>
> \setuphead[subtitle][style={\switchtobodyfont[14pt,ss]\it}]
>
> [this also give you better breaking etc]
>
> Hans
>
I almost uderstand this code :-)
What is the trailing \it for? I sometimes use a trailing \rm just to
make sure that type gets reset to normal. But \it?
John Culleton
^ permalink raw reply [flat|nested] 6+ messages in thread
end of thread, other threads:[~2002-09-12 17:14 UTC | newest]
Thread overview: 6+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2002-09-10 3:37 defining a subtitle? Bruce D'Arcus
2002-09-10 8:24 ` David Antos
2002-09-10 13:49 ` Bruce D'Arcus
2002-09-11 17:18 ` Hans Hagen
2002-09-12 11:36 ` John Culleton
2002-09-12 17:14 ` Henning Hraban Ramm
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).