Hey again, ntg-context. I would like to align one piece of a line to the left, and another piece of the same line to the right, sort of like numbered math equations, except not math. Additionally I would like to do this inside a narrowed block How can I do this? I have tried side-by-side-frames-inside-a-frame but the two pieces of the line just stay clumped together. I have tried '\startalign' and '\(left|right)aligned' to no avail. I have tried '\hfill' but that pushes things past into/past the right margin...
Am 17.05.2009 um 21:23 schrieb afsmith:
Hey again, ntg-context.
I would like to align one piece of a line to the left, and another piece of the same line to the right, sort of like numbered math equations, except not math. Additionally I would like to do this inside a narrowed block
\starttext \input knuth \startnarrower \input knuth \dontleavehmode\framed[width=\localhsize,align=normal]{left\hfill right} \stopnarrower \stoptext Wolfgang
Thanks Wolfgang. That works... Now how about inside a definition or subject header? Here is an example. \localhsize in this case seems to resolve to a width of 0, making the contained text break as often as it can... \defineframed[lrframe][ width=\localhsize, align=normal, rulethickness=1pt] \setuplayout[header=0pt,footer=0pt] \definedescription[topdesc][ inbetween={\blank[none]}, headstyle={\bf}, style={\tf\rm}, location=top, width=broad] \define[3]\CHRONDESC {\starttopdesc {\dontleavehmode\lrframe{#1\hfill#2}} \startnarrower[left]{#3}\stopnarrower \stoptopdesc} \definehead[mysubject][subject] \setuphead[mysubject][style={\bf}] \define[3]\CHRONSUB {\mysubject{\dontleavehmode\lrframe{#1\hfill#2}} \startnarrower[left]{#3}\stopnarrower} \showframe[text] \starttext \startnarrower[left] \dontleavehmode\lrframe[width=broad] {leftleftleft \hfill right rightrightright} \stopnarrower \crlf \startnarrower[left] \dontleavehmode\lrframe[width=\localhsize] {leftleftleftleft\hfill right rightrightright} \stopnarrower \crlf \CHRONDESC {This happened from June 08 to June 09} {06/08--06/09} {\CHRONDESC {This happened from June 08 to December 08} {06/08--12/08} {\input tufte } \CHRONDESC {This happened from January 09 to June 09} {01/09--06/09} {\input zapf }} \CHRONDESC {This happened from June 09 to July 09} {06/09-07/09} {\input knuth } \crlf \CHRONSUB {This happened from June 08 to June 09} {06/08--06/09} {\CHRONSUB {This happened from June 08 to December 08} {06/08--12/08} {\input tufte } \CHRONSUB {This happened from January 09 to June 09} {01/09--06/09} {\input zapf }} \crlf \stoptext
Am 17.05.2009 um 21:23 schrieb afsmith:
Hey again, ntg-context.
I would like to align one piece of a line to the left, and another piece of the same line to the right, sort of like numbered math equations, except not math. Additionally I would like to do this inside a narrowed block
\starttext
\input knuth
\startnarrower
\input knuth
\dontleavehmode\framed[width=\localhsize,align=normal]{left\hfill right}
\stopnarrower
\stoptext
Wolfgang
participants (2)
-
afsmith
-
Wolfgang Schuster