-
Notifications
You must be signed in to change notification settings - Fork 80
GtkApplication #64
Comments
I hadn't seen that API before. That is awesome. (note that GApplication is a Gtk+ 2 API also!)
(Alternatively, now that JuliaLang/julia#5687 is merged, we could flip the ownership of the mainloop so that Gtk is the primary and Julia is triggered from a timer.) |
Ah yes I see. I had only read the information text to GtkApplication and thought that gtk-init is called in the constructor. I also had not seen that all this depends on libgio. I am not so sure about whether we should flip the ownership of the mainloop. The other way around seems to be more natural for Gtk bindings. But if I get it right we would loose the possibility to construct Gtk widgets on the REPL, right? Or, more concretely, we could only construct them but the callbacks would not be invoked until gtk-init is called, which would block. |
That's the fun part about flipping it correctly -- it would be completely transparent to the user. |
I love how stuff gets tackled on a "deep" level in this community, and how it opens up new possibilities. |
It's definitely helpful to both maintain a package and be deeply into the core of julia. |
Try that with Matlab 😄. |
@tknopp feel free to submit a pull request for this. I've now switched the mainloop ownership on master (aside from being mildly sketchy that we do a stack replacement while inside a Gtk callback). But now you can do whatever you want with the main loop! |
@vtjnash I am not entirely sure if I find much time for Gtk.jl development in the near future so I won't commit myself to this. My main motivation here was to get a global main menu on OSX when I was developing Julietta. I have not yet ported Julietta to the new Gtk.jl API. In general I think it is a quite nice testbed for Gtk.jl. |
No pressure. Just thought I would point out how the situation has changed recently, making this much easier to play around with |
Yes, thanks for the hint. I am really looking forward playing around with this when I find time. |
@vtjnash: Do you see any way that we could wrap GtkApplication (https://developer.gnome.org/gtk3/stable/GtkApplication.html)? The motivation is that it allows to get the proper global menu on OSX and Gnome. The issue is that it seems to initialize the gtk main loop. If I understand this correctly, this is a problem right?
The text was updated successfully, but these errors were encountered: