From cbf4ab6b2fdcbd02b474224f9e8a9ce4405ff3c3 Mon Sep 17 00:00:00 2001 From: Joseph Ferano Date: Thu, 16 Nov 2023 17:36:15 +0700 Subject: [PATCH] Updating README --- README.org | 46 ++++++++++++++++++++++++++++++++++++++++++---- bt.todo | 10 ++++++---- 2 files changed, 48 insertions(+), 8 deletions(-) diff --git a/README.org b/README.org index 146afeb..134a88e 100644 --- a/README.org +++ b/README.org @@ -1,5 +1,43 @@ -* Basic Term +#+OPTIONS: toc:nil -Simple X11 VT100 terminal emulator, written in C. Using the following resources; -- [[https://www.uninformativ.de/blog/postings/2018-02-24/0/POSTING-en.html][The very basics of a terminal emulator]] -- [[http://mech.math.msu.su/~nap/2/GWindow/xintro.html][A Brief intro to X11 Programming]] +* Basicterm + +Linux terminal emulator, written in C. Keyboard input handling and text +rendering are done with ~SDL2~ and ~SDL2_ttf~. I got the idea of working on the +project by reading through [[https://www.uninformativ.de/blog/postings/2018-02-24/0/POSTING-en.html][this]] tutorial. + +** Another terminal? + +This is part of my attempt to gain a deeper understanding of the tools I use on +a daily basis. + +** Status +This is very much a work-in-progress. Work was started last year and initially +used Raylib for the rendering, however, an [[https://github.com/raysan5/raylib/issues/2041][issue]] with handling keyboard input at +the time of implementation meant it wasn't ideal. The project was shelved with a +~TODO: Switch to SDL2~ and I finally got around to making the switch. + +Project is now using SDL2 and it renders a bash shell and running commands work +for the most part. It's handling backspace but not much else. It has some color +escape code parsing in place but the text rendering currently only renders line +by line so it's on the TODO list to get that working. + +Eventually, I'll revisit this project when I want to learn more about this +topic. + +** Shell support + +Currently, Fish and ZSH do not work. Only bash and dash. + +** Building + +You need to install ~SDL2~ and ~SDL2_ttf~, ideally from your distro's package +manager. I probably should setup the includes and whatnot properly according to +[[https://nullprogram.com/blog/2023/01/08/][this blog post]] but I'll leave that for another day. + +You can then run ~make build~ or ~make run~ + +** LICENSE + +Basicterm is licensed under the terms of the MIT license. For more information, +see the included LICENSE file. diff --git a/bt.todo b/bt.todo index 12c5d8a..f22e43e 100644 --- a/bt.todo +++ b/bt.todo @@ -12,11 +12,13 @@ * DONE Render scrollback by rows * DONE Handle color escape sequences * DONE Switch to SDL2 -* TODO Clean up the rendering of the scrollback buffer -* TODO Get Backspace and Return to repeat properly [[https://github.com/raysan5/raylib/issues/2041][Why we switched to SDL]] -* TODO Render the scrollback line by line +* DONE Clean up the rendering of the scrollback buffer +* DONE Get Backspace and Return to repeat properly [[https://github.com/raysan5/raylib/issues/2041][Why we switched to SDL]] +* DONE Render the scrollback line by line +* TODO Render lines by colored subsection +* TODO Handle raw mode * TODO Only draw scrollback that is visible +* TODO Handle non-canonical mode * TODO Handle unicode characters -* TODO Handle canonical and raw commands * TODO Mouse copy/paste * TODO Create basic vertical splits?