ntg-context - mailing list for ConTeXt users
 help / color / mirror / Atom feed
* Unbalanced column widths
@ 2002-07-14 18:07 John Culleton
  2002-07-14 21:06 ` Henning Hraban Ramm
  0 siblings, 1 reply; 15+ messages in thread
From: John Culleton @ 2002-07-14 18:07 UTC (permalink / raw)


It is possible to set up unbalanced column widths? One can do it
with pragraphs but there seems to be no mechanism for setting
the left column narrower than the right column. Or perhaps it exists and I 
have not found the directions yet. 

John Culleton

__________________________________________________
D O T E A S Y - "Join the web hosting revolution!"
             http://www.doteasy.com


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

* Re: Unbalanced column widths
  2002-07-14 18:07 Unbalanced column widths John Culleton
@ 2002-07-14 21:06 ` Henning Hraban Ramm
  2002-07-16 12:39   ` John Culleton
  0 siblings, 1 reply; 15+ messages in thread
From: Henning Hraban Ramm @ 2002-07-14 21:06 UTC (permalink / raw)


Am Sonntag, 14. Juli 2002 20:07 schrieb John Culleton:
> It is possible to set up unbalanced column widths? One can do it
> with pragraphs but there seems to be no mechanism for setting
> the left column narrower than the right column. Or perhaps it exists and I
> have not found the directions yet.

You could use columnsets and do the paragraph breaking by hand.

Grüßlis vom Hraban!
-- 
http://www.angerweit.de
http://www.fiee.net/texnique/
http://www.ramm.ch
---


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

* Re: Unbalanced column widths
  2002-07-14 21:06 ` Henning Hraban Ramm
@ 2002-07-16 12:39   ` John Culleton
  2002-07-16 18:27     ` Henning Hraban Ramm
  2002-07-19 20:47     ` Hans Hagen
  0 siblings, 2 replies; 15+ messages in thread
From: John Culleton @ 2002-07-16 12:39 UTC (permalink / raw)


On Sunday 14 July 2002 05:06 pm, Henning Hraban Ramm wrote:
> Am Sonntag, 14. Juli 2002 20:07 schrieb John Culleton:
> > It is possible to set up unbalanced column widths? One can do it
> > with pragraphs but there seems to be no mechanism for setting
> > the left column narrower than the right column. Or perhaps it exists and
> > I have not found the directions yet.
>
> You could use columnsets and do the paragraph breaking by hand.
>
> Grüßlis vom Hraban!

Can you be more specific? Are you suggesting paragraphs instead of columns?

Thanks 

John C. 

__________________________________________________
D O T E A S Y - "Join the web hosting revolution!"
             http://www.doteasy.com


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

* Re: Unbalanced column widths
  2002-07-16 12:39   ` John Culleton
@ 2002-07-16 18:27     ` Henning Hraban Ramm
  2002-07-19 20:47     ` Hans Hagen
  1 sibling, 0 replies; 15+ messages in thread
From: Henning Hraban Ramm @ 2002-07-16 18:27 UTC (permalink / raw)


Am Dienstag, 16. Juli 2002 14:39 schrieb John Culleton:
> Can you be more specific? Are you suggesting paragraphs instead of columns?

Sorry, I got not yet experienced with columnsets, but it should work like this 
(sample of the header field of a multi column layout):

\definecolumnset[five][n=5,distance=6mm]
\definecolumntextarea	[mytitlefiedl] [right][x=1,y=1,nx=4,ny=18]
\definecolumntextarea	[mytitlefield] [left] [x=2,y=1,nx=4,ny=18]

\startbuffer[sample]
Name Author
\title{My Title}
Some Preface
\stopbuffer
\setupcolumntextareatext [mytitlefield] [right][{\getbuffer[sample]}]

Hint: Define a columnset whose column width fits n-times in both of your 
desired text columns. Define column text areas for them.
x = start in set column x
y = start in grid line y
nx = span nx set columns
ny = span ny grid lines

As following you get five slim columns (as defined above):
\startcolumnset[five]
\stopcolumnset

HTH

Grüßlis vom Hraban!
-- 
http://www.angerweit.de
http://www.fiee.net
http://www.ramm.ch
---


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

* Re: Unbalanced column widths
  2002-07-16 12:39   ` John Culleton
  2002-07-16 18:27     ` Henning Hraban Ramm
@ 2002-07-19 20:47     ` Hans Hagen
  2002-07-24 17:19       ` Willi Egger
  1 sibling, 1 reply; 15+ messages in thread
From: Hans Hagen @ 2002-07-19 20:47 UTC (permalink / raw)
  Cc: Henning Hraban Ramm, ntg-context

