|
View:
New views
7 Messages
—
Rating Filter:
Alert me
|
|
|
Questions on the Python ShellHi I'm playing with the new python shell dialog and I must say, it is really useful! To give one example, one can interactively learn the python interface much faster than any other way, specially people like me that are not experienced programmers. I have some questions regarding the python shell 1) K3d 0.7.11.0 does not have really usable shell. On the other hand 0.7.12.0 has a nice python shell but the mesh module will be off for some time. I would like to have both. How can I build 0.7.11.0 but with the newest python shell? I tried to copy ngui_python_shell/dialog.cpp over the old one, but it did not work. 2) It seems that line editing in 0.7.12.0 python shell is not working. For example, I am able to move the cursor to any point on a line of text, but I can not erase or insert any character. 3) Can I get a python shell inside of a Scripted Node? In the same way as for document context scripts, I think that would be useful for exploring, testing and developing scripted node codes. Thanks, Paulo ------------------------------------------------------------------------------ _______________________________________________ K3d-development mailing list K3d-development@... https://lists.sourceforge.net/lists/listinfo/k3d-development |
|
|
Re: Questions on the Python ShellPaulo Teotonio Sobrinho wrote:
> Hi > > I'm playing with the new python shell dialog and I must say, it is really > useful! To give one example, one can interactively learn the python > interface much faster than any other way, specially people like me that > are not experienced programmers. Glad to hear it! > I have some questions regarding the python shell > > 1) K3d 0.7.11.0 does not have really usable shell. On the other hand > 0.7.12.0 has a nice python shell but the mesh module will be off for some > time. I would like to have both. How can I build 0.7.11.0 but with the > newest python shell? I tried to copy ngui_python_shell/dialog.cpp over the > old one, but it did not work. Hopefully the mesh module won't be off for long :) In the meantime, multiple files changed to implement the Python shell. If you want to backport it, you'll have to use svn to look at the history and see everything that changed. This is technically feasible, but you'll have to do the homework. > 2) It seems that line editing in 0.7.12.0 python shell is not working. For > example, I am able to move the cursor to any point on a line of text, but > I can not erase or insert any character. This is by-design - the Python shell works like any other - once you enter a command with the "return" key, it becomes part of the shell history. Editing it after the fact wouldn't make any sense, since the command has already been executed by the Python interpreter. You seem to want some kind of hybrid between a text editor and an interactive interpreter. I'm open to the idea, but I've never seen such a thing. Got an example? > 3) Can I get a python shell inside of a Scripted Node? In the same way as > for document context scripts, I think that would be useful for exploring, > testing and developing scripted node codes. A scripted node executes its script whenever its output needs to be updated, so it isn't clear how one would use an interactive shell in that context. Cheers, Tim [tshead.vcf] begin:vcard fn:Timothy Shead n:Shead;Timothy org:www.k-3d.org email;internet:tshead@... title:Founder x-mozilla-html:FALSE url:www.k-3d.org version:2.1 end:vcard ------------------------------------------------------------------------------ Enter the BlackBerry Developer Challenge This is your chance to win up to $100,000 in prizes! For a limited time, vendors submitting new applications to BlackBerry App World(TM) will have the opportunity to enter the BlackBerry Developer Challenge. See full prize details at: http://p.sf.net/sfu/blackberry _______________________________________________ K3d-development mailing list K3d-development@... https://lists.sourceforge.net/lists/listinfo/k3d-development |
|
|
Re: Questions on the Python ShellOn Tue, Jul 7, 2009 at 2:30 AM, Timothy M. Shead<tshead@...> wrote:
> Paulo Teotonio Sobrinho wrote: >> Hi >> >> I'm playing with the new python shell dialog and I must say, it is really >> useful! To give one example, one can interactively learn the python >> interface much faster than any other way, specially people like me that >> are not experienced programmers. > > Glad to hear it! > >> I have some questions regarding the python shell >> >> 1) K3d 0.7.11.0 does not have really usable shell. On the other hand >> 0.7.12.0 has a nice python shell but the mesh module will be off for some >> time. I would like to have both. How can I build 0.7.11.0 but with the >> newest python shell? I tried to copy ngui_python_shell/dialog.cpp over the >> old one, but it did not work. > > Hopefully the mesh module won't be off for long :) In the meantime, > multiple files changed to implement the Python shell. If you want to > backport it, you'll have to use svn to look at the history and see > everything that changed. This is technically feasible, but you'll have > to do the homework. > >> 2) It seems that line editing in 0.7.12.0 python shell is not working. For >> example, I am able to move the cursor to any point on a line of text, but >> I can not erase or insert any character. > > This is by-design - the Python shell works like any other - once you > enter a command with the "return" key, it becomes part of the shell > history. Editing it after the fact wouldn't make any sense, since the > command has already been executed by the Python interpreter. You seem > to want some kind of hybrid between a text editor and an interactive > interpreter. I'm open to the idea, but I've never seen such a thing. > Got an example? I think this really was a bug: moving somewhere in the middle of a non-submitted line of code did not allow editing. I fixed this in my branch, see changeset: http://code.google.com/p/k3d-bart/source/detail?r=9c859a8ea62a22817ea44f236fcf150ee0dce7c9 Cheers, -- Bart ------------------------------------------------------------------------------ Enter the BlackBerry Developer Challenge This is your chance to win up to $100,000 in prizes! For a limited time, vendors submitting new applications to BlackBerry App World(TM) will have the opportunity to enter the BlackBerry Developer Challenge. See full prize details at: http://p.sf.net/sfu/blackberry _______________________________________________ K3d-development mailing list K3d-development@... https://lists.sourceforge.net/lists/listinfo/k3d-development |
|
|
Re: Questions on the Python ShellBart Janssens wrote:
> On Tue, Jul 7, 2009 at 2:30 AM, Timothy M. Shead<tshead@...> wrote: >> Paulo Teotonio Sobrinho wrote: >>> 2) It seems that line editing in 0.7.12.0 python shell is not working. For >>> example, I am able to move the cursor to any point on a line of text, but >>> I can not erase or insert any character. >> This is by-design - the Python shell works like any other - once you >> enter a command with the "return" key, it becomes part of the shell >> history. Editing it after the fact wouldn't make any sense, since the >> command has already been executed by the Python interpreter. You seem >> to want some kind of hybrid between a text editor and an interactive >> interpreter. I'm open to the idea, but I've never seen such a thing. >> Got an example? > I think this really was a bug: moving somewhere in the middle of a > non-submitted line of code did not allow editing. I fixed this in my > branch, see changeset: > http://code.google.com/p/k3d-bart/source/detail?r=9c859a8ea62a22817ea44f236fcf150ee0dce7c9 My mistake, I see what you mean now. Although I'm not giving-up on my lifelong dream of a hybrid text editor / interactive shell ;) I notice that the diff on your changeset is the entire file ... is this google code do you think, or some subtlety of the way you're bridging to svn? Cheers, Tim [tshead.vcf] begin:vcard fn:Timothy Shead n:Shead;Timothy org:www.k-3d.org email;internet:tshead@... title:Founder x-mozilla-html:FALSE url:www.k-3d.org version:2.1 end:vcard ------------------------------------------------------------------------------ Enter the BlackBerry Developer Challenge This is your chance to win up to $100,000 in prizes! For a limited time, vendors submitting new applications to BlackBerry App World(TM) will have the opportunity to enter the BlackBerry Developer Challenge. See full prize details at: http://p.sf.net/sfu/Challenge _______________________________________________ K3d-development mailing list K3d-development@... https://lists.sourceforge.net/lists/listinfo/k3d-development |
|
|
Re: Questions on the Python ShellOn Tue, 7 Jul 2009, Bart Janssens wrote: > On Tue, Jul 7, 2009 at 2:30 AM, Timothy M. Shead<tshead@...> wrote: >> Paulo Teotonio Sobrinho wrote: >>> Hi >>> >>> I'm playing with the new python shell dialog and I must say, it is really >>> useful! To give one example, one can interactively learn the python >>> interface much faster than any other way, specially people like me that >>> are not experienced programmers. >> >> Glad to hear it! >> >>> I have some questions regarding the python shell >>> >>> 1) K3d 0.7.11.0 does not have really usable shell. On the other hand >>> 0.7.12.0 has a nice python shell but the mesh module will be off for some >>> time. I would like to have both. How can I build 0.7.11.0 but with the >>> newest python shell? I tried to copy ngui_python_shell/dialog.cpp over the >>> old one, but it did not work. >> >> Hopefully the mesh module won't be off for long :) In the meantime, >> multiple files changed to implement the Python shell. If you want to >> backport it, you'll have to use svn to look at the history and see >> everything that changed. This is technically feasible, but you'll have >> to do the homework. >> >>> 2) It seems that line editing in 0.7.12.0 python shell is not working. For >>> example, I am able to move the cursor to any point on a line of text, but >>> I can not erase or insert any character. >> >> This is by-design - the Python shell works like any other - once you >> enter a command with the "return" key, it becomes part of the shell >> history. Editing it after the fact wouldn't make any sense, since the >> command has already been executed by the Python interpreter. You seem >> to want some kind of hybrid between a text editor and an interactive >> interpreter. I'm open to the idea, but I've never seen such a thing. >> Got an example? > > I think this really was a bug: moving somewhere in the middle of a > non-submitted line of code did not allow editing. I fixed this in my > branch, see changeset: > http://code.google.com/p/k3d-bart/source/detail?r=9c859a8ea62a22817ea44f236fcf150ee0dce7c9 > > Cheers, > > -- > Bart > I used used your code and now non-submitted lines can be edited nicely. Thanks! Paulo ------------------------------------------------------------------------------ Enter the BlackBerry Developer Challenge This is your chance to win up to $100,000 in prizes! For a limited time, vendors submitting new applications to BlackBerry App World(TM) will have the opportunity to enter the BlackBerry Developer Challenge. See full prize details at: http://p.sf.net/sfu/Challenge _______________________________________________ K3d-development mailing list K3d-development@... https://lists.sourceforge.net/lists/listinfo/k3d-development |
|
|
Re: Questions on the Python ShellOn Wed, Jul 8, 2009 at 4:31 AM, Timothy M. Shead<tshead@...> wrote:
> I notice that the diff on your changeset is the entire file ... is this > google code do you think, or some subtlety of the way you're bridging to > svn? This is a bug in Google Code, see http://code.google.com/p/support/issues/detail?id=2521 Cheers, -- Bart ------------------------------------------------------------------------------ Enter the BlackBerry Developer Challenge This is your chance to win up to $100,000 in prizes! For a limited time, vendors submitting new applications to BlackBerry App World(TM) will have the opportunity to enter the BlackBerry Developer Challenge. See full prize details at: http://p.sf.net/sfu/Challenge _______________________________________________ K3d-development mailing list K3d-development@... https://lists.sourceforge.net/lists/listinfo/k3d-development |
|
|
Re: Questions on the Python ShellOn Tue, Jul 7, 2009 at 2:30 AM, Timothy M. Shead<tshead@...> wrote:
> Hopefully the mesh module won't be off for long :) In the meantime, > multiple files changed to implement the Python shell. If you want to > backport it, you'll have to use svn to look at the history and see > everything that changed. This is technically feasible, but you'll have > to do the homework. The last two modules have been converted, at the tip of http://code.google.com/p/k3d-bart/source/list Cheers, -- Bart ------------------------------------------------------------------------------ Enter the BlackBerry Developer Challenge This is your chance to win up to $100,000 in prizes! For a limited time, vendors submitting new applications to BlackBerry App World(TM) will have the opportunity to enter the BlackBerry Developer Challenge. See full prize details at: http://p.sf.net/sfu/Challenge _______________________________________________ K3d-development mailing list K3d-development@... https://lists.sourceforge.net/lists/listinfo/k3d-development |
| Free embeddable forum powered by Nabble | Forum Help |