ntg-context - mailing list for ConTeXt users
 help / color / mirror / Atom feed
* columns and vglue
@ 2000-05-17 17:44 Ed L Cashin
  2000-05-17 22:01 ` Hans Hagen
  0 siblings, 1 reply; 3+ messages in thread
From: Ed L Cashin @ 2000-05-17 17:44 UTC (permalink / raw)


I would like to use columns in a document.  To help the columns line
up, I would like to use vglue between the things in the columns.

I like the method of stretching and shrinking glue because it will
stretch or shrink to the exact distance necessary to achieve the most
appealing layout.  I know there are grid features in context, but I
would like to know whether I can use simple boxes and glue rather than
using the grid.  

In the code below the columns are balancing nicely, but, changing the
null definition of \thingskip to "\vskip\thingskipamt" (and thereby
adding vertical glue between the things in the columns) makes the
columns turn out unbalanced.  Why?  Wouldn't it be easier (or at least
just as easy) for tex to balance the columns when there's glue giving
some breathing room?  

Here's the code:

\def\lyrics{``Rock over London!  Rock on Chicago!  Budweiser -- it's
	the king of beers.''}   % (Wesley Willis)

\newskip\thingskipamt \thingskipamt=1ex plus 2ex minus .5ex
% \def\thingskip{\vskip\thingskipamt}
\def\thingskip{}
\def\mything{\framed{\vbox{foo\par bar\par baz\par\lyrics}}\thingskip}

\starttext
\mything
\startcolumns[n=2]
\mything
\mything
\mything
\mything
\stopcolumns

\blank[2*big]

\startcolumns[n=3]
\mything
\mything
\mything
\mything
\mything
\mything
\stopcolumns

\stoptext

-- 
--Ed Cashin                     PGP public key:
  ecashin@coe.uga.edu           http://www.coe.uga.edu/~ecashin/pgp/


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

* Re: columns and vglue
  2000-05-17 17:44 columns and vglue Ed L Cashin
@ 2000-05-17 22:01 ` Hans Hagen
  2000-05-18 13:07   ` Ed L Cashin
  0 siblings, 1 reply; 3+ messages in thread
From: Hans Hagen @ 2000-05-17 22:01 UTC (permalink / raw)
  Cc: NTG-ConTeXt mailing list

At 01:44 PM 5/17/2000 -0400, Ed L Cashin wrote:

>appealing layout.  I know there are grid features in context, but I
>would like to know whether I can use simple boxes and glue rather than
>using the grid.  

The grid works ok in most cases. When you add your own low level stuff in
there, you can always use \snaptogrid (see core-grd.tex). 

>columns turn out unbalanced.  Why?  Wouldn't it be easier (or at least
>just as easy) for tex to balance the columns when there's glue giving
>some breathing room?  

I'll look into it later. Keep in mind that tex was never designed to do
columns. Supporting them is always hackery and the work of macros. Some day
soon I'll try to optimize the non grid stuff and add more column methods. 

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


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

* Re: columns and vglue
  2000-05-17 22:01 ` Hans Hagen
@ 2000-05-18 13:07   ` Ed L Cashin
  0 siblings, 0 replies; 3+ messages in thread
From: Ed L Cashin @ 2000-05-18 13:07 UTC (permalink / raw)
  Cc: NTG-ConTeXt mailing list

Hans Hagen <pragma@wxs.nl> writes:

> I'll look into it later. Keep in mind that tex was never designed to
> do columns. Supporting them is always hackery and the work of
> macros. Some day soon I'll try to optimize the non grid stuff and
> add more column methods.

Yes, when reading the english version of the manual I got that
impression!  Thanks.

-- 
--Ed Cashin                     PGP public key:
  ecashin@coe.uga.edu           http://www.coe.uga.edu/~ecashin/pgp/


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

end of thread, other threads:[~2000-05-18 13:07 UTC | newest]

Thread overview: 3+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2000-05-17 17:44 columns and vglue Ed L Cashin
2000-05-17 22:01 ` Hans Hagen
2000-05-18 13:07   ` Ed L Cashin

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