You can help CodeWalrus stay online by donating here. | New CodeWalrus | Old (dark mode) | Old (light) | Discord server

clgui

Previous topic - Next topic

0 Members and 1 Guest are viewing this topic.

0
b/PC, Mac & Vintage Computers publicado por u/Yuki November 05, 2015, 08:18:28 AM
So I was messing with Ruby today and I did this. It's a Command-Line Graphic User Interface library. As in, it takes a text-only VT100 emulator such as your Linux terminal and turns it into a thing you can draw on, thanks to Unicode Braille characters. It have some drawing functions such as pxl_on, pxl_off, pxl_change, line and many others. Not complete yet but it's a good start. :P

Download the source here: https://github.com/juju2143/clgui
Inicia sesión o crea una cuenta para dejar un comentario
u/Dream of Omnimaga November 05, 2015, 08:22:10 AM
is there a demo somewhere to try to see how it looks like or is it looking like most command line interfaces out there? I notice some drawing commands, but I am unfamiliar with graphical command line interfaces.
u/Yuki November 05, 2015, 08:47:42 AM
Yeah it's kind of hard to explain, if you've got Ruby and know how to install a gem you can always try the example out (not sure it works on Windows though, maybe Cygwin), it's basically a dot drawn with Braille characters moving around with the arrow keys. It allows for 8 dots per character this way, it's kind of like this thing I did once:
⣇⣀⡇⡠⠤⡀⠈⡇⠀⠈⡇⠀⡠⠤⡀
⠇⠀⠇⠫⠭⠁⠠⠧⠀⠠⠧⠀⠣⠤⠃
u/Dream of Omnimaga November 05, 2015, 09:37:38 AM
Oh I see now, it uses braille. So I assume that it makes it easier for people to do pixel-art-oriented games in command prompt? (Eg like old text RPGs but more graphical)
u/novenary November 05, 2015, 01:51:09 PM
Yeah basically that, with higher resolution, the only problem is that color resolution is unchanged (you can only color whole characters, not individual dots). Libcaca might be a lot more interesting for that kind of stuff. MPV supports outputting with it, it's pretty funny.
Still a fun thing to do Juju, nice job on this. I've mentioned this on IRC already, z80e uses the same trick to emulate a calculator display in a terminal without the need for any graphics library.
u/Dream of Omnimaga November 15, 2015, 06:27:59 AM
Wait, I didn't know z80e did that. Is it faster that way or is it just for the convenience of not having to use graphics library? And what if the user wants to setup the display to 1x size? Is that possible?


Back on topic, I am curious if any game could be made out of this program Juju.
u/novenary November 15, 2015, 09:35:23 AM
Quote from: DJ Omnimaga on November 15, 2015, 06:27:59 AM
Wait, I didn't know z80e did that. Is it faster that way or is it just for the convenience of not having to use graphics library? And what if the user wants to setup the display to 1x size? Is that possible?
The latter, and you can't have any scaling with that method other than changing the terminal font size.
u/Dream of Omnimaga November 16, 2015, 06:29:21 PM
Hmm that might be problematic when people start using 19 inch monitors at 4k resolutions, then the display will be very small. Hopefully changing the terminal font size will allow decent scaling. (I know that when changing the size of some fonts, they don't scale evenly in each direction)
u/novenary November 16, 2015, 07:59:51 PM
Well when you use high resolutions, the OS is supposed to compensate by enlarging the fonts so that the physical size of the characters remains the same. See phones where they keep increasing the pixel density, yet it remains readable (the microcat subforum font is actually more readable on my phone than my computer because of that).
u/Dream of Omnimaga November 16, 2015, 10:15:22 PM
Not really. On XP and 7 you need to go in your settings and change the font size yourself. In browsers, you need to use CTRL+ +/- to resize page content and stuff.
u/novenary November 16, 2015, 10:16:12 PM
Well XP and 7 existed before high density displays so they're not aware of that.
u/Dream of Omnimaga November 16, 2015, 10:18:06 PM
Yeah true. Back then, people cared about having as much content as possible in the screen than being able to click stuff easily.
u/alexgt November 17, 2015, 12:14:56 AM
Quote from: DJ Omnimaga on November 16, 2015, 10:18:06 PM
Yeah true. Back then, people cared about having as much content as possible in the screen than being able to click stuff easily.
I still want more stuff on my screen when I have a mouse because it is just more convenient but on touch screens I like bigger objects.
u/novenary November 17, 2015, 09:13:19 AM
I also like to have content over visibility. I have my phone set up to think the screen is larger than it is, because honestly Android is made for blind people. <_<
u/alexgt November 17, 2015, 01:44:45 PM
Yeah, no kidding it is a problem on the Prime kinda since the touch screen is not the best but it is still really responsive. The smallest button I would make is 10x10.
Start a Discussion

b/PC, Mac & Vintage Computers

Computer programming discussion and project showcase

132
Topics
Explore Board
Website statistics


MyCalcs | Ticalc.org | Cemetech | Omnimaga | TI-Basic Developer | MaxCoderz | TI-Story | Casiocalc.org | Casiopeia | The Museum of HP Calculators | HPCalc.org | CnCalc.org | Music 2000 Community | TI Education | Casio Education | HP Calcs | NumWorks | SwissMicros | Sharp Calculators
Powered by EzPortal