diff options
| author | Laurenz <laurmaedje@gmail.com> | 2021-11-23 12:45:20 +0100 |
|---|---|---|
| committer | Laurenz <laurmaedje@gmail.com> | 2021-11-23 12:45:20 +0100 |
| commit | 4f9e5819bbab1f93ad4f4b789038c60487a76368 (patch) | |
| tree | 488a4e0422db4531d9882cf08f0b5cc21ae55a23 /src/geom | |
| parent | d3f6040cedacad1b6c323be721c9086f6c5d9a44 (diff) | |
2d alignments with plus operator
Diffstat (limited to 'src/geom')
| -rw-r--r-- | src/geom/spec.rs | 11 |
1 files changed, 10 insertions, 1 deletions
diff --git a/src/geom/spec.rs b/src/geom/spec.rs index 576c1c89..02263481 100644 --- a/src/geom/spec.rs +++ b/src/geom/spec.rs @@ -123,7 +123,7 @@ impl<T: Debug> Debug for Spec<T> { } /// The two specific layouting axes. -#[derive(Debug, Copy, Clone, Eq, PartialEq, Hash)] +#[derive(Copy, Clone, Eq, PartialEq, Hash)] pub enum SpecAxis { /// The horizontal layouting axis. Horizontal, @@ -150,3 +150,12 @@ impl SpecAxis { } } } + +impl Debug for SpecAxis { + fn fmt(&self, f: &mut Formatter) -> fmt::Result { + f.pad(match self { + Self::Horizontal => "horizontal", + Self::Vertical => "vertical", + }) + } +} |
