Julia for GUI app

Count me in. I have extended Matlab GUI experience but only minor on Julia.

1 Like

Big vision! It would make a good topic in the Visualization category.

I don’t want to sound negative on the great work on GLVizualize but I think their is still a distinction between this work and a classical UI framework.

Implementing something like Mirone should be pretty doable with Gtk.jl right now. All the menus and the toolbar can be done in a UI designer and the raster graphics could be drawn on a Cairo canvas including the ability to mix vector and raster graphic. I am doing just that in a project that uses Gtk.jl

I see what you mean (and partially agree) but I have years of work in Mirone (Open Hub estimates 49 :astonished:) and from what I have read GTK is not particular fast in rendering big files and lots of vector elements. But above all, as I mentioned earlier, I fear that it is a dying technology. Off course I may be wrong but …

1 Like

No worries :wink: Can you elaborate on this?

Yes porting such a big project is quite certainly much too much effort. But this holds true for any UI framework.

I don’t see why Gtk should be slow in rendering big images. This all goes through Cairo and if this is not fast enough (which I doubt given that you program Mirone in Matlab) one could use an OpenGL widget and still do alle the widgets with Gtk.

That you do not trust in Gtk’s future is something that you have to judge on your own. It seems to be actively developed, widely distributed and open source. So I would bet against that :wink:

For instance: A classical UI framework allows to open different windows (controlled by the window manager). It has predefined dialogs (open file / save file), scrollbars, and so on.

It this really the direction where you are heading with GLVizualize?

I was thinking more into vector renderings but let me tell you guys a secret. By not following TMW advice, avoiding doubles and surface objects at all cost and using older Matlab versions + some MEXing, one can do ML GUIs that work amazingly fast. For a lot of things, Mirone is (was when I tested it) way faster than QGis. It’s the vector part that screws with its absurd memory consumption.

But I’m diverging from issues in question in this thread, sorry.

It is possible to combine both. QML.jl exposes a component that can be used as a GLVisualize screen, so you could combine an interactive viewport with classic Qt elements around (or even over) it. The current version of this is not compatible yet with the new GLVisualize interface, but I intend to have a working proof-of-concept on the first QML.jl release Real Soon Now ™ ;).

I do think so. In my experience, an interactive plotting libraries will need these anyways, so it’s not that far stretched. I’ve started with GLVisualize + Julia to minimize the 2 language problem, so it would be all for naught if you need a C/C++ library just for scrollbars :stuck_out_tongue:
As I sketch out in the blog post: you really need to put development time into creating a nice general API that works seamlessly for interactive graphics or creating popups that interact with other parts of the app.
And if you have that, creating e.g. a scrollbar or other popups is trivial. Which should be the general goal: make the interactive parts of GLVisualize so easy to use, that the user isn’t even aware, that he just created something you usually need a 25 year old ~8million LOC GUI library for.

But I guess it will mainly depend on the resources behind GLVisualize. If I will stay the sole developer of GLVisualize, it’s admittedly improbable that these things will happen (in a nice way) :wink:
So in the end we might need to settle for the great work that you, @barche or others are doing with 3rd party libraries. But it’s definitely not what I consider as ideal.

3 Likes

yes a combination of both GL based fancy 3D visualization framework within a classical UI toolkit is a very promising approach. This is also what is done in various applications dealing with visualization. Just as an example, VTK is usually embedded into a Qt/Gtk interface.

8 posts were split to a new topic: Installing QML.jl

@barche : Is it possible to obtain the QWidget and the QPainter reference for the plotting area used by your QML package? With this information GR could draw directly into the corresponding object without creating an intermediate image. That would be much faster.

Might sound crazy - but we’ve used this method for years …

Yes, I was planning to do this kind of thing. The QPainter is easy, but in QML there is no QWidget but a QQuickItem (QQuickPaintedItem here). Why is the QWidget needed? Also, how should these be passed to GR?

BTW, it may be best to discuss this in a github issue?

I want to use browser technology (HTML5 CSS3 javascript library + chrome / firefox / safari) as the basis off two way interaction (get user selections, track user mouse position and button press, show plots, autohighlight parts of a datatable that are of interest to the user). It would be much more complete as a medium with the ability to present and two-way play with Qt5+QML+QQuick windowed content and GR graphics plots. To have this available within the context of the DOM (webpage construction and dynamic content adjustment) would be ideal.

Could you express in a more non-compressed form? I cannot really follow what your question is

thank you for asking, see above

One can embed Webkit (i.e. Browser technology) in both Qt and Gtk if this is would you want.

@tknopp I have read about that. Julia’s style seems better suited to having the Web realized part as the outermost deliverer of interactive technology. That way, I would think globally and refine incrementally.

I think in Julia Escher.jl aims to provide this. There is also qmlweb, which attempts to bring QML to the browser, but I’m not sure how far along that is. I have never tried either of these, but I have seen some demos of Escher.jl and it looks very impressive.