(beebop music player) - Implemented basic (and slow for now) layout system

Hi everyone! I renamed my music player project from Tunedotsh to beebop, since it's going to drastically change in terms of presentation.

In my previous (and first) thread, mrmixer suggested that I should turn it from terminal ui into a lightweight GUI.
mrmixer
Why exactly do you want to make a terminal application if you want to have mouse support ? Wouldn't it be better to make a lightweight GUI ?


You were right. It is actually a lot easier now! I started by implementing a simple layout system, using a simple progress bar ui element for testing (I don't even know why I chose this). Here's a video of the layout system working:


Now, partitioning everything equally is very easy, so next up is having a way to require a max region percentage. This is my first time working on GUI and I really don't want to make it too complicated (I'm planning for base usage at the end of this month).
So any suggestions are welcome and thanks in advance!

Edited by Michael Dodis on Reason: Initial post
One advice would be to build your UI functions when you specifically need them in your application. Otherwise it's easy to make something that doesn't do what you actually need, or an API that is hard to use for what you need.

Having some code that needs the UI allows you to write the usage code first to get a basic idea of what you need to do. After that writing the simplest code that solve the problem without caring about performance or "clean code" will give you more insight on what actually goes on to solve the problem (and often the simplest thing is good enough for some time).

You can then refine the code better when most of the variables are known. Don't expect to get everything right the first time, nobody does. But it should get better with every iteration.

Edited by Simon Anciaux on Reason: typo
Thanks, that makes a lot of sense! I'll try to setup the audio soon.