pub struct FontManager {
initialized: bool,
}
impl FontManager {
pub fn new() -> Self {
Self { initialized: false }
}
pub fn init(&mut self) -> Result<(), String> {
Err("SDL2_ttf linking pendiente - v0.10.8".to_string())
}
pub fn load_font(&mut self, _path: &str, _size: u16) -> Result<(), String> {
Err("SDL2_ttf linking pendiente - v0.10.8".to_string())
}
pub fn render_text(&self, _text: &str, _color: (u8, u8, u8)) -> Result<(), String> {
Err("SDL2_ttf linking pendiente - v0.10.8".to_string())
}
pub fn is_initialized(&self) -> bool {
self.initialized
}
}
impl Default for FontManager {
fn default() -> Self {
Self::new()
}
}
#[cfg(test)]
mod tests {
use super::*;
#[test]
fn test_font_manager_new() {
let font = FontManager::new();
assert!(!font.is_initialized());
}
}