At 08:39 AM 7/16/2002 -0400, John Culleton wrote:
>On Sunday 14 July 2002 05:06 pm, Henning Hraban Ramm wrote:
> > Am Sonntag, 14. Juli 2002 20:07 schrieb John Culleton:
> > > It is possible to set up unbalanced column widths? One can do it
> > > with pragraphs but there seems to be no mechanism for setting
> > > the left column narrower than the right column. Or perhaps it exists and
> > > I have not found the directions yet.
> >
> > You could use columnsets and do the paragraph breaking by hand.
> >
> > Grüßlis vom Hraban!
>
>Can you be more specific? Are you suggesting paragraphs instead of columns?

\definecolumnset[two][n=2]

\setupcolumnset[two][1][width=4cm]
\setupcolumnset[two][2][width=8cm]

\startcolumnset[two]

some text

\stopcolumnset

now, run this document, and see where the second column starts, put a 
\nextcolumn (or bla-\nextcolumn) there and voila

this is how far tex can go

Hans
-------------------------------------------------------------------------
                                   Hans Hagen | PRAGMA ADE | pragma@wxs.nl
                       Ridderstraat 27 | 8061 GH Hasselt | The Netherlands
  tel: +31 (0)38 477 53 69 | fax: +31 (0)38 477 53 74 | www.pragma-ade.com
-------------------------------------------------------------------------
                        information: http://www.pragma-ade.com/roadmap.pdf
                     documentation: http://www.pragma-ade.com/showcase.pdf
-------------------------------------------------------------------------


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

* Re: Unbalanced column widths
  2002-07-19 20:47     ` Hans Hagen
@ 2002-07-24 17:19       ` Willi Egger
  2002-07-25  7:17         ` Hans Hagen
  0 siblings, 1 reply; 15+ messages in thread
From: Willi Egger @ 2002-07-24 17:19 UTC (permalink / raw)


Hi Hans,

This sounds great! I tried your code, but I did not get more than the
following error:

 pdfeTeX, Version 3.14159-1.00b-pretest-20020211-2.1 (Web2c 7.3.7x)
ConTeXt  ver: 2002.6.25  fmt: 2002.7.14  int: english  mes: english

! Arithmetic overflow.
<recently read> \scratchcounter

\OTRSETassignwidths ...ratchdimen \scratchcounter
                                                  \dorecurse \nofcolumns
{\d...

\OTRSETinitializecolumns ...i \OTRSETassignwidths
                                                  \global \mofcolumns =1
\co...

\OTRSETrestart ...sttext \OTRSETinitializecolumns
                                                  \OTRSETcheckinsert
\OTRSET...

\dostartcolumnset ...list {#1}\OTRSETgotonextpage
                                                  \OTRSETgetmanualbalance
\O...
<to be read again>
                   \par
l.11

Is my CONTEXT to old?

Kind regards Willi


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

* Re: Unbalanced column widths
  2002-07-24 17:19       ` Willi Egger
@ 2002-07-25  7:17         ` Hans Hagen
  2002-07-26 15:03           ` John Culleton
  0 siblings, 1 reply; 15+ messages in thread
From: Hans Hagen @ 2002-07-25  7:17 UTC (permalink / raw)
  Cc: ntg-context

At 07:19 PM 7/24/2002 +0200, you wrote:
>Hi Hans,
>
>This sounds great! I tried your code, but I did not get more than the
>following error:
>
>  pdfeTeX, Version 3.14159-1.00b-pretest-20020211-2.1 (Web2c 7.3.7x)
>ConTeXt  ver: 2002.6.25  fmt: 2002.7.14  int: english  mes: english

no, but maybe you did not define columnset in the right way (i will add 
more error catching when finishing the module)

Hans

-------------------------------------------------------------------------
                                   Hans Hagen | PRAGMA ADE | pragma@wxs.nl
                       Ridderstraat 27 | 8061 GH Hasselt | The Netherlands
  tel: +31 (0)38 477 53 69 | fax: +31 (0)38 477 53 74 | www.pragma-ade.com
-------------------------------------------------------------------------
                        information: http://www.pragma-ade.com/roadmap.pdf
                     documentation: http://www.pragma-ade.com/showcase.pdf
-------------------------------------------------------------------------


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

