From mboxrd@z Thu Jan 1 00:00:00 1970 X-Msuck: nntp://news.gmane.io/gmane.comp.tex.context/18929 Path: news.gmane.org!not-for-mail From: "luigi.scarso" Newsgroups: gmane.comp.tex.context Subject: Re: A (my) OTR problem Date: Mon, 14 Mar 2005 08:21:34 +0100 Message-ID: <42353B7E.8030301@logosrl.it> References: <4231D8DC.30501@logosrl.it> <4234C72D.9090503@wxs.nl> Reply-To: mailing list for ConTeXt users NNTP-Posting-Host: main.gmane.org Mime-Version: 1.0 Content-Type: multipart/mixed; boundary="===============1636134373==" X-Trace: sea.gmane.org 1110784852 32591 80.91.229.2 (14 Mar 2005 07:20:52 GMT) X-Complaints-To: usenet@sea.gmane.org NNTP-Posting-Date: Mon, 14 Mar 2005 07:20:52 +0000 (UTC) Original-X-From: ntg-context-bounces@ntg.nl Mon Mar 14 08:20:52 2005 Original-Received: from ronja.vet.uu.nl ([131.211.172.88] helo=ronja.ntg.nl) by ciao.gmane.org with esmtp (Exim 4.43) id 1DAjsd-0005VS-2r for gctc-ntg-context-518@m.gmane.org; Mon, 14 Mar 2005 08:20:47 +0100 Original-Received: from localhost (localhost.localdomain [127.0.0.1]) by ronja.ntg.nl (Postfix) with ESMTP id 69B4412877; Mon, 14 Mar 2005 08:21:46 +0100 (CET) Original-Received: from ronja.ntg.nl ([127.0.0.1]) by localhost (ronja.vet.uu.nl [127.0.0.1]) (amavisd-new, port 10024) with LMTP id 03446-03; Mon, 14 Mar 2005 08:21:42 +0100 (CET) Original-Received: from ronja.vet.uu.nl (localhost.localdomain [127.0.0.1]) by ronja.ntg.nl (Postfix) with ESMTP id B6291127E5; Mon, 14 Mar 2005 08:21:42 +0100 (CET) Original-Received: from localhost (localhost.localdomain [127.0.0.1]) by ronja.ntg.nl (Postfix) with ESMTP id E9C07127E5 for ; Mon, 14 Mar 2005 08:21:40 +0100 (CET) Original-Received: from ronja.ntg.nl ([127.0.0.1]) by localhost (ronja.vet.uu.nl [127.0.0.1]) (amavisd-new, port 10024) with LMTP id 03362-06-2 for ; Mon, 14 Mar 2005 08:21:40 +0100 (CET) Original-Received: from ServerNotes.logosrl.it (unknown [81.208.99.91]) by ronja.ntg.nl (Postfix) with ESMTP id 3330B127E3 for ; Mon, 14 Mar 2005 08:21:40 +0100 (CET) Original-Received: from [192.168.2.85] ([192.168.2.85]) by ServerNotes.logosrl.it (Lotus Domino Release 6.5.1) with ESMTP id 2005031408191869-2564 ; Mon, 14 Mar 2005 08:19:18 +0100 User-Agent: Mozilla Thunderbird 1.0 (X11/20041206) X-Accept-Language: en-us, en Original-To: mailing list for ConTeXt users In-Reply-To: <4234C72D.9090503@wxs.nl> X-MIMETrack: Itemize by SMTP Server on ServerNotes/Logo(Release 6.5.1|January 21, 2004) at 14/03/2005 08.19.18, Serialize by Router on ServerNotes/Logo(Release 6.5.1|January 21, 2004) at 14/03/2005 08.19.19, Serialize complete at 14/03/2005 08.19.19 X-Virus-Scanned: by amavisd-new at ntg.nl X-BeenThere: ntg-context@ntg.nl X-Mailman-Version: 2.1.5 Precedence: list List-Id: mailing list for ConTeXt users List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Original-Sender: ntg-context-bounces@ntg.nl Errors-To: ntg-context-bounces@ntg.nl X-Virus-Scanned: by amavisd-new at ntg.nl X-MailScanner-From: ntg-context-bounces@ntg.nl X-MailScanner-To: gctc-ntg-context-518@m.gmane.org Xref: news.gmane.org gmane.comp.tex.context:18929 X-Report-Spam: http://spam.gmane.org/gmane.comp.tex.context:18929 This is a multi-part message in MIME format. --===============1636134373== Content-Type: multipart/alternative; boundary="------------080306090600080904020609" This is a multi-part message in MIME format. --------------080306090600080904020609 Content-Transfer-Encoding: 7bit Content-Type: text/plain; charset=ISO-8859-1; format=flowed h h extern wrote: > luigi.scarso wrote: > >> I have the following code: >> >> \showframe >> \setuplayout[topdistance=0mm,topspace=10mm,header=10mm,headerdistance=10mm, >> >> footerdistance=5mm,footer=20mm,bottomspace=2mm, >> backspace=25mm, >> >> rightmargin=10mm,rightmargindistance=1mm,rightedge=0mm,rightedgedistance=0mm, >> >> >> leftmargin=15mm,leftmargindistance=1mm,leftedge=9mm,leftedgedistance=0mm, >> >> width=fit,height=fit, >> location=middle] >> >> \newdimen\RightMarginWidth \RightMarginWidth=\rightmarginwidth >> \def\PageNumber#1{\vbox to \footerheight{\vss\hbox >> to\RightMarginWidth{\hss #1 \hss}\vss}} >> \setuppagenumbering[location={margin},alternative=doublesided,command={\PageNumber}] >> >> >> \newbox\ContinueNextPage \setbox\ContinueNextPage=\vbox{\strut\hbox >> to\textwidth{\hfill\mathematics{\blacktriangleright}\mathematics{\blacktriangleright}\quad}} >> >> >> >> \starttext >> \dorecurse{20}% >> {\framed[width=\textwidth,height=3em,align={middle,lohi}]{\hfil >> \CONTEXT --\recurselevel \hfil}}% >> >> \stoptext >> >> >> I would like to put \copy\ContinueNextPage after the last \framed in >> every page >> (in this example, after CONTEXT--18 at page 1 and CONTEXT--36 at page >> 2). >> >> I don't want use tables/tabular, i try to use \vsplit. >> >> I try to read page-ini, i find useful things like \everyafterpagebody >> but i'm still confused. > > > This needs to happen in the normal text flow (unless you want to use > more dirty tricks) > > \startsetups [continue] > \strut\hbox to \textwidth > {\hfill\mathematics{\blacktriangleright\blacktriangleright}\quad} > \stopsetups > > \def\LetsCheckItOut > {\dowithnextbox > {\ifdim\dimexpr\pagetotal+\ht\nextbox+\dp\nextbox+\lineheight\relax>\pagegoal > > \endgraf\nobreak\setups[continue]\page > \fi > \box\nextbox} > \vbox} > > > \starttext > > \dorecurse{40} > {\LetsCheckItOut > {\framed > [width=\textwidth,height=3em,align={middle,lohi}] > {\hfil\CONTEXT--\recurselevel\hfil}}} > > \stoptext > Not only it works, it's also very nice: thanks Hans. ( I know that /\newdimen\RightMarginWidth \RightMarginWidth=\rightmarginwidth /it's strange (after all i use \footerheight at the next line...). Some time ago i wrote something like \/MyDimension/=0.87\/rightmarginwidth /// During some corrections/enhancement i made a mistake and i wrote \/rightmarginwidth =0.87/\/MyDimension/// A nightmare. When i feel insecure (will i use this dimensions as readonly or read/write variables ?) i prefer a safe copy (in this case i'm sure that i use \footerheight as a readonly var). ) luigi --------------080306090600080904020609 Content-Transfer-Encoding: 7bit Content-Type: text/html; charset=ISO-8859-1 h h extern wrote:
luigi.scarso wrote:
I have the following code:

