ntg-context - mailing list for ConTeXt users
 help / color / mirror / Atom feed
From: Kirill Davidov <davidov_ka@edu.surgu.ru>
To: Hans Hagen <j.hagen@freedom.nl>,
	mailing list for ConTeXt users <ntg-context@ntg.nl>
Subject: [NTG-context] Re: Vanishing floats with location=split and \start ... \stopsplittext within
Date: Tue, 4 Jun 2024 23:44:52 +0500	[thread overview]
Message-ID: <a1c70392-068e-4b02-b1e7-4cfa2b61f996@edu.surgu.ru> (raw)
In-Reply-To: <d76db46d-6562-4b1a-abb0-9edeca3d3624@freedom.nl>

On 6/4/24 21:22, Hans Hagen wrote:
> best add a missing \stopplacecodelisting
That one's on me, thank you. Unfortunately, this does not fix the main
issue. Checking the MWE's logs reveals that the splitting command found
nothing to split, even if there's enough text for multiple pages. My
best guess is that something goes awry when checking how much vertical
space is available, since uncommenting the filler line leaves no space
for an additional line in the page.

On 6/4/2024 3:57 PM, Давыдов, Кирилл Александрович wrote:
> On a related note, one can also observe that with specific amounts of
> text a float may end up being split in two on a single page, however I
> could not replicate it.
Replicated it:
\definefloat[codelisting][codelistings]
\setupcaption[codelisting][location=top]
\setuplabeltext[english][codelisting=Listing ]
\showboxes
\starttext
%\dorecurse{37}{line\crlf} % splits fine up to this point
\dorecurse{38}{line\crlf} % split on the same page
%\dorecurse{39}{line\crlf} % float vanishes, "there is nothing to split"
%\dorecurse{40}{line\crlf} % all fine
\startplacecodelisting[
    title=My great C program on display!,
    location=split,
]
\startsplittext
\tt\dorecurse{6}{\input zapf}
\stopsplittext
\stopplacecodelisting
\stoptext
___________________________________________________________________________________
If your question is of interest to others as well, please add an entry to the Wiki!

maillist : ntg-context@ntg.nl / https://mailman.ntg.nl/mailman3/lists/ntg-context.ntg.nl
webpage  : https://www.pragma-ade.nl / https://context.aanhet.net (mirror)
archive  : https://github.com/contextgarden/context
wiki     : https://wiki.contextgarden.net
___________________________________________________________________________________

      reply	other threads:[~2024-06-04 18:50 UTC|newest]

Thread overview: 3+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2024-06-04 13:57 [NTG-context] " Давыдов, Кирилл Александрович
2024-06-04 16:22 ` [NTG-context] " Hans Hagen via ntg-context
2024-06-04 18:44   ` Kirill Davidov [this message]

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=a1c70392-068e-4b02-b1e7-4cfa2b61f996@edu.surgu.ru \
    --to=davidov_ka@edu.surgu.ru \
    --cc=j.hagen@freedom.nl \
    --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).