#[derive(Copy, Clone, Debug, PartialEq, Eq)]
pub struct NcPlaneFlag(pub c_api::NcPlaneFlag_u64);
impl NcPlaneFlag {
pub const None: Self = Self(0);
pub const HorAligned: Self = Self(c_api::NCPLANE_OPTION_HORALIGNED);
pub const VerAligned: Self = Self(c_api::NCPLANE_OPTION_VERALIGNED);
pub const Marginalized: Self = Self(c_api::NCPLANE_OPTION_MARGINALIZED);
pub const Fixed: Self = Self(c_api::NCPLANE_OPTION_FIXED);
pub const AutoGrow: Self = Self(c_api::NCPLANE_OPTION_AUTOGROW);
pub const VScroll: Self = Self(c_api::NCPLANE_OPTION_VSCROLL);
}
mod core_impls {
use super::{c_api::NcPlaneFlag_u64, NcPlaneFlag};
impl Default for NcPlaneFlag {
fn default() -> Self {
Self::None
}
}
crate::from_primitive![NcPlaneFlag, NcPlaneFlag_u64];
crate::unit_impl_from![NcPlaneFlag, NcPlaneFlag_u64];
crate::unit_impl_ops![bitwise; NcPlaneFlag, NcPlaneFlag_u64];
crate::unit_impl_fmt![bases+display; NcPlaneFlag];
}
pub(crate) mod c_api {
use crate::c_api::ffi;
pub type NcPlaneFlag_u64 = u64;
pub const NCPLANE_OPTION_HORALIGNED: NcPlaneFlag_u64 =
ffi::NCPLANE_OPTION_HORALIGNED as NcPlaneFlag_u64;
pub const NCPLANE_OPTION_VERALIGNED: NcPlaneFlag_u64 =
ffi::NCPLANE_OPTION_VERALIGNED as NcPlaneFlag_u64;
pub const NCPLANE_OPTION_MARGINALIZED: NcPlaneFlag_u64 =
ffi::NCPLANE_OPTION_MARGINALIZED as NcPlaneFlag_u64;
pub const NCPLANE_OPTION_FIXED: NcPlaneFlag_u64 = ffi::NCPLANE_OPTION_FIXED as NcPlaneFlag_u64;
pub const NCPLANE_OPTION_AUTOGROW: NcPlaneFlag_u64 =
ffi::NCPLANE_OPTION_AUTOGROW as NcPlaneFlag_u64;
pub const NCPLANE_OPTION_VSCROLL: NcPlaneFlag_u64 =
ffi::NCPLANE_OPTION_VSCROLL as NcPlaneFlag_u64;
}