From noreply at sourceforge.net Sat Nov 1 09:59:11 2003 From: noreply at sourceforge.net (SourceForge.net) Date: Sat Nov 1 09:59:14 2003 Subject: [Idle-dev] [ idlefork-Bugs-834136 ] control-c doesn't work Message-ID: Bugs item #834136, was opened at 2003-11-01 14:59 Message generated for change (Tracker Item Submitted) made by Item Submitter You can respond by visiting: https://sourceforge.net/tracker/?func=detail&atid=109579&aid=834136&group_id=9579 Category: None Group: None Status: Open Resolution: None Priority: 5 Submitted By: Egon Frerich (efrerich) Assigned to: Nobody/Anonymous (nobody) Summary: control-c doesn't work Initial Comment: (IDLE 1.0 - Python 2.3 -Windows XP) I put a never ending loop into my python program. control-c didn't stop the Run-Command. Then I choosed the exit option in the File Menu of the Shell-Window. Then I h've got the message, that the program is still running and if I would like to kill the program. After saying "yes" (or "ok" IDLE disappeared. But I cannot start IDLE again. I have to reboot my system. When I shutdown the system there is a program "Menu Window" which I have to destroy. ---------------------------------------------------------------------- You can respond by visiting: https://sourceforge.net/tracker/?func=detail&atid=109579&aid=834136&group_id=9579 From noreply at sourceforge.net Thu Nov 6 04:47:17 2003 From: noreply at sourceforge.net (SourceForge.net) Date: Thu Nov 6 04:47:19 2003 Subject: [Idle-dev] [ idlefork-Bugs-837085 ] Print colored Message-ID: Bugs item #837085, was opened at 2003-11-06 09:47 Message generated for change (Tracker Item Submitted) made by Item Submitter You can respond by visiting: https://sourceforge.net/tracker/?func=detail&atid=109579&aid=837085&group_id=9579 Category: None Group: None Status: Open Resolution: None Priority: 5 Submitted By: Heiko Selber (drhok) Assigned to: Nobody/Anonymous (nobody) Summary: Print colored Initial Comment: It would be nice if the syntax highlighting could be printed. Currently, the print function is in black and white only, even on color printers. ---------------------------------------------------------------------- You can respond by visiting: https://sourceforge.net/tracker/?func=detail&atid=109579&aid=837085&group_id=9579 From noreply at sourceforge.net Sat Nov 8 18:20:21 2003 From: noreply at sourceforge.net (SourceForge.net) Date: Sat Nov 8 18:20:24 2003 Subject: [Idle-dev] [ idlefork-Bugs-837085 ] Print colored Message-ID: Bugs item #837085, was opened at 2003-11-06 01:47 Message generated for change (Comment added) made by nobody You can respond by visiting: https://sourceforge.net/tracker/?func=detail&atid=109579&aid=837085&group_id=9579 Category: None Group: None Status: Open Resolution: None Priority: 5 Submitted By: Heiko Selber (drhok) Assigned to: Nobody/Anonymous (nobody) Summary: Print colored Initial Comment: It would be nice if the syntax highlighting could be printed. Currently, the print function is in black and white only, even on color printers. ---------------------------------------------------------------------- Comment By: Nobody/Anonymous (nobody) Date: 2003-11-08 15:20 Message: Logged In: NO I wanted to print in color too. As far as I can tell, IDLE sends the contents of your editor window to notepad.exe (on windows) for printing; I don't know what it does on other platforms. Notepad doesn't do color but I found another way. I was reading the "Python Cookbook" and there's a recipe in there for formatting python source in colorized HTML. J?rgen Hermann has made a "colorizer" for the MoinMoin project (MoinMoin urls: http://moin.sourceforge.net/ http://twistedmatrix.com/users/jh.twistd/moin/moin.cgi/ ) You can find the colorizer here: http://twistedmatrix.com/users/jh.twistd/python/moin.cgi/MoinMoinColorizer If you want to get it to give you output the same as IDLE a few small modifications are needed: In python, all name tokens are treated the same, 'if' is a name just like any identifier, so all "names" are colored the same. To get output like IDLE's, you want only identifiers occuring after "class" and "def" to be blue. 1. We need a new token type, so add the line _DEForCLASS = token.NT_OFFSET + 3 after _KEYWORD = token.NT_OFFSET + 1 _TEXT = token.NT_OFFSET + 2 (you can use any identifier you want, it doesn't have to be _DEForCLASS) 2. Next, edit the '_colors' dictionary to get more IDLE-like colors and add an entry for _DEForCLASS _colors = { token.NUMBER: '#000000', #black token.OP: '#000000', #black token.STRING: '#008000', #green tokenize.COMMENT: '#ff0000', #red token.NAME: '#000000', #black token.ERRORTOKEN: '#FF8080', _KEYWORD: '#ff8c00', #dark orange _TEXT: '#000000', #black _DEForCLASS: '#0000ff', #blue } 3. We need something to keep track of the previously scanned token for each current token so we can know to color a token blue if it follows a 'def' or 'class' token, so add the following to the __init__ function of the Parser class self.prev_tok = '' 4. Then in the if...elif statement with the comment "# map token type to a color group" in the __call__ function, add a branch to check if the previous token was "def" or "class" # map token type to a color group if token.LPAR <= toktype and toktype <= token.OP: toktype = token.OP elif toktype == token.NAME and keyword.iskeyword(toktext): toktype = _KEYWORD #add this branch... elif toktype == token.NAME and self.prev_tok in ['def', 'class']: toktype = _NEWDEForCLASS #in Python 2.3 you could just say self.prev_tok in 'def class' #it might be slightly faster, but in practice it probably won't matter 5. Last but not least, somewhere before the end of the __call__ function put the following line, to remember the previous token for the elif from step 4. self.prev_tok = toktext There ya go! This works great and is pretty simple to use. It's not as good as just clicking a menu option from within IDLE, but it will let you print your python source in color. Yay! Many thanks to J?rgen Hermann for writing and making known this useful script. I hope this helps you out. Sincerely, ~Simon Forman calroc@mindspring.com BTW, if you want the background to be white (in the browser, I don't think it affects printing) make the following changes in the format function
')
 !> sys.stdout.write('
')

and

 
') !> sys.stdout.write('
') ---------------------------------------------------------------------- You can respond by visiting: https://sourceforge.net/tracker/?func=detail&atid=109579&aid=837085&group_id=9579 From noreply at sourceforge.net Sat Nov 8 18:22:59 2003 From: noreply at sourceforge.net (SourceForge.net) Date: Sat Nov 8 18:23:03 2003 Subject: [Idle-dev] [ idlefork-Bugs-837085 ] Print colored Message-ID: Bugs item #837085, was opened at 2003-11-06 01:47 Message generated for change (Comment added) made by nobody You can respond by visiting: https://sourceforge.net/tracker/?func=detail&atid=109579&aid=837085&group_id=9579 Category: None Group: None Status: Open Resolution: None Priority: 5 Submitted By: Heiko Selber (drhok) Assigned to: Nobody/Anonymous (nobody) Summary: Print colored Initial Comment: It would be nice if the syntax highlighting could be printed. Currently, the print function is in black and white only, even on color printers. ---------------------------------------------------------------------- Comment By: Nobody/Anonymous (nobody) Date: 2003-11-08 15:22 Message: Logged In: NO I wanted to print in color too. As far as I can tell, IDLE sends the contents of your editor window to notepad.exe (on windows) for printing; I don't know what it does on other platforms. Notepad doesn't do color but I found another way. I was reading the "Python Cookbook" and there's a recipe in there for formatting python source in colorized HTML. J?rgen Hermann has made a "colorizer" for the MoinMoin project (MoinMoin urls: http://moin.sourceforge.net/ http://twistedmatrix.com/users/jh.twistd/moin/moin.cgi/ ) You can find the colorizer here: http://twistedmatrix.com/users/jh.twistd/python/moin.cgi/MoinMoinColorizer If you want to get it to give you output the same as IDLE a few small modifications are needed: In python, all name tokens are treated the same, 'if' is a name just like any identifier, so all "names" are colored the same. To get output like IDLE's, you want only identifiers occuring after "class" and "def" to be blue. 1. We need a new token type, so add the line _DEForCLASS = token.NT_OFFSET + 3 after _KEYWORD = token.NT_OFFSET + 1 _TEXT = token.NT_OFFSET + 2 (you can use any identifier you want, it doesn't have to be _DEForCLASS) 2. Next, edit the '_colors' dictionary to get more IDLE-like colors and add an entry for _DEForCLASS _colors = { token.NUMBER: '#000000', #black token.OP: '#000000', #black token.STRING: '#008000', #green tokenize.COMMENT: '#ff0000', #red token.NAME: '#000000', #black token.ERRORTOKEN: '#FF8080', _KEYWORD: '#ff8c00', #dark orange _TEXT: '#000000', #black _DEForCLASS: '#0000ff', #blue } 3. We need something to keep track of the previously scanned token for each current token so we can know to color a token blue if it follows a 'def' or 'class' token, so add the following to the __init__ function of the Parser class self.prev_tok = '' 4. Then in the if...elif statement with the comment "# map token type to a color group" in the __call__ function, add a branch to check if the previous token was "def" or "class" # map token type to a color group if token.LPAR <= toktype and toktype <= token.OP: toktype = token.OP elif toktype == token.NAME and keyword.iskeyword(toktext): toktype = _KEYWORD #add this branch... elif toktype == token.NAME and self.prev_tok in ['def', 'class']: toktype = _NEWDEForCLASS #in Python 2.3 you could just say self.prev_tok in 'def class' #it might be slightly faster, but in practice it probably won't matter 5. Last but not least, somewhere before the end of the __call__ function put the following line, to remember the previous token for the elif from step 4. self.prev_tok = toktext There ya go! This works great and is pretty simple to use. It's not as good as just clicking a menu option from within IDLE, but it will let you print your python source in color. Yay! Many thanks to J?rgen Hermann for writing and making known this useful script. I hope this helps you out. Sincerely, ~Simon Forman calroc@mindspring.com BTW, if you want the background to be white (in the browser, I don't think it affects printing) make the following changes in the format function
')
 !> sys.stdout.write('
')

and

 
') !> sys.stdout.write('
') ---------------------------------------------------------------------- Comment By: Nobody/Anonymous (nobody) Date: 2003-11-08 15:20 Message: Logged In: NO I wanted to print in color too. As far as I can tell, IDLE sends the contents of your editor window to notepad.exe (on windows) for printing; I don't know what it does on other platforms. Notepad doesn't do color but I found another way. I was reading the "Python Cookbook" and there's a recipe in there for formatting python source in colorized HTML. J?rgen Hermann has made a "colorizer" for the MoinMoin project (MoinMoin urls: http://moin.sourceforge.net/ http://twistedmatrix.com/users/jh.twistd/moin/moin.cgi/ ) You can find the colorizer here: http://twistedmatrix.com/users/jh.twistd/python/moin.cgi/MoinMoinColorizer If you want to get it to give you output the same as IDLE a few small modifications are needed: In python, all name tokens are treated the same, 'if' is a name just like any identifier, so all "names" are colored the same. To get output like IDLE's, you want only identifiers occuring after "class" and "def" to be blue. 1. We need a new token type, so add the line _DEForCLASS = token.NT_OFFSET + 3 after _KEYWORD = token.NT_OFFSET + 1 _TEXT = token.NT_OFFSET + 2 (you can use any identifier you want, it doesn't have to be _DEForCLASS) 2. Next, edit the '_colors' dictionary to get more IDLE-like colors and add an entry for _DEForCLASS _colors = { token.NUMBER: '#000000', #black token.OP: '#000000', #black token.STRING: '#008000', #green tokenize.COMMENT: '#ff0000', #red token.NAME: '#000000', #black token.ERRORTOKEN: '#FF8080', _KEYWORD: '#ff8c00', #dark orange _TEXT: '#000000', #black _DEForCLASS: '#0000ff', #blue } 3. We need something to keep track of the previously scanned token for each current token so we can know to color a token blue if it follows a 'def' or 'class' token, so add the following to the __init__ function of the Parser class self.prev_tok = '' 4. Then in the if...elif statement with the comment "# map token type to a color group" in the __call__ function, add a branch to check if the previous token was "def" or "class" # map token type to a color group if token.LPAR <= toktype and toktype <= token.OP: toktype = token.OP elif toktype == token.NAME and keyword.iskeyword(toktext): toktype = _KEYWORD #add this branch... elif toktype == token.NAME and self.prev_tok in ['def', 'class']: toktype = _NEWDEForCLASS #in Python 2.3 you could just say self.prev_tok in 'def class' #it might be slightly faster, but in practice it probably won't matter 5. Last but not least, somewhere before the end of the __call__ function put the following line, to remember the previous token for the elif from step 4. self.prev_tok = toktext There ya go! This works great and is pretty simple to use. It's not as good as just clicking a menu option from within IDLE, but it will let you print your python source in color. Yay! Many thanks to J?rgen Hermann for writing and making known this useful script. I hope this helps you out. Sincerely, ~Simon Forman calroc@mindspring.com BTW, if you want the background to be white (in the browser, I don't think it affects printing) make the following changes in the format function
')
 !> sys.stdout.write('
')

and

 
') !> sys.stdout.write('
') ---------------------------------------------------------------------- You can respond by visiting: https://sourceforge.net/tracker/?func=detail&atid=109579&aid=837085&group_id=9579 From noreply at sourceforge.net Sat Nov 8 18:23:37 2003 From: noreply at sourceforge.net (SourceForge.net) Date: Sat Nov 8 18:23:40 2003 Subject: [Idle-dev] [ idlefork-Bugs-837085 ] Print colored Message-ID: Bugs item #837085, was opened at 2003-11-06 01:47 Message generated for change (Comment added) made by nobody You can respond by visiting: https://sourceforge.net/tracker/?func=detail&atid=109579&aid=837085&group_id=9579 Category: None Group: None Status: Open Resolution: None Priority: 5 Submitted By: Heiko Selber (drhok) Assigned to: Nobody/Anonymous (nobody) Summary: Print colored Initial Comment: It would be nice if the syntax highlighting could be printed. Currently, the print function is in black and white only, even on color printers. ---------------------------------------------------------------------- Comment By: Nobody/Anonymous (nobody) Date: 2003-11-08 15:23 Message: Logged In: NO I wanted to print in color too. As far as I can tell, IDLE sends the contents of your editor window to notepad.exe (on windows) for printing; I don't know what it does on other platforms. Notepad doesn't do color but I found another way. I was reading the "Python Cookbook" and there's a recipe in there for formatting python source in colorized HTML. J?rgen Hermann has made a "colorizer" for the MoinMoin project (MoinMoin urls: http://moin.sourceforge.net/ http://twistedmatrix.com/users/jh.twistd/moin/moin.cgi/ ) You can find the colorizer here: http://twistedmatrix.com/users/jh.twistd/python/moin.cgi/MoinMoinColorizer If you want to get it to give you output the same as IDLE a few small modifications are needed: In python, all name tokens are treated the same, 'if' is a name just like any identifier, so all "names" are colored the same. To get output like IDLE's, you want only identifiers occuring after "class" and "def" to be blue. 1. We need a new token type, so add the line _DEForCLASS = token.NT_OFFSET + 3 after _KEYWORD = token.NT_OFFSET + 1 _TEXT = token.NT_OFFSET + 2 (you can use any identifier you want, it doesn't have to be _DEForCLASS) 2. Next, edit the '_colors' dictionary to get more IDLE-like colors and add an entry for _DEForCLASS _colors = { token.NUMBER: '#000000', #black token.OP: '#000000', #black token.STRING: '#008000', #green tokenize.COMMENT: '#ff0000', #red token.NAME: '#000000', #black token.ERRORTOKEN: '#FF8080', _KEYWORD: '#ff8c00', #dark orange _TEXT: '#000000', #black _DEForCLASS: '#0000ff', #blue } 3. We need something to keep track of the previously scanned token for each current token so we can know to color a token blue if it follows a 'def' or 'class' token, so add the following to the __init__ function of the Parser class self.prev_tok = '' 4. Then in the if...elif statement with the comment "# map token type to a color group" in the __call__ function, add a branch to check if the previous token was "def" or "class" # map token type to a color group if token.LPAR <= toktype and toktype <= token.OP: toktype = token.OP elif toktype == token.NAME and keyword.iskeyword(toktext): toktype = _KEYWORD #add this branch... elif toktype == token.NAME and self.prev_tok in ['def', 'class']: toktype = _NEWDEForCLASS #in Python 2.3 you could just say self.prev_tok in 'def class' #it might be slightly faster, but in practice it probably won't matter 5. Last but not least, somewhere before the end of the __call__ function put the following line, to remember the previous token for the elif from step 4. self.prev_tok = toktext There ya go! This works great and is pretty simple to use. It's not as good as just clicking a menu option from within IDLE, but it will let you print your python source in color. Yay! Many thanks to J?rgen Hermann for writing and making known this useful script. I hope this helps you out. Sincerely, ~Simon Forman calroc@mindspring.com BTW, if you want the background to be white (in the browser, I don't think it affects printing) make the following changes in the format function
')
 !> sys.stdout.write('
')

and

 
') !> sys.stdout.write('
') ---------------------------------------------------------------------- Comment By: Nobody/Anonymous (nobody) Date: 2003-11-08 15:22 Message: Logged In: NO I wanted to print in color too. As far as I can tell, IDLE sends the contents of your editor window to notepad.exe (on windows) for printing; I don't know what it does on other platforms. Notepad doesn't do color but I found another way. I was reading the "Python Cookbook" and there's a recipe in there for formatting python source in colorized HTML. J?rgen Hermann has made a "colorizer" for the MoinMoin project (MoinMoin urls: http://moin.sourceforge.net/ http://twistedmatrix.com/users/jh.twistd/moin/moin.cgi/ ) You can find the colorizer here: http://twistedmatrix.com/users/jh.twistd/python/moin.cgi/MoinMoinColorizer If you want to get it to give you output the same as IDLE a few small modifications are needed: In python, all name tokens are treated the same, 'if' is a name just like any identifier, so all "names" are colored the same. To get output like IDLE's, you want only identifiers occuring after "class" and "def" to be blue. 1. We need a new token type, so add the line _DEForCLASS = token.NT_OFFSET + 3 after _KEYWORD = token.NT_OFFSET + 1 _TEXT = token.NT_OFFSET + 2 (you can use any identifier you want, it doesn't have to be _DEForCLASS) 2. Next, edit the '_colors' dictionary to get more IDLE-like colors and add an entry for _DEForCLASS _colors = { token.NUMBER: '#000000', #black token.OP: '#000000', #black token.STRING: '#008000', #green tokenize.COMMENT: '#ff0000', #red token.NAME: '#000000', #black token.ERRORTOKEN: '#FF8080', _KEYWORD: '#ff8c00', #dark orange _TEXT: '#000000', #black _DEForCLASS: '#0000ff', #blue } 3. We need something to keep track of the previously scanned token for each current token so we can know to color a token blue if it follows a 'def' or 'class' token, so add the following to the __init__ function of the Parser class self.prev_tok = '' 4. Then in the if...elif statement with the comment "# map token type to a color group" in the __call__ function, add a branch to check if the previous token was "def" or "class" # map token type to a color group if token.LPAR <= toktype and toktype <= token.OP: toktype = token.OP elif toktype == token.NAME and keyword.iskeyword(toktext): toktype = _KEYWORD #add this branch... elif toktype == token.NAME and self.prev_tok in ['def', 'class']: toktype = _NEWDEForCLASS #in Python 2.3 you could just say self.prev_tok in 'def class' #it might be slightly faster, but in practice it probably won't matter 5. Last but not least, somewhere before the end of the __call__ function put the following line, to remember the previous token for the elif from step 4. self.prev_tok = toktext There ya go! This works great and is pretty simple to use. It's not as good as just clicking a menu option from within IDLE, but it will let you print your python source in color. Yay! Many thanks to J?rgen Hermann for writing and making known this useful script. I hope this helps you out. Sincerely, ~Simon Forman calroc@mindspring.com BTW, if you want the background to be white (in the browser, I don't think it affects printing) make the following changes in the format function
')
 !> sys.stdout.write('
')

and

 
') !> sys.stdout.write('
') ---------------------------------------------------------------------- Comment By: Nobody/Anonymous (nobody) Date: 2003-11-08 15:20 Message: Logged In: NO I wanted to print in color too. As far as I can tell, IDLE sends the contents of your editor window to notepad.exe (on windows) for printing; I don't know what it does on other platforms. Notepad doesn't do color but I found another way. I was reading the "Python Cookbook" and there's a recipe in there for formatting python source in colorized HTML. J?rgen Hermann has made a "colorizer" for the MoinMoin project (MoinMoin urls: http://moin.sourceforge.net/ http://twistedmatrix.com/users/jh.twistd/moin/moin.cgi/ ) You can find the colorizer here: http://twistedmatrix.com/users/jh.twistd/python/moin.cgi/MoinMoinColorizer If you want to get it to give you output the same as IDLE a few small modifications are needed: In python, all name tokens are treated the same, 'if' is a name just like any identifier, so all "names" are colored the same. To get output like IDLE's, you want only identifiers occuring after "class" and "def" to be blue. 1. We need a new token type, so add the line _DEForCLASS = token.NT_OFFSET + 3 after _KEYWORD = token.NT_OFFSET + 1 _TEXT = token.NT_OFFSET + 2 (you can use any identifier you want, it doesn't have to be _DEForCLASS) 2. Next, edit the '_colors' dictionary to get more IDLE-like colors and add an entry for _DEForCLASS _colors = { token.NUMBER: '#000000', #black token.OP: '#000000', #black token.STRING: '#008000', #green tokenize.COMMENT: '#ff0000', #red token.NAME: '#000000', #black token.ERRORTOKEN: '#FF8080', _KEYWORD: '#ff8c00', #dark orange _TEXT: '#000000', #black _DEForCLASS: '#0000ff', #blue } 3. We need something to keep track of the previously scanned token for each current token so we can know to color a token blue if it follows a 'def' or 'class' token, so add the following to the __init__ function of the Parser class self.prev_tok = '' 4. Then in the if...elif statement with the comment "# map token type to a color group" in the __call__ function, add a branch to check if the previous token was "def" or "class" # map token type to a color group if token.LPAR <= toktype and toktype <= token.OP: toktype = token.OP elif toktype == token.NAME and keyword.iskeyword(toktext): toktype = _KEYWORD #add this branch... elif toktype == token.NAME and self.prev_tok in ['def', 'class']: toktype = _NEWDEForCLASS #in Python 2.3 you could just say self.prev_tok in 'def class' #it might be slightly faster, but in practice it probably won't matter 5. Last but not least, somewhere before the end of the __call__ function put the following line, to remember the previous token for the elif from step 4. self.prev_tok = toktext There ya go! This works great and is pretty simple to use. It's not as good as just clicking a menu option from within IDLE, but it will let you print your python source in color. Yay! Many thanks to J?rgen Hermann for writing and making known this useful script. I hope this helps you out. Sincerely, ~Simon Forman calroc@mindspring.com BTW, if you want the background to be white (in the browser, I don't think it affects printing) make the following changes in the format function
')
 !> sys.stdout.write('
')

and

 
') !> sys.stdout.write('
') ---------------------------------------------------------------------- You can respond by visiting: https://sourceforge.net/tracker/?func=detail&atid=109579&aid=837085&group_id=9579 From soever at email.si Mon Nov 10 13:22:18 2003 From: soever at email.si (Tadey Persic) Date: Mon Nov 10 13:22:22 2003 Subject: [Idle-dev] which version of IDLE do you suggest ?? Message-ID: <20031110182218.7CD318BC35@www.email.si> Hello ... I am using Python v_2.3.2.1 with IDLE 1.0 included. Cause it hasn't contain debbuger I would like to download newer IDLE, but I don't know which version to choose ... verson ... idlefork-0.7.1.tar.gz idlefork-0.8.1 IDLEfork-0.9a1 IDLEfork-0.9a2, or IDLEfork-0.9b1 Please, help me to choose the right one !! Greetings, David from Slovenija ____________________ http://www.email.si/ From noreply at sourceforge.net Fri Nov 14 08:20:19 2003 From: noreply at sourceforge.net (SourceForge.net) Date: Fri Nov 14 08:20:26 2003 Subject: [Idle-dev] [ idlefork-Bugs-842088 ] Cut-Paste: ignore empty selection Message-ID: Bugs item #842088, was opened at 2003-11-14 13:20 Message generated for change (Tracker Item Submitted) made by Item Submitter You can respond by visiting: https://sourceforge.net/tracker/?func=detail&atid=109579&aid=842088&group_id=9579 Category: None Group: None Status: Open Resolution: None Priority: 5 Submitted By: Heiko Selber (drhok) Assigned to: Nobody/Anonymous (nobody) Summary: Cut-Paste: ignore empty selection Initial Comment: Wish: ignore Ctrl-c or CTRL-x if nothing is selected. It happens quite often when I cut and paste with Ctrl- x / Ctrl-v, that I accidentally hit Ctrl-C instead of Ctrl-v. In IDLE, this empties the cut buffer. Other editors ignore Ctrl-x in this case, leaving the content of the cut buffer intact. ---------------------------------------------------------------------- You can respond by visiting: https://sourceforge.net/tracker/?func=detail&atid=109579&aid=842088&group_id=9579 From noreply at sourceforge.net Fri Nov 14 08:37:48 2003 From: noreply at sourceforge.net (SourceForge.net) Date: Fri Nov 14 08:37:52 2003 Subject: [Idle-dev] [ idlefork-Bugs-842102 ] replace (Ctrl-h) doesn't highlight text Message-ID: Bugs item #842102, was opened at 2003-11-14 13:37 Message generated for change (Tracker Item Submitted) made by Item Submitter You can respond by visiting: https://sourceforge.net/tracker/?func=detail&atid=109579&aid=842102&group_id=9579 Category: None Group: None Status: Open Resolution: None Priority: 5 Submitted By: Heiko Selber (drhok) Assigned to: Nobody/Anonymous (nobody) Summary: replace (Ctrl-h) doesn't highlight text Initial Comment: The search-and-replace function in IDLE 1.0 doesn't always highlight the current selection. So you can only guess which particular occurrence of the search string is about to be replaced. I think it depends on whether the selected text follows a certain string. ---------------------------------------------------------------------- You can respond by visiting: https://sourceforge.net/tracker/?func=detail&atid=109579&aid=842102&group_id=9579 From noreply at sourceforge.net Sun Nov 16 22:47:33 2003 From: noreply at sourceforge.net (SourceForge.net) Date: Sun Nov 16 22:47:38 2003 Subject: [Idle-dev] [ idlefork-Bugs-837085 ] Print colored Message-ID: Bugs item #837085, was opened at 2003-11-06 04:47 Message generated for change (Settings changed) made by kbk You can respond by visiting: https://sourceforge.net/tracker/?func=detail&atid=109579&aid=837085&group_id=9579 Category: None Group: None Status: Open Resolution: None >Priority: 4 Submitted By: Heiko Selber (drhok) Assigned to: Nobody/Anonymous (nobody) Summary: Print colored Initial Comment: It would be nice if the syntax highlighting could be printed. Currently, the print function is in black and white only, even on color printers. ---------------------------------------------------------------------- Comment By: Nobody/Anonymous (nobody) Date: 2003-11-08 18:23 Message: Logged In: NO I wanted to print in color too. As far as I can tell, IDLE sends the contents of your editor window to notepad.exe (on windows) for printing; I don't know what it does on other platforms. Notepad doesn't do color but I found another way. I was reading the "Python Cookbook" and there's a recipe in there for formatting python source in colorized HTML. J?rgen Hermann has made a "colorizer" for the MoinMoin project (MoinMoin urls: http://moin.sourceforge.net/ http://twistedmatrix.com/users/jh.twistd/moin/moin.cgi/ ) You can find the colorizer here: http://twistedmatrix.com/users/jh.twistd/python/moin.cgi/MoinMoinColorizer If you want to get it to give you output the same as IDLE a few small modifications are needed: In python, all name tokens are treated the same, 'if' is a name just like any identifier, so all "names" are colored the same. To get output like IDLE's, you want only identifiers occuring after "class" and "def" to be blue. 1. We need a new token type, so add the line _DEForCLASS = token.NT_OFFSET + 3 after _KEYWORD = token.NT_OFFSET + 1 _TEXT = token.NT_OFFSET + 2 (you can use any identifier you want, it doesn't have to be _DEForCLASS) 2. Next, edit the '_colors' dictionary to get more IDLE-like colors and add an entry for _DEForCLASS _colors = { token.NUMBER: '#000000', #black token.OP: '#000000', #black token.STRING: '#008000', #green tokenize.COMMENT: '#ff0000', #red token.NAME: '#000000', #black token.ERRORTOKEN: '#FF8080', _KEYWORD: '#ff8c00', #dark orange _TEXT: '#000000', #black _DEForCLASS: '#0000ff', #blue } 3. We need something to keep track of the previously scanned token for each current token so we can know to color a token blue if it follows a 'def' or 'class' token, so add the following to the __init__ function of the Parser class self.prev_tok = '' 4. Then in the if...elif statement with the comment "# map token type to a color group" in the __call__ function, add a branch to check if the previous token was "def" or "class" # map token type to a color group if token.LPAR <= toktype and toktype <= token.OP: toktype = token.OP elif toktype == token.NAME and keyword.iskeyword(toktext): toktype = _KEYWORD #add this branch... elif toktype == token.NAME and self.prev_tok in ['def', 'class']: toktype = _NEWDEForCLASS #in Python 2.3 you could just say self.prev_tok in 'def class' #it might be slightly faster, but in practice it probably won't matter 5. Last but not least, somewhere before the end of the __call__ function put the following line, to remember the previous token for the elif from step 4. self.prev_tok = toktext There ya go! This works great and is pretty simple to use. It's not as good as just clicking a menu option from within IDLE, but it will let you print your python source in color. Yay! Many thanks to J?rgen Hermann for writing and making known this useful script. I hope this helps you out. Sincerely, ~Simon Forman calroc@mindspring.com BTW, if you want the background to be white (in the browser, I don't think it affects printing) make the following changes in the format function
')
 !> sys.stdout.write('
')

and

 
') !> sys.stdout.write('
') ---------------------------------------------------------------------- Comment By: Nobody/Anonymous (nobody) Date: 2003-11-08 18:22 Message: Logged In: NO I wanted to print in color too. As far as I can tell, IDLE sends the contents of your editor window to notepad.exe (on windows) for printing; I don't know what it does on other platforms. Notepad doesn't do color but I found another way. I was reading the "Python Cookbook" and there's a recipe in there for formatting python source in colorized HTML. J?rgen Hermann has made a "colorizer" for the MoinMoin project (MoinMoin urls: http://moin.sourceforge.net/ http://twistedmatrix.com/users/jh.twistd/moin/moin.cgi/ ) You can find the colorizer here: http://twistedmatrix.com/users/jh.twistd/python/moin.cgi/MoinMoinColorizer If you want to get it to give you output the same as IDLE a few small modifications are needed: In python, all name tokens are treated the same, 'if' is a name just like any identifier, so all "names" are colored the same. To get output like IDLE's, you want only identifiers occuring after "class" and "def" to be blue. 1. We need a new token type, so add the line _DEForCLASS = token.NT_OFFSET + 3 after _KEYWORD = token.NT_OFFSET + 1 _TEXT = token.NT_OFFSET + 2 (you can use any identifier you want, it doesn't have to be _DEForCLASS) 2. Next, edit the '_colors' dictionary to get more IDLE-like colors and add an entry for _DEForCLASS _colors = { token.NUMBER: '#000000', #black token.OP: '#000000', #black token.STRING: '#008000', #green tokenize.COMMENT: '#ff0000', #red token.NAME: '#000000', #black token.ERRORTOKEN: '#FF8080', _KEYWORD: '#ff8c00', #dark orange _TEXT: '#000000', #black _DEForCLASS: '#0000ff', #blue } 3. We need something to keep track of the previously scanned token for each current token so we can know to color a token blue if it follows a 'def' or 'class' token, so add the following to the __init__ function of the Parser class self.prev_tok = '' 4. Then in the if...elif statement with the comment "# map token type to a color group" in the __call__ function, add a branch to check if the previous token was "def" or "class" # map token type to a color group if token.LPAR <= toktype and toktype <= token.OP: toktype = token.OP elif toktype == token.NAME and keyword.iskeyword(toktext): toktype = _KEYWORD #add this branch... elif toktype == token.NAME and self.prev_tok in ['def', 'class']: toktype = _NEWDEForCLASS #in Python 2.3 you could just say self.prev_tok in 'def class' #it might be slightly faster, but in practice it probably won't matter 5. Last but not least, somewhere before the end of the __call__ function put the following line, to remember the previous token for the elif from step 4. self.prev_tok = toktext There ya go! This works great and is pretty simple to use. It's not as good as just clicking a menu option from within IDLE, but it will let you print your python source in color. Yay! Many thanks to J?rgen Hermann for writing and making known this useful script. I hope this helps you out. Sincerely, ~Simon Forman calroc@mindspring.com BTW, if you want the background to be white (in the browser, I don't think it affects printing) make the following changes in the format function
')
 !> sys.stdout.write('
')

and

 
') !> sys.stdout.write('
') ---------------------------------------------------------------------- Comment By: Nobody/Anonymous (nobody) Date: 2003-11-08 18:20 Message: Logged In: NO I wanted to print in color too. As far as I can tell, IDLE sends the contents of your editor window to notepad.exe (on windows) for printing; I don't know what it does on other platforms. Notepad doesn't do color but I found another way. I was reading the "Python Cookbook" and there's a recipe in there for formatting python source in colorized HTML. J?rgen Hermann has made a "colorizer" for the MoinMoin project (MoinMoin urls: http://moin.sourceforge.net/ http://twistedmatrix.com/users/jh.twistd/moin/moin.cgi/ ) You can find the colorizer here: http://twistedmatrix.com/users/jh.twistd/python/moin.cgi/MoinMoinColorizer If you want to get it to give you output the same as IDLE a few small modifications are needed: In python, all name tokens are treated the same, 'if' is a name just like any identifier, so all "names" are colored the same. To get output like IDLE's, you want only identifiers occuring after "class" and "def" to be blue. 1. We need a new token type, so add the line _DEForCLASS = token.NT_OFFSET + 3 after _KEYWORD = token.NT_OFFSET + 1 _TEXT = token.NT_OFFSET + 2 (you can use any identifier you want, it doesn't have to be _DEForCLASS) 2. Next, edit the '_colors' dictionary to get more IDLE-like colors and add an entry for _DEForCLASS _colors = { token.NUMBER: '#000000', #black token.OP: '#000000', #black token.STRING: '#008000', #green tokenize.COMMENT: '#ff0000', #red token.NAME: '#000000', #black token.ERRORTOKEN: '#FF8080', _KEYWORD: '#ff8c00', #dark orange _TEXT: '#000000', #black _DEForCLASS: '#0000ff', #blue } 3. We need something to keep track of the previously scanned token for each current token so we can know to color a token blue if it follows a 'def' or 'class' token, so add the following to the __init__ function of the Parser class self.prev_tok = '' 4. Then in the if...elif statement with the comment "# map token type to a color group" in the __call__ function, add a branch to check if the previous token was "def" or "class" # map token type to a color group if token.LPAR <= toktype and toktype <= token.OP: toktype = token.OP elif toktype == token.NAME and keyword.iskeyword(toktext): toktype = _KEYWORD #add this branch... elif toktype == token.NAME and self.prev_tok in ['def', 'class']: toktype = _NEWDEForCLASS #in Python 2.3 you could just say self.prev_tok in 'def class' #it might be slightly faster, but in practice it probably won't matter 5. Last but not least, somewhere before the end of the __call__ function put the following line, to remember the previous token for the elif from step 4. self.prev_tok = toktext There ya go! This works great and is pretty simple to use. It's not as good as just clicking a menu option from within IDLE, but it will let you print your python source in color. Yay! Many thanks to J?rgen Hermann for writing and making known this useful script. I hope this helps you out. Sincerely, ~Simon Forman calroc@mindspring.com BTW, if you want the background to be white (in the browser, I don't think it affects printing) make the following changes in the format function
')
 !> sys.stdout.write('
')

and

 
') !> sys.stdout.write('
') ---------------------------------------------------------------------- You can respond by visiting: https://sourceforge.net/tracker/?func=detail&atid=109579&aid=837085&group_id=9579 From noreply at sourceforge.net Sun Nov 16 22:59:55 2003 From: noreply at sourceforge.net (SourceForge.net) Date: Sun Nov 16 23:00:00 2003 Subject: [Idle-dev] [ idlefork-Bugs-834136 ] control-c doesn't work Message-ID: Bugs item #834136, was opened at 2003-11-01 09:59 Message generated for change (Comment added) made by kbk You can respond by visiting: https://sourceforge.net/tracker/?func=detail&atid=109579&aid=834136&group_id=9579 Category: None Group: None Status: Open Resolution: None >Priority: 7 Submitted By: Egon Frerich (efrerich) >Assigned to: Kurt B. Kaiser (kbk) Summary: control-c doesn't work Initial Comment: (IDLE 1.0 - Python 2.3 -Windows XP) I put a never ending loop into my python program. control-c didn't stop the Run-Command. Then I choosed the exit option in the File Menu of the Shell-Window. Then I h've got the message, that the program is still running and if I would like to kill the program. After saying "yes" (or "ok" IDLE disappeared. But I cannot start IDLE again. I have to reboot my system. When I shutdown the system there is a program "Menu Window" which I have to destroy. ---------------------------------------------------------------------- >Comment By: Kurt B. Kaiser (kbk) Date: 2003-11-16 22:59 Message: Logged In: YES user_id=149084 Please post a copy of your program and any pertinent data so I can reproduce it. Ctrl-C works for me on the code I've tried. There are cases involving blocking I/O which can't be interrupted. It does sound like the main thread (which runs your code) is blocked. It should not be necessary to reboot XP. Use the Task Manager to kill the python subprocess, they are the (usually two threads) small ones. Kill the one which is getting 100% of the cpu first. If you do that, the GUI will re-spawn the subprocess. ---------------------------------------------------------------------- You can respond by visiting: https://sourceforge.net/tracker/?func=detail&atid=109579&aid=834136&group_id=9579 From noreply at sourceforge.net Sun Nov 16 23:01:14 2003 From: noreply at sourceforge.net (SourceForge.net) Date: Sun Nov 16 23:01:17 2003 Subject: [Idle-dev] [ idlefork-Bugs-842102 ] replace (Ctrl-h) doesn't highlight text Message-ID: Bugs item #842102, was opened at 2003-11-14 08:37 Message generated for change (Comment added) made by kbk You can respond by visiting: https://sourceforge.net/tracker/?func=detail&atid=109579&aid=842102&group_id=9579 Category: None Group: None Status: Open Resolution: None Priority: 5 Submitted By: Heiko Selber (drhok) Assigned to: Nobody/Anonymous (nobody) Summary: replace (Ctrl-h) doesn't highlight text Initial Comment: The search-and-replace function in IDLE 1.0 doesn't always highlight the current selection. So you can only guess which particular occurrence of the search string is about to be replaced. I think it depends on whether the selected text follows a certain string. ---------------------------------------------------------------------- >Comment By: Kurt B. Kaiser (kbk) Date: 2003-11-16 23:01 Message: Logged In: YES user_id=149084 Please give an example! ---------------------------------------------------------------------- You can respond by visiting: https://sourceforge.net/tracker/?func=detail&atid=109579&aid=842102&group_id=9579 From noreply at sourceforge.net Sun Nov 16 23:01:51 2003 From: noreply at sourceforge.net (SourceForge.net) Date: Sun Nov 16 23:01:53 2003 Subject: [Idle-dev] [ idlefork-Bugs-842088 ] Cut-Paste: ignore empty selection Message-ID: Bugs item #842088, was opened at 2003-11-14 08:20 Message generated for change (Settings changed) made by kbk You can respond by visiting: https://sourceforge.net/tracker/?func=detail&atid=109579&aid=842088&group_id=9579 Category: None Group: None Status: Open Resolution: None >Priority: 4 Submitted By: Heiko Selber (drhok) Assigned to: Nobody/Anonymous (nobody) Summary: Cut-Paste: ignore empty selection Initial Comment: Wish: ignore Ctrl-c or CTRL-x if nothing is selected. It happens quite often when I cut and paste with Ctrl- x / Ctrl-v, that I accidentally hit Ctrl-C instead of Ctrl-v. In IDLE, this empties the cut buffer. Other editors ignore Ctrl-x in this case, leaving the content of the cut buffer intact. ---------------------------------------------------------------------- You can respond by visiting: https://sourceforge.net/tracker/?func=detail&atid=109579&aid=842088&group_id=9579 From noreply at sourceforge.net Sun Nov 16 23:10:31 2003 From: noreply at sourceforge.net (SourceForge.net) Date: Sun Nov 16 23:10:34 2003 Subject: [Idle-dev] [ idlefork-Bugs-824595 ] filename .idlerc crashes windows98 Message-ID: Bugs item #824595, was opened at 2003-10-16 01:33 Message generated for change (Settings changed) made by kbk You can respond by visiting: https://sourceforge.net/tracker/?func=detail&atid=109579&aid=824595&group_id=9579 Category: None Group: None >Status: Closed Resolution: Works For Me Priority: 1 Submitted By: Nobody/Anonymous (nobody) Assigned to: Nobody/Anonymous (nobody) Summary: filename .idlerc crashes windows98 Initial Comment: Windows 98 crashes in horrible ways when filenames start with a dot. Even deleting the file is difficult! Crashes take place at totally unexpected moments, without any idle activity. Apparently the filesystem crashes when it gives the wrong interpretation to the starting dot. The file .idlerc should be renamed in something without a dot, for instance typical windows would be idle.ini Any name without a starting dot is OK. ---------------------------------------------------------------------- >Comment By: Kurt B. Kaiser (kbk) Date: 2003-11-16 23:10 Message: Logged In: YES user_id=149084 Closing this as WorksForMe. .idlerc is only referenced at one point in the code: configHandler.py: IdleConf.GetUserCfgDir() cfgDir = ".idlerc" Why don't you just change this to whatever you like and give it a try. ---------------------------------------------------------------------- Comment By: Kurt B. Kaiser (kbk) Date: 2003-10-17 20:11 Message: Logged In: YES user_id=149084 Duplocate of #678343 originally submitted 31Jan2003. Cllosed as 'works for me' on 05Sep2003. I have also been using IDLE and IDLEfork on W98 without problems. It's unlikely that a crash when not accessing the file system can be caused by a filename. Are you the same person who submitted the previous bug? ---------------------------------------------------------------------- Comment By: Guido van Rossum (gvanrossum) Date: 2003-10-16 10:09 Message: Logged In: YES user_id=6380 We need to know more about how your system was configured. Do you have a network filesystem or something like that? Virus scanner tools installed? I'm asking because I have used IDLE with this file without trouble for years on my own win98 box, so I doubt that it's win98 itself that causes the crashes. Filenames of this form have always been legal in win98. But some other software you've installed may be buggy. ---------------------------------------------------------------------- Comment By: Nobody/Anonymous (nobody) Date: 2003-10-16 01:33 Message: Logged In: NO e-mail address of submitter: gerrit.muller@embeddedsystems.nl ---------------------------------------------------------------------- You can respond by visiting: https://sourceforge.net/tracker/?func=detail&atid=109579&aid=824595&group_id=9579 From tayiper at volja.net Sun Nov 16 01:26:40 2003 From: tayiper at volja.net (Tadey) Date: Mon Nov 17 00:06:04 2003 Subject: [Idle-dev] double result ... Message-ID: <012c01c3ac0a$a557c8f0$324548d9@mz9s680eu689tz> Hello, I was just trying some different combinations, and noticed, that in sequence of commands: >>> a=7 >>> b=9 >>> c=8 >>> for i in range(a,b,c): >>> print i ... ... 7 ... gives value a, becuse it is the first value in the row, and because a, b, c are no "logical sequence" for computer (it doesn't support alphabet) !! >>> a=4 >>> b=6 >>> c=8 >>> for d in range(a,b,c): ... print d ... 4 .. I changed the order of letters to check if I am right. >>> a=4 >>> b=6 >>> c=8 >>> for d in range(b,c): ... print b ... 6 6 but then I accidentally mixed values and have instead of "print d", used "print b" - and I got two results one after another, two 6. So, I see one stands for varaiable b, and the other for d, from "for d in range" loop, but how is it possible, what happened, how computer gets that result ?? Thanks -------------- next part -------------- An HTML attachment was scrubbed... URL: http://mail.python.org/pipermail/idle-dev/attachments/20031116/316da244/attachment-0001.html From kbk at shore.net Mon Nov 17 00:30:18 2003 From: kbk at shore.net (Kurt B. Kaiser) Date: Mon Nov 17 00:31:34 2003 Subject: [Idle-dev] which version of IDLE do you suggest ?? In-Reply-To: <20031110182218.7CD318BC35@www.email.si> (Tadey Persic's message of "Mon, 10 Nov 2003 19:22:18 +0100") References: <20031110182218.7CD318BC35@www.email.si> Message-ID: Tadey Persic writes: > I am using Python v_2.3.2.1 with IDLE 1.0 included. Cause it hasn't contain > debbuger I would like to download newer IDLE, but I don't know which version to > choose ... > > > verson ... > > idlefork-0.7.1.tar.gz > > idlefork-0.8.1 > > IDLEfork-0.9a1 > > IDLEfork-0.9a2, or > > IDLEfork-0.9b1 > > > Please, help me to choose the right one !! Why do you say that it doesn't have a debugger? It was included in the IDLEfork0.9 releases, and also in IDLE1.0. IDLE 1.0 is the newest version. IDLEfork0.9 could be used if you were running Python2.2, but with 2.3 the included IDLE1.0 is the way to go. The others are totally obsolete. Open a Shell window, and use the Debug menu to switch on the debugger. Sorry for the slow response, I've been away. -- KBK From noreply at sourceforge.net Mon Nov 17 12:00:38 2003 From: noreply at sourceforge.net (SourceForge.net) Date: Mon Nov 17 12:00:45 2003 Subject: [Idle-dev] [ idlefork-Bugs-834136 ] control-c doesn't work Message-ID: Bugs item #834136, was opened at 2003-11-01 14:59 Message generated for change (Comment added) made by efrerich You can respond by visiting: https://sourceforge.net/tracker/?func=detail&atid=109579&aid=834136&group_id=9579 Category: None Group: None Status: Open Resolution: None Priority: 7 Submitted By: Egon Frerich (efrerich) Assigned to: Kurt B. Kaiser (kbk) Summary: control-c doesn't work Initial Comment: (IDLE 1.0 - Python 2.3 -Windows XP) I put a never ending loop into my python program. control-c didn't stop the Run-Command. Then I choosed the exit option in the File Menu of the Shell-Window. Then I h've got the message, that the program is still running and if I would like to kill the program. After saying "yes" (or "ok" IDLE disappeared. But I cannot start IDLE again. I have to reboot my system. When I shutdown the system there is a program "Menu Window" which I have to destroy. ---------------------------------------------------------------------- >Comment By: Egon Frerich (efrerich) Date: 2003-11-17 17:00 Message: Logged In: YES user_id=40342 Python program: actually I used Tkinter with two geometry manager (pack and grid) . Afterwards I read I shouldn't do this. Task Manager: Yes this works. If the geometry managers come to no end and I say Ctrl-C then nothing happens. Then if I kill the 99% cpu-process and afterwards push ctrl-c I get the KeyboardInterrupt in IDLE (and have not to reboot XP). Thanks Egon Frerich ---------------------------------------------------------------------- Comment By: Kurt B. Kaiser (kbk) Date: 2003-11-17 03:59 Message: Logged In: YES user_id=149084 Please post a copy of your program and any pertinent data so I can reproduce it. Ctrl-C works for me on the code I've tried. There are cases involving blocking I/O which can't be interrupted. It does sound like the main thread (which runs your code) is blocked. It should not be necessary to reboot XP. Use the Task Manager to kill the python subprocess, they are the (usually two threads) small ones. Kill the one which is getting 100% of the cpu first. If you do that, the GUI will re-spawn the subprocess. ---------------------------------------------------------------------- You can respond by visiting: https://sourceforge.net/tracker/?func=detail&atid=109579&aid=834136&group_id=9579 From noreply at sourceforge.net Mon Nov 17 22:19:12 2003 From: noreply at sourceforge.net (SourceForge.net) Date: Mon Nov 17 22:19:16 2003 Subject: [Idle-dev] [ idlefork-Bugs-834136 ] control-c doesn't work Message-ID: Bugs item #834136, was opened at 2003-11-01 09:59 Message generated for change (Comment added) made by kbk You can respond by visiting: https://sourceforge.net/tracker/?func=detail&atid=109579&aid=834136&group_id=9579 Category: None Group: None Status: Open Resolution: None >Priority: 4 Submitted By: Egon Frerich (efrerich) Assigned to: Kurt B. Kaiser (kbk) Summary: control-c doesn't work Initial Comment: (IDLE 1.0 - Python 2.3 -Windows XP) I put a never ending loop into my python program. control-c didn't stop the Run-Command. Then I choosed the exit option in the File Menu of the Shell-Window. Then I h've got the message, that the program is still running and if I would like to kill the program. After saying "yes" (or "ok" IDLE disappeared. But I cannot start IDLE again. I have to reboot my system. When I shutdown the system there is a program "Menu Window" which I have to destroy. ---------------------------------------------------------------------- >Comment By: Kurt B. Kaiser (kbk) Date: 2003-11-17 22:19 Message: Logged In: YES user_id=149084 Nonetheless, if you could post the code (or even better, a cut-down) which causes the error, it might be useful. There are some internal IDLE problems which can cause hangs. Otherwise, I'll go ahead and close this. ---------------------------------------------------------------------- Comment By: Egon Frerich (efrerich) Date: 2003-11-17 12:00 Message: Logged In: YES user_id=40342 Python program: actually I used Tkinter with two geometry manager (pack and grid) . Afterwards I read I shouldn't do this. Task Manager: Yes this works. If the geometry managers come to no end and I say Ctrl-C then nothing happens. Then if I kill the 99% cpu-process and afterwards push ctrl-c I get the KeyboardInterrupt in IDLE (and have not to reboot XP). Thanks Egon Frerich ---------------------------------------------------------------------- Comment By: Kurt B. Kaiser (kbk) Date: 2003-11-16 22:59 Message: Logged In: YES user_id=149084 Please post a copy of your program and any pertinent data so I can reproduce it. Ctrl-C works for me on the code I've tried. There are cases involving blocking I/O which can't be interrupted. It does sound like the main thread (which runs your code) is blocked. It should not be necessary to reboot XP. Use the Task Manager to kill the python subprocess, they are the (usually two threads) small ones. Kill the one which is getting 100% of the cpu first. If you do that, the GUI will re-spawn the subprocess. ---------------------------------------------------------------------- You can respond by visiting: https://sourceforge.net/tracker/?func=detail&atid=109579&aid=834136&group_id=9579 From noreply at sourceforge.net Tue Nov 18 05:15:01 2003 From: noreply at sourceforge.net (SourceForge.net) Date: Tue Nov 18 05:15:05 2003 Subject: [Idle-dev] [ idlefork-Bugs-834136 ] control-c doesn't work Message-ID: Bugs item #834136, was opened at 2003-11-01 14:59 Message generated for change (Comment added) made by efrerich You can respond by visiting: https://sourceforge.net/tracker/?func=detail&atid=109579&aid=834136&group_id=9579 Category: None Group: None Status: Open Resolution: None Priority: 4 Submitted By: Egon Frerich (efrerich) Assigned to: Kurt B. Kaiser (kbk) Summary: control-c doesn't work Initial Comment: (IDLE 1.0 - Python 2.3 -Windows XP) I put a never ending loop into my python program. control-c didn't stop the Run-Command. Then I choosed the exit option in the File Menu of the Shell-Window. Then I h've got the message, that the program is still running and if I would like to kill the program. After saying "yes" (or "ok" IDLE disappeared. But I cannot start IDLE again. I have to reboot my system. When I shutdown the system there is a program "Menu Window" which I have to destroy. ---------------------------------------------------------------------- >Comment By: Egon Frerich (efrerich) Date: 2003-11-18 10:15 Message: Logged In: YES user_id=40342 I have written two programs and upload them as one text file. After separating the program with only the pack-geometry manager works. The other program has some functions with calls to the grid manager. With this program you get 95% - 99% cpu-processing and you stop IDLE with ctrl-c. ---------------------------------------------------------------------- Comment By: Kurt B. Kaiser (kbk) Date: 2003-11-18 03:19 Message: Logged In: YES user_id=149084 Nonetheless, if you could post the code (or even better, a cut-down) which causes the error, it might be useful. There are some internal IDLE problems which can cause hangs. Otherwise, I'll go ahead and close this. ---------------------------------------------------------------------- Comment By: Egon Frerich (efrerich) Date: 2003-11-17 17:00 Message: Logged In: YES user_id=40342 Python program: actually I used Tkinter with two geometry manager (pack and grid) . Afterwards I read I shouldn't do this. Task Manager: Yes this works. If the geometry managers come to no end and I say Ctrl-C then nothing happens. Then if I kill the 99% cpu-process and afterwards push ctrl-c I get the KeyboardInterrupt in IDLE (and have not to reboot XP). Thanks Egon Frerich ---------------------------------------------------------------------- Comment By: Kurt B. Kaiser (kbk) Date: 2003-11-17 03:59 Message: Logged In: YES user_id=149084 Please post a copy of your program and any pertinent data so I can reproduce it. Ctrl-C works for me on the code I've tried. There are cases involving blocking I/O which can't be interrupted. It does sound like the main thread (which runs your code) is blocked. It should not be necessary to reboot XP. Use the Task Manager to kill the python subprocess, they are the (usually two threads) small ones. Kill the one which is getting 100% of the cpu first. If you do that, the GUI will re-spawn the subprocess. ---------------------------------------------------------------------- You can respond by visiting: https://sourceforge.net/tracker/?func=detail&atid=109579&aid=834136&group_id=9579 From noreply at sourceforge.net Tue Nov 18 15:35:03 2003 From: noreply at sourceforge.net (SourceForge.net) Date: Tue Nov 18 15:36:11 2003 Subject: [Idle-dev] [ idlefork-Patches-844675 ] Enable pdb.pm() after unhandled exception Message-ID: Patches item #844675, was opened at 2003-11-18 22:35 Message generated for change (Tracker Item Submitted) made by Item Submitter You can respond by visiting: https://sourceforge.net/tracker/?func=detail&atid=309579&aid=844675&group_id=9579 Category: None Group: None Status: Open Resolution: None Priority: 5 Submitted By: Noam Raphael (noamr) Assigned to: Nobody/Anonymous (nobody) Summary: Enable pdb.pm() after unhandled exception Initial Comment: Currently, pdb.pm() doesn't work after an exception was raised, since it is actually handled. The following line should be added to run.py after the line self.usr_exc_info = sys.exc_info() (line 248): sys.last_type, sys.last_value, sys.last_traceback = self.usr_exc_info This emulated the normal behaviour of an unhandled exception, and gives pdb.pm() the information it needs in order to work. ---------------------------------------------------------------------- You can respond by visiting: https://sourceforge.net/tracker/?func=detail&atid=309579&aid=844675&group_id=9579 From noreply at sourceforge.net Thu Nov 20 06:45:53 2003 From: noreply at sourceforge.net (SourceForge.net) Date: Thu Nov 20 06:45:58 2003 Subject: [Idle-dev] [ idlefork-Bugs-842102 ] replace (Ctrl-h) doesn't highlight text Message-ID: Bugs item #842102, was opened at 2003-11-14 13:37 Message generated for change (Comment added) made by drhok You can respond by visiting: https://sourceforge.net/tracker/?func=detail&atid=109579&aid=842102&group_id=9579 Category: None Group: None Status: Open Resolution: None Priority: 5 Submitted By: Heiko Selber (drhok) Assigned to: Nobody/Anonymous (nobody) Summary: replace (Ctrl-h) doesn't highlight text Initial Comment: The search-and-replace function in IDLE 1.0 doesn't always highlight the current selection. So you can only guess which particular occurrence of the search string is about to be replaced. I think it depends on whether the selected text follows a certain string. ---------------------------------------------------------------------- >Comment By: Heiko Selber (drhok) Date: 2003-11-20 11:45 Message: Logged In: YES user_id=865975 I looked a bit closer: Text in strings (i.e. green text) is not highlighted. **** BEGIN Example **** #try to change "myfunc" def myfunc(): "myfunc takes no parameters" **** END Example **** It works in the comment and in def, but not in the string (I use Python-2.3.2-1 on WinXP). ---------------------------------------------------------------------- Comment By: Kurt B. Kaiser (kbk) Date: 2003-11-17 04:01 Message: Logged In: YES user_id=149084 Please give an example! ---------------------------------------------------------------------- You can respond by visiting: https://sourceforge.net/tracker/?func=detail&atid=109579&aid=842102&group_id=9579 From noreply at sourceforge.net Sun Nov 23 22:09:00 2003 From: noreply at sourceforge.net (SourceForge.net) Date: Sun Nov 23 22:09:03 2003 Subject: [Idle-dev] [ idlefork-Patches-844675 ] Enable pdb.pm() after unhandled exception Message-ID: Patches item #844675, was opened at 2003-11-18 15:35 Message generated for change (Comment added) made by kbk You can respond by visiting: https://sourceforge.net/tracker/?func=detail&atid=309579&aid=844675&group_id=9579 Category: None Group: None >Status: Closed >Resolution: Accepted Priority: 5 Submitted By: Noam Raphael (noamr) >Assigned to: Kurt B. Kaiser (kbk) Summary: Enable pdb.pm() after unhandled exception Initial Comment: Currently, pdb.pm() doesn't work after an exception was raised, since it is actually handled. The following line should be added to run.py after the line self.usr_exc_info = sys.exc_info() (line 248): sys.last_type, sys.last_value, sys.last_traceback = self.usr_exc_info This emulated the normal behaviour of an unhandled exception, and gives pdb.pm() the information it needs in order to work. ---------------------------------------------------------------------- >Comment By: Kurt B. Kaiser (kbk) Date: 2003-11-23 22:09 Message: Logged In: YES user_id=149084 Python IDLE run.py 1.26 release23-maint 1.25.8.1 IDLEfork run.py 1.24 ---------------------------------------------------------------------- You can respond by visiting: https://sourceforge.net/tracker/?func=detail&atid=309579&aid=844675&group_id=9579 From kbk at users.sourceforge.net Sun Nov 23 22:08:10 2003 From: kbk at users.sourceforge.net (Kurt B. Kaiser) Date: Mon Nov 24 01:05:11 2003 Subject: [Idle-dev] CVS: idle NEWS.txt, 1.23, 1.24 idlever.py, 1.10, 1.11 run.py, 1.23, 1.24 Message-ID: Update of /cvsroot/idlefork/idle In directory sc8-pr-cvs1:/tmp/cvs-serv21203 Modified Files: NEWS.txt idlever.py run.py Log Message: - After an exception, run.py was not setting the exception vector. Noam Raphael suggested correcting this so pdb's postmortem pm() would work. IDLEfork Patch 844675. Also fixed in Python IDLE. Updated: NEWS.txt idlever.py run.py Index: NEWS.txt =================================================================== RCS file: /cvsroot/idlefork/idle/NEWS.txt,v retrieving revision 1.23 retrieving revision 1.24 diff -C2 -r1.23 -r1.24 *** NEWS.txt 10 Aug 2003 04:05:37 -0000 1.23 --- NEWS.txt 24 Nov 2003 03:08:08 -0000 1.24 *************** *** 8,11 **** --- 8,15 ---- *Release date: XX-XXX-2003* + - After an exception, run.py was not setting the exception vector. Noam + Raphael suggested correcting this so pdb's postmortem pm() would work. + IDLEfork Patch 844675 + - IDLE didn't start correctly when Python was installed in "Program Files" on W2K and XP. Python Bugs 780451, 784183 Index: idlever.py =================================================================== RCS file: /cvsroot/idlefork/idle/idlever.py,v retrieving revision 1.10 retrieving revision 1.11 diff -C2 -r1.10 -r1.11 *** idlever.py 25 Apr 2003 17:48:08 -0000 1.10 --- idlever.py 24 Nov 2003 03:08:08 -0000 1.11 *************** *** 1 **** ! IDLE_VERSION = "0.9b1" --- 1 ---- ! IDLE_VERSION = "0.9b1+" Index: run.py =================================================================== RCS file: /cvsroot/idlefork/idle/run.py,v retrieving revision 1.23 retrieving revision 1.24 diff -C2 -r1.23 -r1.24 *** run.py 10 Jul 2003 03:47:40 -0000 1.23 --- run.py 24 Nov 2003 03:08:08 -0000 1.24 *************** *** 114,118 **** flush_stdout() efile = sys.stderr ! typ, val, tb = sys.exc_info() tbe = traceback.extract_tb(tb) print >>efile, '\nTraceback (most recent call last):' --- 114,119 ---- flush_stdout() efile = sys.stderr ! typ, val, tb = excinfo = sys.exc_info() ! sys.last_type, sys.last_value, sys.last_traceback = excinfo tbe = traceback.extract_tb(tb) print >>efile, '\nTraceback (most recent call last):' From kbk at users.sourceforge.net Mon Nov 24 22:42:34 2003 From: kbk at users.sourceforge.net (Kurt B. Kaiser) Date: Tue Nov 25 01:29:32 2003 Subject: [Idle-dev] CVS: idle NEWS.txt, 1.24, 1.25 PyShell.py, 1.78, 1.79 config-keys.def, 1.19, 1.20 configHandler.py, 1.31, 1.32 keybindingDialog.py, 1.10, 1.11 Message-ID: Update of /cvsroot/idlefork/idle In directory sc8-pr-cvs1:/tmp/cvs-serv26437 Modified Files: NEWS.txt PyShell.py config-keys.def configHandler.py keybindingDialog.py Log Message: Keybindings with the Shift modifier now work correctly. So do bindings which use the Space key. Limit unmodified user keybindings to the function keys. Python Bug 775353, IDLEfork Bugs 755647, 761557 Improve error handling during startup if there's no Tkinter. M NEWS.txt M PyShell.py M config-keys.def M configHandler.py M keybindingDialog.py Also applied to Python IDLE. Index: NEWS.txt =================================================================== RCS file: /cvsroot/idlefork/idle/NEWS.txt,v retrieving revision 1.24 retrieving revision 1.25 diff -C2 -r1.24 -r1.25 *** NEWS.txt 24 Nov 2003 03:08:08 -0000 1.24 --- NEWS.txt 25 Nov 2003 03:42:32 -0000 1.25 *************** *** 8,11 **** --- 8,15 ---- *Release date: XX-XXX-2003* + - Keybindings with the Shift modifier now work correctly. So do bindings which + use the Space key. Limit unmodified user keybindings to the function keys. + Python Bug 775353, IDLEfork Bugs 755647, 761557 + - After an exception, run.py was not setting the exception vector. Noam Raphael suggested correcting this so pdb's postmortem pm() would work. Index: PyShell.py =================================================================== RCS file: /cvsroot/idlefork/idle/PyShell.py,v retrieving revision 1.78 retrieving revision 1.79 diff -C2 -r1.78 -r1.79 *** PyShell.py 10 Aug 2003 04:05:37 -0000 1.78 --- PyShell.py 25 Nov 2003 03:42:32 -0000 1.79 *************** *** 17,21 **** from code import InteractiveInterpreter ! from Tkinter import * import tkMessageBox --- 17,26 ---- from code import InteractiveInterpreter ! try: ! from Tkinter import * ! except ImportError: ! print>>sys.__stderr__, "** IDLE can't import Tkinter. " \ ! "Your Python may not be configured for Tk. **" ! sys.exit(1) import tkMessageBox Index: config-keys.def =================================================================== RCS file: /cvsroot/idlefork/idle/config-keys.def,v retrieving revision 1.19 retrieving revision 1.20 diff -C2 -r1.19 -r1.20 *** config-keys.def 18 May 2003 02:21:55 -0000 1.19 --- config-keys.def 25 Nov 2003 03:42:32 -0000 1.20 *************** *** 31,38 **** plain-newline-and-indent= print-window= ! redo= remove-selection= ! save-copy-of-window-as-file= ! save-window-as-file= save-window= select-all= --- 31,38 ---- plain-newline-and-indent= print-window= ! redo= remove-selection= ! save-copy-of-window-as-file= ! save-window-as-file= save-window= select-all= *************** *** 79,83 **** print-window= python-docs= ! python-context-help= redo= remove-selection= --- 79,83 ---- print-window= python-docs= ! python-context-help= redo= remove-selection= *************** *** 129,135 **** plain-newline-and-indent= print-window= ! redo= remove-selection= ! save-window-as-file= save-window= save-copy-of-window-as-file= --- 129,135 ---- plain-newline-and-indent= print-window= ! redo= remove-selection= ! save-window-as-file= save-window= save-copy-of-window-as-file= Index: configHandler.py =================================================================== RCS file: /cvsroot/idlefork/idle/configHandler.py,v retrieving revision 1.31 retrieving revision 1.32 diff -C2 -r1.31 -r1.32 *** configHandler.py 27 Jan 2003 02:36:18 -0000 1.31 --- configHandler.py 25 Nov 2003 03:42:32 -0000 1.32 *************** *** 532,536 **** '<>': [''], '<>': [''], ! '<>': [''], '<>': [''], '<>': [''], --- 532,536 ---- '<>': [''], '<>': [''], ! '<>': [''], '<>': [''], '<>': [''], Index: keybindingDialog.py =================================================================== RCS file: /cvsroot/idlefork/idle/keybindingDialog.py,v retrieving revision 1.10 retrieving revision 1.11 diff -C2 -r1.10 -r1.11 *** keybindingDialog.py 31 Dec 2002 16:03:23 -0000 1.10 --- keybindingDialog.py 25 Nov 2003 03:42:32 -0000 1.11 *************** *** 1,4 **** """ ! dialog for building tkinter accelerator key bindings """ from Tkinter import * --- 1,4 ---- """ ! Dialog for building Tkinter accelerator key bindings """ from Tkinter import * *************** *** 50,56 **** frameButtons=Frame(self) frameButtons.pack(side=BOTTOM,fill=X) ! self.buttonOk = Button(frameButtons,text='Ok', ! width=8,command=self.Ok) ! self.buttonOk.grid(row=0,column=0,padx=5,pady=5) self.buttonCancel = Button(frameButtons,text='Cancel', width=8,command=self.Cancel) --- 50,56 ---- frameButtons=Frame(self) frameButtons.pack(side=BOTTOM,fill=X) ! self.buttonOK = Button(frameButtons,text='OK', ! width=8,command=self.OK) ! self.buttonOK.grid(row=0,column=0,padx=5,pady=5) self.buttonCancel = Button(frameButtons,text='Cancel', width=8,command=self.Cancel) *************** *** 86,92 **** column += 1 labelFnAdvice=Label(self.frameControlsBasic,justify=LEFT, ! text="Select the desired modifier\n"+ ! "keys above, and final key\n"+ ! "from the list on the right.") labelFnAdvice.grid(row=1,column=0,columnspan=4,padx=2,sticky=W) self.listKeysFinal=Listbox(self.frameControlsBasic,width=15,height=10, --- 86,96 ---- column += 1 labelFnAdvice=Label(self.frameControlsBasic,justify=LEFT, ! text=\ ! "Select the desired modifier keys\n"+ ! "above, and the final key from the\n"+ ! "list on the right.\n\n" + ! "Use upper case Symbols when using\n" + ! "the Shift modifier. (Letters will be\n" + ! "converted automatically.)") labelFnAdvice.grid(row=1,column=0,columnspan=4,padx=2,sticky=W) self.listKeysFinal=Listbox(self.frameControlsBasic,width=15,height=10, *************** *** 103,107 **** labelTitleAdvanced = Label(self.frameKeySeqAdvanced,justify=LEFT, text="Enter new binding(s) for '"+self.action+"' :\n"+ ! "(will not be checked for validity)") labelTitleAdvanced.pack(anchor=W) self.entryKeysAdvanced=Entry(self.frameKeySeqAdvanced, --- 107,111 ---- labelTitleAdvanced = Label(self.frameKeySeqAdvanced,justify=LEFT, text="Enter new binding(s) for '"+self.action+"' :\n"+ ! "(These bindings will not be checked for validity!)") labelTitleAdvanced.pack(anchor=W) self.entryKeysAdvanced=Entry(self.frameKeySeqAdvanced, *************** *** 109,117 **** self.entryKeysAdvanced.pack(fill=X) labelHelpAdvanced=Label(self.frameHelpAdvanced,justify=LEFT, ! text="Key bindings are specified using tkinter key id's as\n"+ "in these samples: , , ,\n" ! ", , .\n\n"+ ! "'Emacs style' multi-keystroke bindings are specified as\n"+ ! "follows: or .\n\n"+ "Multiple separate bindings for one action should be\n"+ "separated by a space, eg., ." ) --- 113,123 ---- self.entryKeysAdvanced.pack(fill=X) labelHelpAdvanced=Label(self.frameHelpAdvanced,justify=LEFT, ! text="Key bindings are specified using Tkinter keysyms as\n"+ "in these samples: , , ,\n" ! ", , .\n" ! "Upper case is used when the Shift modifier is present!\n\n" + ! "'Emacs style' multi-keystroke bindings are specified as\n" + ! "follows: , where the first key\n" + ! "is the 'do-nothing' keybinding.\n\n" + "Multiple separate bindings for one action should be\n"+ "separated by a space, eg., ." ) *************** *** 150,167 **** def BuildKeyString(self): ! keyList=[] ! modifiers=self.GetModifiers() ! finalKey=self.listKeysFinal.get(ANCHOR) ! if modifiers: modifiers[0]='<'+modifiers[0] ! keyList=keyList+modifiers if finalKey: ! if (not modifiers) and (finalKey not ! in self.alphanumKeys+self.punctuationKeys): ! finalKey='<'+self.TranslateKey(finalKey) ! else: ! finalKey=self.TranslateKey(finalKey) ! keyList.append(finalKey+'>') ! keyStr=string.join(keyList,'-') ! self.keyString.set(keyStr) def GetModifiers(self): --- 156,165 ---- def BuildKeyString(self): ! keyList = modifiers = self.GetModifiers() ! finalKey = self.listKeysFinal.get(ANCHOR) if finalKey: ! finalKey = self.TranslateKey(finalKey, modifiers) ! keyList.append(finalKey) ! self.keyString.set('<' + string.join(keyList,'-') + '>') def GetModifiers(self): *************** *** 192,198 **** (END,)+keys) ! def TranslateKey(self,key): ! #translate from key list value to tkinter key-id ! translateDict={'~':'asciitilde','!':'exclam','@':'at','#':'numbersign', '%':'percent','^':'asciicircum','&':'ampersand','*':'asterisk', '(':'parenleft',')':'parenright','_':'underscore','-':'minus', --- 190,197 ---- (END,)+keys) ! def TranslateKey(self, key, modifiers): ! "Translate from keycap symbol to the Tkinter keysym" ! translateDict = {'Space':'space', ! '~':'asciitilde','!':'exclam','@':'at','#':'numbersign', '%':'percent','^':'asciicircum','&':'ampersand','*':'asterisk', '(':'parenleft',')':'parenright','_':'underscore','-':'minus', *************** *** 202,213 **** '/':'slash','?':'question','Page Up':'Prior','Page Down':'Next', 'Left Arrow':'Left','Right Arrow':'Right','Up Arrow':'Up', ! 'Down Arrow': 'Down'} if key in translateDict.keys(): ! key=translateDict[key] ! key='Key-'+key return key ! def Ok(self, event=None): ! if self.KeysOk(): self.result=self.keyString.get() self.destroy() --- 201,214 ---- '/':'slash','?':'question','Page Up':'Prior','Page Down':'Next', 'Left Arrow':'Left','Right Arrow':'Right','Up Arrow':'Up', ! 'Down Arrow': 'Down', 'Tab':'tab'} if key in translateDict.keys(): ! key = translateDict[key] ! if 'Shift' in modifiers and key in string.ascii_lowercase: ! key = key.upper() ! key = 'Key-' + key return key ! def OK(self, event=None): ! if self.KeysOK(): self.result=self.keyString.get() self.destroy() *************** *** 217,254 **** self.destroy() ! def KeysOk(self): ! #simple validity check ! keysOk=1 ! keys=self.keyString.get() keys.strip() ! finalKey=self.listKeysFinal.get(ANCHOR) ! modifiers=self.GetModifiers() ! keySequence=keys.split()#make into a key sequence list for overlap check ! if not keys: #no keys specified ! tkMessageBox.showerror(title='Key Sequence Error', ! message='No keys specified.') ! keysOk=0 ! elif not keys.endswith('>'): #no final key specified ! tkMessageBox.showerror(title='Key Sequence Error', ! message='No final key specified.') ! keysOk=0 ! elif (not modifiers) and (finalKey in ! self.alphanumKeys+self.punctuationKeys): ! #modifier required ! tkMessageBox.showerror(title='Key Sequence Error', ! message='No modifier key(s) specified.') ! keysOk=0 ! elif (modifiers==['Shift']) and (finalKey not ! in self.functionKeys+('Tab',)): ! #shift alone is only a useful modifier with a function key ! tkMessageBox.showerror(title='Key Sequence Error', ! message='Shift alone is not a useful modifier '+ ! 'when used with this final key key.') ! keysOk=0 ! elif keySequence in self.currentKeySequences: #keys combo already in use ! tkMessageBox.showerror(title='Key Sequence Error', ! message='This key combination is already in use.') ! keysOk=0 ! return keysOk if __name__ == '__main__': --- 218,254 ---- self.destroy() ! def KeysOK(self): ! "Validity check on user's keybinding selection" ! keys = self.keyString.get() keys.strip() ! finalKey = self.listKeysFinal.get(ANCHOR) ! modifiers = self.GetModifiers() ! # create a key sequence list for overlap check: ! keySequence = keys.split() ! keysOK = False ! title = 'Key Sequence Error' ! if not keys: ! tkMessageBox.showerror(title=title, parent=self, ! message='No keys specified.') ! elif not keys.endswith('>'): ! tkMessageBox.showerror(title=title, parent=self, ! message='Missing the final Key') ! elif not modifiers and finalKey not in self.functionKeys: ! tkMessageBox.showerror(title=title, parent=self, ! message='No modifier key(s) specified.') ! elif (modifiers == ['Shift']) \ ! and (finalKey not in ! self.functionKeys + ('Tab', 'Space')): ! msg = 'The shift modifier by itself may not be used with' \ ! ' this key symbol; only with F1-F12, Tab, or Space' ! tkMessageBox.showerror(title=title, parent=self, ! message=msg) ! elif keySequence in self.currentKeySequences: ! msg = 'This key combination is already in use.' ! tkMessageBox.showerror(title=title, parent=self, ! message=msg) ! else: ! keysOK = True ! return keysOK if __name__ == '__main__': From kbk at users.sourceforge.net Mon Nov 24 23:52:14 2003 From: kbk at users.sourceforge.net (Kurt B. Kaiser) Date: Tue Nov 25 01:29:44 2003 Subject: [Idle-dev] CVS: idle IOBinding.py,1.18,1.19 NEWS.txt,1.25,1.26 Message-ID: Update of /cvsroot/idlefork/idle In directory sc8-pr-cvs1:/tmp/cvs-serv6394 Modified Files: IOBinding.py NEWS.txt Log Message: Port Martin v. Loewis corrections to IOBinding.py (1.20, 1.21) from Python IDLE. Closes IDLEfork Bug 778547, Python Bugs 788378, 774680, 805728 M IOBinding.py M NEWS.txt Index: IOBinding.py =================================================================== RCS file: /cvsroot/idlefork/idle/IOBinding.py,v retrieving revision 1.18 retrieving revision 1.19 diff -C2 -r1.18 -r1.19 *** IOBinding.py 9 Jun 2003 03:12:42 -0000 1.18 --- IOBinding.py 25 Nov 2003 04:52:11 -0000 1.19 *************** *** 30,34 **** import locale locale.setlocale(locale.LC_CTYPE, "") ! except ImportError: pass --- 30,34 ---- import locale locale.setlocale(locale.LC_CTYPE, "") ! except (ImportError, locale.Error): pass *************** *** 253,256 **** --- 253,259 ---- if firsteol: self.eol_convention = firsteol.group(0) + if isinstance(self.eol_convention, unicode): + # Make sure it is an ASCII string + self.eol_convention = self.eol_convention.encode("ascii") chars = self.eol_re.sub(r"\n", chars) Index: NEWS.txt =================================================================== RCS file: /cvsroot/idlefork/idle/NEWS.txt,v retrieving revision 1.25 retrieving revision 1.26 diff -C2 -r1.25 -r1.26 *** NEWS.txt 25 Nov 2003 03:42:32 -0000 1.25 --- NEWS.txt 25 Nov 2003 04:52:12 -0000 1.26 *************** *** 8,11 **** --- 8,14 ---- *Release date: XX-XXX-2003* + - Port Martin v. Loewis corrections to IOBinding.py (1.20, 1.21) from Python + IDLE. Closes IDLEfork Bug 778547, Python Bugs 788378, 774680, 805728 + - Keybindings with the Shift modifier now work correctly. So do bindings which use the Space key. Limit unmodified user keybindings to the function keys. From noreply at sourceforge.net Mon Nov 24 22:57:18 2003 From: noreply at sourceforge.net (SourceForge.net) Date: Tue Nov 25 03:02:06 2003 Subject: [Idle-dev] [ idlefork-Bugs-755647 ] Save Copy As control keys do not function Message-ID: Bugs item #755647, was opened at 2003-06-16 20:53 Message generated for change (Comment added) made by kbk You can respond by visiting: https://sourceforge.net/tracker/?func=detail&atid=109579&aid=755647&group_id=9579 Category: None Group: None >Status: Closed >Resolution: Fixed Priority: 6 Submitted By: Nobody/Anonymous (nobody) Assigned to: Kurt B. Kaiser (kbk) Summary: Save Copy As control keys do not function Initial Comment: The control keys for Save Copy As (Alt+Shift+S) do not function. Simple to reproduce: Just open up a new buffer, type some text, and hit the 3-key control combo. Manually using Save Copy As works as expected. Although this bug is trivial, it means a bunch to lazy people like myself:) ---------------------------------------------------------------------- >Comment By: Kurt B. Kaiser (kbk) Date: 2003-11-24 22:57 Message: Logged In: YES user_id=149084 configHandler.py 1.32 keyBindingDialog.py 1.11 config-keys.def 1.20 ---------------------------------------------------------------------- Comment By: Kurt B. Kaiser (kbk) Date: 2003-07-01 00:59 Message: Logged In: YES user_id=149084 None of the bindings with a Shift modifier work because it is then necessary to use the upper case keysym. IDLE is using the lower case. ---------------------------------------------------------------------- You can respond by visiting: https://sourceforge.net/tracker/?func=detail&atid=109579&aid=755647&group_id=9579 From noreply at sourceforge.net Mon Nov 24 22:54:29 2003 From: noreply at sourceforge.net (SourceForge.net) Date: Tue Nov 25 03:02:32 2003 Subject: [Idle-dev] [ idlefork-Bugs-761557 ] Rebinding text-completion from Ctrl-/ to Ctrl-space is broke Message-ID: Bugs item #761557, was opened at 2003-06-26 20:01 Message generated for change (Comment added) made by kbk You can respond by visiting: https://sourceforge.net/tracker/?func=detail&atid=109579&aid=761557&group_id=9579 Category: None Group: None >Status: Closed >Resolution: Fixed Priority: 6 Submitted By: Nobody/Anonymous (nobody) Assigned to: Kurt B. Kaiser (kbk) Summary: Rebinding text-completion from Ctrl-/ to Ctrl-space is broke Initial Comment: Rebinding Text completion from Ctrl-/ to Ctrl-space gives the following stack trace: Exception in Tkinter callback Traceback (most recent call last): File "F:\PYTHON23\lib\lib-tk\Tkinter.py", line 1337, in __call__ return self.func(*args) File "F:\PYTHON23\Lib\site- packages\idleforklib\configDialog.py", line 1168, n Ok self.Apply() File "F:\PYTHON23\Lib\site- packages\idleforklib\configDialog.py", line 1173, n Apply self.ActivateConfigChanges() File "F:\PYTHON23\Lib\site- packages\idleforklib\configDialog.py", line 1161, n ActivateConfigChanges instance.ResetKeybindings() File "F:\PYTHON23\Lib\site- packages\idleforklib\EditorWindow.py", line 530, i ResetKeybindings self.apply_bindings() File "F:\PYTHON23\Lib\site- packages\idleforklib\EditorWindow.py", line 798, i apply_bindings apply(text.event_add, (event,) + tuple(keylist)) File "F:\PYTHON23\lib\lib-tk\Tkinter.py", line 1291, in event_add self.tk.call(args) TclError: bad event type or keysym "Space" ---------------------------------------------------------------------- >Comment By: Kurt B. Kaiser (kbk) Date: 2003-11-24 22:54 Message: Logged In: YES user_id=149084 configHandler.py 1.32 keyBindingDialog.py 1.11 config-keys.def 1.20 ---------------------------------------------------------------------- You can respond by visiting: https://sourceforge.net/tracker/?func=detail&atid=109579&aid=761557&group_id=9579 From noreply at sourceforge.net Tue Nov 25 00:08:30 2003 From: noreply at sourceforge.net (SourceForge.net) Date: Tue Nov 25 07:04:00 2003 Subject: [Idle-dev] [ idlefork-Bugs-778547 ] UTF-8 mode files won't save with non-ASCII characters Message-ID: Bugs item #778547, was opened at 2003-07-27 13:29 Message generated for change (Comment added) made by kbk You can respond by visiting: https://sourceforge.net/tracker/?func=detail&atid=109579&aid=778547&group_id=9579 Category: None Group: None >Status: Closed >Resolution: Fixed Priority: 5 Submitted By: Nobody/Anonymous (nobody) >Assigned to: Kurt B. Kaiser (kbk) Summary: UTF-8 mode files won't save with non-ASCII characters Initial Comment: Changing "Defaulr Source Encoding" to UTF-8 prevents error messages for files with "european characters" (???). However the file will not save any longer... Remove those characters and saving is o.k. again. Michael Peuser ---------------------------------------------------------------------- >Comment By: Kurt B. Kaiser (kbk) Date: 2003-11-25 00:08 Message: Logged In: YES user_id=149084 Ported loewis' fix: Python IDLE IOBinding.py 1.20, 1.21, and fixed a typo in 1.21. IOBinding 1.19 ---------------------------------------------------------------------- Comment By: Nobody/Anonymous (nobody) Date: 2003-09-22 07:32 Message: Logged In: NO I think bug #805728 (https://sourceforge.net/tracker/?func=detail&atid=105470&aid=805728&group_id=5470) should cover this case. ---------------------------------------------------------------------- Comment By: Nobody/Anonymous (nobody) Date: 2003-08-03 10:10 Message: Logged In: NO I found it happens only when editing existing files, not when saving new ones. ---------------------------------------------------------------------- Comment By: Nobody/Anonymous (nobody) Date: 2003-07-31 16:32 Message: Logged In: NO I noticed the same problem with these characters (in my case they were "?" and "?""). Here is what I get in the shell, when trying to save from Idle: >>> Exception in Tkinter callback Traceback (most recent call last): File "C:\PROGRA~1\Python23\lib\lib-tk\Tkinter.py", line 1345, in __call__ return self.func(*args) File "C:\PROGRA~1\Python23\lib\idlelib\IOBinding.py", line 335, in save if self.writefile(self.filename): File "C:\PROGRA~1\Python23\lib\idlelib\IOBinding.py", line 370, in writefile chars = chars.replace("\n", self.eol_convention) UnicodeDecodeError: 'ascii' codec can't decode byte 0xc3 in position 365: ordinal not in range(128) ---------------------------------------------------------------------- You can respond by visiting: https://sourceforge.net/tracker/?func=detail&atid=109579&aid=778547&group_id=9579 From noreply at sourceforge.net Sun Nov 30 15:17:59 2003 From: noreply at sourceforge.net (SourceForge.net) Date: Sun Nov 30 15:18:03 2003 Subject: [Idle-dev] [ idlefork-Bugs-629985 ] Slow output Message-ID: Bugs item #629985, was opened at 2002-10-28 12:28 Message generated for change (Comment added) made by kbk You can respond by visiting: https://sourceforge.net/tracker/?func=detail&atid=109579&aid=629985&group_id=9579 Category: None Group: None Status: Closed >Resolution: Fixed Priority: 4 Submitted By: Guido van Rossum (gvanrossum) >Assigned to: Kurt B. Kaiser (kbk) Summary: Slow output Initial Comment: When a program writes many small amounts of text to sys.stdout, the RPC package really seems to slow things down. Perhaps the RPC mechanism can be extended with a special case for "no-return" method calls, where the client doesn't wait for a response and the server doesn't send one. (This should only be done for functions that aren't expected to return a value or raise an exception, of course.) ---------------------------------------------------------------------- >Comment By: Kurt B. Kaiser (kbk) Date: 2003-11-30 15:17 Message: Logged In: YES user_id=149084 Retrospective: This was greatly improved in May 2003 by tuning the signal() parameters. From my notes at the time, for future reference: "Problem was being caused by rpc.SocketIO.ioready() using a wait=None. This causes signal.signal to return immediately forcing re-schedule of PyShell.ModifiedInterpreter.poll_subprocess(), I think. Setting these wait()s to 50 ms helped a lot - got about 100% improvement from worst case." ---------------------------------------------------------------------- Comment By: Guido van Rossum (gvanrossum) Date: 2003-06-13 14:18 Message: Logged In: YES user_id=6380 I think this has been hashed to death; there are some mysteries, but it's no big deal any more. ---------------------------------------------------------------------- You can respond by visiting: https://sourceforge.net/tracker/?func=detail&atid=109579&aid=629985&group_id=9579 From noreply at sourceforge.net Sun Nov 30 15:26:39 2003 From: noreply at sourceforge.net (SourceForge.net) Date: Sun Nov 30 15:26:43 2003 Subject: [Idle-dev] [ idlefork-Bugs-834136 ] Subprocess hangs when using Tk with both pack and grid Message-ID: Bugs item #834136, was opened at 2003-11-01 09:59 Message generated for change (Comment added) made by kbk You can respond by visiting: https://sourceforge.net/tracker/?func=detail&atid=109579&aid=834136&group_id=9579 Category: None Group: None Status: Open >Resolution: Later >Priority: 3 Submitted By: Egon Frerich (efrerich) >Assigned to: Nobody/Anonymous (nobody) >Summary: Subprocess hangs when using Tk with both pack and grid Initial Comment: (IDLE 1.0 - Python 2.3 -Windows XP) I put a never ending loop into my python program. control-c didn't stop the Run-Command. Then I choosed the exit option in the File Menu of the Shell-Window. Then I h've got the message, that the program is still running and if I would like to kill the program. After saying "yes" (or "ok" IDLE disappeared. But I cannot start IDLE again. I have to reboot my system. When I shutdown the system there is a program "Menu Window" which I have to destroy. ---------------------------------------------------------------------- >Comment By: Kurt B. Kaiser (kbk) Date: 2003-11-30 15:26 Message: Logged In: YES user_id=149084 Thanks for the code. I may get to this someday :-) ---------------------------------------------------------------------- Comment By: Egon Frerich (efrerich) Date: 2003-11-18 05:15 Message: Logged In: YES user_id=40342 I have written two programs and upload them as one text file. After separating the program with only the pack-geometry manager works. The other program has some functions with calls to the grid manager. With this program you get 95% - 99% cpu-processing and you stop IDLE with ctrl-c. ---------------------------------------------------------------------- Comment By: Kurt B. Kaiser (kbk) Date: 2003-11-17 22:19 Message: Logged In: YES user_id=149084 Nonetheless, if you could post the code (or even better, a cut-down) which causes the error, it might be useful. There are some internal IDLE problems which can cause hangs. Otherwise, I'll go ahead and close this. ---------------------------------------------------------------------- Comment By: Egon Frerich (efrerich) Date: 2003-11-17 12:00 Message: Logged In: YES user_id=40342 Python program: actually I used Tkinter with two geometry manager (pack and grid) . Afterwards I read I shouldn't do this. Task Manager: Yes this works. If the geometry managers come to no end and I say Ctrl-C then nothing happens. Then if I kill the 99% cpu-process and afterwards push ctrl-c I get the KeyboardInterrupt in IDLE (and have not to reboot XP). Thanks Egon Frerich ---------------------------------------------------------------------- Comment By: Kurt B. Kaiser (kbk) Date: 2003-11-16 22:59 Message: Logged In: YES user_id=149084 Please post a copy of your program and any pertinent data so I can reproduce it. Ctrl-C works for me on the code I've tried. There are cases involving blocking I/O which can't be interrupted. It does sound like the main thread (which runs your code) is blocked. It should not be necessary to reboot XP. Use the Task Manager to kill the python subprocess, they are the (usually two threads) small ones. Kill the one which is getting 100% of the cpu first. If you do that, the GUI will re-spawn the subprocess. ---------------------------------------------------------------------- You can respond by visiting: https://sourceforge.net/tracker/?func=detail&atid=109579&aid=834136&group_id=9579 From noreply at sourceforge.net Sun Nov 30 16:51:38 2003 From: noreply at sourceforge.net (SourceForge.net) Date: Sun Nov 30 16:51:41 2003 Subject: [Idle-dev] [ idlefork-Bugs-629985 ] Slow output Message-ID: Bugs item #629985, was opened at 2002-10-28 12:28 Message generated for change (Comment added) made by gvanrossum You can respond by visiting: https://sourceforge.net/tracker/?func=detail&atid=109579&aid=629985&group_id=9579 Category: None Group: None Status: Closed Resolution: Fixed Priority: 4 Submitted By: Guido van Rossum (gvanrossum) Assigned to: Kurt B. Kaiser (kbk) Summary: Slow output Initial Comment: When a program writes many small amounts of text to sys.stdout, the RPC package really seems to slow things down. Perhaps the RPC mechanism can be extended with a special case for "no-return" method calls, where the client doesn't wait for a response and the server doesn't send one. (This should only be done for functions that aren't expected to return a value or raise an exception, of course.) ---------------------------------------------------------------------- >Comment By: Guido van Rossum (gvanrossum) Date: 2003-11-30 16:51 Message: Logged In: YES user_id=6380 I don't see any signal calls in the rpc code. Maybe you meant select.select? Also, wait=None should cause select() to wait forever (until I/O is possible), not return immediately. But yes, it does look like it was being invoked with wait=None from asyncreturn(), and that was switched to 0.05 on May 8th in rpc.py rev 1.23. (The CVS comment also mistakenly talks about signal instead of select. :-) In any case, thanks for the changes, the response time really *is* much better now. ---------------------------------------------------------------------- Comment By: Kurt B. Kaiser (kbk) Date: 2003-11-30 15:17 Message: Logged In: YES user_id=149084 Retrospective: This was greatly improved in May 2003 by tuning the signal() parameters. From my notes at the time, for future reference: "Problem was being caused by rpc.SocketIO.ioready() using a wait=None. This causes signal.signal to return immediately forcing re-schedule of PyShell.ModifiedInterpreter.poll_subprocess(), I think. Setting these wait()s to 50 ms helped a lot - got about 100% improvement from worst case." ---------------------------------------------------------------------- Comment By: Guido van Rossum (gvanrossum) Date: 2003-06-13 15:18 Message: Logged In: YES user_id=6380 I think this has been hashed to death; there are some mysteries, but it's no big deal any more. ---------------------------------------------------------------------- You can respond by visiting: https://sourceforge.net/tracker/?func=detail&atid=109579&aid=629985&group_id=9579