it: test region creation
This commit is contained in:
parent
6af9d909b8
commit
ae34a65efe
9 changed files with 179 additions and 35 deletions
|
|
@ -533,7 +533,7 @@ fn rects_to_bands(rects_tmp: &[Rect]) -> Container {
|
|||
merged
|
||||
}
|
||||
|
||||
#[derive(Copy, Clone, Eq, PartialEq)]
|
||||
#[derive(Copy, Clone, Eq, PartialEq, Debug)]
|
||||
enum BuilderOp {
|
||||
Add,
|
||||
Sub,
|
||||
|
|
@ -545,6 +545,7 @@ impl Default for BuilderOp {
|
|||
}
|
||||
}
|
||||
|
||||
#[derive(Debug)]
|
||||
pub struct RegionBuilder {
|
||||
base: Rc<Region>,
|
||||
op: BuilderOp,
|
||||
|
|
@ -599,5 +600,6 @@ impl RegionBuilder {
|
|||
BuilderOp::Add => self.base.union(®ion),
|
||||
BuilderOp::Sub => self.base.subtract(®ion),
|
||||
};
|
||||
self.pending.clear();
|
||||
}
|
||||
}
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue