![](https://secure.gravatar.com/avatar/c454c7402b3c58eaddc7622147742a81.jpg?s=120&d=mm&r=g)
I am trying to place two tables side-by-side one another with equal spacing between the margin and each table and between tables. That is, I would like the layout to be like --- A --- B --- where A and B are tables and --- represents an equal amount of spacing on the left of table A, between tables A and B, and on the right of table B. At this point, I've been able to place A and B immediately beside one another using \startcombination[2*1] ... \stopcombination, but this doesn't give me the horizontal spacing between the tables that I would like. I would appreciate any help in getting the layout that I am looking for. Thanks in advance, Troy
![](https://secure.gravatar.com/avatar/44ca9eda7aaa681c0e3b3e90125c56b0.jpg?s=120&d=mm&r=g)
Am 24.08.2011 13:56, schrieb Troy Henderson:
I am trying to place two tables side-by-side one another with equal spacing between the margin and each table and between tables. That is, I would like the layout to be like
--- A --- B ---
where A and B are tables and --- represents an equal amount of spacing on the left of table A, between tables A and B, and on the right of table B.
At this point, I've been able to place A and B immediately beside one another using \startcombination[2*1] ... \stopcombination, but this doesn't give me the horizontal spacing between the tables that I would like.
have you tried the 'inbetween' or 'distance' parameter from \setupcombinations? http://wiki.contextgarden.net/Reference/en/setupcombinations Best wishes, Peter
I would appreciate any help in getting the layout that I am looking for.
Thanks in advance,
Troy
___________________________________________________________________________________ If your question is of interest to others as well, please add an entry to the Wiki!
maillist : ntg-context@ntg.nl / http://www.ntg.nl/mailman/listinfo/ntg-context webpage : http://www.pragma-ade.nl / http://tex.aanhet.net archive : http://foundry.supelec.fr/projects/contextrev/ wiki : http://contextgarden.net ___________________________________________________________________________________
![](https://secure.gravatar.com/avatar/44ca9eda7aaa681c0e3b3e90125c56b0.jpg?s=120&d=mm&r=g)
Am 24.08.2011 14:16, schrieb Troy Henderson:
have you tried the 'inbetween' or 'distance' parameter from \setupcombinations?
Well what I would like would be for the following to work
\setupcombinations[before={\hfill},inbetween={\hfill},after={\hfill}]
I looked into the ConTeXt manual (p229[259]) and 'distance' is used for the horizontal distance between objects. You can try '\hss' for the vertical distance (imo less problematic than \hfill). If it all fails, do it yourself. Measure the two table widths with boxes and calculate the offset.
but it doesn't do what I would like for it to do.
Troy
___________________________________________________________________________________ If your question is of interest to others as well, please add an entry to the Wiki!
maillist : ntg-context@ntg.nl / http://www.ntg.nl/mailman/listinfo/ntg-context webpage : http://www.pragma-ade.nl / http://tex.aanhet.net archive : http://foundry.supelec.fr/projects/contextrev/ wiki : http://contextgarden.net ___________________________________________________________________________________
![](https://secure.gravatar.com/avatar/c5ae4f9aa0d3a9bd5376e92b322c3e50.jpg?s=120&d=mm&r=g)
On Wed, 24 Aug 2011, Troy Henderson wrote:
have you tried the 'inbetween' or 'distance' parameter from \setupcombinations?
Well what I would like would be for the following to work
\setupcombinations[before={\hfill},inbetween={\hfill},after={\hfill}]
but it doesn't do what I would like for it to do.
before and after go on the top and the bottom of the combination block, inbetween goes between the figure/table and the caption. One possibility to simplify measurement is to abuse figurecollections (Please wikify). \startbuffer[table:1] \startTABLE \NC A \NC B \NC C \NC D \NC \NR \NC A \NC B \NC C \NC D \NC \NR \NC A \NC B \NC C \NC D \NC \NR \NC A \NC B \NC C \NC D \NC \NR \stopTABLE \stopbuffer \startbuffer[table:2] \startTABLE \NC A \NC B \NC C \NC D \NC E \NC F \NC \NR \NC A \NC B \NC C \NC D \NC E \NC F \NC \NR \NC A \NC B \NC C \NC D \NC E \NC F \NC \NR \NC A \NC B \NC C \NC D \NC E \NC F \NC \NR \NC A \NC B \NC C \NC D \NC E \NC F \NC \NR \NC A \NC B \NC C \NC D \NC E \NC F \NC \NR \NC A \NC B \NC C \NC D \NC E \NC F \NC \NR \NC A \NC B \NC C \NC D \NC E \NC F \NC \NR \stopTABLE \stopbuffer % Ideally, we should be able to place the figure definitions inside the % \startexternalfigurecollection, but that macro starts a group, so the % figure definitions inside are lost. \useexternalfigure[one][table:1][method=buffer] \useexternalfigure[two][table:2][method=buffer] \startexternalfigurecollection[tables] \useexternalfigure[dummy][one] \useexternalfigure[dummy][two] \stopexternalfigurecollection \definemeasure [sidebyside] [\the\dimexpr\hsize/2 - \externalfigurecollectionmaxwidth{tables}/2 - \externalfigurecollectionminwidth{tables}/2] \definecombination[sidebyside] [distance=\measure{sidebyside}, location=middle] \starttext \showframe \placetable [here,nonumber]{Side by side tables} \startcombination[sidebyside][2*1] {\externalfigure[one]}{(a)} {\externalfigure[two]}{(b)} \stopcombination \stoptext @Hans: Can we also have totalheight and totalwidth as parameters of figure combinations (is relatively easy to implement)? Aditya
participants (3)
-
Aditya Mahajan
-
Peter Rolf
-
Troy Henderson