ntg-context - mailing list for ConTeXt users
 help / color / mirror / Atom feed
* \definelayout question
@ 2005-03-03  7:45 Paul Tremblay
  2005-03-03  8:21 ` Hans Hagen
  2005-03-03 10:03 ` Adam Lindsay
  0 siblings, 2 replies; 4+ messages in thread
From: Paul Tremblay @ 2005-03-03  7:45 UTC (permalink / raw)


Thanks Adam for the suggestions on the wiki page.

You point out that I can use \definelayout for odd and even pages.
I assume I can use this command in place of \setuplayout?

I had a problem using \definelayout. I found that I had to use a
\setuplayout before my text, or the first page would not get formatted.
Is the ConTeXt code right below?

Also, is there any way to change the layout for the first page?

\definelayout[first] [....

Thanks

Paul



\part{}

\definelayout[odd][
 topspace=.5in, % the space at the very top of the page
 backspace=3in,  % the space in the gutter 
 header=2in, % the space for headers
 footer=2in, % the space for footers
 leftmargin=1in, % the space for margin notes
 rightmargin=1.5in, % the space for right margin notes
 width=3in, % the width of the body text
 height=7in % the height of the body text
]

\definelayout[even][
 topspace=.5in, % the space at the very top of the page
 backspace=3in,  % the space in the gutter 
 header=2in, % the space for headers
 footer=2in, % the space for footers
 leftmargin=1in, % the space for margin notes
 rightmargin=1.5in, % the space for right margin notes
 width=3in, % the width of the body text
 height=4in % the height of the body text
]

\setuplayout
% the header for the first page of part 1
\definetext[partStart1][header][\vbox{Chapter 1 \vskip5pt Author}]
\setuphead[part][header=partStart1]

-- 

************************
*Paul Tremblay         *
*phthenry@iglou.com    *
************************

^ permalink raw reply	[flat|nested] 4+ messages in thread

* Re: \definelayout question
  2005-03-03  7:45 \definelayout question Paul Tremblay
@ 2005-03-03  8:21 ` Hans Hagen
  2005-03-03 10:03 ` Adam Lindsay
  1 sibling, 0 replies; 4+ messages in thread
From: Hans Hagen @ 2005-03-03  8:21 UTC (permalink / raw)


Paul Tremblay wrote:
> Thanks Adam for the suggestions on the wiki page.
> 
> You point out that I can use \definelayout for odd and even pages.
> I assume I can use this command in place of \setuplayout?
> 
> I had a problem using \definelayout. I found that I had to use a
> \setuplayout before my text, or the first page would not get formatted.
> Is the ConTeXt code right below?
> 
> Also, is there any way to change the layout for the first page?
> 
> \definelayout[first] [....

\definelayout[1][...]

> \definetext[partStart1][header][\vbox{Chapter 1 \vskip5pt Author}]
> \setuphead[part][header=partStart1]

for consistency i'd go for

\definetext
   [partStart1]
   [header]
   [\vbox{\strut Chapter 1 \vskip.25\bodyfontsize Author}]

scales nicer with changes in font and other specs

Hans


-----------------------------------------------------------------
                                           Hans Hagen | PRAGMA ADE
               Ridderstraat 27 | 8061 GH Hasselt | The Netherlands
      tel: 038 477 53 69 | fax: 038 477 53 74 | www.pragma-ade.com
                                              | www.pragma-pod.nl
-----------------------------------------------------------------

^ permalink raw reply	[flat|nested] 4+ messages in thread

* Re: \definelayout question
  2005-03-03  7:45 \definelayout question Paul Tremblay
  2005-03-03  8:21 ` Hans Hagen
@ 2005-03-03 10:03 ` Adam Lindsay
  2005-03-03 10:46   ` Hans Hagen
  1 sibling, 1 reply; 4+ messages in thread
From: Adam Lindsay @ 2005-03-03 10:03 UTC (permalink / raw)


Paul,

I can't really address the bulk of your question (I consider myself a
beginner in the art of the \layout, and am still working through some of
its invocation options), but I do notice a couple things:

Paul Tremblay said this at Thu, 3 Mar 2005 02:45:01 -0500:

>\definelayout[odd][
> header=2in, % the space for headers
> footer=2in, % the space for footers
> height=7in % the height of the body text
>]

This (nominally, without use of page=high or some such) leaves three
inches for the body text. Unlike the right/left margin, header/footer
space is considered part of the textblock's height. I don't know the
historical reasons for this, but it makes a kind of sense.

>\definelayout[even][
> header=2in, % the space for headers
> footer=2in, % the space for footers
> height=4in % the height of the body text
>]

This, then, leaves zero height for the main body text, which is why I see
only a single line typeset on even pages.

\showframe is your esteemed friend in debugging these matters.
-- 
=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=
 Adam T. Lindsay, Computing Dept.     atl@comp.lancs.ac.uk
 Lancaster University, InfoLab21        +44(0)1524/510.514
 Lancaster, LA1 4WA, UK             Fax:+44(0)1524/510.492
-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-

^ permalink raw reply	[flat|nested] 4+ messages in thread

* Re: \definelayout question
  2005-03-03 10:03 ` Adam Lindsay
@ 2005-03-03 10:46   ` Hans Hagen
  0 siblings, 0 replies; 4+ messages in thread
From: Hans Hagen @ 2005-03-03 10:46 UTC (permalink / raw)


Adam Lindsay wrote:

>>\definelayout[odd][
>>header=2in, % the space for headers
>>footer=2in, % the space for footers
>>height=7in % the height of the body text
>>]
> 
> 
> This (nominally, without use of page=high or some such) leaves three
> inches for the body text. Unlike the right/left margin, header/footer
> space is considered part of the textblock's height. I don't know the
> historical reasons for this, but it makes a kind of sense.

just keep in mind that header and footer lines can be empty, not-present, high, 
etc, so in a sense they are part of the flow

margins are virtual things and their width influence line breaking, backgrounds 
etc, since there can be multiple margins it does not make sense to define 
back-of-page -> text as being the margin, because then we would need other 
variables to set the real ones; backspace (in dutch 'rugwit' is a better name i 
think) is more convenient

Hans
-----------------------------------------------------------------
                                           Hans Hagen | PRAGMA ADE
               Ridderstraat 27 | 8061 GH Hasselt | The Netherlands
      tel: 038 477 53 69 | fax: 038 477 53 74 | www.pragma-ade.com
                                              | www.pragma-pod.nl
-----------------------------------------------------------------

^ permalink raw reply	[flat|nested] 4+ messages in thread

end of thread, other threads:[~2005-03-03 10:46 UTC | newest]

Thread overview: 4+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2005-03-03  7:45 \definelayout question Paul Tremblay
2005-03-03  8:21 ` Hans Hagen
2005-03-03 10:03 ` Adam Lindsay
2005-03-03 10:46   ` Hans Hagen

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