Live data from Hacker News

Ask HN: Why does visual programming suck?

news.ycombinator.com

131–140 of 325 posts

Re: Ask HN: Why does visual programming suck?

#131

Earlier quoted context omitted.

Right, code is data. But the interface to write and modify that data is text. Consider, how long does it take you to draw an infographic representing the percentage of the United States that has a college education? How long does it take to modify it when you realise it is a mistake Now how long does it take you to represent/change that data with text?

Your example is strange. Changing the text and changing the data would require the same amount of time. And a graph would, in fact, instantly put that change into context. Right, code is data. Not now, though. Currently, code is text -- it's not data. That's the problem. And, yes, currently, drawing it instead of typing out the text is a horrible idea. We agree. But remember, currently, we're failing. Software is a d…

> Changing the text and changing the data would require the same amount of time.

Really? really?

Open up powerpoint, openoffice, or whatever you use to make infographics. Also open up vim, atom, or whatever you use to edit text.

Time yourself clicking and dragging to make a graph in one and then typing to write a number in the other.

> Imagine a decent IDE

I'm imagining something where you are able to select visual elements without either clicking and dragging or doing an O(n) walk by hitting alt-tab. But I can't imagine how you acheive that, much less efficiently specify how you connect things up and how you write automated tests.

Some of this is my failure of imagination, but its still on you to provide the sketch of a proposal if you want to convince.

Re: Ask HN: Why does visual programming suck?

#132
post #52

I think the reason is that text is already a highly optimized visual way to represent information. It started with cave paintings and evolved to what it is now. "Please go to the supermarket and get two bottles of beer. If you see Joe, tell him we are having a party in my house at 6 tomorrow." It took me a few seconds to write that. Imagine I had to paint it.

then why does everyone sketch a picture when trying to convey an idea? text is obviously useful but so is visual information. the complete dismissal of visual programming by text-based programmers is often infuriating. visual programming can provide an immediate indication of structure and dataflow, something that text-based languages struggle with. in my mind, the best case scenario is some sort of hybrid, where vis…

Sketching a picture can help for certain classes of problems, but I think that is far from universal: it often tends to be of less use for logical concepts than structural ones, for example.

Beyond that, though, even when a sketch is a useful tool, I find I seldom use the computer to create it. A whiteboard, notebook, or back of an envelope all seem easier than working with typical graphical input mechanisms that are commonly available. Good touchscreens are a step in the right direction, but still far from perfect and far from universally available, especially on desktops. Aside from any innate problems with graphical programming in general, I think this input problem makes the approach generally unappealing at the moment. It's not an insurmountable issue, but until there are good input mechanisms that are as common as keyboards, I think you will just find that it is hard to reach the critical mass a new representation needs.

I know that input speed is not really a limiting factor in most programming, and maybe shouldn't be the deciding factor, but given how attached to their text editors programmers already are, and how disruptive and frustrating it can be to have to switch, I think it's clear that it is an issue.

Re: Ask HN: Why does visual programming suck?

#133
post #59
post #52

I think the reason is that text is already a highly optimized visual way to represent information. It started with cave paintings and evolved to what it is now. "Please go to the supermarket and get two bottles of beer. If you see Joe, tell him we are having a party in my house at 6 tomorrow." It took me a few seconds to write that. Imagine I had to paint it.

Exactly! I'm actually bewildered why some people think visual programming is a good idea at all.

Zero syntax errors.

Re: Ask HN: Why does visual programming suck?

#134
I think it's because some visual mediums are better at representing certain forms of information than others, and visual programming tools attempt to represent a form of information (programming logic) using a visual medium (images) that isn't optimal for that form of information. Analogies can be made for things like calendars (which are the preferred visual medium for visualizing schedules), sheet music (which is the preferred visual medium for visualizing music - though guitar tabs present an interesting alternative to think about), and movie scripts (for which text is the preferred medium).

In the same way that a movie script is best represented by text, my belief is that text is superior to images for representing programming logic, and images are superior to text for representing UI elements. I think most people at least feel the same about representing UI elements, which is why visual programming tools are appealing.

This leads to the conclusion that the best tools for building UIs would represent programming logic in text, and represent UI elements using images. In my experience, this is true; tools like Unity and Flash are, in my opinion, better for UI development than HTML/CSS (text). This also leads to the conclusion that unless someone invents a better way of representing programming logic than using text - like the equivalent of inventing a calendar to display a schedule, if we had never invented a calendar before - visual-only programming is inherently limited.

Tools that keep UI in visual-land and programming logic in text-land - and don't try to mix the two - work great.

Re: Ask HN: Why does visual programming suck?

#135

Earlier quoted context omitted.