\showframe
\setuplayout[topdistance=0mm,topspace=10mm,header=10mm,headerdistance=10mm,
            footerdistance=5mm,footer=20mm,bottomspace=2mm,
            backspace=25mm,
            rightmargin=10mm,rightmargindistance=1mm,rightedge=0mm,rightedgedistance=0mm,
             leftmargin=15mm,leftmargindistance=1mm,leftedge=9mm,leftedgedistance=0mm,
            width=fit,height=fit,
             location=middle]

\newdimen\RightMarginWidth \RightMarginWidth=\rightmarginwidth
\def\PageNumber#1{\vbox to \footerheight{\vss\hbox to\RightMarginWidth{\hss #1 \hss}\vss}}
\setuppagenumbering[location={margin},alternative=doublesided,command={\PageNumber}]

\newbox\ContinueNextPage \setbox\ContinueNextPage=\vbox{\strut\hbox to\textwidth{\hfill\mathematics{\blacktriangleright}\mathematics{\blacktriangleright}\quad}}


\starttext
\dorecurse{20}%
{\framed[width=\textwidth,height=3em,align={middle,lohi}]{\hfil
    \CONTEXT --\recurselevel \hfil}}%

\stoptext


I would like to put \copy\ContinueNextPage after the last \framed in every page
(in this example, after CONTEXT--18 at page 1 and CONTEXT--36 at page 2).

I don't want use tables/tabular, i try to use \vsplit.

I try to read page-ini, i find useful things like \everyafterpagebody
but i'm still confused.

This needs to happen in the normal text flow (unless you want to use more dirty tricks)

\startsetups [continue]
  \strut\hbox to \textwidth
    {\hfill\mathematics{\blacktriangleright\blacktriangleright}\quad}
\stopsetups

\def\LetsCheckItOut
  {\dowithnextbox {\ifdim\dimexpr\pagetotal+\ht\nextbox+\dp\nextbox+\lineheight\relax>\pagegoal
        \endgraf\nobreak\setups[continue]\page
      \fi
      \box\nextbox}
   \vbox}


\starttext

\dorecurse{40}
  {\LetsCheckItOut
     {\framed
        [width=\textwidth,height=3em,align={middle,lohi}]
        {\hfil\CONTEXT--\recurselevel\hfil}}}

\stoptext

Not only it works, it's also  very nice:
thanks Hans.

(
I know that
\newdimen\RightMarginWidth \RightMarginWidth=\rightmarginwidth
it's strange (after all i use \footerheight at the next line...).

Some time ago i wrote something like
\MyDimension=0.87\rightmarginwidth
During some corrections/enhancement  i made a mistake and i wrote
\rightmarginwidth =0.87\MyDimension

A nightmare.

When i feel insecure (will i use this dimensions as readonly or read/write variables ?)
i prefer a safe copy
(in this case i'm sure that i use \footerheight as a readonly var).
)

luigi
--------------080306090600080904020609-- --===============1636134373== Content-Type: text/plain; charset="us-ascii" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit Content-Disposition: inline _______________________________________________ ntg-context mailing list ntg-context@ntg.nl http://www.ntg.nl/mailman/listinfo/ntg-context --===============1636134373==--