ntg-context - mailing list for ConTeXt users
 help / color / mirror / Atom feed
* columns in framedtext
@ 2006-02-18 17:05 Hans van der Meer
  2006-02-20  9:34 ` Taco Hoekwater
  0 siblings, 1 reply; 12+ messages in thread
From: Hans van der Meer @ 2006-02-18 17:05 UTC (permalink / raw)


It seems not possible to typeset in columns (\startcolumns[n=3]... 
\stopcolumns) within a \startframedtext...\stopframedtext. It all  
comes out in one long column.
How can I accomplish this?

yours sincerely,
dr. H. van der Meer

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

* Re: columns in framedtext
  2006-02-18 17:05 columns in framedtext Hans van der Meer
@ 2006-02-20  9:34 ` Taco Hoekwater
  2006-02-20 12:49   ` Hans van der Meer
  2006-02-20 15:18   ` Hans van der Meer
  0 siblings, 2 replies; 12+ messages in thread
From: Taco Hoekwater @ 2006-02-20  9:34 UTC (permalink / raw)




Hans van der Meer wrote:
> It seems not possible to typeset in columns (\startcolumns[n=3]... 
> \stopcolumns) within a \startframedtext...\stopframedtext. It all  
> comes out in one long column.
> How can I accomplish this?

For this, you have to use \starttextbackground (or \startbackground)
instead of \startframedtext.

Cheers, Taco

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

* Re: columns in framedtext
  2006-02-20  9:34 ` Taco Hoekwater
@ 2006-02-20 12:49   ` Hans van der Meer
  2006-02-20 13:05     ` Taco Hoekwater
  2006-02-20 15:18   ` Hans van der Meer
  1 sibling, 1 reply; 12+ messages in thread
From: Hans van der Meer @ 2006-02-20 12:49 UTC (permalink / raw)




On Feb 20, 2006, at 10:34, Taco Hoekwater wrote:

>
>
> Hans van der Meer wrote:
>> It seems not possible to typeset in columns (\startcolumns[n=3]...
>> \stopcolumns) within a \startframedtext...\stopframedtext. It all
>> comes out in one long column.
>> How can I accomplish this?
>
> For this, you have to use \starttextbackground

Thanks, but I am afraid it does not do what I have in mind.
That is a frame of specific dimensions wherein the text is put in  
columns, like this
--------------------
| line  line  line |
| line  line  line |
| line  line  line |
--------------------

It does not matter if the columns become too long or the text too  
wide, like this
--------------------
| line  line  line |
| line  line  line |
| line  line  line |
| line  line  line |
--------------------
   line  line  line
   line  line  line

because in that case I know I have to adapt fontsize, total contents  
etc.
Is there a solution for this?

> (or \startbackground)

\startbackground doesn't work: columns are not honored. Witness this  
example:
	\startbackground
	\startcolumns[n=3] \input tufte \stopcolumns
	\stopbackground

> instead of \startframedtext.
>
> Cheers, Taco


yours sincerely,
dr. H. van der Meer

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

* Re: columns in framedtext
  2006-02-20 12:49   ` Hans van der Meer
@ 2006-02-20 13:05     ` Taco Hoekwater
  2006-02-20 14:19       ` Hans Hagen
  0 siblings, 1 reply; 12+ messages in thread
From: Taco Hoekwater @ 2006-02-20 13:05 UTC (permalink / raw)




Hans van der Meer wrote:
> 
> because in that case I know I have to adapt fontsize, total contents  
> etc.
> Is there a solution for this?

Not that I know of, but maybe something could be done using layers
(not my area)?

Cheers, Taco

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

* Re: columns in framedtext
  2006-02-20 13:05     ` Taco Hoekwater
@ 2006-02-20 14:19       ` Hans Hagen
  2006-02-20 17:27         ` Hans van der Meer
  0 siblings, 1 reply; 12+ messages in thread
From: Hans Hagen @ 2006-02-20 14:19 UTC (permalink / raw)


