// SPDX-FileCopyrightText: 2023 CELESTIFYX Team
// SPDX-License-Identifier: GPL-3.0-or-later

#[derive(Debug, Clone)]
pub struct DisplayConfig {
    pub(super) lines: Vec<String>,
    pub(super) margin: usize,
    pub(super) color_resolution: usize
}

impl Default for DisplayConfig {
    fn default() -> Self {
        Self {
            lines: vec![],
            margin: 4,
            color_resolution: 64
        }
    }
}

impl DisplayConfig {
    pub fn new() -> Self {
        Self::default()
    }

    pub fn with_lines(mut self, lines: Vec<String>) -> Self {
        self.lines = lines;
        self
    }

    pub fn with_margin(mut self, margin: usize) -> Self {
        self.margin = margin;
        self
    }

    pub fn with_color_resolution(mut self, color_resolution: usize) -> Self {
        self.color_resolution = color_resolution;
        self
    }
}
