On Sunday, November 3, 2024 at 3:50:44 PM UTC-5 jkn wrote:

I feel like I am being a bit dim here...

I'm trying to enable the freewin plugin (I am actually also trying 
viewrendered/viewrendered3, but 'backed off' to freewin, because I seem to 
be having fundamental plugin issues.


You have to include the ".py" extension in the enabled-plugins body.  It 
the extension is present Leo will look in the leo/plugins directory.  If 
it's absent, Leo will try to import the module from the known sys.path 
locations.  So for freewin, the entry in enabled-plugins needs to be: 
freewin.py 
-

plugins_menu.py
viewrendered.py
viewrendered3.py
contextmenu.py
nav_qt.py
mod_scripting.py
mod_autosave.py
python_terminal.py
qt_layout.py
quicksearch.py
freewin.py
rpcalc.py
leo_to_html.py

 

- I have an @settings node '@enabled-plugins' in myLeoSettings.leo
- the body of this has several plugins already listed (which I hardly 
ever/never use)
- I added a 'freewin' line
- after restarting Leo, I run a node with 
"g.es(g.app.config.getEnabledPlugins())" 
(NB: docs says 'g.app.gui.getEnabledPlugins()"; I will correct this later)


Running that exact expression, I see all the plugins I've enabled, 
including freewin:

plugins_menu.py
viewrendered.py
viewrendered3.py
contextmenu.py
nav_qt.py
mod_scripting.py
mod_autosave.py
python_terminal.py
qt_layout.py
quicksearch.py
*freewin.py*
rpcalc.py
leo_to_html.py
 

- nothing is shown! my @enabled-plugins node does not appear to be read.
- so ... I put a similar node under @settings in a particular file
- now I can run g.es(g.app.config.getEnabledPlugins()) and see 'freewin' in 
the log pane.
- however...
- show-commands does not show z-open-freewin


It never occurred to me to enable it locally only for one outline so I 
haven't tested for this. Off-hand I don't see why the commands wouldn't be 
present. I just went to one of my Linux VMs and tried it. the 
z-open-freewin command was present in all outlines, not just the one where 
I had put the enabled setting.  That surprised me.

-- 
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 visit 
https://groups.google.com/d/msgid/leo-editor/e7fae4fe-0263-41c2-adcd-7427d2d1d5fan%40googlegroups.com.

Reply via email to