It's time for widgets for Figuro!
I've been working on a basic set. They're animated where it makes sense like sliding the dropdown in and fading the checkbox out, etc. They can be styled with a subset of CSS that doesn't actually cascade.
Here's a preview:
Most of the required bits are there. But there’s still a few things needed for a scalable text editor widget.
The current text input widget supports mutiline select and cursor movement, basic key bindings, etc. But it’s limited to laying out and rending the entire text. That wouldn’t scale even though Pixie does do text layout pretty fast.
I’d hope 3-4 solid days might get a rudimentary text editor widget? Maybe less for an old school dos style editor with fixed rows. Assuming there’s code to still for syntax highlighting and ropes for strings or similar.
That’s excluding a number of other widgets needed for an editor.
Great job! I've been looking at Figuro for a while now (after you opened the issue in the tracker) and it really seems like it's the true successor to Fidget. I hope it eventually becomes as good as something like GTK4 or Qt.
I'm considering sending in a few patches for improving Linux support later too. :P Either ways, great work!
I’d hope 3-4 solid days might get a rudimentary text editor widget?
Define rudimentary. A TextEdit requires an actual thought-out data model for the component to work reliably. I think this is the hardest common widget to implement and the complexity grows almost exponentially with every little feature. And you want features for code editing.
Perhaps it would be wise to follow the traditional way and have a basic multiline text box with "native" behaviour and a "RichEdit" for code.
A TextEdit requires an actual thought-out data model for the component to work reliably.
Yeah but NimEdit has the code for that or let's say an 80% solution. We don't have to start from scratch here.
Great job! I've been looking at Figuro for a while now (after you opened the issue in the tracker) and it really seems like it's the true successor to Fidget. I hope it eventually becomes as good as something like GTK4 or Qt.
Thanks! I mean I'm partial but I think it's already better than GTK4 or QT. Well except for lacking widgets, or inputs, or menus, or multiple windows, lots of little bugs, but other than that much better. :P
I'm considering sending in a few patches for improving Linux support later too. :P Either ways, great work!
Definitely, that'd be great! Especially any windowing stuff. Also, I've been looking through your rendering project. It might be something Figuro could support as well.
Yeah but NimEdit has the code for that or let's say an 80% solution. We don't have to start from scratch here.
Definitely, that's perfect for a starting point. Looks like it should translate over pretty well.
Looks impressive!
Keep up the great work!
Not in particular. It’d be cool have, but the community would have to build it.
However Figuro doesn’t have “privileged” widgets. The Input widget can be extended or reused by connecting to the signals and slots it uses. It’s also only a hundred something lines.
The signals and slots also support sending and receiving to a thread running async Nim, so it’d not be hard to wire in networking. There’s a libp2p library for Nim too.
although it looks like Araq doesn't like ropes
Your ropes don't look like mine so I don't have an opinion. :-)