Hi! Today I discovered that the parameter order in float location matters: \starttext \samplefile{knuth} \startplacefigure [location={top,none}] %% works: float is at the top \externalfigure \stopplacefigure \startplacefigure [location={none,top}] %% top is ignored here \externalfigure \stopplacefigure \stoptext Not sure if that's how it's supposed to be. In any case, I didn't expect it. Marco
Am 30.11.21 um 12:16 schrieb Marco Patzer via ntg-context:
Hi!
Today I discovered that the parameter order in float location matters:
\starttext \samplefile{knuth}
\startplacefigure [location={top,none}] %% works: float is at the top \externalfigure \stopplacefigure
\startplacefigure [location={none,top}] %% top is ignored here \externalfigure \stopplacefigure \stoptext
Not sure if that's how it's supposed to be. In any case, I didn't expect it.
Well, in {bottom,top,here} it’s the order that TeX should try. In some other combinations it might make less sense. Hraban
On Tue, 30 Nov 2021 13:06:00 +0100
Henning Hraban Ramm via ntg-context
Well, in {bottom,top,here} it’s the order that TeX should try.
“location“ sets the location of the caption as well as the position of the entire float. If you want to influence one, you'll also have to specify the other, AFAIK. Which is a bit unfortunate since the placement belongs in an environment and not the running text (it's a style decision after all). Take the following example: \setupfloats [figure] [default=top] \setupfloats [table] [default=bottom] %% \setupfloats [table] [default=top] \starttext \samplefile{knuth} \startplacefigure %% [location=top] %% default \externalfigure \stopplacefigure %% Goal here: turn off the caption, not influence the default placement %% needs to be adapted when the global style changes %% \startplacefigure [location=none] %% fails, messes up the placement \startplacefigure [location={top, none}] %% works \externalfigure \stopplacefigure %% Goal here: turn off the caption, not influence the default placement %% needs to be adapted when the global style is changed to “top” \startplacetable [location={bottom, none}] \externalfigure \stopplacetable \stoptext As far as I know there's no way to only turn off captions, so one has to know the default placement value (which might be buried in an environment file) and specify it again together with the “none” option. If you (or someone else) knows a way to disable the caption without influencing the placement, I'm all ears. Marco
Am 30.11.21 um 13:38 schrieb Marco Patzer via ntg-context:
As far as I know there's no way to only turn off captions, so one has to know the default placement value (which might be buried in an environment file) and specify it again together with the “none” option.
If you (or someone else) knows a way to disable the caption without influencing the placement, I'm all ears.
Now I understand your problem, and unfortunately I can’t help you. Maybe you could define your own float type for the cases without caption? Hraban
On Tue, 30 Nov 2021 14:05:23 +0100
Henning Hraban Ramm via ntg-context
Maybe you could define your own float type for the cases without caption?
I've done that for other options, too, I guess no-caption-floats get a dedicated float type as well now. It's more robust than relying on typing the correct parameter order each time. BTW: creating new float types fails in LMTX, I'll post an MWE in a new thread shortly. Marco
participants (2)
-
Henning Hraban Ramm
-
Marco Patzer