On Wed, 17 Oct 2012 06:50:19 -0500
"Edward K. Ream" <edream...@gmail.com> wrote:

> On Sun, Oct 14, 2012 at 9:40 PM, Terry Brown <terry_n_br...@yahoo.com> wrote:
> > Is there are function to return the current commander (c), defined as the 
> > commander in the visible tab in the tabbed (default) interface?  
> 
> What's your use case for this?  That is, how can it be that the c you
> desire is not the c in the script you are executing?

It's for the bookmark a page from your web browser in Leo with tags,
snippets, and comments code in the mod_http plugin.  I guess the
mod_http code is associated with or at least started by a particular c,
but that certainly doesn't mean that's the c you want to receive the
incoming bookmark.

Currently it can go either to a outline indicated by a predefined UNL,
or by default to the top of g.app.commanders[0].

But I'd like to add the option of sending it to the commander whose tab
is currently on top in the tabbed interface - I didn't want to spend
the time working out where the widget is and how to find out which c
it's for if that was already done.  It's something like

g.app.gui.?.?.?.tab_widget.currentWidget().?.?.c

The closest code I know would be the code which ensures the tab for a
particular c is on top, I could work back from that I guess.

Cheers -Terry

-- 
You received this message because you are subscribed to the Google Groups 
"leo-editor" group.
To post to this group, send email to leo-editor@googlegroups.com.
To unsubscribe from this group, send email to 
leo-editor+unsubscr...@googlegroups.com.
For more options, visit this group at 
http://groups.google.com/group/leo-editor?hl=en.

Reply via email to