Taco Hoekwater wrote:
> Hans van der Meer wrote:
>   
>> because in that case I know I have to adapt fontsize, total contents  
>> etc.
>> Is there a solution for this?
>>     
>
> Not that I know of, but maybe something could be done using layers
> (not my area)?
>   
it's up to Hans to wikify this: 

\setuplist
  [chapter]
  [before=\blank,
   after=\blank\setups{section:list}]

% \startsetups section:list
%     \startsimplecolumns[n=2]
%         \placelist[section]
%     \stopsimplecolumns
% \stopsetups

\startsetups section:list
    \startframedtext[width=\textwidth]
    \startsimplecolumns[n=2]
        \placelist[section]
    \stopsimplecolumns
    \stopframedtext
\stopsetups


\starttext

\title{Contents}

\placelist[chapter]

\chapter{whatever} \dorecurse{10}{\section{Oeps}}

\chapter{whatever} \dorecurse{10}{\section{Oeps}}

\stoptext


-----------------------------------------------------------------
                                          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] 12+ messages in thread

* Re: columns in framedtext
  2006-02-20  9:34 ` Taco Hoekwater
  2006-02-20 12:49   ` Hans van der Meer
@ 2006-02-20 15:18   ` Hans van der Meer
  2006-02-20 16:11     ` Hans van der Meer
  2006-02-20 23:21     ` Hans Hagen
  1 sibling, 2 replies; 12+ messages in thread
From: Hans van der Meer @ 2006-02-20 15:18 UTC (permalink / raw)


I have been experimenting with columnsets too.
There I encounter the problem that I cannot set the distance between  
the columns at will.
Neither lt columnsets force themselves into the frame.
\starttextbackground doesn't help here, at most I get frames around  
the separate columns, not the thing that is wanted.

The bad thing is, that LateX multicols inside a parbox does what is  
wanted.
It would be too bad if such behaviour could not be duplicated in  
ConTeXt!

yours sincerely,
dr. H. van der Meer



On Feb 20, 2006, at 10:34, Taco Hoekwater wrote:

>
>
> Hans van der Meer wrote:
>> It seems not possible to typeset in columns (\startcolumns[n=3]...
>> \stopcolumns) within a \startframedtext...\stopframedtext. It all
>> comes out in one long column.
>> How can I accomplish this?
>
> For this, you have to use \starttextbackground (or \startbackground)
> instead of \startframedtext.
>
> Cheers, Taco
> _______________________________________________
> ntg-context mailing list
> ntg-context@ntg.nl
> http://www.ntg.nl/mailman/listinfo/ntg-context

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

* Re: columns in framedtext
  2006-02-20 15:18   ` Hans van der Meer
@ 2006-02-20 16:11     ` Hans van der Meer
  2006-02-20 16:31       ` Adam Lindsay
  2006-02-20 23:21     ` Hans Hagen
  1 sibling, 1 reply; 12+ messages in thread
From: Hans van der Meer @ 2006-02-20 16:11 UTC (permalink / raw)





On Feb 20, 2006, at 16:18, Hans van der Meer wrote:

> I have been experimenting with columnsets too.
> There I encounter the problem that I cannot set the distance between
> the columns at will.

That has been solved. Just had to dig a little deeper in columns.pdf  
and iron out my bugs.
I will now first pursue Hans Hagens suggestion of using setuplists.

> Neither lt columnsets force themselves into the frame.
> \starttextbackground doesn't help here, at most I get frames around
> the separate columns, not the thing that is wanted.
>
> The bad thing is, that LateX multicols inside a parbox does what is
> wanted.
> It would be too bad if such behaviour could not be duplicated in
> ConTeXt!



yours sincerely,
dr. H. van der Meer

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

* Re: columns in framedtext
  2006-02-20 16:11     ` Hans van der Meer
