#[repr(u8)]pub enum CidSet {
Unknown = 0,
Gb1 = 1,
Cns1 = 2,
Japan1 = 3,
Korea1 = 4,
Unicode = 5,
}Expand description
The character collection a CID belongs to — the /Registry–/Ordering
pair of a /CIDSystemInfo (ISO 32000-1 §9.7.3), reduced to the five
collections that have built-in tables plus “none of them”.
The discriminants index the static blob’s registry directory, so they are part of the format, not an implementation detail.
use pdfrum_cmap::{CidSet, charset_from_ordering};
assert_eq!(charset_from_ordering(b"Japan1"), CidSet::Japan1);
assert_eq!(charset_from_ordering(b"Latin1"), CidSet::Unknown);Variants§
Unknown = 0
No recognised collection: the CMap has no CID table and no CID→Unicode table.
Gb1 = 1
Adobe-GB1 — Simplified Chinese.
Cns1 = 2
Adobe-CNS1 — Traditional Chinese.
Japan1 = 3
Adobe-Japan1 — Japanese.
Korea1 = 4
Adobe-Korea1 — Korean.
Unicode = 5
Adobe-Identity / UCS: the CID is the Unicode scalar value.
Implementations§
Trait Implementations§
impl Copy for CidSet
impl Eq for CidSet
Source§impl Ord for CidSet
impl Ord for CidSet
1.21.0 (const: unstable) · Source§fn max(self, other: Self) -> Selfwhere
Self: Sized,
fn max(self, other: Self) -> Selfwhere
Self: Sized,
Compares and returns the maximum of two values. Read more
1.21.0 (const: unstable) · Source§fn min(self, other: Self) -> Selfwhere
Self: Sized,
fn min(self, other: Self) -> Selfwhere
Self: Sized,
Compares and returns the minimum of two values. Read more
Source§impl PartialOrd for CidSet
impl PartialOrd for CidSet
impl StructuralPartialEq for CidSet
Auto Trait Implementations§
impl Freeze for CidSet
impl RefUnwindSafe for CidSet
impl Send for CidSet
impl Sync for CidSet
impl Unpin for CidSet
impl UnsafeUnpin for CidSet
impl UnwindSafe for CidSet
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