Re: In defence of 80-char lines

2013-04-04 Thread Steven D'Aprano
On Wed, 03 Apr 2013 21:32:33 -0700, llanitedave wrote: I also tend to prefer a maximum between 110 and 120 characters. I find continuation lines confusing, and when you use some third-party tools, such as wxPython, for example, the boilerplate code leads to some long lines. Excessive

Re: In defence of 80-char lines

2013-04-04 Thread Peter Otten
llanitedave wrote: I also tend to prefer a maximum between 110 and 120 characters. I find continuation lines confusing, and when you use some third-party tools, such as wxPython, for example, the boilerplate code leads to some long lines. I would hate to have to break up this line, for

Re: In defence of 80-char lines

2013-04-04 Thread gregor
Am Wed, 3 Apr 2013 21:32:33 -0700 (PDT) schrieb llanitedave llanited...@veawb.coop: I would hate to have to break up this line, for instance: self.mainLabel.SetFont(wx.Font(12, wx.DEFAULT, wx.NORMAL, wx.BOLD, faceName = FreeSans)) I think this is much more readable:

Re: In defence of 80-char lines

2013-04-04 Thread Rui Maciel
lines to 80 characters. (Strictly speaking, 79 characters.) Here is a good defence of 80 char lines: http://wrongsideofmemphis.com/2013/03/25/80-chars-per-line-is-great/ The now arbitrary 80-column limit is a remnant of the limitations built into ancient terminals. Why not let the text

Re: In defence of 80-char lines

2013-04-04 Thread Tim Chase
On 2013-04-04 08:43, Peter Otten wrote: llanitedave wrote: self.mainLabel.SetFont(wx.Font(12, wx.DEFAULT, wx.NORMAL, wx.BOLD, faceName = FreeSans)) I think I would prefer labelfont = wx.Font( pointSize=12, style=wx.DEFAULT, family=wx.NORMAL, weight=wx.BOLD,

Re: In defence of 80-char lines

2013-04-04 Thread Roy Smith
In article c338b844-e9ce-46a7-9daf-203743723...@googlegroups.com, llanitedave llanited...@veawb.coop wrote: I would hate to have to break up this line, for instance: self.mainLabel.SetFont(wx.Font(12, wx.DEFAULT, wx.NORMAL, wx.BOLD, faceName = FreeSans)) I would write that as some

Re: In defence of 80-char lines

2013-04-04 Thread Jason Swails
, 79 characters.) Here is a good defence of 80 char lines: http://wrongsideofmemphis.com/2013/03/25/80-chars-per-line-is-great/ Personally, I try my best to keep all lines at 80 character max (80 + newline, not 79). In addition to liking my 84-character-width gvim windows (to allow a little

Re: In defence of 80-char lines