@ 2006-02-20 16:31       ` Adam Lindsay
  0 siblings, 0 replies; 12+ messages in thread
From: Adam Lindsay @ 2006-02-20 16:31 UTC (permalink / raw)


Hans van der Meer wrote:
> 
> 
> On Feb 20, 2006, at 16:18, Hans van der Meer wrote:
> 
>> I have been experimenting with columnsets too.
>> There I encounter the problem that I cannot set the distance between
>> the columns at will.
> 
> That has been solved. Just had to dig a little deeper in columns.pdf  
> and iron out my bugs.
> I will now first pursue Hans Hagens suggestion of using setuplists.

Unless HH knows more about your use-case than what you've sent to the 
list, it looks like it can be summarised as:
\startframedtext[width=\textwidth]
  \startsimplecolumns[n=2]
   \input knuth
  \stopsimplecolumns
\stopframedtext

\setuplist doesn't enter into it, other than his demonstration.
-- 
=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=
  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] 12+ messages in thread

* Re: columns in framedtext
  2006-02-20 14:19       ` Hans Hagen
@ 2006-02-20 17:27         ` Hans van der Meer
  2006-02-20 22:56           ` Hans Hagen
  0 siblings, 1 reply; 12+ messages in thread
From: Hans van der Meer @ 2006-02-20 17:27 UTC (permalink / raw)


I had already experimented with simplecolumns, because these can be  
placed within framed and at first did seem to do the trick.
But the problem I then encountered -- and could not see how to  
correct that -- is balancing of the columns, both at normal  
linespacing and with fixed lineskip.
The bottomline of the columns is not consistently comeing out straight.
It is then also difficult to get the whitespace above and below at  
equal size.
Is there a solution?

yours sincerely,
dr. H. van der Meer



On Feb 20, 2006, at 15:19, Hans Hagen wrote:

> Taco Hoekwater wrote:
>> Hans van der Meer wrote:
>>
>>> because in that case I know I have to adapt fontsize, total contents
>>> etc.
>>> Is there a solution for this?
>>>
>>
>> Not that I know of, but maybe something could be done using layers
>> (not my area)?
>>
> it's up to Hans to wikify this:
>
> \setuplist
>   [chapter]
>   [before=\blank,
>    after=\blank\setups{section:list}]
>
> % \startsetups section:list
> %     \startsimplecolumns[n=2]
> %         \placelist[section]
> %     \stopsimplecolumns
> % \stopsetups
>
> \startsetups section:list
>     \startframedtext[width=\textwidth]
>     \startsimplecolumns[n=2]
>         \placelist[section]
>     \stopsimplecolumns
>     \stopframedtext
> \stopsetups
>
>
> \starttext
>
> \title{Contents}
>
> \placelist[chapter]
>
> \chapter{whatever} \dorecurse{10}{\section{Oeps}}
>
> \chapter{whatever} \dorecurse{10}{\section{Oeps}}
>
> \stoptext
>
>
> -----------------------------------------------------------------
>                                           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
> -----------------------------------------------------------------
>
> _______________________________________________
> ntg-context mailing list
> ntg-context@ntg.nl
> http://www.ntg.nl/mailman/listinfo/ntg-context

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

* Re: columns in framedtext
  2006-02-20 17:27         ` Hans van der Meer
@ 2006-02-20 22:56           ` Hans Hagen
  2006-02-22 10:26             ` Hans van der Meer
  0 siblings, 1 reply; 12+ messages in thread
From: Hans Hagen @ 2006-02-20 22:56 UTC (permalink / raw)


Hans van der Meer wrote:
> I had already experimented with simplecolumns, because these can be  
> placed within framed and at first did seem to do the trick.
> But the problem I then encountered -- and could not see how to  
> correct that -- is balancing of the columns, both at normal  
> linespacing and with fixed lineskip.
> The bottomline of the columns is not consistently comeing out straight.
> It is then also difficult to get the whitespace above and below at  
> equal size.
> Is there a solution?
>   
actually, pdftex now has a feature to manipulate lineheights/depths but i will start using that when i'm sure that this version of pdftex is widely spreak 

you can try to add struts, 

\startsimplecolumns
\begstrut some text ... and more \endstrut 
\stopsimplecolumns 

-----------------------------------------------------------------
                                          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] 12+ messages in thread

* Re: columns in framedtext
  2006-02-20 15:18   ` Hans van der Meer
  2006-02-20 16:11     ` Hans van der Meer
@ 2006-02-20 23:21     ` Hans Hagen
  1 sibling, 0 replies; 12+ messages in thread
