This also exists outside of pluto, and is not too difficult in either GLMakie.jl or Interact.jl
For those times when one needs just a quick couple of sliders and buttons, one old-fashioned possibility is GtkServer.jl.
Jumping back on this argument and the interaction with GUIs, when I first heard of julia, I’ve partially been convinced by its compatibility advertisement : knowing that julia comes late in the game with respect to python or other languages, it was made to be composed with other languages.
However, except for the example linked in my previous post, there does not seem to be much work on an interface with .NET.
For me it’s really a pity. .NET has a lot of cool features for GUIs, which julia lacks almost completely, and on the other hand, .NET lacks the scientific side of julia (though being a general-purpose language).
Just a note, when you change something in Pluto, it only updates things that are dependent on the thing you changed.
Kind of harping on the web interface idea, I think that if Julia is going to be taken as a serious general programming language instead of a niche language, there needs to be the ability to create stand alone apps. This means that if developers are forced into using a web interface for a UI we will be limiting the development of stand alone apps.
Being an Evolutionary Biologist, I can see the need to create a non-web based UI. Most scientists working in this realm don’t want to deal with command line. Anyone doing modeling in this realm wants to see what happens with the model under changing conditions, which is the fundamental basis of Ecology/Evolution research. If this can be done in an interactive UI that is fantastic, and to tie it to a internet connection adds a level of complexity to field research, you may not be in an area that has service or the possibility to connect without a several hours of travel. Can it be used locally? Sure but what kind of configurations would you have to make to the browser? What needs to be done when service is available, what other unforseen circumstances can occur, etc. Remember you may be hours from civilization. To just include a UI with the app it is ready to go out of the box is really the way to go for this field in my opinion.
Internet browsers can run without an active internet connection.
Sure but what kind of configurations would you have to make to the browser?
What needs to be done when service is available, what other unforseen circumstances can occur, …
Well, the same applies to any desktop UI.
I’ve been experimenting with building Blazor apps using C# for the UI and standing up a rest api in Julia using Oxygen.jl. I have very little c# or UI knowledge and it’s been working well so far.
While I understand what it is that you are saying, and while I largely agree, I can see circumstances and have experienced circumstances where there have been incompatabilities or issues that a non developer couldn’t solve or won’t solve in the field. I guess what I am saying is that the more self-contained and robust something is in the field the less one has to worry about. A web browser is simply not the answer to every situation.
As I mentioned earlier, but perhaps not explicitly enough, essentially anything that is meant to work in a browser can work inside a QT GUI with one simple widget (browser) stretched across the entire window. Making it indistinguishable from a local app. With added bonus of multi os compatibility and more importantly, having all the ui side pretty much for “free”
I’m not advocating for web based, just saying it is a viable option.
Having said all that, as a scientist I often really don’t care about the beautifulness of the UI, I just need buttons, axes, input fields, etc. So web graphics is a huge overkill for strictly scientific work, especially if it adds development time which is counterproductive to fast interactive modeling.
Well, what I’m doing so far is to use some custom JSON RPC between julia and .NET but I’m facing the problem of portability of the code all the time.
I’m using the StructTypes package to help with the marshaling.
Well i do not want to diverge too far from the original theme of this threade, but my most recent attempt to improve my approach is to use JSONRPC.jl . Since it’s the base of the VSCode extension and should be able to handle anything thrown at it, I guess it should work for my use cases…
My two cents, as someone who isn’t currently developing UIs but has been an eager observer for a while…
The current Julia wrapper is Electron.jl.
Edit: Apparently Blink.jl is the Julia wrapper.
I know it’s programmer heresy, as these weren’t even considered “real languages” twenty years ago, and knowing them didn’t make you a “real programmer.” But here we are. The modern way to do “real” full desktop app development, without having to worry about hardware and OS compatibility, is to do it in HTML; to do otherwise is a waste of time.
And if you don’t want to touch those languages because you just want a simple interface for scientific experiments or something, then Interact, GLMakie, Pluto, and even IJulia are amazing.
Isn’t this the probable future of most GUIs?
AIso my two cents, I do not think people working on .NET apps would agree with you on the “anyway”. It surely is a way to handle think kind of development, but requiring electron as a dependency for basic apps is kind of problematic. When you compile apps developed in .NET you can be efficient and quite lightweight in comparison. The same goes for the web browser, though a lot of machines may have them, not all of them do (I’m going a bit far there, but it’s still an additional soft w.r.t the app)
I would LOVE to see .net visual studio with a Julia backend. It would be magic.
This is certainly true, but if there’s any constant in the history of personal computers (and technology in general) for the past four decades, it’s been that bloat is solved with better hardware and the march of “progress” continues (over the protests of the technical experts who detest how inelegant and messy it has all become).
Plenty of apps that run on our phones work through WebViews, but we don’t complain over how resource-intensive Twitter is. Heck, we can now buy computers the size of postage stamps that run Linux and Python and cost less than some meals. While this trend might slow as we reach the physical limits of silicon, I don’t see much reason for it to stop (unless certain geopolitical hazards regarding islands with semi fabs play out, but then we’d have bigger problems).
It’s funny and strange that I’m making this argument in a thread for a language which specifically prioritizes performance and allows us to inspect the native assembly but my attitude on this is specific to user interfaces, where the cost of development/engineering is usually greater than the cost of suboptimal runtime performance.
The web-based GUI model has been dominant for a number of years and there is now a new movement, especially in the Rust community, to replace it with more efficient models.
However, developing a modern GUI system is extremely complex, and I don’t see this area as very strong for Julia in terms of community expertise or language design. Binding to one of the newer GUI toolkits seems like a better option to me rather than trying to build a native Julia one.
Indeed, developing full-fledged GUI systems is a lot (a lot lot) of gruntwork which is uninteresting to much of the crowd Julia has attracted. The integral under the effort×time curve is very large, and it’s thankless work. And to top it off, a lot of it is fashion so it’s a moving target.
I think web-based desktop GUIs are here to stay, despite their inefficiencies, because a) in most cases they’re good enough, b) the need to operate consistently across platforms forced convergent evolution, so there’s relative stability in the object model and lots of support, and c) they’re simple enough to throw a thousand script kiddies at a problem and come out with Shakespeare, so there’s a strong business interest in keeping the model alive. Or alternatively, c) they’re simple enough for a scientist to build a half-decent UI in their spare time.
I think for a true-native Julia GUI to be well-supported, it must be tailored to meet some persistent need of scientists. Scientists all seem to all need plotting packages, so if I were to bet on what would serve as our go-to Julia GUI platform, I would bet on an interactive plotting package: GLMakie.
One example for the gruntwork, it was already quite a bit of work to get Makie’s Textbox to work even though it’s very limited in functionality. You can input some short strings or numbers, which is nice for scientific GUIs. But people are used to such a wide range of behaviors from text fields, I’ll take volunteers to implement these
- selecting text, marking selected text with boxes
- allowing multiline text
- allowing special character input via OS widgets
- bidirectional text
The selection thing would probably be the most impactful for common usage scenarios.