Closed bluebear94 closed 3 days ago
I think this should be mentioned on the documentation for place
as well.
Hey there, this looks great, I figured I'd give it my two cents:
I think this fits better as a sub-element of place
as this primarily interacts with place(float: true)
elements and nothing else. Similar to figure.caption
, it makes no sense to define caption
by itself.
I also think this should be included in the default heading
show rule, here's my thinking:
set heading(flush: false)
or something similar as an escape hatch, we have precedent for "off-topic" fields like these:
heading.outlined
being only useful for outline
, not heading on its ownfigure.placement
being the inclusion of said floating mechanism for convenience, not necessity, one could wrap figure in place manuallyI think this fits better as a sub-element of
place
as this primarily interacts withplace(float: true)
elements and nothing else. Similar tofigure.caption
, it makes no sense to definecaption
by itself.
I disagree. figure.caption
is namespaced within figure
because it’s present within a figure
element. flush
, on the other hand, is not (usually) used within a place
element.
I also think this should be included in the default
heading
show rule
I agree with this, though.
I disagree.
figure.caption
is namespaced withinfigure
because it’s present within afigure
element.flush
, on the other hand, is not (usually) used within aplace
element.
I don't think this distinction matters all that much in this case, the semantic relationship is still there, a flush
element on its own is useless, it's only useful when used with place(float: true)
elements, a subset of place elements at large. assert.eq
is also scoped within assert
, but used "outside" of it, as it's not an element of course, but it is semantically related to assert
(as well as other examples of function scopes).
I took a quick look, and at first I think this should work with figure.placement
too (please add tests for that), which would, in theory, oppose the argument that this would exclusively affect place
. However, I'm also a bit torn on whether this (relatively) small feature should warrant another name in the global namespace. Maybe it's not too bad since #4038 got merged, but worth considering.
Personally I'd be ok with something like #place.flush()
, but I'd like to see other suggestions as well.
I took a quick look, and at first I think this should work with
figure.placement
too (please add tests for that), which would, in theory, oppose the argument that this would exclusively affectplace
.
Well, the implementation of figure simply wraps itself in a place if it has a non-none
placement field.
Another thing to note is that ‘flush’ has another plausible meaning in the context of typesetting (‘not sticking out’), so perhaps putting it in place
’s namespace might be preferable.
My first instinct was also that it should maybe be moved into the place
namespace.
I also think this should be included in the default heading show rule
I'm not so sure about this. In a two-column paper, you might have lots of short sections and figures should float past them, I think.
Do we know what LaTeX does by default?
cc: LaTeX and Paper guru @Enivex
I also think this should be included in the default heading show rule
I'm not so sure about this. In a two-column paper, you might have lots of short sections and figures should float past them, I think.
Do we know what LaTeX does by default?
cc: LaTeX and Paper guru @Enivex
I don't think LaTeX does anything special here. Flushing figures for every heading seems problematic to me.
I think we shouldn't force flushing on all headings by default (should be opt-in through show rules).
I additionally don't remember this being the case in LaTeX when I last used it (...which was a long while ago, so take that with a grain of salt :smile:)
Yeah, that probably makes sense, in the end it also makes opting out easier.
Thanks!
See #4134.