ntg-context - mailing list for ConTeXt users
 help / color / mirror / Atom feed
* A side by side float that takes advantage of the margin
@ 2005-09-16 14:09 Giuseppe Bilotta
  2005-09-16 14:16 ` Taco Hoekwater
  0 siblings, 1 reply; 6+ messages in thread
From: Giuseppe Bilotta @ 2005-09-16 14:09 UTC (permalink / raw)


I have a situation when I have to put side by side two
floats (a table and figure). My current code is

\placetable[here][label]{caption}%
{\\placesidebyside
{table code}{figure code}
}

The problem is that sometimes the combined width of table
and figure is bigger than the textwidth. I would like the
combo to be centered across the page, not starting from the
left margin of the text and invading the right margin only.

How can I achieve this?

-- 
Giuseppe "Oblomov" Bilotta

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

* Re: A side by side float that takes advantage of the margin
  2005-09-16 14:09 A side by side float that takes advantage of the margin Giuseppe Bilotta
@ 2005-09-16 14:16 ` Taco Hoekwater
  2005-09-16 15:25   ` Hans Hagen
  2005-09-16 15:39   ` Re[2]: " Giuseppe Bilotta
  0 siblings, 2 replies; 6+ messages in thread
From: Taco Hoekwater @ 2005-09-16 14:16 UTC (permalink / raw)




Giuseppe Bilotta wrote:
> I have a situation when I have to put side by side two
> floats (a table and figure). My current code is
> 
> \placetable[here][label]{caption}%
> {\\placesidebyside
> {table code}{figure code}
> }

Have you tried \centerline  (may not work)?

  \placetable[here][label]{caption}%
    {\centerline{\placesidebyside{table code}{figure code}}}

Taco

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

* Re: A side by side float that takes advantage of the margin
  2005-09-16 14:16 ` Taco Hoekwater
@ 2005-09-16 15:25   ` Hans Hagen
  2005-09-16 15:39   ` Re[2]: " Giuseppe Bilotta
  1 sibling, 0 replies; 6+ messages in thread
From: Hans Hagen @ 2005-09-16 15:25 UTC (permalink / raw)


Taco Hoekwater wrote:

>
>
> Giuseppe Bilotta wrote:
>
>> I have a situation when I have to put side by side two
>> floats (a table and figure). My current code is
>>
>> \placetable[here][label]{caption}%
>> {\\placesidebyside
>> {table code}{figure code}
>> }
>
>
> Have you tried \centerline  (may not work)?
>
>  \placetable[here][label]{caption}%
>    {\centerline{\placesidebyside{table code}{figure code}}}

or use 

\startcombination 

\stopcombination 

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

* Re[2]: A side by side float that takes advantage of the margin
  2005-09-16 14:16 ` Taco Hoekwater
  2005-09-16 15:25   ` Hans Hagen
@ 2005-09-16 15:39   ` Giuseppe Bilotta
  2005-09-16 15:55     ` Hans Hagen
  1 sibling, 1 reply; 6+ messages in thread
From: Giuseppe Bilotta @ 2005-09-16 15:39 UTC (permalink / raw)


Friday, September 16, 2005 Taco Hoekwater wrote:



> Giuseppe Bilotta wrote:
>> I have a situation when I have to put side by side two
>> floats (a table and figure). My current code is
>> 
>> \placetable[here][label]{caption}%
>> {\\placesidebyside
>> {table code}{figure code}
>> }

> Have you tried \centerline  (may not work)?

>   \placetable[here][label]{caption}%
>     {\centerline{\placesidebyside{table code}{figure code}}}

It works, but it needs a \scantokens inside the centerline
because of the active stuff in the tables setups.

Thanks.

-- 
Giuseppe "Oblomov" Bilotta

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

* Re: A side by side float that takes advantage of the margin
  2005-09-16 15:39   ` Re[2]: " Giuseppe Bilotta
@ 2005-09-16 15:55     ` Hans Hagen
  2005-09-17 11:44       ` Re[2]: " Giuseppe Bilotta
  0 siblings, 1 reply; 6+ messages in thread
From: Hans Hagen @ 2005-09-16 15:55 UTC (permalink / raw)


Giuseppe Bilotta wrote:

>Friday, September 16, 2005 Taco Hoekwater wrote:
>
>
>
>  
>
>>Giuseppe Bilotta wrote:
>>    
>>
>>>I have a situation when I have to put side by side two
>>>floats (a table and figure). My current code is
>>>
>>>\placetable[here][label]{caption}%
>>>{\\placesidebyside
>>>{table code}{figure code}
>>>}
>>>      
>>>
>
>  
>
>>Have you tried \centerline  (may not work)?
>>    
>>
>
>  
>
>>  \placetable[here][label]{caption}%
>>    {\centerline{\placesidebyside{table code}{figure code}}}
>>    
>>
>
>It works, but it needs a \scantokens inside the centerline
>because of the active stuff in the tables setups.
>  
>
put 'm in buffers: 

\startbuffer[table]
...
\stopbuffer

\startbuffer[figure]
...
\figure

\placetable
    [here][label]
    {caption}
    {\centerline
       {\placesidebyside
          {\getbuffer[table]}
          {\getbuffer[figure]}}}



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

* Re[2]: A side by side float that takes advantage of the margin
  2005-09-16 15:55     ` Hans Hagen
@ 2005-09-17 11:44       ` Giuseppe Bilotta
  0 siblings, 0 replies; 6+ messages in thread
From: Giuseppe Bilotta @ 2005-09-17 11:44 UTC (permalink / raw)


Friday, September 16, 2005 Hans Hagen wrote:

> \startbuffer[table]
> ...
> \stopbuffer

> \startbuffer[figure]
> ...
> \figure

> \placetable
>     [here][label]
>     {caption}
>     {\centerline
>        {\placesidebyside
>           {\getbuffer[table]}
>           {\getbuffer[figure]}}}

Could help, but I've chosen to try a different layout
(separate thread). Can you give it a shot?

-- 
Giuseppe "Oblomov" Bilotta

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

end of thread, other threads:[~2005-09-17 11:44 UTC | newest]

Thread overview: 6+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2005-09-16 14:09 A side by side float that takes advantage of the margin Giuseppe Bilotta
2005-09-16 14:16 ` Taco Hoekwater
2005-09-16 15:25   ` Hans Hagen
2005-09-16 15:39   ` Re[2]: " Giuseppe Bilotta
2005-09-16 15:55     ` Hans Hagen
2005-09-17 11:44       ` Re[2]: " Giuseppe Bilotta

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