use crate::Limit;
#[derive(Clone, Copy, Debug, Eq, PartialEq, thiserror::Error)]
#[non_exhaustive]
pub enum Error {
#[error("invalid application identifier")]
InvalidAppId,
#[error("invalid record identifier")]
InvalidRecordId,
#[error("progress must be between 0 and 100")]
InvalidProgress,
#[error("invalid OSC 7501 framing")]
Framing,
#[error("OSC 7501 {0:?} limit exceeded")]
Limit(Limit),
#[error("text destination too small")]
BufferTooSmall,
#[error("invalid base64 text")]
InvalidBase64,
#[error("invalid UTF-8 text")]
InvalidUtf8,
#[error("control character in text")]
ControlCharacter,
}