adding std io idk

This commit is contained in:
2025-02-24 15:33:42 +00:00
parent 2cbe9641aa
commit d5b15826e2
6 changed files with 12 additions and 4 deletions
+2 -2
View File
@@ -4,7 +4,7 @@ use x86_64::instructions::interrupts;
use super::framebuffer::{colour::Colour, display::FRAMEBUFFER_WRITER}; use super::framebuffer::{colour::Colour, display::FRAMEBUFFER_WRITER};
use crate::resources::font::{FONT_CP850_8X16, Font}; use crate::resources::font::{FONT_SPLEEN_8X16, Font};
static FONT_WIDTH: u32 = 8; static FONT_WIDTH: u32 = 8;
static FONT_HEIGHT: u32 = 16; static FONT_HEIGHT: u32 = 16;
@@ -47,7 +47,7 @@ impl Writer {
panic!("Framebuffer writer not initialized."); panic!("Framebuffer writer not initialized.");
}, },
|writer| Self { |writer| Self {
font: &FONT_CP850_8X16, font: &FONT_SPLEEN_8X16,
screen_width: writer.width() / 8, screen_width: writer.width() / 8,
screen_height: writer.height() / 16, screen_height: writer.height() / 16,
text_line: 0, text_line: 0,
+1 -2
View File
@@ -26,8 +26,7 @@ pub mod std;
/// Re-exports most of the IO macros as well as standard allocation stuff /// Re-exports most of the IO macros as well as standard allocation stuff
pub mod prelude { pub mod prelude {
pub use crate::drivers::io::ascii::{_print, _print_log}; pub use crate::std::io::*;
pub use crate::{print, print_log, println, println_log, serial_print, serial_println};
pub use alloc::{ pub use alloc::{
boxed::Box, boxed::Box,
string::{String, ToString}, string::{String, ToString},
+6
View File
@@ -0,0 +1,6 @@
pub use crate::drivers::io::{
ascii::{_print, _print_err, _print_log},
print, print_log, printerr, println, println_log, printlnerr,
serial::_serial_write,
serial_print, serial_println,
};
+2
View File
@@ -0,0 +1,2 @@
mod io;
pub use io::*;
+1
View File
@@ -1,2 +1,3 @@
pub mod application; pub mod application;
pub mod io;
pub mod maths; pub mod maths;
View File