Leo installer doesn't go all the way yet. Sourceforge website points to an unexisting Leo Website
Hi: Coming back to the currently existing anti-nobies filters in Leo, I just found two: If installing Leo from the LeoSetup-4.11-a2.exe, Leo wont run when the icon is executed. When i call it from command line, the feedback is that it doesnt have PyQt installed. I thought that file was suposed to be one click install, so just giving feedback in case thats not suposed to happen. Also, in the sourceforge website of Leohttp://sourceforge.net/projects/leo/?source=pdlp, there is an hyperlink that is suposed to go to Leo's website, and instead goes here: http://webpages.charter.net/edreamleo/front.html The link is as follow, and points noobs to no website, directly from Leo sourceforge: Leo: a programmer's editor more Web Sitehttp://webpages.charter.net/edreamleo/front.html HTH, regards. -- 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 leo-editor+unsubscr...@googlegroups.com. To post to this group, send email to leo-editor@googlegroups.com. Visit this group at http://groups.google.com/group/leo-editor. For more options, visit https://groups.google.com/groups/opt_out.
Re: Leo installer doesn't go all the way yet. Sourceforge website points to an unexisting Leo Website
Uh, forgot to say, staying in topic, I would put a Free download banner, such as this http://www.mozilla.org/en-US/firefox/new/, directly in Leo homepage http://leoeditor.com/. So people interested in quick install leo without reading to quick check (which happens to be a filter for the user to either pick leo or not) will be able to open then click the dl banner. On Sunday, September 22, 2013 3:51:25 PM UTC+2, Fidel N wrote: Hi: Coming back to the currently existing anti-nobies filters in Leo, I just found two: If installing Leo from the LeoSetup-4.11-a2.exe, Leo wont run when the icon is executed. When i call it from command line, the feedback is that it doesnt have PyQt installed. I thought that file was suposed to be one click install, so just giving feedback in case thats not suposed to happen. Also, in the sourceforge website of Leohttp://sourceforge.net/projects/leo/?source=pdlp, there is an hyperlink that is suposed to go to Leo's website, and instead goes here: http://webpages.charter.net/edreamleo/front.html The link is as follow, and points noobs to no website, directly from Leo sourceforge: Leo: a programmer's editor more Web Sitehttp://webpages.charter.net/edreamleo/front.html HTH, regards. -- 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 leo-editor+unsubscr...@googlegroups.com. To post to this group, send email to leo-editor@googlegroups.com. Visit this group at http://groups.google.com/group/leo-editor. For more options, visit https://groups.google.com/groups/opt_out.
For implementors: summary of Leo's key-handling code
Two days ago I removed lots of unused code. The old code obscured the shape of Leo's actual key-binding scheme. I have just updated the section Key bindings, an overview in leoKeys.py as follows:: The big pictures of key bindings: 1. Code in leoKeys.py and in leoConfig.py converts user key settings to various Python **binding dictionaries** defined in leoKeys.py. 2. An instance of leoQtEventFilter should be attached to all visible panes in Leo's main window. g.app.gui.setFilter does this. 3. leoQtEventFilter.eventFilter calls k.masterKeyhandler for every keystroke. eventFilter passes only just the event argument to k.masterKeyHandler. The event arg gives both the widget in which the event occurs and the keystroke. 4. k.masterKeyHandler and its helpers use the event argument and the binding dictionaries to execute the Leo command (if any) associated with the incoming keystroke. Important details: 1. g.app.gui.setFilter allows various traces and assertions to be made uniformly. The obj argument to setFilter is a QWidget object; the w argument to setFilter can be either the same as obj, or a Leo wrapper class the supports the HighLevelInterface protocol. **Important**: the types of obj and w are not actually all that important, as discussed next. 2. The logic in k.masterKeyHandler and its helpers is long and involved: A. k.getPaneBinding associates a command with the incoming keystroke based on a) the widget's name and b) whether the widget is a text widget (which depends on the type of the widget). To do this, k.getPaneBinding uses a **binding priority table**. This table is defined within k.getPaneBinding itself. The table indicates which of several possible bindings should have priority. For instance, if the widget is a text widget, a user binding for a 'text' widget takes priority over a default key binding. Similarly, if the widget is Leo's tree widget, a 'tree' binding has top priority. There are many other details encapsulated in the table. The exactly details of the binding priority table are open to debate, but in practice the resulting bindings are as expected. B. If k.getPaneBinding finds a command associated with the incoming keystroke, k.masterKeyHandler calls k.masterCommand to execute the command. k.masterCommand handles many complex. See the source code for details. C. If k.getPaneBinding fails to bind the incoming keystroke to a command, k.masterKeyHandler calls k.handleUnboundKeys to handle the keystroke. Depending on the widget, and settings, and the keystroke, k.handleUnboundKeys may do nothing, or it may call k.masterCommand to insert a plain key into the widget. 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 leo-editor+unsubscr...@googlegroups.com. To post to this group, send email to leo-editor@googlegroups.com. Visit this group at http://groups.google.com/group/leo-editor. For more options, visit https://groups.google.com/groups/opt_out.
Design properties are more general than types
This is a follow-on to the previous post: summary of Leo's key-handling code. Interestingly, static type checking would shed little light on this design; the types of widgets passed (in the event arg) to k.masterKeyHandler hardly matter: k.getPaneBinding examines only:: - g.app.gui.isTextWidget(w), True if w supports Leo's HighLevelInterface. - c.widget_name(w), the pane's name. One could imagine devising a type scheme that would replace this combination of properties, but in fact Leo doesn't have such a scheme. In fact, types can be seen as a week form of **design properties**. Imo, these design constraints, rather than types, are the real basis of understand a program as complex as Leo. Design properties seem especially useful at **choke points**, places in the code that handle much of the work load. For key handling, the choke points are: - gui.setFilter - eventFilter - k.masterKeyHandler - k.masterCommand Let's look at each in turn: 1. gui.setFilter allows assertions to be made about *all* objects and widgets for which binding exist. 2. eventFilter calls k.masterKeyHandler for *all* key events. 3. k.masterKeyHandler calls k.getPaneBinding for *all* key events. 4. k.masterCommand dispatches *all* Leo commands, with the appropriate arguments. It's amusing to note that none of the above 4 statements involves types. In fairness, however, the types of the arguments passed to k.masterKeyHandler, k.masterCommand, and all the functions dispatched by k.masterCommand *do* matter. As a result of the recent work, I am looking for ways to enforce global design constraints. I'm not sure how much of this work will involve types in any way... 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 leo-editor+unsubscr...@googlegroups.com. To post to this group, send email to leo-editor@googlegroups.com. Visit this group at http://groups.google.com/group/leo-editor. For more options, visit https://groups.google.com/groups/opt_out.
flush to log console
*How do I flush output to the log console?* *I have:* *-* *g.es(starting )* *#perform long task* ** *g.es('finished with results %s'%result)* *-* *I use ctl+b to run the node.* *When I was on windows, I would see starting and my program would execute. But on Centos I don't see starting till after my program is done. * *I tried:* *import sys* *sys.stdout.flush()* *but I saw the same results. * *The output when I start leo is:* *Leo 4.10 final, build 5020, 2012-02-26 13:18:08 -0600* Python 2.7.5, qt version 4.8.4 linux2 *Brian * -- 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 leo-editor+unsubscr...@googlegroups.com. To post to this group, send email to leo-editor@googlegroups.com. Visit this group at http://groups.google.com/group/leo-editor. For more options, visit https://groups.google.com/groups/opt_out.
feature request - insert headline before current
Hi Edward (Background - I am experimenting with changing my Leo Key bindings to make it work more closely to other (lesser ;-) outliners I am more used to than Leo) One thing that I think is missing from Leo is a primitive command 'insert headline before current'. I would like to bind 'Insert' to this rather than ''insert-node', which of course inserts after the current headline. I've taken a quick look at def insertHeadline() in key-handling-notes.txt but I'm not initially confident of making the necessary additions. Would it be appropriate to raise a wishlist item for this? Thanks. Also, whilst I'm looking at the source - can you explain to me where/how 'key-handling-notes.txt is 'included' as part of Leo? I can't work this out from an initial skim... Thanks a lot Jon N -- 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 leo-editor+unsubscr...@googlegroups.com. To post to this group, send email to leo-editor@googlegroups.com. Visit this group at http://groups.google.com/group/leo-editor. For more options, visit https://groups.google.com/groups/opt_out.
Re: feature request - insert headline before current
Hey Jkn: This quick script will do what you need, although Im pretty sure someone here will update it with something more eficcient =P c.p.insertAfter() c.executeMinibufferCommand('goto-next-sibling') c.executeMinibufferCommand('move-outline-up') c.executeMinibufferCommand('edit-headline') c.redraw() Just run that code (you can make it a button then click it from any node) and it will do what you need. On Monday, September 23, 2013 12:07:04 AM UTC+2, jkn wrote: Hi Edward (Background - I am experimenting with changing my Leo Key bindings to make it work more closely to other (lesser ;-) outliners I am more used to than Leo) One thing that I think is missing from Leo is a primitive command 'insert headline before current'. I would like to bind 'Insert' to this rather than ''insert-node', which of course inserts after the current headline. I've taken a quick look at def insertHeadline() in key-handling-notes.txt but I'm not initially confident of making the necessary additions. Would it be appropriate to raise a wishlist item for this? Thanks. Also, whilst I'm looking at the source - can you explain to me where/how 'key-handling-notes.txt is 'included' as part of Leo? I can't work this out from an initial skim... Thanks a lot Jon N -- 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 leo-editor+unsubscr...@googlegroups.com. To post to this group, send email to leo-editor@googlegroups.com. Visit this group at http://groups.google.com/group/leo-editor. For more options, visit https://groups.google.com/groups/opt_out.
Re: feature request - insert headline before current
To make this a command (which you can bind to with a key), in myLeoSettings.leo, make the node @commands, and then under it, a node @command insert-node-before. Then bind a key to insert-node-before and you're golden. Nice script, Fidel. That's exactly what I would have done :) --Jake On 9/22/2013 6:16 PM, Fidel N wrote: Hey Jkn: This quick script will do what you need, although Im pretty sure someone here will update it with something more eficcient =P c.p.insertAfter() c.executeMinibufferCommand('goto-next-sibling') c.executeMinibufferCommand('move-outline-up') c.executeMinibufferCommand('edit-headline') c.redraw() Just run that code (you can make it a button then click it from any node) and it will do what you need. On Monday, September 23, 2013 12:07:04 AM UTC+2, jkn wrote: Hi Edward (Background - I am experimenting with changing my Leo Key bindings to make it work more closely to other (lesser ;-) outliners I am more used to than Leo) One thing that I think is missing from Leo is a primitive command 'insert headline before current'. I would like to bind 'Insert' to this rather than ''insert-node', which of course inserts after the current headline. I've taken a quick look at def insertHeadline() in key-handling-notes.txt but I'm not initially confident of making the necessary additions. Would it be appropriate to raise a wishlist item for this? Thanks. Also, whilst I'm looking at the source - can you explain to me where/how 'key-handling-notes.txt is 'included' as part of Leo? I can't work this out from an initial skim... Thanks a lot Jon N -- 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 leo-editor+unsubscr...@googlegroups.com. To post to this group, send email to leo-editor@googlegroups.com. Visit this group at http://groups.google.com/group/leo-editor. For more options, visit https://groups.google.com/groups/opt_out. -- 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 leo-editor+unsubscr...@googlegroups.com. To post to this group, send email to leo-editor@googlegroups.com. Visit this group at http://groups.google.com/group/leo-editor. For more options, visit https://groups.google.com/groups/opt_out.