sealed-surface 0.4.0

Non-extractable data surface: tables, timeseries, scatter, treemap as glyphs, never DOM text
Documentation
//! Paint is shared; only the host projection changes.

/// Whether the host may observe cell values as Unicode.
///
/// Pixels are glyph-rasterized in both modes so applications can toggle
/// without swapping widgets.
#[derive(Debug, Clone, Copy, PartialEq, Eq, Hash, Default)]
#[non_exhaustive]
pub enum SurfaceMode {
    /// Cell values must not appear in [`crate::HostProjection`] text or clipboard.
    /// Tooltips are PNG only.
    #[default]
    Sealed,
    /// Host may copy viewport TSV (admin ops). Paint path is unchanged.
    Copyable,
}

impl SurfaceMode {
    /// True when the host is forbidden from emitting cell Unicode.
    #[must_use]
    pub const fn is_sealed(self) -> bool {
        matches!(self, Self::Sealed)
    }
}