align and location in \setupcombination
Dear all, In the output of the following sample, figures are left flushed. I found some discussions about the align and location in \setupcombination. "align=" is for caption and "location=middle" is for figures' location. But "align= " worked while "location= " has no effect at all. So I have to enclose \startcombination … \stopcombination in \placefigure[][]{}. How to locate the combined figures at the horizontal center? Thank you for reading. Best regards, \starttext \setupcombination[align=leftflush, location=middle] \startcombination[2*1] {\externalfigure[dummy][]}{aaaaaa} {\externalfigure[dummy][]}{bbbbbb} \stopcombination \stoptext ***** my system: Mac OS 10.8 This is LuaTeX, Version beta-0.70.2-2012052309 (TeX Live 2012) \write18 enabled. (/Users/graph/ConTeXt/tex/texmf-context/tex/context/base/cont-yes.mkiv ConTeXt ver: 2012.10.19 00:06 MKIV fmt: 2012.10.19 int: english/english
2012-10-27 Jeong Dal:
In the output of the following sample, figures are left flushed. I found some discussions about the align and location in \setupcombination. "align=" is for caption and "location=middle" is for figures' location.
But "align= " worked while "location= " has no effect at all.
location is the vertical location of the element within the combination. Compare: \startcombination[2*1] {\externalfigure[dummy][height=1cm]}{aaaaaa} {\externalfigure[dummy][height=4cm]}{bbbbbb} \stopcombination \setupcombination [location=middle] \startcombination[2*1] {\externalfigure[dummy][height=1cm]}{aaaaaa} {\externalfigure[dummy][height=4cm]}{bbbbbb} \stopcombination
So I have to enclose \startcombination … \stopcombination in \placefigure[][]{}. How to locate the combined figures at the horizontal center?
\midaligned {\startcombination[2*1] {\externalfigure[dummy][]}{aaaaaa} {\externalfigure[dummy][]}{bbbbbb} \stopcombination} Marco
Am 28.10.2012 um 15:59 schrieb Marco Patzer
So I have to enclose \startcombination … \stopcombination in \placefigure[][]{}. How to locate the combined figures at the horizontal center?
\midaligned {\startcombination[2*1] {\externalfigure[dummy][]}{aaaaaa} {\externalfigure[dummy][]}{bbbbbb} \stopcombination}
When there are more combinations in the document I would create a named framedtext to align them. \defineframedtext [centered] [frame=off, width=fit, offset=overlay, location=middle] \useMPlibrary[dum] \starttext \startcentered \startcombination[2*1] \startcontent \externalfigure[dummy]% \stopcontent \startcaption aaaaaa \stopcaption \startcontent \externalfigure[dummy]% \stopcontent \startcaption bbbbbb \stopcaption \stopcombination \stopcentered \stoptext Wolfgang
Am 28.10.2012 um 15:59 schrieb Marco Patzer
So I have to enclose \startcombination … \stopcombination in \placefigure[][]{}. How to locate the combined figures at the horizontal center?
\midaligned {\startcombination[2*1] {\externalfigure[dummy][]}{aaaaaa} {\externalfigure[dummy][]}{bbbbbb} \stopcombination}
With the new beta you can replace \midaligned{…} with \startmidaligned … \stopmidaligned Wolfgang
2012-10-30 Wolfgang Schuster:
\midaligned {\startcombination[2*1] {\externalfigure[dummy][]}{aaaaaa} {\externalfigure[dummy][]}{bbbbbb} \stopcombination}
With the new beta you can replace
\midaligned{…}
with
\startmidaligned … \stopmidaligned
I already noted that. I appreciate the movement to a more uniform \start…\stop syntax. Just a random thought: Would it be possible or even make sense to uniform the syntax even further and maybe merge the functionality into \startalignment? At the moment we have one command with an argument for alignments: \startalignment [right|middle|left] \input knuth \stopalignment however three different command for boxed alignments (furthermore, \startrightaligned works just the opposite of \startalignment[right]): \startrightaligned FooBar \stoprightaligned \startmidaligned FooBar \stopmidaligned \startleftaligned FooBar \stopleftaligned This might be easy to remember for us who still know the \midaligned{} syntax, but I guess for new users it's confusing. Additionally, the difference between the commands is unclear. What about an interface like this: \startlinealignment [right|middle|left] FooBar \stoplinealignment Taking this one step further would be to merge both into one command: \startalignment [align=left, alternative=???] \input knuth \stopalignment \startalignment [align=left, alternative=!!!] FooBar \stopalignment Marco
Am 30.10.2012 um 13:36 schrieb Marco Patzer
2012-10-30 Wolfgang Schuster:
\midaligned {\startcombination[2*1] {\externalfigure[dummy][]}{aaaaaa} {\externalfigure[dummy][]}{bbbbbb} \stopcombination}
With the new beta you can replace
\midaligned{…}
with
\startmidaligned … \stopmidaligned
I already noted that. I appreciate the movement to a more uniform \start…\stop syntax.
Not all people on the list to read the dev list :)
Just a random thought: Would it be possible or even make sense to uniform the syntax even further and maybe merge the functionality into \startalignment? At the moment we have one command with an argument for alignments:
\startalignment [right|middle|left] \input knuth \stopalignment
however three different command for boxed alignments (furthermore, \startrightaligned works just the opposite of \startalignment[right]):
\startrightaligned FooBar \stoprightaligned
\startmidaligned FooBar \stopmidaligned
\startleftaligned FooBar \stopleftaligned
This might be easy to remember for us who still know the \midaligned{} syntax, but I guess for new users it's confusing. Additionally, the difference between the commands is unclear. What about an interface like this:
\startlinealignment [right|middle|left] FooBar \stoplinealignment
+1
Taking this one step further would be to merge both into one command:
\startalignment [align=left, alternative=???] \input knuth \stopalignment
\startalignment [align=left, alternative=!!!] FooBar \stopalignment
Not sure if this method is too complicated for a few people. Wolfgang
On 30-10-2012 18:57, Wolfgang Schuster wrote:
Not all people on the list to read the dev list :)
maybe we need a warning (like the mandate 'this site uses cookies' in NL) like 'if you read this message you agree not to complain about an undocumented feature'
Just a random thought: Would it be possible or even make sense to uniform the syntax even further and maybe merge the functionality into \startalignment? At the moment we have one command with an argument for alignments:
\startalignment [right|middle|left] \input knuth \stopalignment
however three different command for boxed alignments (furthermore, \startrightaligned works just the opposite of \startalignment[right]):
\startrightaligned FooBar \stoprightaligned
\startmidaligned FooBar \stopmidaligned
\startleftaligned FooBar \stopleftaligned
This might be easy to remember for us who still know the \midaligned{} syntax, but I guess for new users it's confusing. Additionally, the difference between the commands is unclear. What about an interface like this:
\startlinealignment [right|middle|left] FooBar \stoplinealignment
+1
I've added something for you to check.
Taking this one step further would be to merge both into one command:
\startalignment [align=left, alternative=???] \input knuth \stopalignment
\startalignment [align=left, alternative=!!!] FooBar \stopalignment
Not sure if this method is too complicated for a few people.
Indeed, Hans ----------------------------------------------------------------- Hans Hagen | PRAGMA ADE Ridderstraat 27 | 8061 GH Hasselt | The Netherlands tel: 038 477 53 69 | voip: 087 875 68 74 | www.pragma-ade.com | www.pragma-pod.nl -----------------------------------------------------------------
Am 30.10.2012 um 19:39 schrieb Hans Hagen
Additionally, the difference between the commands is unclear. What about an interface like this:
\startlinealignment [right|middle|left] FooBar \stoplinealignment
+1
I've added something for you to check.
I found a typo: \unexpanded\def\leftaligned {\spac_align_wrapper_handle\v!left } -\unexpanded\def\midaligned {\spac_align_wrapper_handle\v!middle} +\unexpanded\def\middlealigned{\spac_align_wrapper_handle\v!middle} \unexpanded\def\rightaligned {\spac_align_wrapper_handle\v!right } \unexpanded\def\maxaligned {\spac_align_wrapper_handle\v!max } Wolfgang
On 30-10-2012 20:04, Wolfgang Schuster wrote:
I found a typo:
fixed ----------------------------------------------------------------- Hans Hagen | PRAGMA ADE Ridderstraat 27 | 8061 GH Hasselt | The Netherlands tel: 038 477 53 69 | voip: 087 875 68 74 | www.pragma-ade.com | www.pragma-pod.nl -----------------------------------------------------------------
On Tue, 30 Oct 2012 19:39:33 +0100
Hans Hagen
On 30-10-2012 18:57, Wolfgang Schuster wrote:
Not all people on the list to read the dev list :)
maybe we need a warning (like the mandate 'this site uses cookies' in NL) like 'if you read this message you agree not to complain about an undocumented feature'
So, basically you don't want any complaints at all (as the list of undocumented features now far outweighs the list of documented features!) :) Of course, ConTeXt is "use at your own risk" even though I find it to be more "use to your great benefit". Alan
participants (5)
-
Alan BRASLAU
-
Hans Hagen
-
Jeong Dal
-
Marco Patzer
-
Wolfgang Schuster