How to use glade with Juno?

question

#1

I’m trying to make a GUI with julia so I tried using Glade since that was the builder recommended by Julia docs in this link. I tried using the code posted to connect the widgets to my code in Juno but keep getting a “glade is undefined” error. So I tried saving the glade into the same file as the code and tried putting it in my Desktop but that doesn’t work either.

Does anyone mind explaining how to connect the glade widgets? I’m kinda new to Julia so sorry if I am missing something obvious!


#2

If you have a file called myapp.glade then you’ll need to call @GtkBuilder(filename="myapp.glade"); the missing quotes seem to be an error in the docs.
This is in no way Juno specific, btw.


#3

Thanks for the reply. I tried what you said but it still doesn’t work.

Do you happen to have any other suggestions?


#4

Thanks for the reply. I tried what you said but it still doesn’t work.


Do you happen to have any other suggestions?


#5

No clue.
Pinging @tknopp though, he’ll probably have an idea.


#6

not really. The at-sign should not be necessary anymore but this would not invoke that error.


#7

It seems like it is trying to call GTKBuilderLeaf(::String) but GTKBuilderLeaf only has a keyword function.

What happens if you just directly call GtkBuilderLeaf(filename="glade.glade")?


#8

That works!!! Thank you so much! :grin: