ntg-context - mailing list for ConTeXt users
 help / color / mirror / Atom feed
* part problems
@ 2010-07-30 17:30 Henning Hraban Ramm
  2010-07-30 20:37 ` Wolfgang Schuster
  0 siblings, 1 reply; 10+ messages in thread
From: Henning Hraban Ramm @ 2010-07-30 17:30 UTC (permalink / raw)
  To: mailing list for ConTeXt users

(MkIV, latest beta)

I'm trying to get a title page for book parts:

\def\FPart#1#2{#2}

\setupheads	[align=right, tolerance=verytolerant,
		before=\nohyphen\startlinecorrection,
		after=\stoplinecorrection, number=no]
\setuphead[part][command=\FPart, page=right, style={\bfc}]

\part{My First Part}


But the page is empty, also without "command", also with a suitable  
"textcommand", also without "style".


Next problem:
In my ToC I get "Part  My First Part". (Or "Part 1  My First Part", if  
I enable the number.)
How can I suppress that piece of text ("Part")?


Generally, what's the best approach to get a fixed font size for some  
titles, e.g. the part title should have 64 pt.
Should I use \setuphead[part][before={\switchtobodyfont[64pt]}] ?


Greetlings from Lake Constance!
Hraban
---
http://www.fiee.net/texnique/
http://wiki.contextgarden.net
https://www.cacert.org (I'm an assurer)

___________________________________________________________________________________
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] 10+ messages in thread

* Re: part problems
  2010-07-30 17:30 part problems Henning Hraban Ramm
@ 2010-07-30 20:37 ` Wolfgang Schuster
  2010-07-30 20:46   ` luigi scarso
  2010-07-30 20:56   ` Henning Hraban Ramm
  0 siblings, 2 replies; 10+ messages in thread
From: Wolfgang Schuster @ 2010-07-30 20:37 UTC (permalink / raw)
  To: mailing list for ConTeXt users

  Am 30.07.10 19:30, schrieb Henning Hraban Ramm:
> (MkIV, latest beta)
>
> I'm trying to get a title page for book parts:
>
> \def\FPart#1#2{#2}
>
> \setupheads    [align=right, tolerance=verytolerant,
>         before=\nohyphen\startlinecorrection,
>         after=\stoplinecorrection, number=no]
> \setuphead[part][command=\FPart, page=right, style={\bfc}]
>
> \part{My First Part}
>
>
> But the page is empty, also without "command", also with a suitable 
> "textcommand", also without "style".
\setuphead[part][placehead=yes]

To disable hyphenation in headers you can set 'align={right,nothyphenated}'.
> Next problem:
> In my ToC I get "Part  My First Part". (Or "Part 1  My First Part", if 
> I enable the number.)
> How can I suppress that piece of text ("Part")?

\setuplist[part][label=no]
> Generally, what's the best approach to get a fixed font size for some 
> titles, e.g. the part title should have 64 pt.
> Should I use \setuphead[part][before={\switchtobodyfont[64pt]}] ?
\definefont[PartStyle][Serif sa 64pt]

\setuphead[part][style=PartStyle]

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] 10+ messages in thread

* Re: part problems
  2010-07-30 20:37 ` Wolfgang Schuster
@ 2010-07-30 20:46   ` luigi scarso
  2010-07-30 21:00     ` Henning Hraban Ramm
  2010-07-30 20:56   ` Henning Hraban Ramm
  1 sibling, 1 reply; 10+ messages in thread
From: luigi scarso @ 2010-07-30 20:46 UTC (permalink / raw)
  To: mailing list for ConTeXt users

On Fri, Jul 30, 2010 at 10:37 PM, Wolfgang Schuster
<schuster.wolfgang@googlemail.com> wrote:
>  Am 30.07.10 19:30, schrieb Henning Hraban Ramm:
>>
>> (MkIV, latest beta)
>>
>> I'm trying to get a title page for book parts:
>>
>> \def\FPart#1#2{#2}
>>
>> \setupheads    [align=right, tolerance=verytolerant,
>>        before=\nohyphen\startlinecorrection,
>>        after=\stoplinecorrection, number=no]
>> \setuphead[part][command=\FPart, page=right, style={\bfc}]
>>
>> \part{My First Part}
>>
>>
>> But the page is empty, also without "command", also with a suitable
>> "textcommand", also without "style".
>
> \setuphead[part][placehead=yes]
Hm, Hraban needs really to come to Brejlov

-- 
luigi
___________________________________________________________________________________
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] 10+ messages in thread

* Re: part problems
  2010-07-30 20:37 ` Wolfgang Schuster
  2010-07-30 20:46   ` luigi scarso
@ 2010-07-30 20:56   ` Henning Hraban Ramm
  1 sibling, 0 replies; 10+ messages in thread
From: Henning Hraban Ramm @ 2010-07-30 20:56 UTC (permalink / raw)
  To: mailing list for ConTeXt users

Thank you!

Am 2010-07-30 um 22:37 schrieb Wolfgang Schuster:
>> I'm trying to get a title page for book parts:
>> But the page is empty, also without "command", also with a suitable  
>> "textcommand", also without "style".
> \setuphead[part][placehead=yes]

Good

> To disable hyphenation in headers you can set  
> 'align={right,nothyphenated}'.

Even better ;-)

>> In my ToC I get "Part  My First Part". (Or "Part 1  My First Part",  
>> if I enable the number.)
>> How can I suppress that piece of text ("Part")?
> \setuplist[part][label=no]

also good

>> Generally, what's the best approach to get a fixed font size for  
>> some titles, e.g. the part title should have 64 pt.
>> Should I use \setuphead[part][before={\switchtobodyfont[64pt]}] ?
> \definefont[PartStyle][Serif sa 64pt]
> \setuphead[part][style=PartStyle]

That doesn't work. I get:

structure       : part @ level 1 : 1 -> Märchen
! Missing number, treated as zero.
<to be read again>
                    \edef
\lowleveldefinefont ... \scaledfontsize \fi \edef
                                                   \somefontspec {at  
\number ...
\dododefinefont ...inefont {#2}\rawfontidentifier
                                                   \csname  
\rawfontidentifier...
\dosetfontattribute ...me #1#2\@EA \endcsname \fi
                                                   \empty
\doplacestructureheadtext ...ucturehead }\c!style
                                                    
\structureheadparameter \c...
\dohandlestructurehead ...\placestructureheadtext
                                                   \fi  
\dostructureheadspacin...
l.9 \part{Märchen}


Did you mean "Serif at 64pt"? That works.


Greetlings from Lake Constance!
Hraban
---
http://www.fiee.net/texnique/
http://wiki.contextgarden.net
https://www.cacert.org (I'm an assurer)

___________________________________________________________________________________
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] 10+ messages in thread

* Re: part problems
  2010-07-30 20:46   ` luigi scarso
@ 2010-07-30 21:00     ` Henning Hraban Ramm
  2010-07-30 21:04       ` luigi scarso
  2010-07-30 23:08       ` Alan BRASLAU
  0 siblings, 2 replies; 10+ messages in thread
From: Henning Hraban Ramm @ 2010-07-30 21:00 UTC (permalink / raw)
  To: mailing list for ConTeXt users

Am 2010-07-30 um 22:46 schrieb luigi scarso:

> On Fri, Jul 30, 2010 at 10:37 PM, Wolfgang Schuster
> <schuster.wolfgang@googlemail.com> wrote:
>>  Am 30.07.10 19:30, schrieb Henning Hraban Ramm:
>>>
>>> (MkIV, latest beta)
>>>
>>> I'm trying to get a title page for book parts:
>>>
>>> \def\FPart#1#2{#2}
>>>
>>> \setupheads    [align=right, tolerance=verytolerant,
>>>        before=\nohyphen\startlinecorrection,
>>>        after=\stoplinecorrection, number=no]
>>> \setuphead[part][command=\FPart, page=right, style={\bfc}]
>>>
>>> \part{My First Part}
>>>
>>>
>>> But the page is empty, also without "command", also with a suitable
>>> "textcommand", also without "style".
>>
>> \setuphead[part][placehead=yes]
> Hm, Hraban needs really to come to Brejlov

Because I can't read the docs?
Sorry.
I browsed so much in wiki, source and reference that I'm confused ;-)
Coming back to ConTeXt after a while for a new project is always a bit  
hard - a new program every time ;-)
And yes, I'll try to come to Brejlov, still waiting for an answer from  
my lift...

Greetlings, Hraban

___________________________________________________________________________________
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] 10+ messages in thread

* Re: part problems
  2010-07-30 21:00     ` Henning Hraban Ramm