From: Hans Hagen @ 2006-02-20 23:21 UTC (permalink / raw)


Hans van der Meer wrote:
> I have been experimenting with columnsets too.
> There I encounter the problem that I cannot set the distance between  
> the columns at will.
>   
hm, one can set the distance for each column (isn't that in the 
columns.pdf manual?)

> Neither lt columnsets force themselves into the frame.
> \starttextbackground doesn't help here, at most I get frames around  
> the separate columns, not the thing that is wanted.
>   
so what exactly is it that you want? you can have background behind columns
> The bad thing is, that LateX multicols inside a parbox does what is  
> wanted.
> It would be too bad if such behaviour could not be duplicated in  
> ConTeXt!
>   
column sas part of the text flow and columns inside a box are really differen things; one involves the otr, the other is a 'local vsplit'; the normal multi column handler can be used intermixed with one column mode and (unless one messes around with interline spacing because that will confuse vsplit) this should work well; 

the simple columns mechanism is just an enhanced vsplit; 

my guess is that multicols uses a different routine for both cases as well (at least at the flushing level) 

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] 12+ messages in thread

* Re: columns in framedtext
  2006-02-20 22:56           ` Hans Hagen
@ 2006-02-22 10:26             ` Hans van der Meer
  0 siblings, 0 replies; 12+ messages in thread
From: Hans van der Meer @ 2006-02-22 10:26 UTC (permalink / raw)




On Feb 20, 2006, at 23:56, Hans Hagen wrote:

> Hans van der Meer wrote:
>> I had already experimented with simplecolumns, because these can be
>> placed within framed and at first did seem to do the trick.
>> But the problem I then encountered -- and could not see how to
>> correct that -- is balancing of the columns, both at normal
>> linespacing and with fixed lineskip.
>> The bottomline of the columns is not consistently comeing out  
>> straight.
>> It is then also difficult to get the whitespace above and below at
>> equal size.
>> Is there a solution?
>>
> actually, pdftex now has a feature to manipulate lineheights/depths  
> but i will start using that when i'm sure that this version of  
> pdftex is widely spreak

Thanks Hans. This remark pointed the way. It is so simple I nearly  
feel ashamed.
\startsimplecolumns can be forced to a neat straight bottomline just  
by setting a \baselineskip without stretch or shrink. I therefore did:
	\baselineskip\bodyfontsize
	\advance\baselineskip (dimension)
this extra space settable with [lineskip=dimension] in the calling  
command.

By the way, I did this work in order to implement into ConTeXt the  
LaTeX files of Dennis van Dok's recent article in the NTG MAPS "Jewel  
case listings for mp3 cdroms". If the code seems stable enough, I  
will make it available through Dennis.


yours sincerely,
dr. H. van der Meer

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

end of thread, other threads:[~2006-02-22 10:26 UTC | newest]

Thread overview: 12+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2006-02-18 17:05 columns in framedtext Hans van der Meer
2006-02-20  9:34 ` Taco Hoekwater
2006-02-20 12:49   ` Hans van der Meer
2006-02-20 13:05     ` Taco Hoekwater
2006-02-20 14:19       ` Hans Hagen
2006-02-20 17:27         ` Hans van der Meer
2006-02-20 22:56           ` Hans Hagen
2006-02-22 10:26             ` Hans van der Meer
2006-02-20 15:18   ` Hans van der Meer
2006-02-20 16:11     ` Hans van der Meer
2006-02-20 16:31       ` Adam Lindsay
2006-02-20 23:21     ` 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).