Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Introducing New Skov #12

Open
nicolas-p opened this issue May 30, 2017 · 9 comments
Open

Introducing New Skov #12

nicolas-p opened this issue May 30, 2017 · 9 comments

Comments

@nicolas-p
Copy link
Owner

nicolas-p commented May 30, 2017

I spent the last three months doing massive changes in Skov.

One of my original principles was that it should be as easy to reuse a result several times as it is to use it only once, hence the use of the common 'nodes-and-wires' approach. If you want to connect the output from one node to the input of another node, you draw one wire; if you want to connect the output to two different inputs, you just draw two wires.

I progressively realised that this is bad for two reasons:

  • it is super hard to place the nodes automatically when they can have wires going to any other node anywhere in the graph (the graph layout algorithm has been by far the hardest thing to program in Skov)
  • when you start to have two or three nodes that are each connected to two or three other nodes elsewhere in the graph, it becomes hard to read, you have to follow the wires to understand what the code is doing

So now one node can send its data to one other node only. To reuse a result in several places, you have to name it, and use the name in several places (what almost every programming language is doing). This is a betrayal of my original principle that I mentioned above but the benefits are huge. We don't have a graph structure anymore but a tree structure. Instead of being very hard to layout automatically, it becomes trivial. Everything becomes simpler to manage, including import/export to text files.

New Skov looks like this:

capture d ecran 2017-05-30 a 11 05 58

I will publish a new binary release very soon. In the meantime you can build Skov from Factor yourself by following the instructions in README.

Two features that were present in Old Skov have yet to be re-implemented:

  • word completion: pressing TAB to complete a word will not do anything, and if two words in the system have the same name, you won't be able to choose which one you want
  • objects: it's impossible to define your own objects, or to use constructors, accessors and mutators

These will have to wait for the next release.

@nicolas-p
Copy link
Owner Author

Skov went on a diet!

I abandoned the pyramidal shape and went for a representation that is much slimmer and easier to read. I had this idea months ago but at the time I couldn't find a way to make it look better than the pyramid.

capture d ecran 2017-09-10 a 14 19 06

Also, the graphics don't use bitmaps anymore. I now draw everything with OpenGL. This will make future changes much easier. The only drawback is that I didn't manage to enable antialiasing, as you can see if you look closely.

@mrjbq7
Copy link

mrjbq7 commented Sep 10, 2017

That looks great! Not sure about the anti aliasing. Should be able to figure that out since it's not much OpenGL initialization code but I haven't had time to look yet.

@mrjbq7
Copy link

mrjbq7 commented Sep 10, 2017

How does it handle layout for the second example if "half" was actually called something long like "divide-that-nice-number-by-two"?

@nicolas-p
Copy link
Owner Author

capture d ecran 2017-09-11 a 07 19 52

@mrjbq7
Copy link

mrjbq7 commented Sep 11, 2017

Rocking!

@nicolas-p
Copy link
Owner Author

It is now possible to define words like map and filter:

capture d ecran 2017-09-30 a 14 26 17

capture d ecran 2017-09-30 a 14 42 11

(and they actually work!)

@mrjbq7
Copy link

mrjbq7 commented May 22, 2020

I went to download the latest Skov and the website wasn't working any more!?

Are you still hacking on this? I'd love to help and/or try it again and/or merge some of your code if it's useful.

@mrjbq7
Copy link

mrjbq7 commented Dec 28, 2020

Hi @nicolas-p !

Just checking in on your project, I'd love to help out if I could.

Hope you are well!

@Zireael07
Copy link

Confirming that the site doesn't work. Even via Wayback Machine, most parts are either broken (missing pictures) or outright 404

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

3 participants