* Re: Unbalanced column widths
  2002-07-25  7:17         ` Hans Hagen
@ 2002-07-26 15:03           ` John Culleton
  2002-07-26 18:23             ` Hans Hagen
  0 siblings, 1 reply; 15+ messages in thread
From: John Culleton @ 2002-07-26 15:03 UTC (permalink / raw)
  Cc: ntg-context

On Thursday 25 July 2002 03:17 am, Hans Hagen wrote:
> At 07:19 PM 7/24/2002 +0200, you wrote:
> >Hi Hans,
> >
> >This sounds great! I tried your code, but I did not get more than the
> >following error:
> >
> >  pdfeTeX, Version 3.14159-1.00b-pretest-20020211-2.1 (Web2c 7.3.7x)
> >ConTeXt  ver: 2002.6.25  fmt: 2002.7.14  int: english  mes: english
>
> no, but maybe you did not define columnset in the right way (i will add
> more error catching when finishing the module)
>
> Hans
>

Hans:
I ran the file listed below thorugh texexec and it errored off:
------------------------------------------------------
\definecolumnset[two[n=2]
\setupcolumnset[two][1[width=4cm]
\setupcolumnset[two][2][width=8cm]
\starttext
\startcolumnset[two]
Here is some text.
Here is some more.
\stopcolumnset
\stoptex

Here is the pertinent error message:
systems        : begin file columtest at line 4
! Missing number, treated as zero.
<to be read again>
                   \@@mctwonrechts
\OTRSETinitializecolumns ...dentifier \c!nrechts }
                                                  \global \lofcolumns 
=\getv...

\OTRSETrestart ...sttext \OTRSETinitializecolumns
                                                  \OTRSETcheckinsert 
\OTRSET...

\dostartcolumnset ...list {#1}\OTRSETgotonextpage
                                                  \OTRSETgetmanualbalance 
\O...
<to be read again>
                   H
l.6 H
     ere is some text.
--------------------------------------
Any suggestions?

John Culleton


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

* Re: Unbalanced column widths
  2002-07-26 15:03           ` John Culleton
@ 2002-07-26 18:23             ` Hans Hagen
  2002-07-26 21:14               ` John Culleton
  0 siblings, 1 reply; 15+ messages in thread
From: Hans Hagen @ 2002-07-26 18:23 UTC (permalink / raw)
  Cc: ntg-context

At 11:03 AM 7/26/2002 -0400, you wrote:

