It’s warm, the sun is up, I really should go outside!
I have this SVG/Javascript application (Gridmapper) and I’m sort of wanting to rewrite it into a program that runs without a browser. At least I want to see whether I could potentially do it. I’d like to be able to do it.
My problem with GUI stuff is that the last piece of well-written integration into a programming language was … Perl/Tk in the last millennium? Maybe. I think I had a book about it, back then. Or a chapter in a book. Perhaps GTK and C is also well documented? I guess not, because I can sort of understand the Hello World program and the next one is already pretty long and the third one defines the layout of the user interface in an XML file… Ah. So complicated! Now I remember why using SVG, HTML, and a bit of Javascript feels so liberating.
Anyway, I already know that I don’t enjoy C. I’m sort of maintaining a Bitlbee plugin for Mastodon written in C and it doesn’t spark joy. At some point I wrote that I felt proud about it because it had been so difficult. But these days I dread touching it. Everything takes me a long time.
So I figured, what about Go? Trying to figure out how to use Go with SDL or GTK without knowing either one was so disorienting I didn’t manage to do it.
Now I’m trying Common Lisp an SDL, and it’s somewhat better, perhaps because I’m a bit more familiar with Lisp and can look at the sources of the glue code, and I found some examples and a dozen tiny tutorial programs. The documentation is as confusion or minimal as in the Go/SDL case, so that doesn’t help. It’s all about trying to find examples.
Perhaps the problem is that people like me feel we no longer need to buy books these days but actually we do, because so much documentation online is fragmented, minimal, outdated… I don’t know.
#Programming
(Please contact me if you want to remove your comment.)
⁂
Well, there’s at least something!
Sadly, the fan starts spinning like crazy so whatever the SDL library is doing in idle state is not what I want.
Common Lisp branch of Gridmapper
I can’t store the rectangles anywhere or I’ll get errors about “wrong wrapper”. I have to keep recreating the entire scene before I render it. That surprised me.
– Alex 2022-07-06 17:46 UTC
---
Maybe you like “DearImGui”?
– 2022-07-06 22:38 UTC
---
I don’t think so. C++ is not my favourite. And as far as I can tell, I still need to setup rendering and all that. I’m just super flexible about it. Which I’m interpreting to mean that it’s too low level for me.
Dear ImGui is a … graphical user interface library for C++. It outputs optimized vertex buffers that you can render anytime in your 3D-pipeline enabled application. It … is designed … to empower programmers to create content creation tools and visualization / debug tools (as opposed to UI for the average end-user). – Dear ImGui
– Alex 2022-07-07 11:42 UTC
---
Looking at the Gridmapper application again. The idea of having to implement scrolling…
– Alex 2022-07-07 11:45 UTC
---
Figured out that SDL2 has default delay of 1ms; switched that to 33ms. No more fan spinning.
– Alex 2022-07-09 21:58 UTC
---
The current implementation in Common Lisp has the following features:
– Alex 2022-07-12 – 2022-07-20
---
Found Common Lisp bindings for imgui. That’s going to be the next thing to investigate when I’m once again stuck with fonts and all that.
Common Lisp bindings for imgui
Adding those coordinates was super difficult for me!
Coordinates along the x and y axis
– Alex 2022-07-27 23:01 UTC