Re: [Simple script] Jump exactly one page with Page Down

2014-08-24 Thread Fidel N
I studied the code yesterday, but its too complex for me to understand. And as you say, my scripts are probably unstable, and its hard to wire them into the rest of the existing code. So I'm guessing this conversation is over becasue of those reasons. Anyway, they are very useful, I couldn't study

Re: [Simple script] Jump exactly one page with Page Down

2014-08-24 Thread Brian Theado
Fidel, On Sat, Aug 23, 2014 at 3:46 AM, Fidel N wrote: > Brian, if you are happy with that solution, I will try to replace the > current code with the new one. > Otherwise please tell me what to improve, I'll try and edit the script to do > that. I don't have a good feel for what properties are

Re: [Simple script] Jump exactly one page with Page Down

2014-08-23 Thread Fidel N
Brian, if you are happy with that solution, I will try to replace the current code with the new one. Otherwise please tell me what to improve, I'll try and edit the script to do that. Fidel. -- You received this message because you are subscribed to the Google Groups "leo-editor" group. To uns

Re: [Simple script] Jump exactly one page with Page Down

2014-08-21 Thread Fidel N
Btw, I meant to quote that I did neither notice that behaviour until I had to read so much in Leo. On Thu, Aug 21, 2014 at 9:45 AM, Fidel N wrote: > I've never use Leo to read long chunks of text linearly... > > > Exactly, neither did I until I decided to study my public exam within Leo > > >

Re: [Simple script] Jump exactly one page with Page Down

2014-08-21 Thread Fidel N
> > I've never use Leo to read long chunks of text linearly... Exactly, neither did I until I decided to study my public exam within Leo > So there are misbehaviors in both implementations. I don't immediately > Yes, I also noticed what you mention, but didn't think this had the possibil

Re: [Simple script] Jump exactly one page with Page Down

2014-08-20 Thread Brian Theado
On Wed, Aug 20, 2014 at 2:52 AM, Fidel N wrote: > Its true, in general jumps just one page, but if the body pane is a bit > bigger / smaller than X full lines (ie total length is, for instance, 12'5 > lines), it jumps one line more than desirable, so you have to go back to > read it. You are righ

Re: [Simple script] Jump exactly one page with Page Down

2014-08-19 Thread Fidel N
Thanks Brian for your elaborate response. Its true, in general jumps just one page, but if the body pane is a bit bigger / smaller than X full lines (ie total length is, for instance, 12'5 lines), it jumps one line more than desirable, so you have to go back to read it. In the way I use Leo, I ke

Re: [Simple script] Jump exactly one page with Page Down

2014-08-19 Thread Brian Theado
On Tue, Aug 19, 2014 at 8:16 PM, Brian Theado wrote: > A few years ago the page up/down functionality was a fixed number of > lines. I looked into the QT cpp code and translated it to python and > checked it in: > > https://github.com/leo-editor/leo-editor/commit/9401804f956c0eef31d2068450a21436e9

Re: [Simple script] Jump exactly one page with Page Down

2014-08-19 Thread Brian Theado
A few years ago the page up/down functionality was a fixed number of lines. I looked into the QT cpp code and translated it to python and checked it in: https://github.com/leo-editor/leo-editor/commit/9401804f956c0eef31d2068450a21436e9939268 since then the page up/down has always been exactly a p

Re: [Simple script] Jump exactly one page with Page Down

2014-08-19 Thread Fidel N
Tried to do myself, but cant fin any binding for pgup or pgdn in either leosettings or leopyref. Also, found out that this wont work if the user wants to select the whole page (shift + script) wont select the whole page, just jump. But its good enough for reading as is. On Tue, Aug 19, 2014 at 10

Re: [Simple script] Jump exactly one page with Page Down

2014-08-19 Thread Edward K. Ream
On Tue, Aug 19, 2014 at 3:36 AM, Fidel N wrote: > for number in range(c.frame.body.bodyCtrl.linesPerPage()): > c.executeMinibufferCommand("next-line") Excellent. This should be the default binding of the PageDn key. Edward -- You received this message because you are subscribed to the Go

[Simple script] Jump exactly one page with Page Down

2014-08-19 Thread Fidel N
Hi: For those of you reading a lot in Leo it might be uncomfortable to use Page Down/Up since it doesn't exactly jump one page, so you have to check where you were reading each time you use that. This script jumps exactly the number of lines in the text widget. So you can keep reading where you