[NTG-context] Splitting a combination of figures (also a philosophical question)

Wolfgang Schuster schuster.wolfgang at gmail.com
Wed May 20 23:12:34 CEST 2015


> Am 20.05.2015 um 16:43 schrieb Mojca Miklavec <mojca.miklavec.lists at gmail.com>:
> 
> Hello,
> 
> This is not strictly a ConTeXt question.
> 
> I have two almost identical figures which I want to display one after
> the other. Ideally that would be on the same page with the combination
> of both having a single figure number (and possibly the two individual
> figures having labels (a) and (b), but that's not strictly required).
> 
> However if the page breaks are not favourable, it would be OK to split
> the two figures, so that one ends up on the bottom of the previous
> page and the second one on the top of the new page.
> 
> I could use two separate figure numbers, but then I would need to
> change the text that references the figures (and when the layout
> changes, so that I would figure out that both figures would eventually
> fit on a single page, I would have to change the text again).
> 
> Is there any reasonable (and acceptable) solution to that? One option
> would be to have
>    "Figure 1.5a: description"
> on the first page and
>    "Figure 1.5b: description"
> on the second page while a reference to the figure would still show
> "Figure 1.5", but I'm not sure if this is doable.
> 
> I would like to hear if anyone had a similar "challenge" and what
> solution you used.


\setupexternalfigure[location=default]

\starttext

\dorecurse{5}{\input ward }
%\dorecurse{2}{\input ward }

\startplacefigure[location=split,title=Float dummy]
	\startxtable[frame=off,align=middle]
		\startxrow
			\startxcell
				\dontleavehmode\externalfigure[cow]
			\stopxcell
		\stopxrow
		\startxrow
			\startxcell
				\dontleavehmode\externalfigure[hacker]
			\stopxcell
		\stopxrow
	\stopxtable
\stopplacefigure

\stoptext

Wolfgang


More information about the ntg-context mailing list