ntg-context - mailing list for ConTeXt users
 help / color / mirror / Atom feed
* XY arranging ignores dx/dy
@ 2005-08-04  4:28 Angus Lees
  0 siblings, 0 replies; only message in thread
From: Angus Lees @ 2005-08-04  4:28 UTC (permalink / raw)


The XY arranging macro basically ignores dx/dy parameters by always
padding out the space between "pages".

Here's the existing ConTeXt macro for reference - removing \vss and
\hss makes it do the right thing (imo).  I'd give a simple patch, but
I think the ideal behaviour might be to pad if (and only if) dx/dy
were not specified, which is starting to push my TeX skills.

\def\pusharrangedpageXY#1%
  {\doglobal\increment\arrangedpageN
   \reportarrangedpage\arrangedpageN
   \doglobal\increment\arrangedpageM
   \global\setbox\arrangedpageB\hbox
     \ifdim\@@ppwidth>\zeropoint to \@@ppwidth \fi
     {\ifvoid\arrangedpageB\else
        \unhbox\arrangedpageB\hss\hskip\@@ppdx\hss
      \fi
      \box#1}%
   \ifnum\arrangedpageM<\arrangedpageX\else
     \global\setbox\arrangedpageA\vbox
          \ifdim\@@ppheight>\zeropoint to \@@ppheight \fi
       {\offinterlineskip
        \ifvoid\arrangedpageA\else
          \unvbox\arrangedpageA\vss\vskip\@@ppdy\vss
        \fi
        \box\arrangedpageB}%
     \doglobal\newcounter\arrangedpageM
   \fi
   \ifnum\arrangedpageN<\arrangedpageT\else
     \poparrangedpages
   \fi}


Minimal test, note the dx/dy distances:

 \definepapersize[label][width=30mm,height=20mm]
 \setuppapersize[label][A4]
 \setuppaper[dx=1mm,dy=1mm,nx=2,ny=6]
 \setuparranging[XY]
 \showframe[edge]
 \starttext \dorecurse{6}{test \recurselevel \page} \stoptext

-- 
 - Gus

^ permalink raw reply	[flat|nested] only message in thread

only message in thread, other threads:[~2005-08-04  4:28 UTC | newest]

Thread overview: (only message) (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2005-08-04  4:28 XY arranging ignores dx/dy Angus Lees

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