Enum sndjvu_format::annot::Annot
source · pub enum Annot {
Background(Color),
Zoom(Zoom),
Mode(Mode),
Align {
horiz: HorizAlign,
vert: VertAlign,
},
Maparea(Maparea),
Phead(MarginStrings),
Pfoot(MarginStrings),
Metadata(Vec<(Key, Quoted)>),
Xmp(Quoted),
}
Expand description
A single annotation.
let annots = [
Annot::Background(Color { r: 0xff, g: 0xff, b: 0xff }),
Zoom::Page.into(),
Mode::Bw.into(),
Annot::Align { horiz: HorizAlign::Center, vert: VertAlign::Top },
];
let s = annots.iter().map(Annot::to_string).collect::<Vec<_>>().join(" ");
assert_eq!(
s,
"(background #FFFFFF) (zoom page) (mode bw) (align center top)",
);
Variants§
Background(Color)
Zoom(Zoom)
Mode(Mode)
Align
Maparea(Maparea)
Phead(MarginStrings)
The phead
annotation should not be used in new DjVu documents.
Pfoot(MarginStrings)
The pfoot
annotation should not be used in new DjVu documents.
Metadata(Vec<(Key, Quoted)>)
Xmp(Quoted)
Trait Implementations§
source§impl PartialEq for Annot
impl PartialEq for Annot
impl Eq for Annot
impl StructuralEq for Annot
impl StructuralPartialEq for Annot
Auto Trait Implementations§
impl RefUnwindSafe for Annot
impl Send for Annot
impl Sync for Annot
impl Unpin for Annot
impl UnwindSafe for Annot
Blanket Implementations§
source§impl<T> BorrowMut<T> for Twhere
T: ?Sized,
impl<T> BorrowMut<T> for Twhere
T: ?Sized,
source§fn borrow_mut(&mut self) -> &mut T
fn borrow_mut(&mut self) -> &mut T
Mutably borrows from an owned value. Read more