ntg-context - mailing list for ConTeXt users
 help / color / mirror / Atom feed
From: Wolfgang Schuster <schuster.wolfgang@gmail.com>
To: mailing list for ConTeXt users <ntg-context@ntg.nl>
Subject: Re: Using \startframedtext with \startcombination
Date: Wed, 1 Oct 2014 14:44:00 +0200	[thread overview]
Message-ID: <9BD0BCA0-F1B1-45C3-BEDE-8119DFCB65EB@gmail.com> (raw)
In-Reply-To: <9A057EEB-3E02-4587-8DAF-427CF0E95BCE@wanadoo.fr>


Am 30.09.2014 um 21:52 schrieb Couvreur Fabrice <couvreur.fabrice@wanadoo.fr>:

> Hello Wolfgang,
> Thank you for the answer, but I did not understand everything.

I try ti explain it with a few examples. When you text in a framedtext environment context creates a box with the given width (which is shown with the red frame), this box is then put into another box (which is shown which a black frame) which has the width of the text area. The large outer box is necessary when you want to align the inner box to the left, middle or right of the text block.


\setupframedtext[width=8cm,framecolor=red,frameoffset=-1ex]

\starttext

\ruledhbox\bgroup
	\startframedtext[left]
	\input ward
	\stopframedtext
\egroup

\blank

\ruledhbox\bgroup
	\startframedtext[middle]
	\input ward
	\stopframedtext
\egroup

\blank

\ruledhbox\bgroup
	\startframedtext[right]
	\input ward
	\stopframedtext
\egroup

\blank

\ruledhbox\bgroup
	\startframedtext[none]
	\input ward
	\stopframedtext
\egroup

\stoptext


When you use now a combination with a framedtext environment each cell of the combination is too wide to show more than one cell on the page. You can see in the following example that the second cell is positioned outside of the visible page area.


\setuppapersize[A4][A3,landscape]

\showframe

\setupframedtext[width=8cm,framecolor=red,frameoffset=-1ex]

\starttext

\startcombination
	\startcontent
		\ruledhbox\bgroup
			\startframedtext[left]
			\input ward
			\stopframedtext
		\egroup
	\stopcontent
	\startcaption
		Left aligned!
	\stopcaption
	\startcontent
		\ruledhbox\bgroup
			\startframedtext[right]
			\input ward
			\stopframedtext
		\egroup
	\stopcontent
	\startcaption
		Right aligned!
	\stopcaption
\stopcombination

\stoptext


Wolfgang
___________________________________________________________________________________
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
___________________________________________________________________________________

  reply	other threads:[~2014-10-01 12:44 UTC|newest]

Thread overview: 5+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2014-09-30 19:52 Couvreur Fabrice
2014-10-01 12:44 ` Wolfgang Schuster [this message]
2014-10-03 11:03   ` Fabrice
  -- strict thread matches above, loose matches on Subject: below --
2014-09-29 16:52 Fabrice Couvreur
2014-09-29 20:25 ` Wolfgang Schuster

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=9BD0BCA0-F1B1-45C3-BEDE-8119DFCB65EB@gmail.com \
    --to=schuster.wolfgang@gmail.com \
    --cc=ntg-context@ntg.nl \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
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).