Pineconium / ChoacuryOS

A WIP custom built OS
GNU General Public License v3.0
24 stars 6 forks source link

Implement terminal with scrolling support #10

Closed Bananymous closed 6 months ago

Bananymous commented 6 months ago

This PR replaces old VGA specific printf with more generalized terminal API (with scrolling support).

You no longer specify the line where you want to print, and instead the terminal keeps track of the current cursor position. If you want to write to specific place, you have to call term_move_cursor() after which the following calls to term_putchar() and term_write() print to the new location.

I reworked the current keyboard echoing to use this new terminal API and removed the old k_clear_screen() and k_printf().

If there is anything you want to be different or don't agree with, please leave a comment. If @Pineconium would like to write terminal scrolling by himself, this PR can stand as a guide.