@ 2010-07-30 21:04       ` luigi scarso
  2010-07-30 23:08       ` Alan BRASLAU
  1 sibling, 0 replies; 10+ messages in thread
From: luigi scarso @ 2010-07-30 21:04 UTC (permalink / raw)
  To: mailing list for ConTeXt users

On Fri, Jul 30, 2010 at 11:00 PM, Henning Hraban Ramm <hraban@fiee.net> wrote:

> And yes, I'll try to come to Brejlov, still waiting for an answer from my
> lift...
good.

-- 
luigi
___________________________________________________________________________________
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] 10+ messages in thread

* Re: part problems
  2010-07-30 21:00     ` Henning Hraban Ramm
  2010-07-30 21:04       ` luigi scarso
@ 2010-07-30 23:08       ` Alan BRASLAU
  2010-07-31  9:20         ` Hans Hagen
  1 sibling, 1 reply; 10+ messages in thread
From: Alan BRASLAU @ 2010-07-30 23:08 UTC (permalink / raw)
  To: Henning Hraban Ramm; +Cc: ntg-context

On Friday 30 July 2010 23:00:16 Henning Hraban Ramm wrote:
> Am 2010-07-30 um 22:46 schrieb luigi scarso:
> > 
> > Hm, Hraban needs really to come to Brejlov
> 
> And yes, I'll try to come to Brejlov, still waiting for an answer from
> my lift...

Using parts is not as simple as it seems and is still somewhat problematic,
or maybe I, too, am unable to read the source.

Will someone be giving a special lecture on structure?

As to the lift, I am almost decided to indeed drive as we are for now
at least three...

Alan
___________________________________________________________________________________
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] 10+ messages in thread

* Re: part problems
  2010-07-30 23:08       ` Alan BRASLAU
@ 2010-07-31  9:20         ` Hans Hagen
  2010-08-01  8:20           ` Alan BRASLAU
  0 siblings, 1 reply; 10+ messages in thread
From: Hans Hagen @ 2010-07-31  9:20 UTC (permalink / raw)
  To: mailing list for ConTeXt users; +Cc: Henning Hraban Ramm

On 31-7-2010 1:08, Alan BRASLAU wrote:
> On Friday 30 July 2010 23:00:16 Henning Hraban Ramm wrote:
>> Am 2010-07-30 um 22:46 schrieb luigi scarso:
>>>
>>> Hm, Hraban needs really to come to Brejlov
>>
>> And yes, I'll try to come to Brejlov, still waiting for an answer from
>> my lift...
>
> Using parts is not as simple as it seems and is still somewhat problematic,
> or maybe I, too, am unable to read the source.

parts are just like chapters and sections; the defaults are just set up 
differently; don't think of them as something programatically different



-----------------------------------------------------------------
                                           Hans Hagen | PRAGMA ADE
               Ridderstraat 27 | 8061 GH Hasselt | The Netherlands
     tel: 038 477 53 69 | voip: 087 875 68 74 | www.pragma-ade.com
                                              | www.pragma-pod.nl
-----------------------------------------------------------------
___________________________________________________________________________________
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] 10+ messages in thread

* Re: part problems
  2010-07-31  9:20         ` Hans Hagen
@ 2010-08-01  8:20           ` Alan BRASLAU
  2010-08-01 15:12             ` Hans Hagen
  0 siblings, 1 reply; 10+ messages in thread
