News for hackers. Stuff that matters.
Re:We need visual programming. No, not like that by mapcars on Sunday July 14, 2024 @08:13PM (#40964268)
That is not a problem, and for sure not a fundamental one. The textual representation is very limited, it's actually 1D with a line breaks helping us read it. 2D gives a lot more possibilities of organising code similar to how we draw diagrams on a whiteboard.
Re:We need visual programming. No, not like that by jampekka on Sunday July 14, 2024 @08:23PM (#40964318)
Power of text or other symbols is that they aren't spatially bounded. That's why it works even in "1D".

There are probably some possible usability gains from adding dimensions. E.g. node-type "programming" in Blender is quite nice. But for general purpose progamming it's hard to see how we'd get rid of symbolic representation.

Re:We need visual programming. No, not like that by andrewflnr on Sunday July 14, 2024 @08:28PM (#40964336)
Specifically, textual programs use symbols to build a graph of references between computations, where the average visual language tries to use explicit lines between blocks. But the reference graphs of non-trivial programs are often decidedly non-planar, which only becomes a problem when you try to lay them out on a plane.
Re:We need visual programming. No, not like that by lolinder on Sunday July 14, 2024 @08:39PM (#40964401)
Why does laying out code on a line not cause a problem with spatial reasoning but a plane would? Are we somehow incapable of applying spatial abstractions when we move up into a higher dimension than 1?
Re:We need visual programming. No, not like that by dimask on Sunday July 14, 2024 @09:42PM (#40964650)
The spatial reasoning on reading code does not happen on the dimensions of the literal text, at least not only on these. It happens in how we interpret the code and build relations in our minds while doing so. So I think that the problem is not about the spatial reasoning of what we literally see per se, but if the specific representation helps in something. I like visual representations for the explanatory value they can offer, but if one tries to work rigorously on a kind of spatial algebra of these, then this explanatory power can be lost after some point of complexity. I guess there may be contexts where a visual language may be working well. But in the contexts I have encountered I have not found them helpful. If anything, the more complex a problem is, the more cluttered the visual language form ends up being, and feels overloading my visual memory. I do not think it is a geometric feature or advantage per se, but about how brains of some people work. I like visual representations and I am in general a quite visual thinker, but I do not want to see all these miniscule details in there, I want to them to represent what I want to understand. Text, on the other hand, serves better as a form of (human-related) compression of information, imo, which makes it better for working on these details there.
Re:We need visual programming. No, not like that by mapcars on Monday July 15, 2024 @07:03AM (#40966760)
> If anything, the more complex a problem is, the more cluttered the visual language form ends up being, and feels overloading my visual memory

I feel like you are more concerned about implementation than the idea itself. For me it's the opposite - I find it's easier to understand small pieces of text, but making sense of hundreds of 1k lines files is super hard.

Visual programming in my understanding should allow us to "zoom" in and out on any level and have a digestible overview of the system.

Here is an example of visual-first platform that I know is used for large industrial systems, and it allows viewing different flows separately and zooming into details of any specific piece of logic, I think it's a good example of how visual programming can be: https://youtu.be/CTZeKQ1ypPI?si=DX3bQSiDLew5wvqF&t=953

Re:We need visual programming. No, not like that by andrewflnr on Sunday July 14, 2024 @11:11PM (#40964981)
As jampekka put it, text isn't trying to use spatial abstractions, it's using the (arguably more powerful) abstraction of named values/computations. Hard to think about? Yes, there's a learning curve to say the least. But it seems to be worth it for a lot of cases.
Re:We need visual programming. No, not like that by jampekka on Sunday July 14, 2024 @08:54PM (#40964452)
Text doesn't use spatial abstractions.

The problem with spatializing complex relationsips becomes very apparent when one tries to lay out graphs (as in nodes-and-edges) graphically. Unless the relationships are somehow greatly restricted (e.g. a family tree), the layouts become a total mess, as the connectedness of the nodes can't be mapped to distances and the edges by necessity have to make a lot of crossings on top of each other.

Re:We need visual programming. No, not like that by mapcars on Monday July 15, 2024 @07:10AM (#40966790)
I think you are limiting visual programming to some sort of a single graph that has everything together, but similar to how we split code into modules and files, visual systems can do the same, here's an example I keep showing in this thread of a visual programming system that works pretty well: https://youtu.be/CTZeKQ1ypPI?si=DX3bQSiDLew5wvqF&t=953
Re:We need visual programming. No, not like that by edflsafoiewq on Sunday July 14, 2024 @08:51PM (#40964441)
Writing is based on speech, which is one-dimensional. Most programming is actually already highly two-dimensional thanks to its heavy line orientation.

But most visual programming isn't trying to be a kind of "2D orthography" for language, it is trying to be a "picture" of a physical mechanism.

Re:We need visual programming. No, not like that by eimrine on Tuesday July 16, 2024 @11:14AM (#40977349)
That 2D orthography idea is my pipe dream. Any time I am writing several similar lines of code but with variables having different length I always want my IDE to be acknowledged that some 1-symbol operators would be looking so nice if aligned in one vertical line.
Re:We need visual programming. No, not like that by lolinder on Sunday July 14, 2024 @08:38PM (#40964388)
So why not do 2D visual programming with access to symbols that are not spatially bound? Is there any reason why a 2D plane forces the programmer to think in terms of a plane that doesn't also apply to a 1D line of text?

It seems to me that reducing the frequency with which programmers have to drop into non-spatial symbols would be beneficial even if there are still use cases where they have to.

Re:We need visual programming. No, not like that by edflsafoiewq on Sunday July 14, 2024 @08:40PM (#40964403)
The problem with visual programming is it abandons the fundamental principle of language, whereby to connect two objects it is necessary only to speak their names, in favor of the principle of physicality, whereby to connect two objects it is necessary that they be in physical contact, ie. to be joined by a wire.
Re:We need visual programming. No, not like that by lolinder on Sunday July 14, 2024 @09:51PM (#40964681)
Is that an inherent problem of the medium or the result of people trying too hard to completely change the paradigm?
Re:We need visual programming. No, not like that by mapcars on Monday July 15, 2024 @06:50AM (#40966703)
> only to speak their names

> in physical contact, ie. to be joined by a wire.

I don't really see how that is different, in any given language the name alone is not enough to refer to the object, in general case you have to import it. For me the process of name resolution and connecting by a wire is the same thing with different representations.

Re:We need visual programming. No, not like that by lioeters on Monday July 15, 2024 @12:39PM (#40969375)
> to connect two objects it is necessary that they be in physical contact

I can imagine a way to connect an object to another by selecting the latter's name from a drop-down menu of defined objects. A visual equivalent of a function call.

Re:We need visual programming. No, not like that by ozim on Monday July 15, 2024 @01:53AM (#40965583)
With text/symbolic representation I can describe any amount of dimensions in a super dense way and physicist/mathematicians are doing that, software devs as well because most software is multidimensional.

You do have graphs in mathematics but all the maths I see is about describing reality in really dense couple of symbols, compressing as much of the universe as possible to something like E=mc^2.

Graphical programming representations go the other way - it actually tries to use more bits to describe something that can be described in less bits - many more bits.