diff options
author | Aqua-sama <aqua@iserlohn-fortress.net> | 2021-02-05 23:15:37 +0200 |
---|---|---|
committer | Aqua-sama <aqua@iserlohn-fortress.net> | 2021-02-05 23:15:37 +0200 |
commit | 919ad9d1022edec7fdd97f74ef50de26dde6aebb (patch) | |
tree | 2787aa63255b0ba6c682e4547a2030e591a6a55e /vga.h | |
parent | Rewrite boot.s to use clang instead of nasm (diff) | |
download | kernel.cpp-919ad9d1022edec7fdd97f74ef50de26dde6aebb.tar.xz |
Add IntegerView
Diffstat (limited to 'vga.h')
-rw-r--r-- | vga.h | 10 |
1 files changed, 3 insertions, 7 deletions
@@ -23,15 +23,11 @@ public: VGA_COLOR_WHITE = 15, }; - VGA(vga_color fg = VGA_COLOR_BLACK, vga_color bg = VGA_COLOR_LIGHT_GREY, - uint32_t address = 0xB8000); + VGA(vga_color fg = VGA_COLOR_BLACK, vga_color bg = VGA_COLOR_LIGHT_GREY, uint32_t address = 0xB8000); ~VGA() = default; - void put_char(char c, size_t x, size_t y, uint8_t color = 0); void write(char c) override; - void write(const String &data) override; - void write(int n) override; - void write(unsigned int n) override; + void write(ViewIterator& iter) override; void set_color(vga_color fg, vga_color bg) { color = (fg | bg << 4); } @@ -39,5 +35,5 @@ private: const size_t max_columns = 80, max_rows = 25; size_t column = 0, row = 0; uint8_t color; - uint16_t *buffer; + uint16_t* buffer; }; |