Use qtconsole to interact with QtMainwindow

34 views
Skip to first unread message

Mattia Martinelli

unread,
Jan 22, 2020, 9:50:48 AM1/22/20
to Project Jupyter
Good morning all,
sorry I'm almost new in Python coding. I hope this is the right place for my question.
I'm trying to write a code in Python in order to have a Qt main windows that use the QtInteractor of the pyvista library that allows to visualize and edit 3D meshes.
moreover, I added a second window that contain the jupyter qtconsole.
Is there a mehtod to permit the interaction between the two windows?
I mean to allow to the qtconsole to directly interact with the main window?

Thank you

Trifon Trifonov

unread,
Feb 1, 2020, 4:43:34 AM2/1/20
to jup...@googlegroups.com
Dear Mattia,
 
I am also very interested in this!  I develop a GUI interface that embeds a pyqtconsole. FYI, here is my projects


At least from the screenshots you can see what I am trying to do. Form the GUI I am able to push variables to the Jyputer terminal via

e.g. (for more details see my code in the github):

        from Jupyter_emb import ConsoleWidget_embed
        import numpy as np
        import RVmod as rv
        fit = rv.signalfit()

        class Exo_striker(QtWidgets.QMainWindow, Ui_MainWindow):
            ###################### Console #############################
            self.console_widget = ConsoleWidget_embed(font_size = 9)

             # add the console widget to the user interface
             # push some variables to the console

             self.console_widget.push_vars({"rv": rv,
                                "np": np,
                                "fit": fit,
                                })       



Now what I want is to push variables and functions from the qtconsole to the main GUI. I guess you Mattia want something similar?

I hope someone can help!





--
You received this message because you are subscribed to the Google Groups "Project Jupyter" group.
To unsubscribe from this group and stop receiving emails from it, send an email to jupyter+u...@googlegroups.com.
To view this discussion on the web visit https://groups.google.com/d/msgid/jupyter/6e1ca583-86f7-4c56-a802-32dcff90f836%40googlegroups.com.
Reply all
Reply to author
Forward
0 new messages