DesignCraft: An open-source page and layout design editor written by scratch in pure Rust
Integration: #1058 delete_pages keeps its doc comment, page_has_items has its own
aionggddac0751ffab
diff --git a/crates/doc/src/build.rs b/crates/doc/src/build.rsindex 20643ef4b..2437e0639 100644--- a/crates/doc/src/build.rs+++ b/crates/doc/src/build.rs@@ -462,7 +462,6 @@ impl Document {Ok(ids)}- /// Delete absolute pages (items whose centre is on a deleted page are deleted too)./// Whether absolute page `abs` holds page items: the ones Delete Pages removes with it/// (an item belongs to the page its centre is over).pub fn page_has_items(&self, abs: usize) -> bool {@@ -471,6 +470,7 @@ impl Document {sp.items.iter().any(|it| sp.page_at_x(it.bounds().center().x) == Some(pi))}+ /// Delete absolute pages (items whose centre is on a deleted page are deleted too).pub fn delete_pages(&mut self, pages: &[usize]) -> Result<()> {if pages.len() >= self.page_count() {return Err(DocError::Invalid("a document needs at least one page".into()));