On Sun, Apr 19, 2020 at 11:01 AM Matt Wilkie <[email protected]> wrote:

> How do I get the name/position of a script bound to a button, regardless
> of what node is currently selected when the button is used?
>

You can right-click the button itself, then choose "Goto Script".

If you want to do that programmatically, you will have to study the
horrible code in mod_scripting.py. Searching for 'Goto Script' yields
qtFrame.QtIconBarClass.setCommandForButton, which includes a gnx that could
then be used to find a vnode, and its headline.

The goal is make it clear in the Log pane where the status message is
> coming from (the script).
>

I agree with Thomas that having the script itself print the message looks
simplest.

Edward

-- 
You received this message because you are subscribed to the Google Groups 
"leo-editor" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to [email protected].
To view this discussion on the web visit 
https://groups.google.com/d/msgid/leo-editor/CAMF8tS0jhvECZRac3Ltpc20Ez4CcC-y3iecwY30G8BMN9%2BEAfQ%40mail.gmail.com.

Reply via email to