2013-04-04 Thread Jason Swails
On Thu, Apr 4, 2013 at 7:09 AM, Tim Chase python.l...@tim.thechases.comwrote: On 2013-04-04 08:43, Peter Otten wrote: llanitedave wrote: self.mainLabel.SetFont(wx.Font(12, wx.DEFAULT, wx.NORMAL, wx.BOLD, faceName = FreeSans)) I think I would prefer labelfont = wx.Font(

Re: In defence of 80-char lines

2013-04-04 Thread Roy Smith
In article mailman.96.1365077619.3114.python-l...@python.org, Jason Swails jason.swa...@gmail.com wrote: The only time I regularly break my rule is for regular expressions (at some point I may embrace re.X to allow me to break those up, too). re.X is a pretty cool tool for making huge regexes

Re: In defence of 80-char lines

2013-04-04 Thread Jason Swails
On Thu, Apr 4, 2013 at 8:39 AM, Roy Smith r...@panix.com wrote: In article mailman.96.1365077619.3114.python-l...@python.org, Jason Swails jason.swa...@gmail.com wrote: The only time I regularly break my rule is for regular expressions (at some point I may embrace re.X to allow me to

Re: In defence of 80-char lines

2013-04-04 Thread llanitedave
On Thursday, April 4, 2013 4:52:38 AM UTC-7, Roy Smith wrote: In article c338b844-e9ce-46a7-9daf-203743723...@googlegroups.com, llanitedave llanited...@veawb.coop wrote: I would hate to have to break up this line, for instance: self.mainLabel.SetFont(wx.Font(12, wx.DEFAULT,

Re: In defence of 80-char lines

2013-04-04 Thread Neil Cerutti
On 2013-04-04, Roy Smith r...@panix.com wrote: re.X is a pretty cool tool for making huge regexes readable. But, it turns out that python's auto-continuation and string literal concatenation rules are enough to let you get much the same effect. Here's a regex we use to parse haproxy log

Re: In defence of 80-char lines

2013-04-04 Thread Mitya Sirenef
recommendation to limit lines to 80 characters. (Strictly speaking, 79 characters.) Here is a good defence of 80 char lines: http://wrongsideofmemphis.com/2013/03/25/80-chars-per-line-is-great/ I think one important consideration that wasn't mentioned yet is one of Python principles

Re: In defence of 80-char lines

2013-04-04 Thread Joshua Landau
On 4 April 2013 12:09, Tim Chase python.l...@tim.thechases.com wrote: On 2013-04-04 08:43, Peter Otten wrote: llanitedave wrote: self.mainLabel.SetFont(wx.Font(12, wx.DEFAULT, wx.NORMAL, wx.BOLD, faceName = FreeSans)) I think I would prefer labelfont = wx.Font( pointSize=12,

Re: In defence of 80-char lines

2013-04-04 Thread Kushal Kumaran
Roy Smith r...@panix.com writes: In article mailman.96.1365077619.3114.python-l...@python.org, Jason Swails jason.swa...@gmail.com wrote: The only time I regularly break my rule is for regular expressions (at some point I may embrace re.X to allow me to break those up, too). re.X is a

Re: In defence of 80-char lines

2013-04-04 Thread jmfauth
hate, or ignore, PEP 8's recommendation to limit lines to 80 characters. (Strictly speaking, 79 characters.) Here is a good defence of 80 char lines: http://wrongsideofmemphis.com/2013/03/25/80-chars-per-line-is-great/ -- Steven - With unicode fonts, where even the monospaced fonts

Re: In defence of 80-char lines

2013-04-04 Thread Jason Swails
://www.python.org/dev/peps/pep-0008/ With perhaps one glaring exception: many people hate, or ignore, PEP 8's recommendation to limit lines to 80 characters. (Strictly speaking, 79 characters.) Here is a good defence of 80 char lines: http://wrongsideofmemphis.com/2013/03/25/80-chars-per-line

Re: In defence of 80-char lines

2013-04-04 Thread Roy Smith
In article mailman.111.1365096868.3114.python-l...@python.org, Kushal Kumaran kushal.kumaran+pyt...@gmail.com wrote: Is using csv.DictReader with delimiter=' ' not sufficient for this? I did not actually read the regular expression in its entirety. I believe your second sentence answers

Re: In defence of 80-char lines

2013-04-04 Thread Steven D'Aprano
On Thu, 04 Apr 2013 13:28:04 -0700, jmfauth wrote: With unicode fonts, where even the monospaced fonts present char widths with a variable width depending on the unicode block (obvious reasons), speaking of a text width in chars has not even a sense. A properly-designed Unicode monospaced

In defence of 80-char lines

2013-04-03 Thread Steven D'Aprano
. (Strictly speaking, 79 characters.) Here is a good defence of 80 char lines: http://wrongsideofmemphis.com/2013/03/25/80-chars-per-line-is-great/ -- Steven -- http://mail.python.org/mailman/listinfo/python-list

Re: In defence of 80-char lines

2013-04-03 Thread Andrew Berg
While I agree that not having a line take up hundreds of characters is a good thing, 80 is really arbitrary in 2013 and having any self-imposed hard limit is silly. When you put a single 4- or 5-character word on a new line because you don't want to go over 80 (or 120 or whatever), the code is

Re: In defence of 80-char lines

2013-04-03 Thread Mitya Sirenef
On 04/03/2013 09:59 PM, Andrew Berg wrote: While I agree that not having a line take up hundreds of characters is a good thing, 80 is really arbitrary in 2013 and having any self-imposed hard limit is silly. When you put a single 4- or 5-character word on a new line because you don't want

Re: In defence of 80-char lines

2013-04-03 Thread llanitedave
I also tend to prefer a maximum between 110 and 120 characters. I find continuation lines confusing, and when you use some third-party tools, such as wxPython, for example, the boilerplate code leads to some long lines. I would hate to have to break up this line, for instance:

Re: In defence of 80-char lines

2013-04-03 Thread rusi
-imperative-in-functional.htmlith perhaps one glaring exception: many people hate, or ignore, PEP 8's recommendation to limit lines to 80 characters. (Strictly speaking, 79 characters.) Here is a good defence of 80 char lines: http://wrongsideofmemphis.com/2013/03/25/80-chars-per-line-is-great