Ah, I see. But other than WYSIWYG editing I'm having trouble imagining how a language could be general purpose and could still be visually representative of the output of the program rather than the behavior of the program (much like the visual layout and syntax coloration of modern text languages conveys). Are there other examples of those cases? Edit: maybe I was presumptive to assume that they had to be "general p…

I think the "visually representative of the output" isn't a suitable way to describe it. The visual language I always think of is LabVIEW. It is very different than a textual language.

No it's not. A for loop is a block with inputs, a space for sub-blocks, and outputs. To add an iteration limit, a box with a literal number can be attached. This is visually represented of the program's flow graph. Which does make sense when actual signals are concerned, to extend the wire metaphor of analogue equipment. Reason did that too, where instruments had a back pane to connect them to effect panels via actually visualized wire plug-in. Buzz or unreal blueed apply the same idea, as does model-sim. Block diagrams are just a very popular abstraction in signal theoretic topics. So Algol syntax, the languages like C being close to the hardware, uses the same visual metaphor.

Erlang (Prolog) for example doesn't so much. Sure you have parameters, but matching blocks aren't strictly evaluated in sequence.

Re: Ask HN: Why does visual programming suck?

#136
post #52

I think the reason is that text is already a highly optimized visual way to represent information. It started with cave paintings and evolved to what it is now. "Please go to the supermarket and get two bottles of beer. If you see Joe, tell him we are having a party in my house at 6 tomorrow." It took me a few seconds to write that. Imagine I had to paint it.

So do you use text files for storage or a database? Is your company's accounting system in Word or Oracle? Are programs text, like a novel, or is it data? And to find out, would you query Moby Dick? Not really -- at least that's not how it's meant to be consumed. You read it from beginning to end. Would you read your program from beginning to end or would you query it? You query it, exclusively. I submit that program…

> Is your company's accounting system in Word or Oracle?

Accounting uses numbers, which in this context is text. If you replace a spreadsheet with a graph, your accountants will murder you.

Re: Ask HN: Why does visual programming suck?

#138
post #60

Earlier quoted context omitted.

请你到超市去买两瓶酒。如果你见Joe,告诉他我们明天六点钟参加派对在我的家。 Here, that was quite fast to paint. Would have been even faster with a proper brush instead of a keyboard :p

If that was a painting then surely I would have some remote idea of what it represents. As it is, I (and many others) don't.

Maybe he's making a joke about how Chinese characters evolved from more pictorial-like elements, and are in a sense abstractions over pictures.

Re: Ask HN: Why does visual programming suck?

#139
post #117

Earlier quoted context omitted.

I think you are chasing something that does not exist. While i submit to the idea that programs are "data", and could be represented not just like text, the expressiveness when using a visual representation is small, but the exactness is as high as normal languages. I've seen large visual-programming programs, and they explode into complexity, and I think there is a reason for that, the expressiveness of a symbolic l…

Visual programming does not have to mean 100% not text. https://joshondesign.com/2014/08/22/typopl

Yes, there are probably lots of useful interaction methods to be found in between text files and the "boxes and arrows" visual programming (circuit design) model.

Re: Ask HN: Why does visual programming suck?

#140
The type of visual programming you're suggesting seems to exist in an extreme form as the apps we use to read and write data, like Facebook, Trello, etc. On the other end of the spectrum we have the very technical savvy that want more direct control of what's going on. There's a lot of middle ground that's been covered, from both ends of the stack. I don't think the idea of visualizing things to be more material is flawed, but surely you could overdo it or apply the wrong model at the wrong level of abstraction.

All of our programming is visual.

We rely on a set of visual units of some manageable size (an alphabet of characters), and then we compose them sequentially into strings (visual units of a more general alphabet)

Stringing units together makes sense based on the way we experience a limited bandwidth of signal over time.

While listening, signal is presented one unit of the sequence at a time. When reading, we are presented with a whole page of characters at a time. The surrounding area is displayed, and we can move the focus around at will.

This leads to the development of the visualization models/techniques that we progress from simple features like spaces between words; parentheses/curly braces to group words; indentation of blocks to group/subordinate them, forming trees.

The idea of the unit/object/thing, composed of unit/object/things is thematic.

Files are units of text that are read/written one at a time. Eventually you stop directly typing, and you enter a different level of abstraction, where the units are displayed and manipulated with a different set of controls.

I think this is the point where the flowchart (directed graph) model fits in with the text focused model.

In Sublime, I like having the directory outline view and the zoomed-out scrollbar view with whatever single page of text I'm viewing. I think it'd be cool if these three were integrated, so that I open and close the files in a flowchart in the plane, where edges/arrows represent organization and dependencies. I'd like to import a module by dragging an arrow from one node to another

Post reply on HN