it looks a lot better in the terminal but i made a big clock widget.
it looks a lot better in the terminal but i made a big clock widget.
small devlog, so one thing about my project is that it’s built to help others make tui’s, but not all projects are in python, so how did I learn to make this well I started here: https://gist.github.com/fnky/458719343aabd01cfb17a3a4f7296797 , ANSI escape codes are just cli terminal coloring, add in some unicode and you got a cool stylized thingy. The img is an example of something I quickly built to showcase how much tui’s improve visuals, check it out here: https://codehs.com/sandbox/robopugo/gfojafowj/run . It’s still in python. Just wanted to share how I got introduced to Tui’s since I figured others might also want to find a way to get started.
[this will be a longer devlog]. So what are these 2 things, and what do they have to do with stylized docs, glad you asked. After designing a stylized help func, I made a main menu / repl that shows you the names of all the functions and you can type the name to see its stylized doc card. The first img shows all of the names of the functions in my module currently, the second shows all of the helper funcs / commands in the repl. (not all are implemented, but most are). The main features I like are that it’s stateful with a back command, and the .run command which lets you run the example code right there. I uploaded a long form video to my YT channel if you want to see it in action: https://youtu.be/niP3qDd2KkY
made the border a gradient, which honestly, just looks really good. Now going to work on the menu.
Hello, been a while, but I’m finally happy with it, so some context: python has these things called doc-strings which are basically special comments in a function that explain what the function does and how to use it, you can see this with the help() function. I wanted to make my own version, but stylized, and i succeeded, and mine is pretty dynamic. How it works: it uses a list of headers to make sections and then styles them based on indentation. (also shows color palate in bottom right). Planning on making some sort of menu to easily read these.
started to mess with fonts and sadly a lot of fonts don’t support “\n”, but this one does, and i used wrap to apply the 4 color gradient to it, planning on working on adding the random text, and maybe another loading throbber of sorts. (python)
added a wrap func that is used to dynamically apply colors to strings, allowing you to easily print text that’s color is a gradient. (python)
I haven’t really documented this on star dance, but you can use ascii (or any color type or set of symbols, or even just data) in the gradients instead of rgb…
made a multi positional interpolated gradient in python, simply put, a gradient where you can have any amount of colors and you can pick their position.
a terminal 4 color gradient that uses bilinear interpolation and ANSI. Also made a 1d gradient tool, and both can be used for data gradients. (python)
donut i made that uses ANSI instead of Ascii to render. (python)
I think i speak computer now… reading terminal chars and converting to rgb, was easy….
was organizing my code and starting to add documentation, but got sidetracked and made this cool loading bar. Also im looking into adding ideas from https://charm.land/ but in python. (python)
oof, for some reason i can’t get my extension to activitie / run even after an hour of debugging. So honestly just goona quit for a bit and maybyetry more tomorow, as nothing i try to do to fix works.
21 demos completed, (defiantly not enough), added better char reading and the abilityto read words on the terminal, for better input options. (python)
finished up the clock then made a rhythm game. Planning on adding more features too it soon.
added a working clock
added a maze app, with custom sizes