From d.love at dl.ac.uk Mon Jan 5 09:38:12 2004 From: d.love at dl.ac.uk (Dave Love) Date: Mon Jan 5 22:20:40 2004 Subject: [Python-mode] assorted fixes Message-ID: This patch against recent CVS fixes/adds a bunch of things, including: * Runtime use of cl, per Emacs rules -- actually, avoid it completely; * Proper syntactic fontification in Emacs 21; * Non-ASCII identifiers in Emacs 21; * Missing cases for Emacs; * Menu lossage in transient-mark-mode; * Char tables not defined in the approved way (so you can M-C-x them); * Hooks not local that need to be; * Hooks not removed when unloading; * Losing use of `py-shell-alist'; * Compilation warnings. This is mostly for Emacs 21, but as far as I can tell, it hasn't broken anything in XEmacs. Note that the licence is inconsistent with the use of GPL'ed code in bits copied from elsewhere. -------------- next part -------------- A non-text attachment was scrubbed... Name: not available Type: text/x-patch Size: 56310 bytes Desc: not available Url : http://mail.python.org/pipermail/python-mode/attachments/20040105/5e6f00ba/attachment-0001.bin From noreply at sourceforge.net Sun Jan 11 15:29:39 2004 From: noreply at sourceforge.net (SourceForge.net) Date: Sun Jan 11 15:29:43 2004 Subject: [Python-mode] [ python-mode-Patches-875046 ] py-tab-always-indent implementation Message-ID: Patches item #875046, was opened at 2004-01-11 15:29 Message generated for change (Tracker Item Submitted) made by Item Submitter You can respond by visiting: https://sourceforge.net/tracker/?func=detail&atid=581351&aid=875046&group_id=86916 Category: None Group: None Status: Open Resolution: None Priority: 5 Submitted By: Gary Feldman (garyfx) Assigned to: Nobody/Anonymous (nobody) Summary: py-tab-always-indent implementation Initial Comment: This patch address the issue I raised in http://groups.google.com/groups?hl=en&threadm=mrb2rvk73vu4jfebaelglq257n2p7q5gaf%404ax.com , specifically to provide behavior similar to the C mode c-tab-always-indent, because the previous implementation had no way of setting the tab key to insert tabs in the body of a """ string while keeping the automatic indentation behavior at the beginning of the line. I've attached a diff file for the differences against 4.49, but for ease of reading, and because the patch is so small, here are the changes: (defcustom py-tab-always-indent t "*Non-nil means TAB in Python mode should always reindent the current line, regardless of where in the line point is when the TAB command is used." :type 'boolean :group 'python) (defun py-indent-line (&optional arg) "Fix the indentation of the current line according to Python rules. With \[universal-argument] (programmatically, the optional argument ARG non-nil), ignore dedenting rules for block closing statements (e.g. return, raise, break, continue, pass) This function is normally bound to `indent-line-function' so \[indent-for-tab-command] will call it." (interactive "P") (let* ((ci (current-indentation)) (move-to-indentation-p (<= (current-column) ci)) (need (py-compute-indentation (not arg)))) ;; see if we need to dedent (if (py-outdent-p) (setq need (- need py-indent-offset))) (if (or py-tab-always-indent move-to-indentation-p) (progn (if (/= ci need) (save-excursion (beginning-of-line) (delete-horizontal-space) (indent-to need))) (if move-to-indentation-p (back-to-indentation))) (insert-tab)))) ---------------------------------------------------------------------- You can respond by visiting: https://sourceforge.net/tracker/?func=detail&atid=581351&aid=875046&group_id=86916 From bear at newworldkids.com Mon Jan 12 13:28:14 2004 From: bear at newworldkids.com (Tersina) Date: Mon Jan 12 05:35:50 2004 Subject: [Python-mode] when? Message-ID: <9ss456$c59ifo981a3b802$-df1@ezp.7j6jk7.4ch> New OFFSHORE PHARMACY - Not a single medical question asked, guaranteed or it's free. We have the cheapest drugs w/ overnight delivery all over the world. Valium, Xanaxm, Soma, Zyban, Super V1agara, etc. Lowest cost anywhere in the world. 128-bit encrypted site which means maximum confidentiality & no tracing. Executives, Doctor's, & business people have been using our site for years & we are proud to present it to you. See what were all about today. http://offshorepharm1.nepzzz.com/m001p/index.php?id=m0014 This communication is privileged and contains confidential information intended only for the person(s) to whom it is addressed. Any unauthorized disclosure, copying, other distribution of this communication or taking any action on its contents is strictly prohibited. If you have received this message in error, please notify us immediately OR remove yourself from our list if there is no interest in regards to our products. http://www.nepzzz.com/m001p/byebye.html ndhd dejetugpchinigdj From barry at python.org Mon Jan 12 11:03:31 2004 From: barry at python.org (Barry Warsaw) Date: Mon Jan 12 11:03:37 2004 Subject: [Python-mode] assorted fixes In-Reply-To: References: Message-ID: <1073923410.17326.78.camel@anthem> On Mon, 2004-01-05 at 09:38, Dave Love wrote: > This patch against recent CVS fixes/adds a bunch of things, including: Dave, if at all possible, can you get these changes into the SF patch manager? Big patches sent in email to this list have a high(er) probability of getting buried in people's inboxes. -Barry From skip at pobox.com Mon Jan 12 11:49:29 2004 From: skip at pobox.com (Skip Montanaro) Date: Mon Jan 12 11:49:43 2004 Subject: [Python-mode] assorted fixes In-Reply-To: <1073923410.17326.78.camel@anthem> References: <1073923410.17326.78.camel@anthem> Message-ID: <16386.53273.669158.94494@montanaro.dyndns.org> Barry> On Mon, 2004-01-05 at 09:38, Dave Love wrote: >> This patch against recent CVS fixes/adds a bunch of things, including: Barry> Dave, if at all possible, can you get these changes into the SF Barry> patch manager? Big patches sent in email to this list have a Barry> high(er) probability of getting buried in people's inboxes. Thanks for following up on this Barry. I must admit I was overwhelmed by the (size of the) suggested changes. Skip From barry at python.org Mon Jan 12 12:11:32 2004 From: barry at python.org (Barry Warsaw) Date: Mon Jan 12 12:11:46 2004 Subject: [Python-mode] assorted fixes In-Reply-To: <16386.53273.669158.94494@montanaro.dyndns.org> References: <1073923410.17326.78.camel@anthem> <16386.53273.669158.94494@montanaro.dyndns.org> Message-ID: <1073927491.17326.86.camel@anthem> On Mon, 2004-01-12 at 11:49, Skip Montanaro wrote: > Barry> On Mon, 2004-01-05 at 09:38, Dave Love wrote: > >> This patch against recent CVS fixes/adds a bunch of things, including: > > Barry> Dave, if at all possible, can you get these changes into the SF > Barry> patch manager? Big patches sent in email to this list have a > Barry> high(er) probability of getting buried in people's inboxes. > > Thanks for following up on this Barry. I must admit I was overwhelmed by > the (size of the) suggested changes. Oh yeah that reminds me. Dave, if possible, please split the patches up into manageable chunks. It's much much harder to deal with mondo patches, then with fixes to smaller self-contained problems. Thanks, -Barry From noreply at sourceforge.net Mon Jan 12 14:26:47 2004 From: noreply at sourceforge.net (SourceForge.net) Date: Mon Jan 12 14:26:51 2004 Subject: [Python-mode] [ python-mode-Patches-875596 ] various fixes Message-ID: Patches item #875596, was opened at 2004-01-12 19:26 Message generated for change (Tracker Item Submitted) made by Item Submitter You can respond by visiting: https://sourceforge.net/tracker/?func=detail&atid=581351&aid=875596&group_id=86916 Category: None Group: None Status: Open Resolution: None Priority: 5 Submitted By: Matthias Klose (doko) Assigned to: Nobody/Anonymous (nobody) Summary: various fixes Initial Comment: [forwarded from http://bugs.debian.org/226337] Dave Love writes: I made a load of changes to python-mode.el and realized that several of them fix (at least in Emacs 21) old Debian bugs: 160130, 209723, 164423, 164424 and 159628. Here's what I sent to python-mode in case it's useful. This patch against recent CVS fixes/adds a bunch of things, including: * Runtime use of cl, per Emacs rules -- actually, avoid it completely; * Proper syntactic fontification in Emacs 21; * Non-ASCII identifiers in Emacs 21; * Missing cases for Emacs; * Menu lossage in transient-mark-mode; * Char tables not defined in the approved way (so you can M-C-x them); * Hooks not local that need to be; * Hooks not removed when unloading; * Losing use of `py-shell-alist'; * Compilation warnings. This is mostly for Emacs 21, but as far as I can tell, it hasn't broken anything in XEmacs. Note that the licence is inconsistent with the use of GPL'ed code in bits copied from elsewhere. 2003-12-01 Dave Love * python-mode.el: Doc fixes. (custom, cl, compile): Don't require. (compile-internal): Autoload. (comint-last-input-end): Defvar when compiling. (py-char-classes-p): New. (python-font-lock-keywords, py-defun-start-re, py-class-start-re) (py-pdbtrack-stack-entry-regexp, py-imenu-class-regexp) (py-imenu-method-regexp, py-forward-into-nomenclature): Use it. (py-quote-syntax, py-font-lock-syntactic-keywords) (py-mark-active, py-outline-level, python-mode-unload-hook): New. (py-keep-region-active, py-electric-delete): Avoid compilation warning in Emacs. (py-highlight-line, py-mouseto-exception): Add Emacs case. (py-in-literal): Define separate cases for Emacs and XEmacs, and avoid warning. Simplify Emacs case. (py-fast-in-literal): Deleted. (py-which-shell, py-which-args, py-which-bufname): Move before use. (python-mode): Set parse-sexp-lookup-properties, outline-regexp, outline-level, open-paren-in-column-0-is-defun-start. Modify font-lock-defaults value. (py-pdbtrack-track-stack-file): Bind target_buffer. (py-pdbtrack-grub-for-buffer): Bind buf, not curbuf. (py-output-buffer): defvar, not defconst. (py-help-at-point): Avoid `search'. (py-temp-directory): Maybe use temporary-file-directory. (py-menu, py-shift-region-left, py-shift-region-right): Fix use of `(mark)'. (py-beginning-of-def-or-class): Re-run if it lands in a string. (py-goto-beginning-of-tqs): Don't lose if delim is t. (py-shell-alist): Don't quote cdrs. (py-mode-map, py-shell-map, py-mode-output-map) (py-mode-syntax-table, py-dotted-expression-syntax-table): Define inside defvar. (py-imenu-create-index-engine): Avoid `first', `second'. (py-choose-shell-by-shebang): Use py-shell-alist correctly. (py-shell): Only add to comint-output-filter-functions locally. Set indent-line-function. (py-execute-region): Fix choosing shell. (py-mark-block): Activate mark. (py-python-version): New. Use it with info-lookup-maybe-add-help. (debug-ignored-errors): Add errors used here. (py-shell-map): Don't bind tab. (py-pychecker-run): Use read-shell-command conditionally. (py-mode-output-map): Maybe bind mouse-2. Use suppress-keymap. ---------------------------------------------------------------------- You can respond by visiting: https://sourceforge.net/tracker/?func=detail&atid=581351&aid=875596&group_id=86916 From mail at peterbe.com Wed Jan 14 09:25:12 2004 From: mail at peterbe.com (Peter Bengtsson) Date: Wed Jan 14 09:26:02 2004 Subject: [Python-mode] Bug or intentional Message-ID: <40055148.6030204@peterbe.com> I've been using jed a lot recently but it didn't work to skip words like C-f or C-b, so I decided to switch to emacs with python-mode. Everything worked fine from wonderful instructions on http://www.python.org/emacs/python-mode/installation.html However, I note when opening a python file that the colour coding was missing something. Keywords such as None, True, False didn't get colourcoded. Would it be possible to colour code these things in the next release? ...please. Keep up the good work! Peter -- Peter Bengtsson, http://www.peterbe.com From barry at python.org Wed Jan 14 09:34:50 2004 From: barry at python.org (Barry Warsaw) Date: Wed Jan 14 09:34:55 2004 Subject: [Python-mode] Bug or intentional In-Reply-To: <40055148.6030204@peterbe.com> References: <40055148.6030204@peterbe.com> Message-ID: <1074090889.22861.2.camel@anthem> On Wed, 2004-01-14 at 09:25, Peter Bengtsson wrote: > I've been using jed a lot recently but it didn't work to skip words like > C-f or C-b, so I decided to switch to emacs with python-mode. > Everything worked fine from wonderful instructions on > http://www.python.org/emacs/python-mode/installation.html > > However, I note when opening a python file that the colour coding was > missing something. Keywords such as None, True, False didn't get > colourcoded. > > Would it be possible to colour code these things in the next release? > ...please. > > Keep up the good work! > Peter Are you sure you're using the latest version? These 'pseudo-keywords' have been fontlocked since at least python-mode 4.12 (the latest version in cvs is 4.49). It's also possible python-mode is font-locking them, but the face is the same as the default face so you're not actually seeing anything different. Finally, while I use XEmacs and can guarantee that None, True, False (and many others) are fontlocked, I can't guarantee that that all works in FSF Emacs, since I don't use it. -Barry From LAUIKCFO at msn.com Sat Jan 24 08:07:15 2004 From: LAUIKCFO at msn.com (Ronald Quinones) Date: Fri Jan 23 18:12:03 2004 Subject: [Python-mode] proximate july allusion cornmeal brouhaha disyllable assiduous ferromagnetism geopolitic josephus pageantry bezel collage anthropomorphic enid melville cheerleader knit nucleant osmium celebrity conifer mustang omega urania rater diffuse consist inmate sentiment barren chic coliseum Message-ID: An HTML attachment was scrubbed... URL: http://mail.python.org/pipermail/python-mode/attachments/20040124/6b9b808b/attachment.html From cmg at dok.org Tue Jan 27 16:15:50 2004 From: cmg at dok.org (Chris Green) Date: Tue Jan 27 16:15:55 2004 Subject: [Python-mode] python-mode 3.105; M-q comment action Message-ID: Dear Barry, One function I love to use with source code editing is fill-paragraph-or-region (default bound to M-q). I have one slight enhancement request for python mode. for i in range(5): # this comment spans two lines because it's reasonably long so it just does print i With the cursor somewhere in the comment, M-q would produce: for i in range(5): # this comment spans two lines because it's reasonably # long so it just does print i instead of for i in range(5): # this comment spans two lines because it's reasonably long so it just does print i A similar request affects doc strings: def f(a): "this is a doc string" when M-q is in the doc string produces def f(a): "this is a doc string" def a(f): """this is a doc string that is really long and produces a multiline comment""" instead of def a(f): """this is a doc string that is really long and produces a multiline comment""" OR """ this is a doc string that is really long and produces a multiline comment """ If there is a line between the comments and code, both of these things have reasonable behavior. Thanks for all the work on python-mode! Cheers, Chris Emacs : XEmacs 21.4 (patch 14) "Reasonable Discussion" [Lucid] (i686-pc-linux) of Fri Nov 21 2003 on localhost Package: python-mode 3.105 From skip at pobox.com Tue Jan 27 16:25:23 2004 From: skip at pobox.com (Skip Montanaro) Date: Tue Jan 27 16:29:22 2004 Subject: [Python-mode] python-mode 3.105; M-q comment action In-Reply-To: References: Message-ID: <16406.55107.980427.981605@montanaro.dyndns.org> Chris> One function I love to use with source code editing is Chris> fill-paragraph-or-region (default bound to M-q). I have one Chris> slight enhancement request for python mode. These two enhancements are in the most recent version (4.48). What version are you using? Check the py-version variable's value to find out. -- Skip Montanaro Got gigs? http://www.musi-cal.com/submit.html Got spam? http://spambayes.sf.net/ skip@pobox.com From cmg at dok.org Tue Jan 27 16:41:37 2004 From: cmg at dok.org (Chris Green) Date: Tue Jan 27 16:41:48 2004 Subject: [Python-mode] python-mode 3.105; M-q comment action In-Reply-To: <16406.55107.980427.981605@montanaro.dyndns.org> (Skip Montanaro's message of "Tue, 27 Jan 2004 15:25:23 -0600") References: <16406.55107.980427.981605@montanaro.dyndns.org> Message-ID: Skip Montanaro writes: > Chris> One function I love to use with source code editing is > Chris> fill-paragraph-or-region (default bound to M-q). I have one > Chris> slight enhancement request for python mode. > > These two enhancements are in the most recent version (4.48). What version > are you using? Check the py-version variable's value to find out. > Ahh 3.105 -- ancient.. Thanks! -- Chris Green "I'm beginning to think that my router may be confused." From cmg at dok.org Tue Jan 27 16:50:45 2004 From: cmg at dok.org (Chris Green) Date: Tue Jan 27 16:50:51 2004 Subject: [Python-mode] python-mode 3.105; M-q comment action In-Reply-To: <16406.55107.980427.981605@montanaro.dyndns.org> (Skip Montanaro's message of "Tue, 27 Jan 2004 15:25:23 -0600") References: <16406.55107.980427.981605@montanaro.dyndns.org> Message-ID: Skip Montanaro writes: > Chris> One function I love to use with source code editing is > Chris> fill-paragraph-or-region (default bound to M-q). I have one > Chris> slight enhancement request for python mode. > > These two enhancements are in the most recent version (4.48). What version > are you using? Check the py-version variable's value to find out. Said thanks too quickly: `py-version' is a variable declared in Lisp. -- loaded from "python-mode" Value: "4.6" if __name__=='__main__': # this is a very long comment -- this might take up a few lines of space if I'm not careful s = stuff() M-q on the comment results in: if __name__=='__main__': # this is a very long comment -- this might take up a few lines of space if I'm not careful s = stuff() -- Chris Green Chicken's thinkin' From skip at pobox.com Tue Jan 27 20:31:41 2004 From: skip at pobox.com (Skip Montanaro) Date: Wed Jan 28 00:09:04 2004 Subject: [Python-mode] python-mode 3.105; M-q comment action In-Reply-To: References: <16406.55107.980427.981605@montanaro.dyndns.org> Message-ID: <16407.4349.868635.452506@montanaro.dyndns.org> >> These two enhancements are in the most recent version (4.48). What >> version are you using? Check the py-version variable's value to find >> out. Chris> Said thanks too quickly: Chris> `py-version' is a variable declared in Lisp. Chris> -- loaded from "python-mode" Chris> Value: "4.6" 6 < 48 last time I checked... ;-) Chris> if __name__=='__main__': Chris> # this is a very long comment -- this might take up a few lines of space if I'm not careful Chris> s = stuff() Chris> M-q on the comment results in: Chris> if __name__=='__main__': # this is a very long comment -- this might Chris> take up a few lines of space if I'm not careful s = stuff() Not too surprising. I am not on-net at the moment, so I can't check the precise version in which this feature was added, but I checked in the change (to the Python version before the python-mode probject was started), and I can verify that 4.48 does as we'd all like: if __name__=='__main__': # this is a very long comment -- this might take up a few lines of space # if I'm not careful s = stuff() Skip From barry at python.org Wed Jan 28 07:27:41 2004 From: barry at python.org (Barry Warsaw) Date: Wed Jan 28 07:27:46 2004 Subject: [Python-mode] python-mode 3.105; M-q comment action In-Reply-To: <16407.4349.868635.452506@montanaro.dyndns.org> References: <16406.55107.980427.981605@montanaro.dyndns.org> <16407.4349.868635.452506@montanaro.dyndns.org> Message-ID: <1075292861.18907.2.camel@anthem> On Tue, 2004-01-27 at 20:31, Skip Montanaro wrote: > 48 last time I checked... ;-) Actually, 4.49 is the latest version in cvs. I believe the filling extensions were added in 4.29. > Not too surprising. I am not on-net at the moment, so I can't check the > precise version in which this feature was added, but I checked in the change > (to the Python version before the python-mode probject was started), and I > can verify that 4.48 does as we'd all like: > > if __name__=='__main__': > # this is a very long comment -- this might take up a few lines of space > # if I'm not careful > s = stuff() Yes, this works fine in 4.49. But for some reason, this doesn't: Before: def f(a): """This is a docstring that is really long and produces a multiline comment if you're not careful.""" a = 1 (place cursor on first open quote, hit M-q) After: def f(a): """This is a docstring that is really long and produces a multiline comment if you're not careful.""" a = 1 I could have sworn this worked at one time, but it clearly doesn't now (for me at least). I don't have time right now to cruise back through cvs history to see if I was imagining things, or this has broken sometime between 4.29 and 4.49. -Barry From bh at intevation.de Wed Jan 28 08:15:08 2004 From: bh at intevation.de (Bernhard Herzog) Date: Wed Jan 28 08:15:34 2004 Subject: [Python-mode] python-mode 3.105; M-q comment action In-Reply-To: <1075292861.18907.2.camel@anthem> (Barry Warsaw's message of "Wed, 28 Jan 2004 07:27:41 -0500") References: <16406.55107.980427.981605@montanaro.dyndns.org> <16407.4349.868635.452506@montanaro.dyndns.org> <1075292861.18907.2.camel@anthem> Message-ID: <6qn088xlib.fsf@salmakis.intevation.de> Barry Warsaw writes: > Yes, this works fine in 4.49. But for some reason, this doesn't: > > Before: > > def f(a): > """This is a docstring that is really long and produces a multiline comment if you're not careful.""" > a = 1 > > (place cursor on first open quote, hit M-q) > > After: > > def f(a): > """This is a docstring that is really long and produces a multiline > comment if you're not careful.""" a = 1 I think that never worked. The code is quite simple minded. It only tries to fill a string if the cursor is inside the string. Placing it on the second quote of the opening triple quote works, for instance. If the cursor is on the third it again doesn't work because Emacs doesn't grok triple quoted strings (at least not in the python-mode I'm currently using, 4.48). There's a similar problem if the triple quoted string contains characters of he same quote type as the triple quote. Bernhard -- Intevation GmbH http://intevation.de/ Skencil http://sketch.sourceforge.net/ Thuban http://thuban.intevation.org/ From barry at python.org Wed Jan 28 08:47:47 2004 From: barry at python.org (Barry Warsaw) Date: Wed Jan 28 08:47:52 2004 Subject: [Python-mode] python-mode 3.105; M-q comment action In-Reply-To: <6qn088xlib.fsf@salmakis.intevation.de> References: <16406.55107.980427.981605@montanaro.dyndns.org> <16407.4349.868635.452506@montanaro.dyndns.org> <1075292861.18907.2.camel@anthem> <6qn088xlib.fsf@salmakis.intevation.de> Message-ID: <1075297666.18907.32.camel@anthem> On Wed, 2004-01-28 at 08:15, Bernhard Herzog wrote: > I think that never worked. The code is quite simple minded. It only > tries to fill a string if the cursor is inside the string. Placing it > on the second quote of the opening triple quote works, for instance. If > the cursor is on the third it again doesn't work because Emacs doesn't > grok triple quoted strings (at least not in the python-mode I'm > currently using, 4.48). There's a similar problem if the triple quoted > string contains characters of he same quote type as the triple quote. Ah, you're right, it works if you're inside the string. Here's a crazy idea for anyone with a little spare hacking time. Start by saving-excursion. Check to see if you're in the line's indentation, and if so, do a back-to-indentation. Then, if py-in-literal returns nil, do a forward-word and check if py-in-literal == string. If so, fill the paragraph from there, otherwise fill it from the original position. -Barry From skip at pobox.com Wed Jan 28 10:25:28 2004 From: skip at pobox.com (Skip Montanaro) Date: Wed Jan 28 10:26:38 2004 Subject: [Python-mode] python-mode 3.105; M-q comment action In-Reply-To: <6qn088xlib.fsf@salmakis.intevation.de> References: <16406.55107.980427.981605@montanaro.dyndns.org> <16407.4349.868635.452506@montanaro.dyndns.org> <1075292861.18907.2.camel@anthem> <6qn088xlib.fsf@salmakis.intevation.de> Message-ID: <16407.54376.973660.569438@montanaro.dyndns.org> >> (place cursor on first open quote, hit M-q) [fails] ... Bernhard> I think that never worked. The code is quite simple minded. Bernhard> It only tries to fill a string if the cursor is inside the Bernhard> string. Placing it on the second quote of the opening triple Bernhard> quote works, for instance. If the cursor is on the third it Bernhard> again doesn't work because Emacs doesn't grok triple quoted Bernhard> strings (at least not in the python-mode I'm currently using, Bernhard> 4.48). There's a similar problem if the triple quoted string Bernhard> contains characters of he same quote type as the triple quote. Maybe a not-too-much less simple-minded job would be to extract the string within the triple quotes, stuff it in a separate text-mode buffer, select it all, set the fill column appropriately, fill it, then stuff the result back into the right place. Skip From noreply at sourceforge.net Wed Jan 28 10:55:40 2004 From: noreply at sourceforge.net (SourceForge.net) Date: Wed Jan 28 10:55:48 2004 Subject: [Python-mode] [ python-mode-Patches-886302 ] better filling near (but not in) strings Message-ID: Patches item #886302, was opened at 2004-01-28 10:55 Message generated for change (Tracker Item Submitted) made by Item Submitter You can respond by visiting: https://sourceforge.net/tracker/?func=detail&atid=581351&aid=886302&group_id=86916 Category: None Group: None Status: Open Resolution: None Priority: 5 Submitted By: Barry A. Warsaw (bwarsaw) Assigned to: Nobody/Anonymous (nobody) Summary: better filling near (but not in) strings Initial Comment: Filling long docstrings works pretty well when the cursor is inside the string, but it doesn't work when the cursor is in the line's indentation, or after the closing quote. This patch makes things work better for me. ---------------------------------------------------------------------- You can respond by visiting: https://sourceforge.net/tracker/?func=detail&atid=581351&aid=886302&group_id=86916 From noreply at sourceforge.net Wed Jan 28 11:12:24 2004 From: noreply at sourceforge.net (SourceForge.net) Date: Wed Jan 28 11:23:30 2004 Subject: [Python-mode] [ python-mode-Patches-886302 ] better filling near (but not in) strings Message-ID: Patches item #886302, was opened at 2004-01-28 09:55 Message generated for change (Comment added) made by montanaro You can respond by visiting: https://sourceforge.net/tracker/?func=detail&atid=581351&aid=886302&group_id=86916 Category: None Group: None Status: Open Resolution: None Priority: 5 Submitted By: Barry A. Warsaw (bwarsaw) Assigned to: Nobody/Anonymous (nobody) Summary: better filling near (but not in) strings Initial Comment: Filling long docstrings works pretty well when the cursor is inside the string, but it doesn't work when the cursor is in the line's indentation, or after the closing quote. This patch makes things work better for me. ---------------------------------------------------------------------- >Comment By: Skip Montanaro (montanaro) Date: 2004-01-28 10:12 Message: Logged In: YES user_id=44345 It doesn't solve the apostrophe-in-''' problem, but this is demonstrably better than before, so commit it. ;-) ---------------------------------------------------------------------- You can respond by visiting: https://sourceforge.net/tracker/?func=detail&atid=581351&aid=886302&group_id=86916 From noreply at sourceforge.net Wed Jan 28 11:27:52 2004 From: noreply at sourceforge.net (SourceForge.net) Date: Wed Jan 28 11:28:17 2004 Subject: [Python-mode] [ python-mode-Patches-875596 ] various fixes Message-ID: Patches item #875596, was opened at 2004-01-12 13:26 Message generated for change (Comment added) made by montanaro You can respond by visiting: https://sourceforge.net/tracker/?func=detail&atid=581351&aid=875596&group_id=86916 Category: None Group: None Status: Open Resolution: None Priority: 5 Submitted By: Matthias Klose (doko) Assigned to: Nobody/Anonymous (nobody) Summary: various fixes Initial Comment: [forwarded from http://bugs.debian.org/226337] Dave Love writes: I made a load of changes to python-mode.el and realized that several of them fix (at least in Emacs 21) old Debian bugs: 160130, 209723, 164423, 164424 and 159628. Here's what I sent to python-mode in case it's useful. This patch against recent CVS fixes/adds a bunch of things, including: * Runtime use of cl, per Emacs rules -- actually, avoid it completely; * Proper syntactic fontification in Emacs 21; * Non-ASCII identifiers in Emacs 21; * Missing cases for Emacs; * Menu lossage in transient-mark-mode; * Char tables not defined in the approved way (so you can M-C-x them); * Hooks not local that need to be; * Hooks not removed when unloading; * Losing use of `py-shell-alist'; * Compilation warnings. This is mostly for Emacs 21, but as far as I can tell, it hasn't broken anything in XEmacs. Note that the licence is inconsistent with the use of GPL'ed code in bits copied from elsewhere. 2003-12-01 Dave Love * python-mode.el: Doc fixes. (custom, cl, compile): Don't require. (compile-internal): Autoload. (comint-last-input-end): Defvar when compiling. (py-char-classes-p): New. (python-font-lock-keywords, py-defun-start-re, py-class-start-re) (py-pdbtrack-stack-entry-regexp, py-imenu-class-regexp) (py-imenu-method-regexp, py-forward-into-nomenclature): Use it. (py-quote-syntax, py-font-lock-syntactic-keywords) (py-mark-active, py-outline-level, python-mode-unload-hook): New. (py-keep-region-active, py-electric-delete): Avoid compilation warning in Emacs. (py-highlight-line, py-mouseto-exception): Add Emacs case. (py-in-literal): Define separate cases for Emacs and XEmacs, and avoid warning. Simplify Emacs case. (py-fast-in-literal): Deleted. (py-which-shell, py-which-args, py-which-bufname): Move before use. (python-mode): Set parse-sexp-lookup-properties, outline-regexp, outline-level, open-paren-in-column-0-is-defun-start. Modify font-lock-defaults value. (py-pdbtrack-track-stack-file): Bind target_buffer. (py-pdbtrack-grub-for-buffer): Bind buf, not curbuf. (py-output-buffer): defvar, not defconst. (py-help-at-point): Avoid `search'. (py-temp-directory): Maybe use temporary-file-directory. (py-menu, py-shift-region-left, py-shift-region-right): Fix use of `(mark)'. (py-beginning-of-def-or-class): Re-run if it lands in a string. (py-goto-beginning-of-tqs): Don't lose if delim is t. (py-shell-alist): Don't quote cdrs. (py-mode-map, py-shell-map, py-mode-output-map) (py-mode-syntax-table, py-dotted-expression-syntax-table): Define inside defvar. (py-imenu-create-index-engine): Avoid `first', `second'. (py-choose-shell-by-shebang): Use py-shell-alist correctly. (py-shell): Only add to comint-output-filter-functions locally. Set indent-line-function. (py-execute-region): Fix choosing shell. (py-mark-block): Activate mark. (py-python-version): New. Use it with info-lookup-maybe-add-help. (debug-ignored-errors): Add errors used here. (py-shell-map): Don't bind tab. (py-pychecker-run): Use read-shell-command conditionally. (py-mode-output-map): Maybe bind mouse-2. Use suppress-keymap. ---------------------------------------------------------------------- >Comment By: Skip Montanaro (montanaro) Date: 2004-01-28 10:27 Message: Logged In: YES user_id=44345 What version of python-mode.el was this patch made against? Applying it with patch fails pretty miserably. The reject file is 490 lines and it looks like it will be almost impossible for me to sort out. ---------------------------------------------------------------------- You can respond by visiting: https://sourceforge.net/tracker/?func=detail&atid=581351&aid=875596&group_id=86916 From barry at python.org Wed Jan 28 11:43:24 2004 From: barry at python.org (Barry Warsaw) Date: Wed Jan 28 11:43:32 2004 Subject: [Python-mode] python-mode 3.105; M-q comment action In-Reply-To: <16407.54376.973660.569438@montanaro.dyndns.org> References: <16406.55107.980427.981605@montanaro.dyndns.org> <16407.4349.868635.452506@montanaro.dyndns.org> <1075292861.18907.2.camel@anthem> <6qn088xlib.fsf@salmakis.intevation.de> <16407.54376.973660.569438@montanaro.dyndns.org> Message-ID: <1075308204.2635.13.camel@geddy> On Wed, 2004-01-28 at 10:25, Skip Montanaro wrote: > Maybe a not-too-much less simple-minded job would be to extract the string > within the triple quotes, stuff it in a separate text-mode buffer, select it > all, set the fill column appropriately, fill it, then stuff the result back > into the right place. Turned out to be easier than I thought (I think :). Quick hack job: http://sourceforge.net/tracker/index.php?func=detail&aid=886302&group_id=86916&atid=581351 Let me know if it works for you and I'll commit it. -Barry From noreply at sourceforge.net Wed Jan 28 11:45:48 2004 From: noreply at sourceforge.net (SourceForge.net) Date: Wed Jan 28 11:53:58 2004 Subject: [Python-mode] [ python-mode-Patches-886302 ] better filling near (but not in) strings Message-ID: Patches item #886302, was opened at 2004-01-28 10:55 Message generated for change (Comment added) made by bwarsaw You can respond by visiting: https://sourceforge.net/tracker/?func=detail&atid=581351&aid=886302&group_id=86916 Category: None Group: None >Status: Closed >Resolution: Accepted Priority: 5 Submitted By: Barry A. Warsaw (bwarsaw) Assigned to: Nobody/Anonymous (nobody) Summary: better filling near (but not in) strings Initial Comment: Filling long docstrings works pretty well when the cursor is inside the string, but it doesn't work when the cursor is in the line's indentation, or after the closing quote. This patch makes things work better for me. ---------------------------------------------------------------------- >Comment By: Barry A. Warsaw (bwarsaw) Date: 2004-01-28 11:45 Message: Logged In: YES user_id=12800 I don't think anything can solve the apostophe-in-''' problem since that's basically just inherent in the syntax-table implementation. But I'm glad this works for you so I'll go ahead and commit it. ---------------------------------------------------------------------- Comment By: Skip Montanaro (montanaro) Date: 2004-01-28 11:12 Message: Logged In: YES user_id=44345 It doesn't solve the apostrophe-in-''' problem, but this is demonstrably better than before, so commit it. ;-) ---------------------------------------------------------------------- You can respond by visiting: https://sourceforge.net/tracker/?func=detail&atid=581351&aid=886302&group_id=86916 From cmg at dok.org Wed Jan 28 14:33:55 2004 From: cmg at dok.org (Chris Green) Date: Wed Jan 28 14:34:12 2004 Subject: [Python-mode] python-mode 3.105; M-q comment action In-Reply-To: <1075308204.2635.13.camel@geddy> (Barry Warsaw's message of "Wed, 28 Jan 2004 11:43:24 -0500") References: <16406.55107.980427.981605@montanaro.dyndns.org> <16407.4349.868635.452506@montanaro.dyndns.org> <1075292861.18907.2.camel@anthem> <6qn088xlib.fsf@salmakis.intevation.de> <16407.54376.973660.569438@montanaro.dyndns.org> <1075308204.2635.13.camel@geddy> Message-ID: Barry Warsaw writes: > On Wed, 2004-01-28 at 10:25, Skip Montanaro wrote: > >> Maybe a not-too-much less simple-minded job would be to extract the string >> within the triple quotes, stuff it in a separate text-mode buffer, select it >> all, set the fill column appropriately, fill it, then stuff the result back >> into the right place. > > Turned out to be easier than I thought (I think :). Quick hack job: > > http://sourceforge.net/tracker/index.php?func=detail&aid=886302&group_id=86916&atid=581351 > > Let me know if it works for you and I'll commit it. works great for me! Thanks, Chris (gosh I wish I had mailed a request earlier :-)) -- Chris Green "Yeah, but you're taking the universe out of context." From barry at python.org Wed Jan 28 15:10:19 2004 From: barry at python.org (Barry Warsaw) Date: Wed Jan 28 15:10:22 2004 Subject: [Python-mode] python-mode 3.105; M-q comment action In-Reply-To: References: <16406.55107.980427.981605@montanaro.dyndns.org> <16407.4349.868635.452506@montanaro.dyndns.org> <1075292861.18907.2.camel@anthem> <6qn088xlib.fsf@salmakis.intevation.de> <16407.54376.973660.569438@montanaro.dyndns.org> <1075308204.2635.13.camel@geddy> Message-ID: <1075320618.14195.87.camel@geddy> On Wed, 2004-01-28 at 14:33, Chris Green wrote: > > Let me know if it works for you and I'll commit it. > > works great for me! > > Thanks, > Chris (gosh I wish I had mailed a request earlier :-)) It's been bugging me for a long time. Sometimes it takes just the right prodding, at the right time, to get stuff fixed. Thanks for the poke in the control pinkie! It's committed now. -Barry From acme at otakumail.com Wed Jan 28 15:49:40 2004 From: acme at otakumail.com (Kayaking O. Gill) Date: Wed Jan 28 15:52:09 2004 Subject: [Python-mode] vUtRW Python, 9l95Y9B Message-ID: <100101c3e5e0$7e509c18$b2499806@otakumail.com> An HTML attachment was scrubbed... URL: http://mail.python.org/pipermail/python-mode/attachments/20040128/32e06005/attachment.html -------------- next part -------------- A non-text attachment was scrubbed... Name: tel.gif Type: image/gif Size: 436 bytes Desc: not available Url : http://mail.python.org/pipermail/python-mode/attachments/20040128/32e06005/tel.gif From skip at pobox.com Wed Jan 28 16:06:31 2004 From: skip at pobox.com (Skip Montanaro) Date: Wed Jan 28 16:07:39 2004 Subject: [Python-mode] Re: [ python-mode-Patches-875596 ] various fixes In-Reply-To: <16408.8386.360925.107725@gargle.gargle.HOWL> References: <16408.8386.360925.107725@gargle.gargle.HOWL> Message-ID: <16408.9303.927495.652196@montanaro.dyndns.org> (cc'ing python-mode so this thread is slightly less emphemeral...) Matthias> SF is currently unreachable, so here the response directly ... Yeah, it's been a problem lately. Matthias> the patch is taken against the python2.3 branch. I now see one Matthias> chunk (#14) failing. Dave, maybe you could update the patch? Any chance it can be broken into pieces? One problem in particular is that we copy python-mode.el over to the Python CVS repository every now and again. That can't happen if it has a GPL license. At the very least it would be very helpful to separate the patch into GPL and non-GPL bits. Skip Matthias> Matthias Matthias> SourceForge.net writes: >> Patches item #875596, was opened at 2004-01-12 13:26 >> Message generated for change (Comment added) made by montanaro >> You can respond by visiting: >> https://sourceforge.net/tracker/?func=detail&atid=581351&aid=875596&group_id=86916 >> >> Category: None >> Group: None >> Status: Open >> Resolution: None >> Priority: 5 >> Submitted By: Matthias Klose (doko) >> Assigned to: Nobody/Anonymous (nobody) >> Summary: various fixes >> >> Initial Comment: >> [forwarded from http://bugs.debian.org/226337] >> >> Dave Love writes: >> >> I made a load of changes to python-mode.el and realized >> that several >> of them fix (at least in Emacs 21) old Debian bugs: >> 160130, 209723, >> 164423, 164424 and 159628. Here's what I sent to >> python-mode in case >> it's useful. >> >> This patch against recent CVS fixes/adds a bunch of >> things, including: Matthias> [...] >> ---------------------------------------------------------------------- >> >> >Comment By: Skip Montanaro (montanaro) >> Date: 2004-01-28 10:27 >> >> Message: >> Logged In: YES >> user_id=44345 >> >> What version of python-mode.el was this patch made against? >> Applying it with patch fails pretty miserably. The reject file is >> 490 lines and it looks like it will be almost impossible for me >> to sort out. >> >> >> >> ---------------------------------------------------------------------- >> >> You can respond by visiting: >> https://sourceforge.net/tracker/?func=detail&atid=581351&aid=875596&group_id=86916 From ulaymond at daydreamer.com Wed Jan 28 21:38:28 2004 From: ulaymond at daydreamer.com (Loraine Grove) Date: Wed Jan 28 18:35:57 2004 Subject: [Python-mode] Fast generic solution better than VIAAGRRA_1 Message-ID: OFFSHORE PHARMACY WITH NO QUESTIONS! Super Viagra - CIALIS is Here Dubbed "The Weekend Pill" * LONGER LIFE Up to 36 hours compared to 4 hours for viagra * ACTS FASTER from as little as 15 minutes compared to 60 minutes for viagra * BEST SEX EVER solid erection and only whenever you need it. With cialis YOU are in control "Cialis works in 15 minutes and lasts for 36 hours giving you strong healthy erections whenever you want or need them!" NO QUESTIONS. JUST PAY & WE SHIP. COMPLETE PRIVACY & CONFIDENTIATLITY. 128-bit encrypted website for maximum security. We also have an assortment of other drugs such as soma, valium, xanax, meridia, etc. http://deletion.instrhh.com/m001p/index.php?id=m0015 No more of this sort of material. Honoured in 24-48 hours. http://instrhh.com/m001p/byebye.html ravish steeplebush saponify turmoil dissuade conakry ascetic neutral pontificate copybook grid ancestral 3 5