Personal tools
You are here: Home Forum Extension of the platform Are there examples of sending messages to the python window or the python console while running plugins?

Are there examples of sending messages to the python window or the python console while running plugins?

Up to Extension of the platform


This forum is DEPRECATED, please create new topics in the new SALOME forum.
For existing topics please transfer them to the new forum.

Are there examples of sending messages to the python window or the python console while running plugins?

Posted by vectorhasting at December 24. 2020

I am trying to use the following code in %userprofile%\.config\salome\Plugins\salome_plugins.py :

    import salome_kernel

    displayMessage=salome_kernel.GLogger

    def displayLines(context):

        global displayMessage

        dispayMessage.putMessage("Testing Lines ========")

    salome_pluginsmanager.AddFunction('Display Lines', 'Write lines for readability during debugging", displayLines)

 

It shows up in the salome-mecca 2019 application under Tools > Plugins,

Selecting this plugin does not return any errors, BUT:

I can't see where the message went.

Does anyone know how to see this message and,

Does anyone know the proper way to make a plugin write to either the python console inside Salome or to the Python window that is running the Salome server? 

Thank you. 


This forum is DEPRECATED, please create new topics in the new SALOME forum.
For existing topics please transfer them to the new forum.

Powered by Ploneboard
Document Actions