Rename the legacy Graphene crate to document-legacy (#899)

* Rename /graphene to /document-legacy

* Update names in code
This commit is contained in:
Keavon Chambers
2022-12-22 02:12:05 -08:00
parent 55d5dbaf52
commit 5c6679ab98
95 changed files with 492 additions and 491 deletions
+24
View File
@@ -0,0 +1,24 @@
use super::LayerId;
use crate::boolean_ops::BooleanOperationError;
/// A set of different errors that can occur when using this crate.
#[derive(Debug, Clone, PartialEq, Eq)]
pub enum DocumentError {
LayerNotFound(Vec<LayerId>),
InvalidPath,
IndexOutOfBounds,
NotAFolder,
NonReorderableSelection,
NotAShape,
NotText,
NotAnImage,
NotAnImaginate,
InvalidFile(String),
}
// TODO: change how BooleanOperationErrors are handled
impl From<BooleanOperationError> for DocumentError {
fn from(err: BooleanOperationError) -> Self {
DocumentError::InvalidFile(format!("{:?}", err))
}
}