From: Alan BRASLAU @ 2010-08-01  8:20 UTC (permalink / raw)
  To: Hans Hagen; +Cc: mailing list for ConTeXt users

On Saturday 31 July 2010 11:20:38 Hans Hagen wrote:
> On 31-7-2010 1:08, Alan BRASLAU wrote:
> > 
> > Using parts is not as simple as it seems and is still somewhat
> > problematic, or maybe I, too, am unable to read the source.
> 
> parts are just like chapters and sections; the defaults are just set up
> differently; don't think of them as something programatically different
> 

Some logical subtleties, though, reflecting the different use either as "part" 
or as "volume":


A book (or single volume) may contain several parts, each one containing 
several chapters. One may wish to number the chapters subsequently, 
independent of the part structure.

This is no problem:
  \definestructureresetset [default] [0,0] [1] % do not reset parts and 
chapters
(although the syntax is somewhat obscure here).
also
  \setuphead [part]
             [sectionresetset=default,conversion=Romannumerals,placehead=yes]
and
  \setuphead [chapter,section,subsection] [sectionsegments=2:100]
  \setuppagenumbering [alternative=doublesided,way=bytext,partnumber=no]
(this is what Hans refers to as defaults that are set up differently).

[By the way, the default pagenumbering by part is a very reasonable default, 
as is resetting chapter numbering by part, for often "part" is synonymous with 
"volume". But not always: sometimes a book is to be broken into parts within a 
single volume.]


Now the front matter and the back matter are common to the entire book, 
logically part-less (if part is not to be taken as volume).  The front matter 
may contain chapter(s) (preface, introduction, definitions) that may be 
unnumbered.  The back matter will contain appendices (numbered), an index or 
indexes (unnumbered), etc.

For now, I have found no better way then to use funny definitions:
  \definehead [frontchapter] [chapter] % to get around broken bookmarks
  \setuphead  [frontchapter] [incrementnumber=list]
  \definehead [unnumberedchapter] [chapter]
  \setuphead  [unnumberedchapter] [incrementnumber=list]
  \definehead [unnumberedpart] [part]
  \setuphead  [unnumberedpart] [incrementnumber=list,label=no]
  \definecombinedlist [content]
    [part,unnumberedpart,frontchapter,unnumberedchapter,chapter,section,subsection,subsubsection]
  \setuplist 
[part,unnumberedpart,frontchapter,unnumberedchapter,chapter,section,subsection,subsubsection]
    [alternative=c, % number – title – dots – pagenumber
     interaction=all]


A problem comes up when I want the main body parts to be labeled, as well as 
chapters, as in:
  \setuphead [part]
    [sectionresetset=default,conversion=Romannumerals,placehead=yes]
  \setuplabeltext [chapter=Chapter ] % with trailing space; blank by default
  \startsectionblockenvironment[bodypart]
    \setuplist [chapter]  [label=yes]
  \stopsectionblockenvironment


You see, what should be natural (and probably the default) quickly gets to be 
a bit complicated. Furthermore, I have not yet been able to get everything 
that I want working. In the end, I'm sure that the solution will be quite 
easy.

My point is that the use of \part (or, now, \startpart ... \stoppart) is not 
as simple and obvious as it should be.

Alan
___________________________________________________________________________________
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] 10+ messages in thread

* Re: part problems
  2010-08-01  8:20           ` Alan BRASLAU
@ 2010-08-01 15:12             ` Hans Hagen
  0 siblings, 0 replies; 10+ messages in thread
From: Hans Hagen @ 2010-08-01 15:12 UTC (permalink / raw)
  To: Alan BRASLAU; +Cc: mailing list for ConTeXt users

