ntg-context - mailing list for ConTeXt users
 help / color / mirror / Atom feed
* "Turning off" special chapter headings
@ 2012-02-17  0:48 Alasdair McAndrew
  2012-02-17  5:05 ` Otared Kavian
  0 siblings, 1 reply; 3+ messages in thread
From: Alasdair McAndrew @ 2012-02-17  0:48 UTC (permalink / raw)
  To: mailing list for ConTeXt users


[-- Attachment #1.1: Type: text/plain, Size: 633 bytes --]

I'm using the following:

\def\chap#1#2{\vbox{Chapter #1\crlf\framed[frame=off,topframe=on]{#2}}}
\setuphead[chapter][command=\chap,style=bfd,after={\blank[1cm]}]

for my chapter headings.  But one chapter: "Answers to Exercises" I want
unnumbered, without the "Chapter" text, and also in the table of contents.

Can anybody point me to the simplest way of achieving this?  (I've tried
various combinations of \setuphead, \definehead, but nothing so far has
given me what I want.)

Thanks,
Alasdair

-- 
Blog: http://amca01.wordpress.com
Web:  http://sites.google.com/site/amca01/
Facebook: http://www.facebook.com/alasdair.mcandrew

[-- Attachment #1.2: Type: text/html, Size: 1020 bytes --]

[-- Attachment #2: Type: text/plain, Size: 485 bytes --]

___________________________________________________________________________________
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: "Turning off" special chapter headings
  2012-02-17  0:48 "Turning off" special chapter headings Alasdair McAndrew
@ 2012-02-17  5:05 ` Otared Kavian
  2012-02-17  5:22   ` Alasdair McAndrew
  0 siblings, 1 reply; 3+ messages in thread
From: Otared Kavian @ 2012-02-17  5:05 UTC (permalink / raw)
  To: mailing list for ConTeXt users


[-- Attachment #1.1: Type: text/plain, Size: 1849 bytes --]

Hi,

Didn't you see my answer? As suggested below, you can use \chapter[title={Answer to all the questions},number=no].

On 16 févr. 2012, at 08:59, Otared Kavian wrote:

> Hi Alasdair,
> 
> Is this what you want?
> %%%% begin
> \starttext
> 
> \completecontent
> 
> \chapter{Chapter one}
> 
> \section{First section}
> 
> \section{Second section}
> 
> \chapter{Chapter two}
> 
> \section{First section}
> 
> \section{Second section}
> 
> \chapter[title={Answer to all the questions},number=no]
> 
> \stoptext
> %%%%% end
> 
> Best regards: OK


Best regards: OK

On 17 févr. 2012, at 01:48, Alasdair McAndrew wrote:

> I'm using the following:
> 
> \def\chap#1#2{\vbox{Chapter #1\crlf\framed[frame=off,topframe=on]{#2}}}
> \setuphead[chapter][command=\chap,style=bfd,after={\blank[1cm]}]
> 
> for my chapter headings.  But one chapter: "Answers to Exercises" I want unnumbered, without the "Chapter" text, and also in the table of contents.
> 
> Can anybody point me to the simplest way of achieving this?  (I've tried various combinations of \setuphead, \definehead, but nothing so far has given me what I want.)
> 
> Thanks,
> Alasdair
> 
> -- 
> Blog: http://amca01.wordpress.com
> Web:  http://sites.google.com/site/amca01/
> Facebook: http://www.facebook.com/alasdair.mcandrew
> ___________________________________________________________________________________
> 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
> ___________________________________________________________________________________


[-- Attachment #1.2: Type: text/html, Size: 3221 bytes --]

[-- Attachment #2: Type: text/plain, Size: 485 bytes --]

___________________________________________________________________________________
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: "Turning off" special chapter headings
  2012-02-17  5:05 ` Otared Kavian
@ 2012-02-17  5:22   ` Alasdair McAndrew
  0 siblings, 0 replies; 3+ messages in thread
From: Alasdair McAndrew @ 2012-02-17  5:22 UTC (permalink / raw)
  To: mailing list for ConTeXt users


[-- Attachment #1.1: Type: text/plain, Size: 3044 bytes --]

Thanks for your suggestion, but it didn't seem to work. I just discovered
the answer myself and that was to create a new chapter command:

\def\uchap#1#2{#2}

and then follow as per the wiki:

\definehead[ans][chapter]
\setuphead[ans][command=\uchap,number=no]
\definecombinedlist[content][ans,chapter,section]
\setuplist[ans][headnumber=no]

Then finally

\ans{Answers to Exercises}

cheers,
Alasdair

On Fri, Feb 17, 2012 at 4:05 PM, Otared Kavian <otared@gmail.com> wrote:

> Hi,
>
> Didn't you see my answer? As suggested below, you can
> use \chapter[title={Answer to all the questions},number=no].
>
> On 16 févr. 2012, at 08:59, Otared Kavian wrote:
>
> Hi Alasdair,
>
> Is this what you want?
> %%%% begin
> \starttext
>
> \completecontent
>
> \chapter{Chapter one}
>
> \section{First section}
>
> \section{Second section}
>
> \chapter{Chapter two}
>
> \section{First section}
>
> \section{Second section}
>
> \chapter[title={Answer to all the questions},number=no]
>
> \stoptext
> %%%%% end
>
> Best regards: OK
>
>
>
> Best regards: OK
>
> On 17 févr. 2012, at 01:48, Alasdair McAndrew wrote:
>
> I'm using the following:
>
> \def\chap#1#2{\vbox{Chapter #1\crlf\framed[frame=off,topframe=on]{#2}}}
> \setuphead[chapter][command=\chap,style=bfd,after={\blank[1cm]}]
>
> for my chapter headings.  But one chapter: "Answers to Exercises" I want
> unnumbered, without the "Chapter" text, and also in the table of contents.
>
> Can anybody point me to the simplest way of achieving this?  (I've tried
> various combinations of \setuphead, \definehead, but nothing so far has
> given me what I want.)
>
> Thanks,
> Alasdair
>
> --
> Blog: http://amca01.wordpress.com
> Web:  http://sites.google.com/site/amca01/
> Facebook: http://www.facebook.com/alasdair.mcandrew
> ___________________________________________________________________________________
> 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
>
> ___________________________________________________________________________________
>



-- 
Blog: http://amca01.wordpress.com
Web:  http://sites.google.com/site/amca01/
Facebook: http://www.facebook.com/alasdair.mcandrew

[-- Attachment #1.2: Type: text/html, Size: 5313 bytes --]

[-- Attachment #2: Type: text/plain, Size: 485 bytes --]

___________________________________________________________________________________
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:[~2012-02-17  5:22 UTC | newest]

Thread overview: 3+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2012-02-17  0:48 "Turning off" special chapter headings Alasdair McAndrew
2012-02-17  5:05 ` Otared Kavian
2012-02-17  5:22   ` Alasdair McAndrew

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