>I ran the file listed below thorugh texexec and it errored off:
>------------------------------------------------------
>\definecolumnset[two[n=2]

                      ][

Hans
-------------------------------------------------------------------------
                                   Hans Hagen | PRAGMA ADE | pragma@wxs.nl
                       Ridderstraat 27 | 8061 GH Hasselt | The Netherlands
  tel: +31 (0)38 477 53 69 | fax: +31 (0)38 477 53 74 | www.pragma-ade.com
-------------------------------------------------------------------------
                        information: http://www.pragma-ade.com/roadmap.pdf
                     documentation: http://www.pragma-ade.com/showcase.pdf
-------------------------------------------------------------------------


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

* Re: Unbalanced column widths
  2002-07-26 18:23             ` Hans Hagen
@ 2002-07-26 21:14               ` John Culleton
  2002-07-26 21:37                 ` Hans Hagen
  0 siblings, 1 reply; 15+ messages in thread
From: John Culleton @ 2002-07-26 21:14 UTC (permalink / raw)
  Cc: ntg-context

On Friday 26 July 2002 02:23 pm, Hans Hagen wrote:
> At 11:03 AM 7/26/2002 -0400, you wrote:
> >I ran the file listed below thorugh texexec and it errored off:
> >------------------------------------------------------
> >\definecolumnset[two[n=2]
>
>                       ][

OK I cleaned up the typos and now it works. In many ways it is better
than the alternative of \startcolumns. In particular forcing a column
break is quite reliable. It does not do column balancing, but I have 
done manual (cut and try) column balancing and that works OK.

All in all \columnset is more flexible, reliable and useful than 
\startcolumns. 

Just those darn typos :-)

John Culleton


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

* Re: Unbalanced column widths
  2002-07-26 21:14               ` John Culleton
@ 2002-07-26 21:37                 ` Hans Hagen
  2002-07-27 11:48                   ` John Culleton
  0 siblings, 1 reply; 15+ messages in thread
From: Hans Hagen @ 2002-07-26 21:37 UTC (permalink / raw)
  Cc: ntg-context

At 05:14 PM 7/26/2002 -0400, John Culleton wrote:
>On Friday 26 July 2002 02:23 pm, Hans Hagen wrote:
> > At 11:03 AM 7/26/2002 -0400, you wrote:
> > >I ran the file listed below thorugh texexec and it errored off:
> > >------------------------------------------------------
> > >\definecolumnset[two[n=2]
> >
> >                       ][
>
>OK I cleaned up the typos and now it works. In many ways it is better
>than the alternative of \startcolumns. In particular forcing a column
>break is quite reliable. It does not do column balancing, but I have
>done manual (cut and try) column balancing and that works OK.
>
>All in all \columnset is more flexible, reliable and useful than
>\startcolumns.

well, you can balance:

just say

\setupcolumnset[two][1][n=34]
\setupcolumnset[two][2][n=21]

to force a split

Hans
-------------------------------------------------------------------------
                                   Hans Hagen | PRAGMA ADE | pragma@wxs.nl
                       Ridderstraat 27 | 8061 GH Hasselt | The Netherlands
  tel: +31 (0)38 477 53 69 | fax: +31 (0)38 477 53 74 | www.pragma-ade.com
-------------------------------------------------------------------------
                        information: http://www.pragma-ade.com/roadmap.pdf
                     documentation: http://www.pragma-ade.com/showcase.pdf
-------------------------------------------------------------------------


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

* Re: Unbalanced column widths
  2002-07-26 21:37                 ` Hans Hagen
@ 2002-07-27 11:48                   ` John Culleton
  2002-07-27 13:44                     ` Hans Hagen
  0 siblings, 1 reply; 15+ messages in thread
From: John Culleton @ 2002-07-27 11:48 UTC (permalink / raw)
  Cc: ntg-context

On Friday 26 July 2002 05:37 pm, Hans Hagen wrote:
> At 05:14 PM 7/26/2002 -0400, John Culleton wrote:
> >On Friday 26 July 2002 02:23 pm, Hans Hagen wrote:
> > > At 11:03 AM 7/26/2002 -0400, you wrote:
> >
>
> well, you can balance:
>
> just say
>
> \setupcolumnset[two][1][n=34]
> \setupcolumnset[two][2][n=21]
>
> to force a split
>
> Hans

OK I'll try it. What does the [n=34] reperesent? the number of lines in the
column?

I use a narrow column followed by a wide column. If the text overflows to the
next page the wide column is still in effect. So assuming enough text I get 
two wide columns which overlap on the following page. (Bug or feature? :)
When this happens I insert 
\stopcolumnset
\page[yes]
\startcolumnset[alt]
...which is an alternate equal width set of columns.
I insert the above at the point where the page naturally breaks.

I'll keep on playing!

John Culleton


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

* Re: Unbalanced column widths
  2002-07-27 11:48                   ` John Culleton
@ 2002-07-27 13:44                     ` Hans Hagen
  2002-08-15 18:35                       ` John Culleton
  0 siblings, 1 reply; 15+ messages in thread
From: Hans Hagen @ 2002-07-27 13:44 UTC (permalink / raw)
  Cc: ntg-context

At 07:48 AM 7/27/2002 -0400, you wrote:
>On Friday 26 July 2002 05:37 pm, Hans Hagen wrote:
> > At 05:14 PM 7/26/2002 -0400, John Culleton wrote:
> > >On Friday 26 July 2002 02:23 pm, Hans Hagen wrote:
> > > > At 11:03 AM 7/26/2002 -0400, you wrote:
> > >
> >
> > well, you can balance:
> >
> > just say
> >
> > \setupcolumnset[two][1][n=34]
> > \setupcolumnset[two][2][n=21]
> >
> > to force a split
> >
> > Hans
>
>OK I'll try it. What does the [n=34] reperesent? the number of lines in the
>column?

indeed, last page of columnset only

>I use a narrow column followed by a wide column. If the text overflows to the
>next page the wide column is still in effect. So assuming enough text I get
>two wide columns which overlap on the following page. (Bug or feature? :)
>When this happens I insert
>\stopcolumnset
>\page[yes]
>\startcolumnset[alt]
>...which is an alternate equal width set of columns.
>I insert the above at the point where the page naturally breaks.

you can define multiple columnsets and say:

\startcolumnset[whatever,another,...]

which saves you the \page mess

>I'll keep on playing!

the nice things of columnsets are placing graphics

Hans
-------------------------------------------------------------------------
                                   Hans Hagen | PRAGMA ADE | pragma@wxs.nl
                       Ridderstraat 27 | 8061 GH Hasselt | The Netherlands
  tel: +31 (0)38 477 53 69 | fax: +31 (0)38 477 53 74 | www.pragma-ade.com
-------------------------------------------------------------------------
                        information: http://www.pragma-ade.com/roadmap.pdf
                     documentation: http://www.pragma-ade.com/showcase.pdf
-------------------------------------------------------------------------


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

* Re: Unbalanced column widths
  2002-07-27 13:44                     ` Hans Hagen
@ 2002-08-15 18:35                       ` John Culleton
  2002-08-15 20:03                         ` John Culleton
  0 siblings, 1 reply; 15+ messages in thread
From: John Culleton @ 2002-08-15 18:35 UTC (permalink / raw)
  Cc: ntg-context

On Saturday 27 July 2002 09:44 am, Hans Hagen wrote:
> At 07:48 AM 7/27/2002 -0400, you wrote:
> >On Friday 26 July 2002 05:37 pm, Hans Hagen wrote:
> > > At 05:14 PM 7/26/2002 -0400, John Culleton wrote:
> > > >On Friday 26 July 2002 02:23 pm, Hans Hagen wrote:
> > > > > At 11:03 AM 7/26/2002 -0400, you wrote:
> > >
> > > well, you can balance:
> > >
> > > just say
> > >
> > > \setupcolumnset[two][1][n=34]
> > > \setupcolumnset[two][2][n=21]
>

All of a sudden columnset, which worked fine before, stopped working.
I cleaned up some typos and that caused the problem.

So I created a simplistic test file with as few extraneaous factors as
possible, and I got error messages. Here is the file:
----------------------------------------------

\setupoutput
  [pdftex]
%
\definecolumnset[two][n=2]
\setupcolumnset[two][1][width=1.5in]
\setupcolumnset[two][2][width=3.5in]
\starttext
\startcolumnset[two]
foo
bar foo
bar
less 88888888 8888888 8888888888
more 999999999  9999999999
\stopcolumnset
\stoptext
-----------------------------------------
and here are the error messages:
(./test.tuo) (./test.tuo) (./test.tuo) (./test.tuo) (./test.tuo) (./test.tuo)
(./test.tuo) (./test.tuo) (./test.tuo) (./test.tuo) (./test.tuo) (./test.tuo)
(./test.tuo)
systems        : begin file test at line 7
! Arithmetic overflow.
<recently read> \scratchcounter

\OTRSETassignwidths ...ratchdimen \scratchcounter
                                                  \dorecurse \nofcolumns 
{\d...

\OTRSETinitializecolumns ...i \OTRSETassignwidths
                                                  \global \mofcolumns =1 
\co...

\OTRSETrestart ...sttext \OTRSETinitializecolumns
                                                  \OTRSETcheckinsert 
\OTRSET...

\dostartcolumnset ...list {#1}\OTRSETgotonextpage
                                                  \OTRSETgetmanualbalance 
\O...
<to be read again>
                   f
l.9 f
     oo
?
--------------------------------------------------------------------------
I am perplexed again :-(

John Culleton


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

* Re: Unbalanced column widths
  2002-08-15 18:35                       ` John Culleton
@ 2002-08-15 20:03                         ` John Culleton
  0 siblings, 0 replies; 15+ messages in thread
From: John Culleton @ 2002-08-15 20:03 UTC (permalink / raw)
  Cc: ntg-context

On Thursday 15 August 2002 02:35 pm, John Culleton wrote:

> All of a sudden columnset, which worked fine before, stopped working.
> I cleaned up some typos and that caused the problem.
>
>

OK problem solved, but it was a subtle one. When I corrected an error in the
line:

\setupcolumnset[two][1][width=1.5in]

everything stopped working. When I simply commented out the line things
worked again. As near as I can figure the overall width of the two columns
was too great. 

This is perplexing since I set the paper up in landscape and I should have
had plenty of width. Here was my paper setup and my setuplayout:
 \setuppapersize[letter,landscape][letter,landscape]
\setuplayout
  [topspace=0.5cm,
   leftmargin=1cm,
   rightmargin=1cm,
   width=middle,
   grid=yes,
   footer=1.5cm,
   header=1.0cm,
   height=middle]

I am not sure of the effect of width=middle and height=middle. 

John Culleton


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

end of thread, other threads:[~2002-08-15 20:03 UTC | newest]

Thread overview: 15+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2002-07-14 18:07 Unbalanced column widths John Culleton
2002-07-14 21:06 ` Henning Hraban Ramm
2002-07-16 12:39   ` John Culleton
2002-07-16 18:27     ` Henning Hraban Ramm
2002-07-19 20:47     ` Hans Hagen
2002-07-24 17:19       ` Willi Egger
2002-07-25  7:17         ` Hans Hagen
2002-07-26 15:03           ` John Culleton
2002-07-26 18:23             ` Hans Hagen
2002-07-26 21:14               ` John Culleton
2002-07-26 21:37                 ` Hans Hagen
2002-07-27 11:48                   ` John Culleton
2002-07-27 13:44                     ` Hans Hagen
2002-08-15 18:35                       ` John Culleton
2002-08-15 20:03                         ` John Culleton

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