On 1-8-2010 10:20, Alan BRASLAU wrote:
> On Saturday 31 July 2010 11:20:38 Hans Hagen wrote:
>> On 31-7-2010 1:08, Alan BRASLAU wrote:
>>>
>>> Using parts is not as simple as it seems and is still somewhat
>>> problematic, or maybe I, too, am unable to read the source.
>>
>> parts are just like chapters and sections; the defaults are just set up
>> differently; don't think of them as something programatically different
>>
>
> Some logical subtleties, though, reflecting the different use either as "part"
> or as "volume":
>
>
> A book (or single volume) may contain several parts, each one containing
> several chapters. One may wish to number the chapters subsequently,
> independent of the part structure.
>
> This is no problem:
>    \definestructureresetset [default] [0,0] [1] % do not reset parts and
> chapters
> (although the syntax is somewhat obscure here).
> also
>    \setuphead [part]
>               [sectionresetset=default,conversion=Romannumerals,placehead=yes]
> and
>    \setuphead [chapter,section,subsection] [sectionsegments=2:100]
>    \setuppagenumbering [alternative=doublesided,way=bytext,partnumber=no]
> (this is what Hans refers to as defaults that are set up differently).
>
> [By the way, the default pagenumbering by part is a very reasonable default,
> as is resetting chapter numbering by part, for often "part" is synonymous with
> "volume". But not always: sometimes a book is to be broken into parts within a
> single volume.]
>
>
> Now the front matter and the back matter are common to the entire book,
> logically part-less (if part is not to be taken as volume).  The front matter
> may contain chapter(s) (preface, introduction, definitions) that may be
> unnumbered.  The back matter will contain appendices (numbered), an index or
> indexes (unnumbered), etc.
>
> For now, I have found no better way then to use funny definitions:
>    \definehead [frontchapter] [chapter] % to get around broken bookmarks
>    \setuphead  [frontchapter] [incrementnumber=list]
>    \definehead [unnumberedchapter] [chapter]
>    \setuphead  [unnumberedchapter] [incrementnumber=list]
>    \definehead [unnumberedpart] [part]
>    \setuphead  [unnumberedpart] [incrementnumber=list,label=no]
>    \definecombinedlist [content]
>      [part,unnumberedpart,frontchapter,unnumberedchapter,chapter,section,subsection,subsubsection]
>    \setuplist
> [part,unnumberedpart,frontchapter,unnumberedchapter,chapter,section,subsection,subsubsection]
>      [alternative=c, % number – title – dots – pagenumber
>       interaction=all]
>
>
> A problem comes up when I want the main body parts to be labeled, as well as
> chapters, as in:
>    \setuphead [part]
>      [sectionresetset=default,conversion=Romannumerals,placehead=yes]
>    \setuplabeltext [chapter=Chapter ] % with trailing space; blank by default
>    \startsectionblockenvironment[bodypart]
>      \setuplist [chapter]  [label=yes]
>    \stopsectionblockenvironment

The problem is always that easier setups also lead to more options 
(undocumented) that when explained lead to the previous code.

At some point we can thing of some 'common preset' but I'm not yet sure 
how to implement that.

btw, there is:

\setupstructurehead
   [chapter]
   [appendixlabel=appendix,
    bodypartlabel=chapter]


-- 

-----------------------------------------------------------------
                                           Hans Hagen | PRAGMA ADE
               Ridderstraat 27 | 8061 GH Hasselt | The Netherlands
     tel: 038 477 53 69 | voip: 087 875 68 74 | www.pragma-ade.com
                                              | www.pragma-pod.nl
-----------------------------------------------------------------
___________________________________________________________________________________
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] 10+ messages in thread

end of thread, other threads:[~2010-08-01 15:12 UTC | newest]

Thread overview: 10+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2010-07-30 17:30 part problems Henning Hraban Ramm
2010-07-30 20:37 ` Wolfgang Schuster
2010-07-30 20:46   ` luigi scarso
2010-07-30 21:00     ` Henning Hraban Ramm
2010-07-30 21:04       ` luigi scarso
2010-07-30 23:08       ` Alan BRASLAU
2010-07-31  9:20         ` Hans Hagen
2010-08-01  8:20           ` Alan BRASLAU
2010-08-01 15:12             ` Hans Hagen
2010-07-30 20:56   ` 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).