diff options
| author | Laurenz <laurmaedje@gmail.com> | 2022-11-21 16:12:24 +0100 |
|---|---|---|
| committer | Laurenz <laurmaedje@gmail.com> | 2022-11-21 16:12:24 +0100 |
| commit | 1d7e082d1d83d4c7e454a2d08258794d716aea1a (patch) | |
| tree | 73ee43a9d039edbe34c81a4ea6f4ec4f7f9e11cf /library/src/text | |
| parent | fd7b9d9e1eb8eef60c20e65dfc946c4424f02c8f (diff) | |
Labels
Diffstat (limited to 'library/src/text')
| -rw-r--r-- | library/src/text/mod.rs | 4 | ||||
| -rw-r--r-- | library/src/text/par.rs | 4 |
2 files changed, 6 insertions, 2 deletions
diff --git a/library/src/text/mod.rs b/library/src/text/mod.rs index c12a61cb..45808310 100644 --- a/library/src/text/mod.rs +++ b/library/src/text/mod.rs @@ -414,13 +414,15 @@ impl Fold for FontFeatures { #[derive(Debug, Hash)] pub struct SpaceNode; -#[node(Behave)] +#[node(Unlabellable, Behave)] impl SpaceNode { fn construct(_: &mut Vm, _: &mut Args) -> SourceResult<Content> { Ok(Self.pack()) } } +impl Unlabellable for SpaceNode {} + impl Behave for SpaceNode { fn behaviour(&self) -> Behaviour { Behaviour::Weak(2) diff --git a/library/src/text/par.rs b/library/src/text/par.rs index 6551ae9c..37d5e396 100644 --- a/library/src/text/par.rs +++ b/library/src/text/par.rs @@ -117,13 +117,15 @@ castable! { #[derive(Debug, Hash)] pub struct ParbreakNode; -#[node] +#[node(Unlabellable)] impl ParbreakNode { fn construct(_: &mut Vm, _: &mut Args) -> SourceResult<Content> { Ok(Self.pack()) } } +impl Unlabellable for ParbreakNode {} + /// Repeats content to fill a line. #[derive(Debug, Hash)] pub struct RepeatNode(pub Content); |
