summaryrefslogtreecommitdiff
path: root/library/src/layout/container.rs
diff options
context:
space:
mode:
authorLaurenz <laurmaedje@gmail.com>2022-11-28 17:57:16 +0100
committerLaurenz <laurmaedje@gmail.com>2022-11-28 17:57:16 +0100
commit836692e73cff0356e409a9ba5b4887b86809d4ca (patch)
treee174178047c368c66746ee073eea1b3129825479 /library/src/layout/container.rs
parent989d170dc7318ca3cbaa5b76760eb14f4e6a8605 (diff)
Widow and orphan prevention
Diffstat (limited to 'library/src/layout/container.rs')
-rw-r--r--library/src/layout/container.rs3
1 files changed, 3 insertions, 0 deletions
diff --git a/library/src/layout/container.rs b/library/src/layout/container.rs
index 1c1f8762..a77e0249 100644
--- a/library/src/layout/container.rs
+++ b/library/src/layout/container.rs
@@ -71,6 +71,9 @@ impl BlockNode {
/// The spacing between this and the following block.
#[property(skip)]
pub const BELOW: VNode = VNode::block_spacing(Em::new(1.2).into());
+ /// Whether this block must stick to the following one.
+ #[property(skip)]
+ pub const STICKY: bool = false;
fn construct(_: &Vm, args: &mut Args) -> SourceResult<Content> {
Ok(Self(args.eat()?.unwrap_or_default()).pack())